NVIDIA Cg Compiler Technology to be Open Source
Jim Norton writes "This announcement from nVidia states that
their Cg compiler technology for 3D applications will be Open Source and available under a free, unrestrictive license. The ETA for this is in August and will be available here." The linked company release says it will be under "a nonrestrictive, free license," but does not give further details. BSD?
What's a "Cg compiler"
Cg compiler stands for "C for Graphics"
People who write pixel shaders ( those nice little algorithms that makes games pretty ) for things like fog effects, lighting etc have to use some low level assembly ( which is sometimes tied to the card as well ). This will allow for a higher level language so you can use do loops, for next etc. with writing shaders and for possible expanded ( cross card ) support
I've been coding in Cg for some time, there have been a number of problems I've faced so far:
1. The vertex engine calls are not logical. Sometimes you call passing a referenced pointer, other time you have to pass a referenced strucute, some form of standarization to calls would have made it easier for developers to write function calls (more insane than POSIX threads).
2. The lanugae is not truely Turning complete. Which could have been fixed by taking some more time and making the language more complete.
3. The compiled bytecode is giving a security mask that disables it's use on chips that do not carry a compliment decoder (To keep competetors away?).
4. Confusing definitions of pointer/references. They could have made this easier by removing the entire pointer usage.
5. Class calls outside of friend functions can at certain times reach memory outside of parent definitions (Bad language design?! I think this is one of the most debated feature/bug, since you can piggyback this to implement vertex calls within lighmaps).
6. No SMP support in current implmentation and no thoughts to future support (What about threading?!).
7. Inlining support is bad and possibly unusable outside the scope of inling cg within c.
Please read here:
http://www.cgshaders.org/contest/
As you can see from the terms and conditions on that CG site, they favour and link to the ZLib license.
I think that CG will be under the PHP/ZLib license.
I'm not sure if it will help, but you can read more about Cg Here.
File under 'M' for 'Manic ranting'
They dont need to open source to port it to *BSD. But it would make developing simpler. It seems you have fallen victim to the assumption that closed source is evil. It can be a good thing in a comptative system. Nvidia doesnt need to open their drivers just port them. Last time I checked Creative didnt have open drivers for the SoundBlaster cards but they run just fine on Linux (I have not checked for BSD support and dont really plan on doing it). That is an example of a company with a great product that is cross platform compatible. Open drivers are nice but ultimatly not that important. It's the existance of drivers that is the issue.
This is how you know you're a geek the power goes out and you are unemployed and unemployable. Yes I know I can't spell
I thought the whole reason they made a new language (Cg) is because the chipsets weren't Turing complete. If they WERE Turing complete, then it would be a complete waste of time to make a new language -- just make a new back-end for your favourite C compiler and write a bit of run-time.
However, the chips themselves can't do very much -- they can't do a conditional branch, for example. This makes it quite difficult to make a C compiler target them :)
It would be very cool to just be able to do gcc -b nvidia-geforce9 ... or what have you since you'd be able to take advantage of a rich existing toolchain. But, alas, it's not to be.
They have kick-ass products that officially support my platform of choice. 'Nuff said. :-)
Karma whorin' since 1999
Theoretically, you don't need source to port to BSD. The kernel driver has an abstraction layer (which comes in source form) and is fully portable. The XFree86 module (by design of the XFree86 driver model) is platform independent and can be loaded on any x86 OS. As it stands, it is not in NVIDIA's best interest to release the driver code. First, parts of it are copyrighted by other parties. Second, you can bet that ATI and Matrox would love to get their hands on it. Remember, an OpenGL ICD is an entire OpenGL implementation, not just a hardware banger. That makes the situation rather unique. ATI has some hardware that could be seriously compatitive with NVIDIA's if it had proper drivers. Why should NVIDIA jepordize their company to placate 0.01% of its users?
A deep unwavering belief is a sure sign you're missing something...
NVidia cannot release the source code due to parts which are not belong to them (they belong to SGI and other parties)...
SGI has said, on a number of occaisions, that they are not at all involved in keeping the nVidia driver closed source. They have also stated that they are in favor of open sourcing the driver.
Dinivin