Reimplemented from Impala::Application::MediaTable::VisualizationModule. Definition at line 64 of file MapModule.h. References Impala::Application::TagsLife::ViewListenerCircles::AddCircle(), OglGui::OglWindow::ConnectTo(), Impala::Application::MediaTable::TableDataStore::GetInstance(), OglGui::WindowView2D::GetOglView(), OglGui::OglWindow::GetOGLWND(), Impala::Application::MediaTable::TableDataView::GetSortedDoubleData(), Impala::Application::MediaTable::TableDataView::GetSortedIntData(), Impala::Application::MediaTable::TableDataStore::GetTableDataView(), Impala::Application::MediaTable::TableDataView::GetTotalRows(), OglGui::OglWindow::H(), lat2y(), map(), Impala::Application::MediaTable::ConfigWindowModule::mStringValues, mViewListenerCircles, Impala::Application::DemoCamera2d::oglWnd, OglGui::ZoomPanControl::PanWindow(), OglGui::OglWindow::SetBorderType(), Impala::Application::MediaTable::TableDataView::SetNumberOfRows(), OglGui::OglWindow::SetRoundness(), OglGui::WindowView2D::SetScaleToWindow(), Impala::Application::MediaTable::TableDataView::SetStartRow(), OglGui::TOBOTTOM, OglGui::TOLEFTRIGHT, and OglGui::OglWindow::W(). 00065 { 00066 OGLIMAGE* oglIm = TryReadPNG("world.png"); 00067 WindowView2D* mGlobeMap = 00068 new WindowView2D(mMapWnd,0,92,mMapWnd->W(),mMapWnd->H()-92,oglIm); 00069 mGlobeMap->SetBorderType(1); 00070 mGlobeMap->SetScaleToWindow(false); 00071 mGlobeMap->ConnectTo(mMapWnd); 00072 00073 // Turn the C-Based OGLVIEW2D into a C++ based View with listener 00074 OGLVIEW* oglView = mGlobeMap->GetOglView(); 00075 new OglGui::View(oglView, &mViewListenerCircles); 00076 00077 ZoomPanControl* mZoomPanControl = 00078 new ZoomPanControl(mMapWnd,0,0,400,90,mGlobeMap->GetOGLWND(),5,1); 00079 mZoomPanControl->PanWindow()->SetRoundness(0,0,0,0); 00080 mZoomPanControl->ConnectTo(mMapWnd,OglGui::TOBOTTOM|OglGui::TOLEFTRIGHT); 00081 00082 // Turn the C-Based OGLVIEW2D into a C++ based View with listener 00083 OGLWND* oglWnd = mZoomPanControl->PanWindow()->GetOGLWND(); 00084 oglView = (OGLVIEW*) oglWnd->objectList->info; 00085 new OglGui::View(oglView, &mViewListenerCircles); 00086 00087 TableDataView* view = 00088 TableDataStore::GetInstance()->GetTableDataView(mStringValues["View"]); 00089 view->SetStartRow(0); 00090 view->SetNumberOfRows(view->GetTotalRows()); 00091 //mCache = new TableViewCache(this, mSource); 00092 00093 float lat2ym65 = lat2y(-65), lat2y85 = lat2y(85); 00094 00095 double longitude, latitude; 00096 for (int i=0; i<view->GetTotalRows(); i++) 00097 { 00098 longitude = view->GetSortedDoubleData(mStringValues["Latitude"], i); 00099 latitude = view->GetSortedDoubleData(mStringValues["Longitude"], i); 00100 int x = map(longitude, -180, 180, 0, oglIm->w); 00101 int y = map(lat2y(latitude), lat2ym65, lat2y85, 0, oglIm->h); 00102 int r = view->GetSortedIntData(mStringValues["Magnitude"], i)+3; 00103 mViewListenerCircles.AddCircle(x, y, r); 00104 } 00105 ReleaseOglImage(oglIm); 00106 }
Here is the call graph for this function:
|