Home || Visual Search || Applications || Architecture || Important Messages || OGL || Src

virtual void Impala::Application::SDash::SurveillanceApp::WindowMouseEvent ( Window src,
int  msg,
int  but,
int  state,
int  x,
int  y,
void *  vData 
) [inline, virtual]

Reimplemented from OglGui::WindowListener.

Definition at line 857 of file SurveillanceApp.cpp.

References Impala::Application::SDash::VideoJpgCamera::FrameNr(), OglGui::AlertTimeLine::GetCurrentTime(), OglGui::AlertTimeLine::GetStartTime(), OglGui::OglWindow::GetVisible(), mAllCamerasVideos, mExitButton, mFramesPerSecond, mInspectionPane, mMonitorSelector, Impala::Application::SDash::VideoPlayerView::mShowFrameNr, mSurveillanceMap, mTimeLine, mVideoCameras, mVideoCamerasVideoId, mVideoPlayerView, OglGui::OglWindow::SetVisible(), and VideoInspect().

00859     {
00860         int userData = (int)(long long) vData;
00861         if (src == mInspectionPane &&
00862             msg == oglMouseDblClick && (state&oglControl))
00863         {
00864             if (state&oglLeftButton)
00865                 mExitButton->SetVisible(!mExitButton->GetVisible());
00866             if (state&oglRightButton)
00867             {
00868                 if(state&oglShift)
00869                     mVideoPlayerView->mShowFrameNr = !mVideoPlayerView->mShowFrameNr;
00870                 else
00871                     mFramesPerSecond->SetVisible(!mFramesPerSecond->GetVisible());
00872             }
00873         }
00874         if (src == mSurveillanceMap && msg == oglMouseDown)
00875         {
00876             mMonitorSelector->SetVisible(false);
00877             printf("X: %d y: %d\n", x, y);
00878         }
00879 #ifdef ALL_MONITORS
00880         else if (msg == oglMouseDown && userData)
00881         {
00882             int  frNr = mAllCamerasVideos[userData-1]->FrameNr();
00883             long startTime   = mTimeLine->GetStartTime();
00884             long elapsedTime = mTimeLine->GetCurrentTime()-startTime;
00885             int  videoId     = userData;
00886             VideoInspect(videoId, videoId-1, elapsedTime, frNr); 
00887         }
00888 #endif
00889         else if (msg == oglMouseDown)
00890         {
00891             // If user clicked one of the monitors then display in inspect video
00892             for (int i=0; i<3; i++)
00893                 if (src == mVideoCameras[i])
00894                 {
00895                     int frNr = mVideoCameras[i]->FrameNr();
00896                     long startTime   = mTimeLine->GetStartTime();
00897                     long elapsedTime = mTimeLine->GetCurrentTime()-startTime;
00898                     int  videoId     = mVideoCamerasVideoId[i];
00899                     VideoInspect(videoId+1, videoId, elapsedTime, frNr); 
00900                 }
00901         }
00902     }

Here is the call graph for this function:


Generated on Thu Jan 13 09:16:10 2011 for ImpalaSrc by  doxygen 1.5.1