PDA

View Full Version : Bug in Cg sample demo



SirKnight
06-13-2002, 02:45 PM
The sample program called "cgGL_vertex_sample.c" has a bug in the cg shader. The problem is in the #pragma bind's. The first one is ok where it binds appdata.postion with ATTR0, but the other two is the problem. Where in the example is shows:

#pragma bind appdata.normal = ATTR1;
#pragma bind appdata.color = ATTR2;

Should read:

#pragma bind appdata.normal = ATTR2;
#pragma bind appdata.color = ATTR3;

ATTR1 is the vertex weight, NOT the normal. http://www.opengl.org/discussion_boards/ubb/smile.gif Simple mistake is all.

If I find anything else ill post.

-SirKnight

[This message has been edited by SirKnight (edited 06-13-2002).]

SirKnight
06-13-2002, 02:48 PM
Oh ya i almost forgot one other bug. Where the actual drawing with glVertex and whatnot is done, right after that this func is called:

cgGLDisableProgramType(cgFragmentProfile);

This should be:

cgGLDisableProgramType(cgVertexProfile);

Wierd how it still works fine with out changing it to cgVertexProfile.

-SirKnight

[This message has been edited by SirKnight (edited 06-13-2002).]

jra101
06-13-2002, 03:05 PM
These have been fixed and will be in the next release.

Thanks for the bug report! http://www.opengl.org/discussion_boards/ubb/smile.gif

davepermen
06-13-2002, 11:45 PM
sorry to bitch you sirknight, but this is offtopic.

please move over to this forum: http://www.cgshaders.org/forums/

http://www.opengl.org/discussion_boards/ubb/smile.gif

take it easy

SirKnight
06-14-2002, 05:30 AM
Whats wrong with reporting bugs about something from NVIDIA? People do it all the time with driver bugs. That is just as "off topic" as this. This really isnt offtopic though. Its not like im asking how do i texture map a quad in opengl. Or how do i declare a pointer to a function. See, i also knew that jra101 was here so i just posted the bugs here. Plus i wanted everyone else here to see it and fix it themselfs if they wanted to.

-SirKnight

richardve
06-14-2002, 05:34 AM
There are NVIDIA people on the Cg forum too..

davepermen
06-14-2002, 05:45 AM
why it is offtopic?
because its a question/report about cg, not gl (the first one). for cg-stuff, go to the cg forum. thats what it is for

it was just a joke man.. but in every joke there is some truth anyways..

as i said
take it easy

jra101
06-14-2002, 09:39 AM
We do browse the Cgshaders forum as well so this kind of stuff should probably be posted there http://www.opengl.org/discussion_boards/ubb/smile.gif

SirKnight
06-14-2002, 10:34 AM
Well you see you have to keep in mind that at the time i did not know about the cgshaders.org website. I just d/l'ed the compiler from nvidia and started playing with it. It wasnt untill later on that day (after i posted my bug report) that i found out about that site.

Yes i do know there are nvidia people at that cg forum too. I found that out last night also.

And actually, i dont care if my post WAS offtopic. Everyone here has made off topic posts before. You know, i dont even know why im arguing with this. Its totally stupid. Normally i ignore the comments like "this post is off topic go elsewhere...blah blah blah" and stuff like that. O well, i really dont care, lets just end this. :p

-SirKnight

Deiussum
06-14-2002, 10:42 AM
SirKnight should be publicly flogged and humilated for posting this off-topic post! http://www.opengl.org/discussion_boards/ubb/smile.gif (j/k)

Seriously, guys, what's the big deal. It's not like he was posting things I've seen like, "Quake 3 keeps giving me OpenGL errors, what do I do?," by some newbie who doesn't understand that this is the programmer's forum and not a technical support forum for OpenGL games.

Lighten up a little.

In daveperman's defense, I originally thought he might have said it in a joking manner, but I couldn't be sure...