|
Occlusion query
#264824
05/08/09 12:27
05/08/09 12:27
|
Joined: Aug 2004
Posts: 1,345 Kyiv, Ukraine
VeT
OP
Serious User
|
OP
Serious User
Joined: Aug 2004
Posts: 1,345
Kyiv, Ukraine
|
I have a project with a huge cube, each side if it consists of panels. Some of them are on the other side of the cube, so they are not visible( they are rendered and eat FPS, but not visible for the camera). First, i thought about a trace from every panel to camera to know, if it is visible... But it isnt good idea, as i'd need as many traces, as many panels i have. Second idea - it to calculate camera's angle... With the help of it, i increase FPS from 80 to 120-140, that depends of the visible blocks (as other sides of the cube are invisible)... So, the question: is there a build-in(or is it possible) function for culling models, that invisble for camera? Something like this: http://www.codesampler.com/dx9src/dx9src_7.htm#dx9_occlusion_query
|
|
|
Re: Occlusion query
[Re: VeT]
#264836
05/08/09 13:06
05/08/09 13:06
|
Joined: Aug 2004
Posts: 1,345 Kyiv, Ukraine
VeT
OP
Serious User
|
OP
Serious User
Joined: Aug 2004
Posts: 1,345
Kyiv, Ukraine
|
jcl, but i'd needed to run through all panels each frame(compare their orientation)... I'm afraid, it would be little bit slow.
I solved this, just checking position of camera (looking like its the fastest method), and hiding some panels, if camera.pan<a1 and camera.pan>a2 I was just curious if there are(or, probably, "would be") some kinds of culling in nearest time? I think that it could be useful in large numbers of another cases, where camera position would'nt be enough.
|
|
|
Re: Occlusion query
[Re: VeT]
#264839
05/08/09 13:10
05/08/09 13:10
|
Joined: Jun 2008
Posts: 151 Ukraine
XD1v0
Member
|
Member
Joined: Jun 2008
Posts: 151
Ukraine
|
A7 Commercial Celeron 1700, GeForce 5500 FX 256mb, 1 Gb Ram
|
|
|
|