writing a driver

How would I go about writing an OpenGL driver for my card since one doens’t exist for my card? I just downloaded the Windows DDK and I’m looking for either an example of driver source code or the OpenGlL spec that I can write my driver from. I’d prefer example source code since that would give me a better idea of what to do. Anyone know I where I can find some? Thanks.

-AJ

Writing a driver for a foreign, undocumented piece of hardware is very tricky. Not impossible, but pretty freaking close to it. If you’re at the stage where you know exactly how to operate your videocard through hardware then I’m guessing you’d also be smart enough to reverse engineer windows’ driver interface model and thus wouldn’t need to ask us any questions at all because anything we’d say would be beneath you.

Having said that, tho’, you could use Mesa. Its opengl, its accelerated on SOME systems (notably 3Dfx and possibly something else). If you have a more recent video card, then chances are there’s already an opengl driver for you.

Writing your own opengl driver is certainly a non-trivial problem.

cheers
John

The hardest part will be getting information on the how to program the video cards graphics processor. Just like a cpu has a assembly like language the graphics processor has it own language telling it how to draw things, and in which the commands are diffrent for each video card.

But without the above information a opengl drive will be almost imposible to write, even if you can reverse a windows driver for the card, it may not use all of the cards features.

Originally posted by redneckCoder:
[b]How would I go about writing an OpenGL driver for my card since one doens’t exist for my card? I just downloaded the Windows DDK and I’m looking for either an example of driver source code or the OpenGlL spec that I can write my driver from. I’d prefer example source code since that would give me a better idea of what to do. Anyone know I where I can find some? Thanks.

-AJ[/b]

Some considerations:

  • do you know the graphics card through and through: is it capable of doing hardware acceleration in the first place. If not: why bother writing an OpenGL driver, if software rendering is the most you will be able to get.

  • do you have experience in writing graphics drivers (they are not something trivial to write)

  • what do you intend to do with the driver?

  • perhaps changing the card to a card that has OpenGL drivers available is a less painful and quicker solution to the problem

By the way, this certainly would not be a ‘beginners’ question in my opinion, so you could also try in the advanced forum…

HTH and good luck

Jean-Marc.