Simple Direct3D

Started by
0 comments, last by Trip99 19 years, 9 months ago
Can anyone please give me a small piece of code that plots pixels/draws line in Direct3D? I have already successfully created the surface etc. but would really appreciate a simple drawing example. Cheers!
Advertisement
Direct3D nowadays is so heavily geared up to 3D hardware accelerated graphics that the old days of pixel plotting and line drawing are tricky to implement - at least at a decent speed. If you have the surface you can lock it and obtain a pointer to the data, use the pixel format and pitch and calculate the offset for pixel plotting etc. for line drawing you just need to implement your own bresenham.
------------------------See my games programming site at: www.toymaker.info

This topic is closed to new replies.

Advertisement