Definition at line 15 of file mainQuasiInvariantTest.cpp. References Impala::Visualization::ImagesWindow::AddImage(), Impala::CmdOptions::AddOption(), Impala::CmdOptions::GetArg(), Impala::CmdOptions::GetDouble(), Impala::CmdOptions::GetInstance(), OglGui::Sys::Instance(), Impala::Core::Array::InvQuasi(), Impala::CmdOptions::ParseArgs(), Impala::Application::DemoCamera2d::precision, Impala::Core::Array::ReadPng(), Impala::Core::Array::Set(), OglGui::OglWindow::SetBackground(), Impala::Application::DemoCamera2d::sigma, Impala::Util::Sleep(), and OglGui::OglWindow::Start(). 00016 { 00017 Impala::CmdOptions& options = Impala::CmdOptions::GetInstance(); 00018 options.AddOption(0, "sigma", "sigma for the gaussian derivatives", "1.0"); 00019 options.AddOption(0, "precision", "precision for the gaussian derivatives", "2"); 00020 if(!options.ParseArgs(argc, argv, "<input image>", 1)) 00021 return 0; 00022 00023 std::string filename = options.GetArg(0); 00024 double sigma = options.GetDouble("sigma"); 00025 double precision = options.GetDouble("precision"); 00026 00027 Array2dVec3UInt8* inputimage = 0; 00028 ReadPng(inputimage, filename); 00029 if(inputimage == 0) 00030 return 0; 00031 00032 Array2dVec3Real64* src = 0; 00033 Set(src, inputimage); 00034 00035 std::vector<Array2dScalarReal64*> quasiList = InvQuasi(src, sigma, precision); 00036 00037 OglGui::Window* win = new OglGui::Window(0,0,1080,550); 00038 win->SetBackground(0xffffff); 00039 Visualization::ImagesWindow* images; 00040 00041 new OglGui::StaticText(win,800,16,"joosts invarianten", false); 00042 images = new Visualization::ImageSet(win, 256, 256, 2.0, 2, 1); 00043 images->AddImage(inputimage, "Direct", "original", false, false, -1); 00044 images->AddImage(inputimage, "Direct", "original", false, false, -1); 00045 00046 images->AddImage(quasiList[0], "Stretch", "specular quasi invariant", false, false, -1); 00047 images->AddImage(quasiList[1], "Stretch", "specular variant", false, false, -1); 00048 images->AddImage(quasiList[2], "Stretch", "shadow-shading quasi invariant", false, false, -1); 00049 images->AddImage(quasiList[3], "Stretch", "shadow-shading variant", false, false, -1); 00050 images->AddImage(quasiList[4], "Stretch", "specular shadow-shading quasi invariant", false, false, -1); 00051 images->AddImage(quasiList[5], "Stretch", "specular shadow-shading variant", false, false, -1); 00052 00053 win->Start(); 00054 while(1) 00055 { 00056 if(OglGui::Sys::Instance().WindowManage()) 00057 break; 00058 ::Sleep(20); 00059 } 00060 00061 return 1; 00062 }
Here is the call graph for this function:
|