#include <FWEveView.h>
Definition at line 53 of file FWEveView.h.
FWEveView::FWEveView | ( | TEveWindowSlot * | iParent, |
FWViewType::EType | type, | ||
unsigned int | version = 7 |
||
) |
Definition at line 80 of file FWEveView.cc.
References FWEnumParameter::addEntry(), cameraGuideChanged(), FWGenericParameter< T >::changed_, m_cameraGuide, m_drawCMSLogo, m_energyMaxValAnnotation, m_eventInfoLevel, m_eventScene, m_geoScene, m_lineOutlineScale, m_lineSmooth, m_lineWidth, m_lineWireframeScale, m_localEnergyScale, m_overlayEventInfo, m_overlayLogo, m_ownedProducts, m_pointSize, m_pointSmooth, m_showCameraGuide, m_useGlobalEnergyScale, m_viewContext, m_viewContextMenu, m_viewer, FWGLEventHandler::openSelectedModelContextMenu_, FWViewBase::openSelectedModelContextMenu_, pointLineScalesChanged(), FWEventAnnotation::setLevel(), setupEnergyScale(), FWGLEventHandler::setViewer(), CmsAnnotation::setVisible(), FWViewBase::typeName(), useGlobalEnergyScaleChanged(), and viewerGL().
: FWViewBase(type, version), m_viewer(0), m_eventScene(0), m_ownedProducts(0), m_geoScene(0), m_overlayEventInfo(0), m_overlayLogo(0), m_energyMaxValAnnotation(0), m_cameraGuide(0), m_context(0), // style #if ROOT_VERSION_CODE >= ROOT_VERSION(5,26,0) m_imageScale(this, "Image Scale", 1.0, 1.0, 6.0), #endif m_eventInfoLevel(this, "Overlay Event Info", 0l, 0l, 2l), m_drawCMSLogo(this,"Show Logo",false), m_pointSmooth(this, "Smooth points", false), m_pointSize(this, "Point size", 1.0, 1.0, 10.0), m_lineSmooth(this, "Smooth lines", false), m_lineWidth(this,"Line width",1.0,1.0,10.0), m_lineOutlineScale(this, "Outline width scale", 1.0, 0.01, 10.0), m_lineWireframeScale(this, "Wireframe width scale", 1.0, 0.01, 10.0), m_showCameraGuide(this,"Show Camera Guide",false), m_useGlobalEnergyScale(this, "UseGlobalEnergyScale", true), m_viewContext( new FWViewContext()), m_localEnergyScale( new FWViewEnergyScale(FWViewType::idToName(type), version)), m_viewEnergyScaleEditor(0) { m_viewer = new TEveViewer(typeName().c_str()); TGLEmbeddedViewer* embeddedViewer; #if ROOT_VERSION_CODE >= ROOT_VERSION(5,25,4) embeddedViewer = m_viewer->SpawnGLEmbeddedViewer(0); #else embeddedViewer = m_viewer->SpawnGLEmbeddedViewer(); #endif iParent->ReplaceWindow(m_viewer); gEve->GetViewers()->AddElement(m_viewer); m_eventScene = gEve->SpawnNewScene(Form("EventScene %s", typeName().c_str())); m_ownedProducts = new TEveElementList("ViewSpecificProducts"); m_eventScene->AddElement(m_ownedProducts); m_viewer->AddScene(m_eventScene); // spawn geo scene m_geoScene = gEve->SpawnNewScene(Form("GeoScene %s", typeName().c_str())); m_geoScene->GetGLScene()->SetSelectable(kFALSE); m_viewer->AddScene(m_geoScene); FWGLEventHandler* eh = new FWGLEventHandler((TGWindow*)embeddedViewer->GetGLWidget(), (TObject*)embeddedViewer); embeddedViewer->SetEventHandler(eh); eh->setViewer(m_viewer); eh->openSelectedModelContextMenu_.connect(openSelectedModelContextMenu_); eh->SetDoInternalSelection(kFALSE); FWViewContextMenuHandlerGL* ctxHand = new FWViewContextMenuHandlerGL(this); // ctxHand->setPickCameraCenter(true); m_viewContextMenu.reset(ctxHand); m_energyMaxValAnnotation = new ScaleAnnotation(viewerGL(), "empty", 0.1, 0.9); m_energyMaxValAnnotation->SetRole(TGLOverlayElement::kViewer); m_energyMaxValAnnotation->SetState(TGLOverlayElement::kInvisible); m_energyMaxValAnnotation->SetUseColorSet(false); m_energyMaxValAnnotation->SetTextSize(0.05); m_energyMaxValAnnotation->SetTextColor(kMagenta); // style params m_overlayEventInfo = new FWEventAnnotation(embeddedViewer); m_overlayEventInfo->setLevel(0); m_eventInfoLevel.addEntry(0, "Nothing"); m_eventInfoLevel.addEntry(1, "Run / event"); m_eventInfoLevel.addEntry(2, "Run / event / lumi"); m_eventInfoLevel.addEntry(3, "Full"); m_eventInfoLevel.changed_.connect(boost::bind(&FWEventAnnotation::setLevel,m_overlayEventInfo, _1)); m_overlayLogo = new CmsAnnotation(embeddedViewer, 0.02, 0.98); m_overlayLogo->setVisible(false); m_drawCMSLogo.changed_.connect(boost::bind(&CmsAnnotation::setVisible,m_overlayLogo, _1)); m_cameraGuide = new TGLCameraGuide(0.9, 0.1, 0.08); m_cameraGuide->SetState(TGLOverlayElement::kInvisible); embeddedViewer->AddOverlayElement(m_cameraGuide); m_showCameraGuide.changed_.connect(boost::bind(&FWEveView::cameraGuideChanged,this)); m_pointSmooth.changed_.connect(boost::bind(&FWEveView::pointLineScalesChanged,this)); m_pointSize.changed_.connect(boost::bind(&FWEveView::pointLineScalesChanged,this)); m_lineSmooth.changed_.connect(boost::bind(&FWEveView::pointLineScalesChanged,this)); m_lineWidth.changed_.connect(boost::bind(&FWEveView::pointLineScalesChanged,this)); m_lineOutlineScale.changed_.connect(boost::bind(&FWEveView::pointLineScalesChanged,this)); m_lineWireframeScale.changed_.connect(boost::bind(&FWEveView::pointLineScalesChanged,this)); // create scale for view .. m_viewContext->setEnergyScale(m_localEnergyScale.get()); m_useGlobalEnergyScale.changed_.connect(boost::bind(&FWEveView::useGlobalEnergyScaleChanged, this)); m_localEnergyScale->parameterChanged_.connect(boost::bind(&FWEveView::setupEnergyScale, this)); }
FWEveView::~FWEveView | ( | ) | [virtual] |
Definition at line 181 of file FWEveView.cc.
References m_eventScene, m_geoScene, and m_viewer.
{ m_geoScene->RemoveElements(); m_eventScene->RemoveElements(); m_viewer->DestroyWindowAndSlot(); }
FWEveView::FWEveView | ( | const FWEveView & | ) | [private] |
void FWEveView::addTo | ( | FWConfiguration & | iTo | ) | const [virtual] |
Reimplemented from FWConfigurableParameterizable.
Reimplemented in FW3DViewBase, FWGlimpseView, FWLegoViewBase, and FWRPZView.
Definition at line 338 of file FWEveView.cc.
References CmsAnnotation::addTo(), FWEventAnnotation::addTo(), m_overlayEventInfo, m_overlayLogo, and m_viewContext.
{ // take care of parameters FWConfigurableParameterizable::addTo(iTo); { assert ( m_overlayEventInfo ); m_overlayEventInfo->addTo(iTo); } { assert ( m_overlayLogo ); m_overlayLogo->addTo(iTo); } m_viewContext->getEnergyScale()->addTo(iTo); }
void FWEveView::addToOrthoCamera | ( | TGLOrthoCamera * | camera, |
FWConfiguration & | iTo | ||
) | const [protected] |
Definition at line 405 of file FWEveView.cc.
References FWConfiguration::addKeyValue(), i, mergeVDriftHistosByStation::name, alignCSCRings::s, AlCaHLTBitMon_QueryRunRegistry::string, and FWViewBase::typeName().
Referenced by FWRPZView::addTo(), and FWLegoViewBase::addTo().
{ // zoom std::ostringstream s; s<<(camera->fZoom); std::string name("cameraZoom"); iTo.addKeyValue(name+typeName(),FWConfiguration(s.str())); // transformation matrix std::string matrixName("cameraMatrix"); for ( unsigned int i = 0; i < 16; ++i ) { std::ostringstream osIndex; osIndex << i; std::ostringstream osValue; osValue << camera->GetCamTrans()[i]; iTo.addKeyValue(matrixName+osIndex.str()+typeName(),FWConfiguration(osValue.str())); } }
void FWEveView::addToPerspectiveCamera | ( | TGLPerspectiveCamera * | cam, |
const std::string & | name, | ||
FWConfiguration & | iTo | ||
) | const [protected] |
Definition at line 461 of file FWEveView.cc.
References FWConfiguration::addKeyValue(), i, mergeVDriftHistosByStation::name, and AlCaHLTBitMon_QueryRunRegistry::string.
Referenced by FW3DViewBase::addTo(), FWLegoViewBase::addTo(), and FWGlimpseView::addTo().
{ // transformation matrix std::string matrixName("cameraMatrix"); for ( unsigned int i = 0; i < 16; ++i ){ std::ostringstream osIndex; osIndex << i; std::ostringstream osValue; osValue << (cam->GetCamTrans())[i]; iTo.addKeyValue(matrixName+osIndex.str()+name,FWConfiguration(osValue.str())); } // transformation matrix base matrixName = "cameraMatrixBase"; for ( unsigned int i = 0; i < 16; ++i ){ std::ostringstream osIndex; osIndex << i; std::ostringstream osValue; osValue << (cam->GetCamBase())[i]; iTo.addKeyValue(matrixName+osIndex.str()+name,FWConfiguration(osValue.str())); } { std::ostringstream osValue; osValue << cam->fFOV; iTo.addKeyValue(name+" FOV",FWConfiguration(osValue.str())); } }
void FWEveView::cameraGuideChanged | ( | ) | [protected, virtual] |
Definition at line 234 of file FWEveView.cc.
References m_cameraGuide, m_showCameraGuide, FWGenericParameter< T >::value(), and viewerGL().
Referenced by FWEveView().
{ m_cameraGuide->SetBinaryState(m_showCameraGuide.value()); viewerGL()->Changed(); gEve->Redraw3D(); }
const fireworks::Context& FWEveView::context | ( | ) | [inline] |
Definition at line 65 of file FWEveView.h.
References m_context.
Referenced by FWRPZView::eventBegin(), FWRPZView::resetOrigin(), FWViewContextMenuHandlerGL::select(), FWEveLegoView::setBackgroundColor(), FWRPZView::setContext(), FW3DView::setContext(), setContext(), FWRPZView::setEtaRng(), FW3DViewBase::setFrom(), setupEnergyScale(), useGlobalEnergyScaleChanged(), FWRPZView::voteCaloMaxVal(), and voteCaloMaxVal().
{ return *m_context; }
FWViewContextMenuHandlerBase * FWEveView::contextMenuHandler | ( | ) | const [virtual] |
Reimplemented from FWViewBase.
Definition at line 193 of file FWEveView.cc.
References m_viewContextMenu.
{ return dynamic_cast<FWViewContextMenuHandlerBase*> (m_viewContextMenu.get()); }
void FWEveView::eventBegin | ( | ) | [virtual] |
void FWEveView::eventEnd | ( | ) | [virtual] |
Reimplemented in FWRPZView.
Definition at line 247 of file FWEveView.cc.
References m_overlayEventInfo, FWEventAnnotation::setEvent(), and setupEnergyScale().
{ m_overlayEventInfo->setEvent(); setupEnergyScale(); }
TEveScene* FWEveView::eventScene | ( | ) | [inline] |
Definition at line 76 of file FWEveView.h.
References m_eventScene.
Referenced by addElements(), FWEveViewManager::finishViewCreate(), FWRPZView::FWRPZView(), FWRPZView::setContext(), FW3DViewBase::setContext(), FW3DView::setContext(), and FWLegoViewBase::setContext().
{ return m_eventScene;}
TEveScene* FWEveView::geoScene | ( | ) | [inline] |
Definition at line 77 of file FWEveView.h.
References m_geoScene.
Referenced by FWGlimpseView::createAxis(), FWRPZView::FWRPZView(), FW3DViewBase::rnrStyle(), FW3DViewBase::sceneClip(), FW3DViewBase::selectable(), FWRPZView::setContext(), and FW3DViewBase::setContext().
{ return m_geoScene; }
virtual TEveCaloViz* FWEveView::getEveCalo | ( | ) | const [inline, protected, virtual] |
Reimplemented in FW3DView, FWLegoViewBase, and FWRPZView.
Definition at line 95 of file FWEveView.h.
Referenced by setupEnergyScale(), and voteCaloMaxVal().
{ return 0; }
bool FWEveView::isEnergyScaleGlobal | ( | ) | const [virtual] |
Definition at line 277 of file FWEveView.cc.
References m_useGlobalEnergyScale, and FWGenericParameter< T >::value().
{ return m_useGlobalEnergyScale.value(); }
TEveElement* FWEveView::ownedProducts | ( | ) | [inline] |
Definition at line 79 of file FWEveView.h.
References m_ownedProducts.
Referenced by FWEveViewManager::finishViewCreate().
{ return m_ownedProducts; }
void FWEveView::pointLineScalesChanged | ( | ) | [protected, virtual] |
Definition at line 221 of file FWEveView.cc.
References m_lineOutlineScale, m_lineSmooth, m_lineWidth, m_lineWireframeScale, m_pointSize, m_pointSmooth, FWGenericParameter< T >::value(), and viewerGL().
Referenced by FWEveView().
{ viewerGL()->SetSmoothPoints(m_pointSmooth.value()); viewerGL()->SetPointScale (m_pointSize.value()); viewerGL()->SetSmoothLines (m_lineSmooth.value()); viewerGL()->SetLineScale (m_lineWidth.value()); viewerGL()->SetOLLineW (m_lineOutlineScale.value()); viewerGL()->SetWFLineW (m_lineWireframeScale.value()); viewerGL()->Changed(); gEve->Redraw3D(); }
void FWEveView::populateController | ( | ViewerParameterGUI & | gui | ) | const [virtual] |
Reimplemented from FWViewBase.
Reimplemented in FW3DViewBase, FWLegoViewBase, and FWRPZView.
Definition at line 543 of file FWEveView.cc.
References ViewerParameterGUI::addFrameToContainer(), ViewerParameterGUI::getTabContainer(), FWViewType::isLego(), m_drawCMSLogo, m_eventInfoLevel, m_imageScale, m_lineOutlineScale, m_lineSmooth, m_lineWidth, m_lineWireframeScale, m_localEnergyScale, m_pointSize, m_pointSmooth, m_showCameraGuide, m_useGlobalEnergyScale, m_viewEnergyScaleEditor, ViewerParameterGUI::requestTab(), FWViewEnergyScaleEditor::setEnabled(), FWViewBase::typeId(), and FWGenericParameter< T >::value().
{ gui.requestTab("Style"). addParam(&m_eventInfoLevel). addParam(&m_drawCMSLogo). addParam(&m_showCameraGuide). separator(). #if ROOT_VERSION_CODE >= ROOT_VERSION(5,26,0) addParam(&m_imageScale). #endif addParam(&m_pointSize). addParam(&m_pointSmooth). addParam(&m_lineSmooth). addParam(&m_lineWidth). addParam(&m_lineOutlineScale). addParam(&m_lineWireframeScale); gui.requestTab("Scales"). addParam(&m_useGlobalEnergyScale); m_viewEnergyScaleEditor = new FWViewEnergyScaleEditor(m_localEnergyScale.get(), gui.getTabContainer(), !FWViewType::isLego(typeId())); m_viewEnergyScaleEditor->setEnabled(!m_useGlobalEnergyScale.value()); gui.addFrameToContainer(m_viewEnergyScaleEditor); }
void FWEveView::resetCamera | ( | ) | [protected, virtual] |
Definition at line 260 of file FWEveView.cc.
References viewerGL().
{ viewerGL()->ResetCurrentCamera(); }
void FWEveView::saveImageTo | ( | const std::string & | iName | ) | const [virtual] |
Implements FWViewBase.
Definition at line 204 of file FWEveView.cc.
References fwLog, fwlog::kInfo, m_imageScale, summarizeEdmComparisonLogfiles::succeeded, FWGenericParameter< T >::value(), and viewerGL().
{ bool succeeded = false; #if ROOT_VERSION_CODE >= ROOT_VERSION(5,26,0) succeeded = viewerGL()->SavePictureScale(iName, m_imageScale.value()); #else succeeded = viewerGL()->SavePicture(iName.c_str()); #endif if(!succeeded) { throw std::runtime_error("Unable to save picture"); } fwLog(fwlog::kInfo) << "Saved image " << iName << std::endl; }
void FWEveView::setBackgroundColor | ( | Color_t | iColor | ) | [virtual] |
Reimplemented in FWEveLegoView.
Definition at line 254 of file FWEveView.cc.
References FWColorManager::setColorSetViewer(), and viewerGL().
{ FWColorManager::setColorSetViewer(viewerGL(), iColor); }
void FWEveView::setContext | ( | const fireworks::Context & | x | ) | [virtual] |
Reimplemented in FW3DView, FW3DViewBase, FWEveLegoView, FWHFView, FWLegoViewBase, and FWRPZView.
Definition at line 267 of file FWEveView.cc.
References context(), m_context, m_useGlobalEnergyScale, m_viewContext, FWGenericParameter< T >::value(), and x.
Referenced by FWEveViewManager::finishViewCreate().
{ m_context = &x ; // in constructor view context has local scale if (m_useGlobalEnergyScale.value()) m_viewContext->setEnergyScale(context().commonPrefs()->getEnergyScale()); }
void FWEveView::setFrom | ( | const FWConfiguration & | iFrom | ) | [virtual] |
Reimplemented from FWConfigurableParameterizable.
Reimplemented in FW3DViewBase, FWGlimpseView, FWLegoViewBase, and FWRPZView.
Definition at line 356 of file FWEveView.cc.
References FWParameterizable::begin(), FWParameterizable::end(), m_localEnergyScale, m_overlayEventInfo, m_overlayLogo, FWEventAnnotation::setFrom(), CmsAnnotation::setFrom(), FWConfigurableParameterizable::version(), FWConfiguration::version(), and viewerGL().
{ // Make sure you change the version ranges here // whenever you update the logic. // The rationale should be: // (version range supported by the next block) && (version range in the configuration file) // // This is not "forward" compatible, but I don't think // we care. if (version() >= 2 && iFrom.version() >= 1) { for(const_iterator it =begin(), itEnd = end(); it != itEnd; ++it) { (*it)->setFrom(iFrom); } } if (iFrom.version() > 1) { assert( m_overlayEventInfo); m_overlayEventInfo->setFrom(iFrom); } { assert( m_overlayLogo); m_overlayLogo->setFrom(iFrom); } if (iFrom.version() > 4) { m_localEnergyScale->setFrom(iFrom); } // selection clors UChar_t* ca = 0; ca = gEve->GetDefaultGLViewer()->RefLightColorSet().Selection(1).Arr(); viewerGL()->RefLightColorSet().Selection(1).SetColor(ca[0], ca[1], ca[2]); ca = gEve->GetDefaultGLViewer()->RefLightColorSet().Selection(3).Arr(); viewerGL()->RefLightColorSet().Selection(3).SetColor(ca[0], ca[1], ca[2]); ca = gEve->GetDefaultGLViewer()->RefDarkColorSet().Selection(1).Arr(); viewerGL()->RefDarkColorSet().Selection(1).SetColor(ca[0], ca[1], ca[2]); ca = gEve->GetDefaultGLViewer()->RefDarkColorSet().Selection(3).Arr(); viewerGL()->RefDarkColorSet().Selection(3).SetColor(ca[0], ca[1], ca[2]); }
void FWEveView::setFromOrthoCamera | ( | TGLOrthoCamera * | camera, |
const FWConfiguration & | iFrom | ||
) | [protected] |
Definition at line 425 of file FWEveView.cc.
References fwLog, i, fwlog::kInfo, alignCSCRings::s, AlCaHLTBitMon_QueryRunRegistry::string, FWViewBase::typeName(), FWConfiguration::value(), relativeConstraints::value, FWConfiguration::valueForKey(), and viewerGL().
Referenced by FWLegoViewBase::setFrom(), and FWRPZView::setFrom().
{ try { // zoom std::string zoomName("cameraZoom"); zoomName += typeName(); if (iFrom.valueForKey(zoomName) == 0 ) { throw std::runtime_error("can't restore parameter cameraZoom"); } std::istringstream s(iFrom.valueForKey(zoomName)->value()); s>>(camera->fZoom); // transformation matrix std::string matrixName("cameraMatrix"); for ( unsigned int i = 0; i < 16; ++i ) { std::ostringstream os; os << i; const FWConfiguration* value = iFrom.valueForKey( matrixName + os.str() + typeName() ); if ( value == 0 ) { throw std::runtime_error ("can't restore parameter cameraMatrix."); } std::istringstream s(value->value()); s>> (camera->RefCamTrans()[i]); } } catch (const std::runtime_error& iException) { fwLog(fwlog::kInfo) << "Caught exception while restoring camera parameters in view " << typeName() << "\n."; viewerGL()->ResetCamerasAfterNextUpdate(); } camera->IncTimeStamp(); }
void FWEveView::setFromPerspectiveCamera | ( | TGLPerspectiveCamera * | cam, |
const std::string & | name, | ||
const FWConfiguration & | iFrom | ||
) | [protected] |
Definition at line 490 of file FWEveView.cc.
References fwLog, i, fwlog::kDebug, fwlog::kInfo, mergeVDriftHistosByStation::name, alignCSCRings::s, AlCaHLTBitMon_QueryRunRegistry::string, FWViewBase::typeName(), FWConfiguration::value(), relativeConstraints::value, FWConfiguration::valueForKey(), and viewerGL().
Referenced by FWLegoViewBase::setFrom(), FW3DViewBase::setFrom(), and FWGlimpseView::setFrom().
{ try { std::string matrixName("cameraMatrix"); for ( unsigned int i = 0; i < 16; ++i ){ std::ostringstream os; os << i; const FWConfiguration* value = iFrom.valueForKey( matrixName + os.str() + name ); if ( value == 0 ) { throw std::runtime_error ("can't restore parameter cameraMatrix."); } std::istringstream s(value->value()); s>>((cam->RefCamTrans())[i]); } // transformation matrix base matrixName = "cameraMatrixBase"; for ( unsigned int i = 0; i < 16; ++i ){ std::ostringstream os; os << i; const FWConfiguration* value = iFrom.valueForKey( matrixName + os.str() + name ); if ( value == 0 ) { throw std::runtime_error ("can't restore parameter cameraMatrixBase."); } std::istringstream s(value->value()); s>>((cam->RefCamBase())[i]); } { const FWConfiguration* value = iFrom.valueForKey( name + " FOV" ); if ( value == 0 ) { throw std::runtime_error ("can't restore parameter cameraMatrixBase."); } std::istringstream s(value->value()); s>>cam->fFOV; } cam->IncTimeStamp(); } catch (const std::runtime_error& iException) { fwLog(fwlog::kInfo) << "Caught exception while restoring camera parameters in view " << typeName() << "\n."; viewerGL()->ResetCamerasAfterNextUpdate(); fwLog(fwlog::kDebug) << "Reset camera fo view " << typeName() << "\n."; } }
void FWEveView::setupEnergyScale | ( | ) | [virtual] |
Definition at line 299 of file FWEveView.cc.
References context(), f, FWViewContext::getEnergyScale(), getEveCalo(), fireworks::Context::getMaxEnergyInEvent(), FWViewEnergyScale::getPlotEt(), FWViewEnergyScale::getScaleFactor3D(), FWViewEnergyScale::getScaleFactorLego(), FWViewType::isLego(), Pi, FWViewContext::scaleChanged(), FWViewBase::typeId(), FWViewEnergyScale::updateScaleFactors(), viewContext(), and voteCaloMaxVal().
Referenced by eventEnd(), FWEveView(), FWRPZView::setEtaRng(), and useGlobalEnergyScaleChanged().
{ // Called at end of event OR if scale parameters changed. FWViewEnergyScale* energyScale = viewContext()->getEnergyScale(); // printf("setupEnergyScale %s >> scale name %s\n", typeName().c_str(), energyScale->name().c_str()); voteCaloMaxVal(); // set cache for energy to lenght conversion float maxVal = context().getMaxEnergyInEvent(energyScale->getPlotEt()); energyScale->updateScaleFactors(maxVal); // printf("max event val %f \n", maxVal); // printf("scales lego %f \n", energyScale->getScaleFactorLego()); // configure TEveCaloViz TEveCaloViz* calo = getEveCalo(); if (calo) { calo->SetPlotEt(energyScale->getPlotEt()); if (FWViewType::isLego(typeId())) { float f = energyScale->getScaleFactorLego(); calo->SetMaxValAbs(TMath::Pi()/f); } else { float f = energyScale->getScaleFactor3D(); calo->SetMaxValAbs(100/f); } calo->ElementChanged(); } // emit signal to proxy builders viewContext()->scaleChanged(); gEve->Redraw3D(); }
void FWEveView::useGlobalEnergyScaleChanged | ( | ) | [virtual] |
Definition at line 283 of file FWEveView.cc.
References fireworks::Context::commonPrefs(), context(), CmsShowCommon::getEnergyScale(), m_localEnergyScale, m_useGlobalEnergyScale, m_viewContext, m_viewEnergyScaleEditor, FWViewEnergyScaleEditor::setEnabled(), setupEnergyScale(), and FWGenericParameter< T >::value().
Referenced by FWEveView().
{ m_viewContext->setEnergyScale(m_useGlobalEnergyScale.value() ? context().commonPrefs()->getEnergyScale() : m_localEnergyScale.get()); if (m_viewEnergyScaleEditor) m_viewEnergyScaleEditor->setEnabled(!m_useGlobalEnergyScale.value()); setupEnergyScale(); }
FWViewContext* FWEveView::viewContext | ( | ) | [inline] |
Definition at line 80 of file FWEveView.h.
References m_viewContext.
Referenced by FWEveViewManager::beingDestroyed(), FWEveViewManager::newItem(), and setupEnergyScale().
{ return m_viewContext.get(); }
TEveViewer* FWEveView::viewer | ( | ) | [inline] |
Definition at line 75 of file FWEveView.h.
References m_viewer.
Referenced by FWGlimpseView::FWGlimpseView().
{ return m_viewer; }
TGLViewer * FWEveView::viewerGL | ( | ) | const |
Definition at line 198 of file FWEveView.cc.
References m_viewer.
Referenced by FWRPZView::addTo(), FW3DViewBase::addTo(), FWLegoViewBase::addTo(), FWGlimpseView::addTo(), cameraGuideChanged(), FWRPZView::eventBegin(), FWRPZView::eventEnd(), FW3DView::FW3DView(), FW3DViewBase::FW3DViewBase(), FWEveView(), FWGlimpseView::FWGlimpseView(), FWISpyView::FWISpyView(), FWLegoViewBase::FWLegoViewBase(), FWRPZView::FWRPZView(), pointLineScalesChanged(), FW3DViewBase::populateController(), FWRPZView::projectionAxesLabelSize(), resetCamera(), FW3DViewBase::rnrStyle(), saveImageTo(), FW3DViewBase::sceneClip(), FWViewContextMenuHandlerGL::select(), setBackgroundColor(), FWLegoViewBase::setCell2DMode(), FWLegoViewBase::setContext(), FWLegoViewBase::setFrom(), setFrom(), FWRPZView::setFrom(), FW3DViewBase::setFrom(), FWGlimpseView::setFrom(), setFromOrthoCamera(), setFromPerspectiveCamera(), FWLegoViewBase::setProjectionMode(), FWRPZView::shiftOrigin(), FWGlimpseView::showAxes(), FWLegoViewBase::showOverlay(), FWRPZView::showProjectionAxes(), and FWLegoViewBase::~FWLegoViewBase().
{ return m_viewer->GetGLViewer(); }
void FWEveView::voteCaloMaxVal | ( | ) | [virtual] |
Reimplemented in FWRPZView.
Definition at line 291 of file FWEveView.cc.
References context(), getEveCalo(), and fireworks::Context::voteMaxEtAndEnergy().
Referenced by setupEnergyScale().
{ TEveCaloViz* calo = getEveCalo(); if (calo) context().voteMaxEtAndEnergy(calo->GetData()->GetMaxVal(1), calo->GetData()->GetMaxVal(0)); }
TGLCameraGuide* FWEveView::m_cameraGuide [private] |
Definition at line 119 of file FWEveView.h.
Referenced by cameraGuideChanged(), and FWEveView().
const fireworks::Context* FWEveView::m_context [private] |
Definition at line 121 of file FWEveView.h.
Referenced by context(), and setContext().
FWBoolParameter FWEveView::m_drawCMSLogo [private] |
Definition at line 131 of file FWEveView.h.
Referenced by FWEveView(), and populateController().
Definition at line 118 of file FWEveView.h.
Referenced by FWEveView().
FWEnumParameter FWEveView::m_eventInfoLevel [private] |
Definition at line 130 of file FWEveView.h.
Referenced by FWEveView(), and populateController().
TEveScene* FWEveView::m_eventScene [private] |
Definition at line 112 of file FWEveView.h.
Referenced by eventScene(), FWEveView(), and ~FWEveView().
TEveScene* FWEveView::m_geoScene [private] |
Definition at line 114 of file FWEveView.h.
Referenced by FWEveView(), geoScene(), and ~FWEveView().
FWDoubleParameter FWEveView::m_imageScale [private] |
Definition at line 128 of file FWEveView.h.
Referenced by populateController(), and saveImageTo().
Definition at line 137 of file FWEveView.h.
Referenced by FWEveView(), pointLineScalesChanged(), and populateController().
FWBoolParameter FWEveView::m_lineSmooth [private] |
Definition at line 135 of file FWEveView.h.
Referenced by FWEveView(), pointLineScalesChanged(), and populateController().
FWDoubleParameter FWEveView::m_lineWidth [private] |
Definition at line 136 of file FWEveView.h.
Referenced by FWEveView(), pointLineScalesChanged(), and populateController().
Definition at line 138 of file FWEveView.h.
Referenced by FWEveView(), pointLineScalesChanged(), and populateController().
std::auto_ptr<FWViewEnergyScale> FWEveView::m_localEnergyScale [private] |
Definition at line 145 of file FWEveView.h.
Referenced by FWEveView(), populateController(), setFrom(), and useGlobalEnergyScaleChanged().
FWEventAnnotation* FWEveView::m_overlayEventInfo [private] |
Definition at line 116 of file FWEveView.h.
Referenced by addTo(), eventEnd(), FWEveView(), and setFrom().
CmsAnnotation* FWEveView::m_overlayLogo [private] |
Definition at line 117 of file FWEveView.h.
Referenced by addTo(), FWEveView(), and setFrom().
TEveElement* FWEveView::m_ownedProducts [private] |
Definition at line 113 of file FWEveView.h.
Referenced by FWEveView(), and ownedProducts().
FWDoubleParameter FWEveView::m_pointSize [private] |
Definition at line 134 of file FWEveView.h.
Referenced by FWEveView(), pointLineScalesChanged(), and populateController().
FWBoolParameter FWEveView::m_pointSmooth [private] |
Definition at line 133 of file FWEveView.h.
Referenced by FWEveView(), pointLineScalesChanged(), and populateController().
FWBoolParameter FWEveView::m_showCameraGuide [private] |
Definition at line 140 of file FWEveView.h.
Referenced by cameraGuideChanged(), FWEveView(), and populateController().
Definition at line 141 of file FWEveView.h.
Referenced by FWEveView(), isEnergyScaleGlobal(), populateController(), setContext(), and useGlobalEnergyScaleChanged().
std::auto_ptr<FWViewContext> FWEveView::m_viewContext [private] |
Definition at line 144 of file FWEveView.h.
Referenced by addTo(), FWEveView(), setContext(), useGlobalEnergyScaleChanged(), and viewContext().
boost::shared_ptr<FWViewContextMenuHandlerGL> FWEveView::m_viewContextMenu [private] |
Definition at line 143 of file FWEveView.h.
Referenced by contextMenuHandler(), and FWEveView().
FWViewEnergyScaleEditor* FWEveView::m_viewEnergyScaleEditor [mutable, private] |
Definition at line 147 of file FWEveView.h.
Referenced by populateController(), and useGlobalEnergyScaleChanged().
TEveViewer* FWEveView::m_viewer [private] |
Definition at line 111 of file FWEveView.h.
Referenced by FWEveView(), viewer(), viewerGL(), and ~FWEveView().