Directx equivalent of picturebox.pset
I am trying to find if there is any directx equivalent to the picturebox's pset function. I want to color a few individual pixels of a picture box using directx8.
This is a common source of confusion and frustration for DirectX developers who have newly migrated from GDI and the likes.
There is no particularly efficient method for dynamic per-pixel access of DirectX surfaces. The functionality can be emulated by using LockRect (and it works very well), but this strongly undermines hardware acceleration.
A few workarounds exist, such as rendering D3DPT_POINTLISTs or cannibalising pixel shaders, but you're advised to stick to straightforward shaded/textured geometry as your primary source of visual effects.
Admiral
There is no particularly efficient method for dynamic per-pixel access of DirectX surfaces. The functionality can be emulated by using LockRect (and it works very well), but this strongly undermines hardware acceleration.
A few workarounds exist, such as rendering D3DPT_POINTLISTs or cannibalising pixel shaders, but you're advised to stick to straightforward shaded/textured geometry as your primary source of visual effects.
Admiral
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement