@Raven
"ya know i'm tired of trying to get you to see,"
Same here only vice versa.
"firstly your posting examples which aren't identical sections of code"
I know that. Although I considered it, I figured that if I posted identical sections of code you would just say that they are both cg and not HLSL. I figuared if I used an example from microsoft and one from Nvidia you couldn't deny that they were accurate and are almost identical. Apparently I was being over optimistic.
"and even so they're being done differently."
No they aren't. Oh, yes, they do different things but their syntax is identical. Perhaps a little refresher will help jog your memory.
The HLSL code:
///////////////////////////////////////////////////////////
// Vertex Shader /////////////////////////////////
///////////////////////////////////////////////////////////
struct VS_OUTPUT
{
float4 Pos : POSITION;
};
VS_OUTPUT SimpleTransform(float4 iPos : POSITION)
{
VS_OUTPUT o;
// Project the position into screen space
o.Pos = mul(iPos, g_mTot);
return o;
}
The Cg code:
struct myVertexOut {
float4 lightVec : COLOR0;
float4 texCoord0 : TEXCOORD0;
float4 texCoord1 : TEXCOORD1;
};
float4 main(myVertexOut I,
uniform sampler2D colorMap,
uniform sampler2D normalMap) : COLOR
{
float4 texColor = tex2D(colorMap, I.texCoord0.xy);
float4 normal = 2 * (tex2D(normalMap, I.texCoord1.xy) - 0.5);
float3 light_vector = 2 * (I.lightVec.xyz - 0.5);
float4 dot_result = saturate(dot(light_vector, normal.xyz).xxxx);
return dot_result * texColor;
}
Both of these have output stuctures and binding semantics like positon. Its just that my Cg example is one half of a lighting shader and my HLSL example is just a very simple test concept that doesn't really do anything of note. But perhaps I'm missing your elusive point. Please, why don't you point out to me out of these two examples what exactly is so different about them(syntax wise, I know one does more than the other, that much is painfully obvious). Heck, I'll even be nice to you and let you take another example from somewhere else and offer that as proof that Cg is "ALOT different" than HLSL.
"just because there are similar syntax they're still different"
This is getting ridculous. Look, if case you haven't figured it out already, the are basically the same. If you write a working shader in HLSL and try to compile it with the Cg compiler you will succeed. It is simple as that. They are not vastly different and you know that. If they were vastly different then you wouldn't be able to compile it.
"and more importantly you can use then ALOT differently."
There is nothing inherent in either language that allows it to be used in a way that the other language could not. HLSL code will compile in a Cg compiler and Cg code will compile in a HLSL compiler. HLSL code will work with the Cg runtime and Cg code will almost always work with DirectX 9 commands like D3DXAssembleShaderFromFile.
PROVE ME WRONG.
"Cg is alot like Renderman Shaders Language - if you want to understand how that is used rather than how HLSL is used perhaps you might actually have a better grasp of what the languages does."
In syntax they are alike but so is HLSL. Are you saying that Cg is a software shader language because that is what the Renderman Shading Language is? You can't be serious, can you?
"The Interface appliaction of language within C++ is JUST as important as the actual language code itself"
No, it isn't. You can use Cg without the Cg runtime as I've demonstrated before. As nice as the Cg runtime is, it is not by any strech of the imagination nescarry to use Cg.
"you're aruging that these are just runtime compilers "
Basically, yes they are. There is more too them then that, but that is there primary function and the purpose of there exsistence. If you don't believe me look at the reference I gave you to the Cg runtime help file. It explains it in there.
"but the fact of the matter is they don't compile on runtime unless you use that interface "
This isn't true. You can compile a Cg shader during runtime with the microsoft fxc compiler. Their syntax is bascially identical remember? What works in one will work in the other.
"and infact you have to compile all of your code anyway prior to use even if you're using ASM Shaders you're still compiling them first from ANSI to Machine "
I'm well aware of that. In fact I told you this before. Why are you repeating what I said? Oh and it can compile Unicode as well as ANSI.
"so your point about compiling them really is an entire misnomer wouldn't you agree?"
If I had any idea where your mad train of thought was going I could probably answer that question. How exactly is my point about compiling(where did I make this point?) them an entire "misnomer."
You are making little sense here.
"it is clear you just won't accept how these things work,"
The irony. It overwhelms me.
"and you want to think in arcaic terms to thier implimentation"
Huh? How am I thinking in archaic terms? How is the Cg runtime an Archaic term? How is the directx 9 API an Archaic term? I think you have this backwards.
"if you want to think like that then fair enough do that, "
Ok.

