You should have it be more consistent with the other PP effects:
[code]
function DrawToyTown( NumPasses, H )
cam.Start2D()
surface.SetMaterial( _Material )
surface.SetDrawColor( 255, 255, 255, 255 )
for i=1, NumPasses do
render.UpdateScreenEffectTexture()
surface.DrawTexturedRect( 0, 0, ScrW(), H )
surface.DrawTexturedRectRotated( ScrW() * 0.5, ScrH() - H * 0.5, ScrW(), H, 180 )
end
cam.End2D()
end
local function DrawInternal()
if ( !pp_toytown:GetBool() ) then return end
if ( !GAMEMODE:PostProcessPermitted( "toytown" ) ) then return end
if ( !render.SupportsPixelShaders_2_0() ) then return end
local NumPasses = pp_toytown_passes:GetInt()
local H = ScrH() * pp_toytown_size:GetFloat();
DrawToyTown( NumPasses, H )
end[/code]
So other scripts can run the effect.
Anyone fancy upload a screen shot of what this looks like?
Yeah, I'd like to see this too.
[media]http://filesmelt.com/dl/gm_flatgrass00177.jpg[/media]
[editline]17th February 2011[/editline]
Height goes from 0 to 1, 0 being not covered, 0.5 being the screenshot, 1 being gaussian blur
Passes go from 1 to 100, 1 being barely blurry, 20 being the screenshot, 100 being ridonc blur (and ridonc fps drop)
[editline]17th February 2011[/editline]
[url]http://en.wikipedia.org/wiki/Tilt-shift_photography[/url]
Sorry, you need to Log In to post a reply to this thread.