use the argument from command line as file to process, if present
authorskal <pascal.massimino@gmail.com>
Fri, 16 Nov 2012 20:40:00 +0000 (21:40 +0100)
committerSteinar H. Gunderson <sgunderson@bigfoot.com>
Fri, 16 Nov 2012 20:43:56 +0000 (21:43 +0100)
demo.cpp

index e72007b..cd6cf88 100644 (file)
--- a/demo.cpp
+++ b/demo.cpp
@@ -159,7 +159,7 @@ int main(int argc, char **argv)
                log2(1.0f / movit_texel_subpixel_precision));
        
        unsigned img_w, img_h;
-       unsigned char *src_img = load_image("blg_wheels_woman_1.jpg", &img_w, &img_h);
+       unsigned char *src_img = load_image(argc > 1 ? argv[1] : "blg_wheels_woman_1.jpg", &img_w, &img_h);
 
        EffectChain chain(WIDTH, HEIGHT);
        glViewport(0, 0, WIDTH, HEIGHT);