Question is will you think that(ie Correctly)?
"you loose out on the performance increase"
What performance increase? As I have shown you before they both go through the API and Cg does not "directly access the hardware layer."
The only performance increase you will get is with the fp30 profile on Nvidia hardware. Remember how I always prefaced my comparisons of Cg to HLSL with "basically"? There is one major difference between the two to my knowledge and that is the support of the
fixed data type. The fixed data type is exculsive to Nvidia hardware and is for their CineFX hardware fragment shaders. The microsoft fxc compiler doesn't support the fixed data type. So there you have it. Your alleged vast performace increase really only applies to 4th generation Nvidia hardware pixel shaders. Hardly something I would lose any sleep over if I were you.
"and you also loose out on the depth the language is there to provide."
What exactly is it that I'm doing that would make me miss out on the depth of the language hmmm? Or is this just some rhetorical device of yours? As far as I can see the "depth of the language" is exactly as deep as HLSL considering they are pretty much one and the same.
"finally as for the code, i didn't just write the bloody shader files,"
<sarcasm>Sure you did, Raven. I believe you.</sarcasm>
"although the Cg in themselves also have trademark hints to whomever wrote them "
Like what? Care to elaborate or are you just going to ignore this question like all of the other valid ones that I pose to you? Or maybe you are just stalling for time desperately trying to invent some distinction in the code where there is none. Funny, how you still haven't said which ones you wrote or given any reasonable method to determine their ownership.
"but i also wrote the C code that accompanies them with Robert James."
Ahh. A name. Finally we are getting somewhere. Sadly, you still haven't given me a way to determine if you wrote them or not.
"if you think that each persons coding styles is identical"
I never said that. Go back and read what I said. I said that a persons coding style is not a finger print. There are differences but there are also overlapping simularities as well. If you worked with another person on a large project there style might become appartent to you but it doesn't mean that if you line up a series of files that they will be able to determine the author with any sense of accurary. Programming languages are generally too restrictive in syntax to allow for any sense of "style" to become overly developed and apparent.
The exeception to this is with comments. Since comments aren't necessarily bound by any rules of grammer other that what it takes for the compiler to skip over them(with this I am refering to // or /* */ like in C or ; in ASM) an individualistic style can become apparrent. It is amazing what amusing comments or scatological references can do to the individiuality of a piece of code.
But, that aside, this exception doesn't really apply to shaders for they are not long enough or commented enough for any real stlye to become apparrent.
"and you can't tell them from how they code then christ you've never coded with another sole in your entire life have you?"
Now here you are correct. I have never coded with another person's shoe before in my life.

But seriously, if this is so obvious to you then why don't you just point out the differences that seperate your code from your partners? You do recognize your own code don't you? If you do then you should have no trouble at all. I on the other hand have no Idea what your code looks like since I've never seen you code in C in my life.
"have you even looked around the forums for programming or even around here to see how each person programs "
Yes. Occasionally.
"it is very oftenly a unique affair,"
That is because DBPRO is using a basic syntax which allows for a lot of lee way with how you can code things. A C-style syntax, however, doesn't give you a whole lot of lee way and since we are talking about Cg this is a rather moot point.
"just because on person made cose which looks similar to say Lee DBpro code - there are still things about it that will look unique."
Unique. Yes. To that person alone? I think not. Still, it is nice that you finally recognize that there is some overlap between styles. It makes my next point easier to grasp.
It is impossible to tell with any sense of accurarcy who coded a paticular piece of code. You may be able to narrow it down to a paticular pool of possible programmers but you will never know exactly. Programming is not a fingerprint! NO ONE has a completely 100% unique style. There is always someone somewhere who will have a style identical to theirs.
It is just not possiable given the restrictions of the language to have a 100% unique style that you can tell from someone elses.
" This isn't just about programming but every god damn'd aspect in life,"
Since when did this become about "every god damn'd aspect in life"? And how would you know this?
"if someone repairs your car - a mechanic in the
same garage would be able to tell you how did it and probably be able to tell if a problem happened because of it."
Keyword. Same. Accepting for a moment that this is true(which it might be in some cases but I can tell you for a fact that it isn't in all or even nearly the majority. In fact it probably only happens in rare instances and only with cetain kinds of repairs) how would I know what someone elses style was if I was not in the same "garage" so to speak? If you just took your car and got it fixed by one mechanic then showed the repair to another mechanic in another state do you really think he would be able to tell who repaired it? What makes your analogy even possiablely true is that the mechanics are in the same garage and have gotten to know how each other work. I am not in the same "garage" as you Raven so how would I know how you work like? Please answer this point before you make another affirmation that "programming is like a fingerprint" or something like that. You'll just be wasting both our times.
"stop having you nose in the books all the bloody time and get some actual field experience,"
So now I have my nose in books all the time, eh? Raven, you don't know a thing about me so don't pretend to. While we our on the topic of books, heres a thought, pick one up and actually learn the language. If you did that then you wouldn't be caught with your pants down trying defend some ridiculous notion you picked up off the net somewhere like "Vertex shaders 1.2,1.3,1.4."
Hearsay != Knowledge.
"each time you post it does become more and more apparent you don't seem to have a clue what is going on "
What exactly is it about my posts that makes it apparrent that i don't know what is going on? Is it when you prove how wrong I was about...oh...wait...you haven't actually proved me wrong yet on anything have you? Need I even list the number of misconceptions and falsehoods you posted to me that I proved wrong? The Sad part of all this is you just can't see the irony of you lecturing me on how little I know when it is I who has to correct YOU about YOUR misconceptions. Do yourself a favor Raven and take one big look at yourself before you begin to critize.
"your just taking from examples you see hoping that noone will notice you don't have a bloody clue,"
Where exactly did I take examples? Was it with the vertex shaders that were in Cg and HLSL? I took those for a reason and I already explained it to you. It was so you couldn't deny the accuracy of the examples. You have a habit of deny the crap out of anything I post to you Raven just like you are doing now. Not that you ever take examples and hope that nobody finds out you are bluffing *cough*directx 9 sdk help files and vertex shaders 1.2,1.3,1.4*cough*
"hoping that the text will back you up."
I don't hope. I know. Unless you would like to cite an example of text i provided that didn't back me up? No? Didn't think so.
"IT WON'T ... all your showing is you know howto read and take in overviews "
An excellent skill. Might I suggest you learn it? It would be less embarassing for you to be contradicted by the overviews all the time.
"my 5yo cusion can do that,"
So why can't you?
"doesn't mean he know howto use a language "
True. But he is 5 and I am most certainly not. My compacity to learn from said manuel and then apply the CORRECT knowledge is vastly superior.
"but he can repeat a manual quite well."
Good. Maybe he can read you this one.
http://developer.nvidia.com/view.asp?IO=cg_specification