X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Feffects%2Fambientocclusion.cpp;h=96fc7317a9b2fe5727c66f6bdea5362496cd5d76;hb=f73e671dcb36c097647cddbf5b1eaaad2ffc9299;hp=d431bcdd51ea68417a6b285b1b7ba8773542742b;hpb=5bb193f930fb8738d099d630c4d625d82c1215b5;p=libs%2Fgl.git diff --git a/source/effects/ambientocclusion.cpp b/source/effects/ambientocclusion.cpp index d431bcdd..96fc7317 100644 --- a/source/effects/ambientocclusion.cpp +++ b/source/effects/ambientocclusion.cpp @@ -12,7 +12,7 @@ using namespace std; namespace Msp { namespace GL { -AmbientOcclusion::AmbientOcclusion(unsigned w, unsigned h, float): +AmbientOcclusion::AmbientOcclusion(unsigned w, unsigned h): rotate_lookup(get_or_create_rotate_lookup()), occlude_target(w, h, (COLOR_ATTACHMENT,R8)), occlude_shader(Resources::get_global().get("_ambientocclusion_occlude.glsl.shader")), @@ -32,7 +32,7 @@ const Texture2D &AmbientOcclusion::get_or_create_rotate_lookup() { Resources &resources = Resources::get_global(); - static const string name = "_ambientocclusion_rotate.tex2d"; + static const string name = "_ambientocclusion_rotate.tex"; Texture2D *rotate_lookup = resources.find(name); if(rotate_lookup) return *rotate_lookup; @@ -128,13 +128,6 @@ void AmbientOcclusion::set_debug_name(const string &name) } -AmbientOcclusion::Template::Template(): - n_samples(16), - occlusion_radius(0.5f), - darkness(1.0f), - edge_depth_threshold(0.1f) -{ } - AmbientOcclusion *AmbientOcclusion::Template::create(unsigned width, unsigned height) const { RefPtr ao = new AmbientOcclusion(width/size_divisor, height/size_divisor);