|
-
Jun 29th, 2001, 11:24 PM
#1
Thread Starter
Good Ol' Platypus
Okay I want to know a few things about D3D:
And Zaei I expect you to answer =).
1. How do you create a point sprite, not radiating light or whatever, like in 3DMark2001 (the horse & female statues)? Most importantly how do you make point sprites, period.
2. How do you tell D3D to create a Hardware Transform & Lighting engine? Right now I'm using D3DCREATE_HARDWARE_VERTEXPROCESSING, but should I be using D3DCREATE_PUREDEVICE?
3. How do you check if the video board in question supports FSAA? I have a function but it doesn't seem to work.
4. How do you check for functionality of pixel-shaders and the like?
All contents of the above post that aren't somebody elses are mine, not the property of some media corporation. 
(Just a heads-up)
-
Jun 30th, 2001, 01:50 AM
#2
1. Point sprites are just a bunch of RenderStates that you need to set.
Code:
Device.SetRenderState(D3DRS_ZWRITEENABLE, FALSE)
Device.SetRenderState(D3DRS_POINTSPRITE_ENABLE, TRUE)
Device.SetRenderState(D3DRS_POINTSCALE_ENABLE, TRUE)
Device.SetRenderSrare(D3DRS_POINTSIZE, FtoDW(1.0))
Device.SetRenderState(D3DRS_ALPHABLENDENABLE, TRUE)
Device.SetTexture(0, WhateverTexture)
'//Render using DrawPrimitive, with a primitive type of
'// D3DPT_POINTLIST
Device.SetStreamSource(0, myVB, Len(VertexSize))
Device.SetVertexShader(myFVF)
Device.DrawPrimitive(D3DPT_POINTLIST, 0, 650)
Device.SetRenderState(D3DRS_ZWRITEENABLE, TRUE)
Device.SetRenderState(D3DRS_POINTSPRITE_ENABLE, FALSE)
Device.SetRenderState(D3DRS_ALPHABLENDENABLE, FALSE)
That all should work, I just pulled it out of my head =).
2. I think you need to use D3DCREATE_PUREDEVICE, but im not sure (my card doesnt support it).
3. You've got me. Again, my card supports jack...
4. Its a CAPS check. Use Device.GetDeviceCaps(DevCaps), and then look in the DevCaps.PixelShaderVersion. Check the SDK documentation for more info.
Z.
-
Jun 30th, 2001, 09:23 AM
#3
Thread Starter
Good Ol' Platypus
Thanks.
I wanted to see what my new card can support
All contents of the above post that aren't somebody elses are mine, not the property of some media corporation. 
(Just a heads-up)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|