Im currently using the D3DXSprite object to display my interface and this im stretching the same border picture for most of my interface.
I have code that shows you how to load any picture as a Dx7 surface, and how to merge them onto screen, but my 3D objects are using the Mesh.DrawSubset. How can i use surfaces for the interface and the DrawSubset method?
Also, i want to use lookup tables for my cos/sin calculations. Im using radians (2xPI = 360) so i dont need to convert all the time. Im also storing the angle as a double, how can i implement the lookup tables?
Well i now have code for dx8 that allows me to load a picture into a dx8 surface. I can put the image in the backbuffer before or after the 3D scene is rendered and that works, but i cant make the center of the surface transparent.
I need to do it this way so that it clips the 3D shapes so they dont display on top of my interface.
The f***ing backsurface just hides all my nice 3D work : (
Im using this method
Set surfPic = D3DDevice.CreateImageSurface(800, 600, D3DFMT_R5G6B5)
You can do very good 2D work in DirectX 8, if you use a vertex type which is closer to the old D3D_TLVERTEX type then you can make a screen-sized rectangle out of 2 triangles made with 4 vertices. Then you can use normal 3D rendering techniques to apply the texture, transparencies, or alphablending that you need.
Hi, i can do that but when i load the textures in they'll be resized to 256x256 maximum (voodoo 3). Im trying to get round this by creating my graphic at the correct size and resizing it to 64 x 64 or 128 x 128 etc... Hopefully when its stretched it wont lose too much in quality.
Im using 3D spheres for planets (seemed like a good choice : ) and i move the camera about. is there a way that i can force the geometry of the interface to be 2D, otherwise as i move the camera the interface will move out of view.
Also has anyone come up with a good way to popup a directx window and halt processing till an answer is received? I mean drawing a window not showing a vb one. Im having to use screen IDs to let me know where the user is.