Show
Ignore:
Timestamp:
06/08/07 17:29:04 (8 years ago)
Author:
robert
Message:

Added fallback for when no command line args are provied.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • OpenSceneGraph/trunk/examples/osgstereoimage/osgstereoimage.cpp

    r6834 r6914  
    451451    } 
    452452     
    453     if (arguments.argc()<=1) 
    454     { 
    455         arguments.getApplicationUsage()->write(std::cout,osg::ApplicationUsage::COMMAND_LINE_OPTION); 
    456         return 1; 
    457     } 
    458  
    459453    // extract the filenames from the arguments list. 
    460454    FileList fileList; 
     
    464458    } 
    465459 
    466     if (fileList.size()<2) 
    467     { 
     460    if (fileList.empty()) 
     461    { 
     462        fileList.push_back("Images/dog_left_eye.jpg"); 
     463         fileList.push_back("Images/dog_right_eye.jpg"); 
     464    } 
     465    else if (fileList.size()<2) 
     466    { 
     467        arguments.getApplicationUsage()->write(std::cout,osg::ApplicationUsage::COMMAND_LINE_OPTION); 
    468468        return 1; 
    469469    }