How to get a screenshot without drawing the object?
I want to generate the screenshot of a set of .x models, but I do not want to use the D3DDevice to draw''em on screen. Any one got the idea, thanks!
You''ll find it tough.
If you did use Direct3D to do it, you could just use D3DX to load it, render it to a texture, and then save out that texture.
If you''re not, you''ll have to write your own .X file loader and renderer.
If you did use Direct3D to do it, you could just use D3DX to load it, render it to a texture, and then save out that texture.
If you''re not, you''ll have to write your own .X file loader and renderer.
You could use a modeling program, such as 3D Studio or Truespace. Or you could write it in OpenGL.
Chris
Chris
You could always create the device, but indicate that you want it in windowed mode, and pass it a handle to a window that is hidden. Then you can use the device to render to a texture, as superpig suggested. So although you technically do have a device and a window and everything, it doesn''t really look like it. You won''t have to worry about mode-changes, unnecessary windows popping up, etc. Or at least, I would think that this should theoretically work...
SetRenderTarget() to a surface -> Save surface.
--
You''re Welcome,
Rick Wong
- Google | Google for GameDev.net | GameDev.net''s DirectX FAQ. (not as cool as the Graphics and Theory FAQ)
--
You''re Welcome,
Rick Wong
- Google | Google for GameDev.net | GameDev.net''s DirectX FAQ. (not as cool as the Graphics and Theory FAQ)
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement