Jump to content

  • Log In with Google      Sign In   
  • Create Account

Awesome job so far everyone! Please give us your feedback on how our article efforts are going. We still need more finished articles for our May contest theme: Remake the Classics

#Actualslicer4ever

Posted 01 June 2012 - 06:25 PM

if you are using the same texture repeateadly, then you can't "merge" the blood splatter without it being repeated across the entire world.

so, here are some suggestions:

A: depending on the size of each texture, and the number of tiles, you could generate a "super" texture and render your geometry across that 1 super texture, instead of being repeated, as such, when your blood spatter occurs, you can update the texture with glTexSubImage2D, and well probably require storing a client-side version of the texture, so you can blend the blood with the existing texture.

B: forgo the idea of unlimted blood spatter, and reduce it down to something like 100 spatter's or so, and create a triangle rectangle batch, positioned with the terrain(using GL_LEQUAL depth test, and drawn after drawing the terrain), combined with blending, this should sufficiently create your effect, without having too serious of a perfomance hit, particularly if you batch the splatters, and use glBufferSubData to upload them/add/modify existing splatters, and using a counter for counting up the blood spatters and controlling where to write the next blood splatter into.

those are really the best available actions you can take imo, but perhaps someone else well have a better idea.

#2slicer4ever

Posted 01 June 2012 - 06:24 PM

if you are using the same texture repeateadly, then you can't "merge" the blood splatter without it being repeated across the entire world.

so, here are some suggestions:

A: depending on the size of each texture, and the number of tiles, you could generate a "super" texture and render your geometry across that 1 super texture, instead of being repeated, as such, when your blood spatter occurs, you can update the texture with glTexSubImage2D, and well probably require storing a client-side version of the texture, so you can blend the blood with the existing texture.

B: forgo the idea of unlimted blood spatter, and reduce it down to something like 100 spatter's or so, and create a triangle rectangle batch, positioned with the terrain(using GL_LEQUAL depth test, and drawn after drawing the terrain), combined with blending, this should sufficiently create your effect, without having too serious of a perfomance hit, particularly if you batch the splatters, and use glBufferSubData to upload them/add/modify existing splatters, and using a counter for counting up the blood spatters.

those are really the best available actions you can take imo, but perhaps someone else well have a better idea.

#1slicer4ever

Posted 01 June 2012 - 06:22 PM

if you are using the same texture repeateadly, then you can't "merge" the blood splatter without it being repeated across the entire world.

so, here are some suggestions:

A: depending on the size of each texture, and the number of tiles, you could generate a "super" texture and render your geometry across that 1 super texture, instead of being repeated, as such, when your blood spatter occurs, you can update the texture with glTexSubImage2D, and well probably require storing a client-side version of the texture, so you can blend the blood with the existing texture.

B: forgo the idea of unlimted blood spatter, and reduce it down to something like 100 spatter's or so, and create a triangle batch, positioned with the terrain(using GL_LEQUAL depth test, and drawn after drawing the terrain), combined with blending, this should sufficiently create your effect, without having too serious of a perfomance hit, particularly if you batch the splatters, and use glBufferSubData to upload them/add/modify existing splatters, and using a counter for counting up the blood spatters.

those are really the best available actions you can take imo, but perhaps someone else well have a better idea.

PARTNERS