checking shadow tutorial compatability

Blitz3D Forums/Blitz3D Programming/checking shadow tutorial compatability

Kalisme(Posted 2007) [#1]
Hi all, I was visiting the TAFE today, so I decided to grab a shadow tutorial off my computer to post on the site... but once I got here, I noticed a major differance in the appearance of the effect once I ran it on the TAFE computers... On mine, it runs fine and creates a shadow... on this computer I'm currently on it blurs with the past shadow creating a very odd motion blur with the shadow texture. I'm pretty sure I know what's causing it.. but I want to know if it's a common accurance.
here is the code:


Sorry it's written oddly, I was writting it as a tutorial.
(not really finished... I should shorten it)
I think the conundrum lies in the fact I was lazey here and tried to hide everything that wasn't the caster, with fog... my card seems to block everything in the haze... (so that's what I had in mind while writting it), but this card lets objects remain visable through the fog...
Is this common?

Oh well, while I'm talking about the tutorial, I want to point out the focus of the long winded tutorial I wrote was actually just these lines:
For s=1 To CountSurfaces(s_receiver) 
	surf=GetSurface(s_receiver,s) 
	For v=0 To CountVertices(surf)-1 
		TFormPoint VertexX(surf,v),VertexY(surf,v),VertexZ(surf,v),s_receiver,s_camera
		VertexTexCoords surf,v,(TFormedX()/Xscale#)/32+0.5,1-((TFormedY()/Xscale#)/32+.5) 
	Next 
Next 

It casts the texture directionly across the mesh.
This can be used in other ways aswell, such as flashlights.
I hope this helps, plese check it out, best of luck.

the controls are:
"left arrow" - lowers the Xscale# variable.
"right arrow" - highers the Xscale# variable.
"esc" - quit.
(this will make the shadow clearer... when you first start it up, you'll have to lower the Xscale# variable by tapping the left arrow about 6 times before you'll see a nice-ish kinda shadow.)


Stevie G(Posted 2007) [#2]
The blur is showing up here. Hide the s_receiver mesh before the shadow renderworld and then show it after. This sorts the problem.

Cheers.
Stevie