Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / Blitzwerks Terrain fullscreen shader

Author
Message
Superbeest
21
Years of Service
User Offline
Joined: 9th Mar 2003
Location: Netherlands
Posted: 4th Sep 2011 11:03
I'm trying to apply a fullscreen shader to my project with Blitzwerks Terrain.
I've got this partially working, as all the object I create using make object xxxx are working with the fullscreen shader. The shader does get applied to the terrain, but only when my basic primitives are in line with the camera. I've added an example project with a cube and sphere (below the start point).

I use set object mask to make sure the specific objects are rendered only to the correct camera, so i don't have to hide/show all the object lateron when outputting the fullscreen shader. However, if I apply the set object mask to the bt object, this does not work. Nor does the BT SetCurrentCamera help here. Can you guys give me any directions as what I might do to apply the fullscreen shader to the terrain?

Also, I found that while using BT SetTerrainQuadReduction, I get some nice gaps (see image). I can also see these gaps in the QuadReduction demo. Any clues on how to resolve these, or is it just because of the demo heightmap used?

Attachments

Login to view attachments
kaedroho
17
Years of Service
User Offline
Joined: 21st Aug 2007
Location: Oxford,UK
Posted: 8th Sep 2011 23:35 Edited at: 8th Sep 2011 23:43
Hi Superbeast,

The Quad Reduction thing is a known issue. Quad Reduction is currently an experimental feature. I'm not sure whats causing it but I will have a good look into it for the next release. I will also look into making it reduce more (it currently doesn't reduce around the edges of sectors).

To solve the issue with masking, you need to render the terrain manually. I will implement object masking into the auto render for the next release (now on the todo list!).

Manual rendering lets you tell Blitzwerks Terrain when and where to render terrains. Its the way Blitzwerks Terrain used to do rendering in the old days, but people said it was too complicated so I added Auto rendering.


Heres how to render manually:

Firstly, remove this line from world.dba
BT EnableAutoRender 1


Also remove this: (this isn't correct useage of this function)
BT SetCurrentCamera %10


Next replace your render scene function with this:



The terrain should only render to camera 1

Your signature has been erased by a mod please reduce it to no larger than 600 x 120.
Superbeest
21
Years of Service
User Offline
Joined: 9th Mar 2003
Location: Netherlands
Posted: 9th Sep 2011 21:31
Hi kaedroho,

Thanks for your clear reply. I'll be looking forward to your next release of Blitzwerks Terrain.

I must be forgetting something, or overlooking something, as I cant seem to render the scene using the given examples. Attached is the result I'm getting.
It seems the terrain is now only rendered, when one of the primitives is in view.

If you have the time, could you please have another look at it and perhaps point me in the right direction?

Attachments

Login to view attachments

Login to post a reply

Server time is: 2024-11-22 16:31:45
Your offset time is: 2024-11-22 16:31:45