19 #include <osgViewer/View>
24 class DatabaseRequestHandler;
30 class DtChannelSpecificGroup;
31 class DtIntersectorResult;
32 class DtIntersectorsContainer;
34 class DtOsgChannelCreator;
35 class DtChannelManager;
36 class DtWindowConfiguration;
39 class DtOsgObserverObject;
40 class DtOsgCullVisitorParameters;
41 class DtTerrainPageSignaler;
43 class DtOsgChannelSensor;
69 virtual bool initialize();
73 virtual void initializeNormalized2DCamera();
74 virtual void initialize2DCamera(
int w,
int h);
75 virtual void initializeSceneCamera();
76 virtual void initializeRenderTexture();
78 virtual void initializeRTTCamera();
80 virtual void clearRttCamera();
82 virtual void recreateRTTCamera();
87 virtual void setShadowState(
bool enable);
90 virtual void addOverlayDrawablesToCameras();
97 virtual void initializeSignalConnections();
109 virtual void setSensorName(
const std::string& sensorName);
112 virtual void setClearColor(
float r,
float g,
float b,
float a);
117 virtual void setWindow(
DtWindow* view);
120 virtual const DtWindow* window()
const;
123 virtual void setViewport(
int x,
int y,
int width,
int height);
128 virtual void clearFrameBufferIfChanged();
131 virtual void getViewport(
int& x,
int& y,
int& width,
int& height)
const;
134 virtual void setCameraPosition(
double x,
double y,
double z);
137 virtual void setCameraOrientation(
double psi,
double theta,
double phi);
143 virtual void setCameraPositionAndOrientation(
double x,
double y,
144 double z,
double psi,
double theta,
double phi);
145 virtual void setCameraPositionAndOrientation(osg::Vec3d& pos,
149 virtual void getCameraPositionAndOrientation(osg::Vec3d& position,
150 osg::Quat& rotation)
const;
162 virtual void setChannelEnabled(
bool enabled,
bool partial)
override;
166 virtual bool channelEnabled()
const;
168 virtual void update();
171 virtual void connectToObserver();
174 virtual osgViewer::View& view();
198 virtual void setRenderToTexture(
bool enabled);
203 virtual void setRenderToTextureFormat(
int format,
int sourceFormat,
int sourceType);
217 virtual void setDepthTextureUsesStencilBuffer(
bool useStencil);
220 virtual bool depthTextureUsesStencilBuffer()
const;
223 virtual int shadowQuality()
const;
228 virtual std::vector<const osg::Camera*> getShadowableCameras()
const;
232 virtual void setProjectionResizePolicy(
237 virtual void updateProjection();
240 double &left,
double zNear,
double &right,
double &top,
double &bottom);
243 double& left,
double zNear,
double& right,
double& top,
double& bottom);
246 virtual void connectChannelToScene();
252 virtual bool processKeyboardEvent(
const DtKeyEvent & ev);
258 virtual void getWorldToWindowMatrix(osg::Matrix& worldToWindowMatrix)
const;
261 virtual void moveMouseToScreenLocation(
float screenX,
float screenY);
266 virtual void projectToScreen(
double dbX,
double dbY,
double dbZ,
267 double& screenX,
double& screenY,
double& screenZ);
270 virtual void projectToWorld(
double screenX,
double screenY,
271 double& dbX,
double& dbY,
double& dbZ);
277 std::vector<DtElementID>* ignoreList = 0);
280 virtual const std::string& name();
293 virtual void addPostProcessEffect(
const std::string& postProcessorEffect);
298 virtual void removePostProcessEffect(
const std::string& postProcessorEffect);
301 virtual bool hasPostProcessEffect(
const std::string& postProcessorEffect);
309 virtual void setEnablePostProcessors(
bool enable);
311 virtual bool getEnablePostProcessors();
314 virtual bool useOldChannelOffsetCalcuation()
const;
315 virtual void setUseOldChannelOffsetCalcuation(
bool enable);
319 virtual bool forceHdrLuminanceOverride();
321 virtual void setForceHdrLuminanceOverride(
bool force);
330 virtual void clearStateGraph(
void);
335 virtual void setEnableHdrPassthrough(
bool flag);
336 virtual bool enableHdrPassthrough();
340 virtual void setHdrOutputScale(
float scale);
343 virtual float hdrOutputScale();
346 virtual void screenCapture();
349 virtual void setOcclusionTextureEnabled(
bool enabled);
352 virtual void initOcclusionTexture();
355 virtual void updateCameraFrustumPlanes( std::vector<
DtVector4<double> >& planes );
359 virtual void updateAcquisitionBoxFrustumPlanes(
const int& boxCenterX,
const int& boxCenterY,
360 const int& boxWidth,
const int& boxHeight, std::vector<
DtVector4<double> >& planes );
368 virtual void releaseResources(osg::State* gcState);
372 virtual void updateShowTracksUniform(
bool value);
379 virtual void makeObserverToCameraMatrix(osg::Vec3d& orient,
380 osg::Matrixd& offsetObserverToCamera, osg::Matrixd& observerToCamera);
381 virtual void makeObserverToCameraMatrix(osg::Quat& qObserverToWorld,
382 osg::Matrixd& offsetObserverToCamera, osg::Matrixd& observerToCamera);
386 virtual void calculateNearFar(
double& zNear,
double& zFar);
391 virtual bool useAttachedForNearClip(
double alt);
394 virtual double calculateNearClip(
double alt,
double zFar);
397 virtual double calculateFarClip(
double alt);
403 virtual double calculateNearClipMagClamp(
double zNear,
double zFar,
float magLevel=2.);
406 virtual void projectFor3D();
409 virtual void projectFor2D();
413 virtual void connectRttCameraToScene();
418 virtual void stopUsingModelSet(
int modelSet);
423 virtual void startUsingModelSet(
int modelSet);
426 virtual void slot_visualizerRootAdded(
int modelSet,
int visualType);
429 virtual void slot_shadowsRemoved();
437 int setting,
bool value);
447 virtual void slot_windowConfigurationModified(
const std::string& deName,
451 virtual void slot_channelConfigurationModified(
const std::string& deName,
452 const std::string& windowName,
const std::string& oldChannelName,
456 virtual void slot_onCoordinateSystemChanged();
460 virtual void slot_paperMapEnabledChanged(
bool setting);
463 virtual void observerRemoved(
const std::string& observerName);
466 virtual void updateMultiSampleOverrideSetting();
471 virtual void getRenderTextureAttachmentInfo(
unsigned int&
level,
unsigned int& face,
unsigned int& sampleBuffers,
unsigned int& samples);
474 virtual void initializeRenderTextureColor();
477 virtual void initializeRenderTextureDepth();
480 virtual void initializeRttCameraDepth();
483 virtual void changedRttCameraFbo();
489 virtual void calculateAndSetFocusPointDistance(
double zNear,
double zFar);
493 osgViewer::CompositeViewer* getOrCreateViewer();
496 virtual void flipHorizontal(
bool flip);
bool myShadowState
Definition: DtOsgChannel.h:542
IntersectProperties
The IntersectProperties enum is a flag set that indicates the types of nodes to be considered for int...
Definition: DtIntersector.h:31
DtOsgObserverObject * myOsgObserverObject
Definition: DtOsgChannel.h:503
Abstract Base class.
Definition: DtWindow.h:25
bool myCoordinateSystemChanged
Definition: DtOsgChannel.h:540
std::vector< osg::Vec3d > myFocusPoints
Definition: DtOsgChannel.h:580
bool myLastFocusPointAttemptedOsgEarthFailed
Definition: DtOsgChannel.h:582
osg::ref_ptr< osg::DatabaseRequestHandlerCallback > myDatabasePagerCallback
Definition: DtOsgChannel.h:559
int myRenderTextureFormat
Definition: DtOsgChannel.h:505
DtOsgWindow * myOsgWindow
Definition: DtOsgChannel.h:502
This class encapsulates a Key event.
Definition: DtKeyEvent.h:16
static int theRunningCameraId
This is used to give names to each camera created. This is appended to the camera name This is useful...
Definition: DtOsgChannel.h:593
#define DT_DLL_VRVOSG
Definition: vrvOsg.h:23
DT_DLL_VRVCORE DtTaitBryan level(const DtCoordinateSystem &cs, const DtVector &localOrigin, double topoHeading)
Returns a level orientation with the topographic heading.
bool myShowTracksEnabled
Definition: DtOsgChannel.h:586
bool myFrameBufferNeedsClear
Definition: DtOsgChannel.h:565
The channel creator for the abstract channel class.
Definition: DtOsgChannel.h:608
Utility class that contains intersectors for all model sets in the system (3d, xr, 2d) Use an object of this class when all models sets can be possibly needed. When you know which model set you need, you can just use the DtIntersectorCreator to create an intersector for a model set Models sets corresponding to 3d, xr and 2d are created by default (these correspond to values of 0, 1 and 5) Additional model sets can be registered with DtIntersectorsContainer::registerModelSet.
Definition: DtIntersectorsContainer.h:36
bool mySensorInitialized
Definition: DtOsgChannel.h:513
int myLastNumMultiSamplesOverride
Definition: DtOsgChannel.h:578
Descriptor for a single intersection result.
Definition: DtIntersectorResult.h:21
Definition: DtOsgChannelSensor.h:22
PostProcessorEffectList myPostProcessorEffects
Definition: DtOsgChannel.h:546
The abstract channel creator for the abstract channel class.
Definition: DtChannel.h:180
This owns a list of channel configurations.
Definition: DtWindowConfiguration.h:28
This class provides the OSG-specific implementation of a DtChannel.
Definition: DtOsgChannel.h:52
osg::ref_ptr< osg::Texture > myRenderTexture
The textures the 3D scene renders into when post processing is on.
Definition: DtOsgChannel.h:530
osg::ref_ptr< osg::Texture > myOcclusionTexture
Definition: DtOsgChannel.h:532
bool myEnableHdrPassthrough
Definition: DtOsgChannel.h:561
This class encapsulates a mouse button event.
Definition: DtMouseEvent.h:19
bool myEnablePostProcessors
Definition: DtOsgChannel.h:552
bool myUseOldChannelOffsetCalcuation
Definition: DtOsgChannel.h:557
bool myChannelEnabled
Definition: DtOsgChannel.h:515
osg::ref_ptr< osgViewer::View > myView
Definition: DtOsgChannel.h:501
osg::ref_ptr< DtCameraNode > myNormalized2DCamera
Definition: DtOsgChannel.h:527
int myRenderTextureSourceType
Definition: DtOsgChannel.h:509
The abstract Channel Class.
Definition: DtChannel.h:35
Contains makVrv:DtIntersector class.
Contains makVrv::DtCameraNode declaration.
std::list< std::string > PostProcessorEffectList
Emitted when the channel's viewport changes dimensions.
Definition: DtOsgChannel.h:288
DtOsgChannelSensor * myChannelSensor
Definition: DtOsgChannel.h:584
This abstract base class defines the interface for OS-specific keyboard and mouse event listeners...
Definition: DtObserverObject.h:29
bool myRenderToTextureFlag
Definition: DtOsgChannel.h:541
float myHdrOutputScale
Definition: DtOsgChannel.h:563
The osg cull vistor parameters class provides additional culling and intersector parameters for choos...
Definition: DtOsgCullVisitorParameters.h:42
osg::Node::NodeMask myOldSceneCameraNodeMask
Definition: DtOsgChannel.h:548
osg::ref_ptr< osg::Group > myRoot
Definition: DtOsgChannel.h:517
Contains makVrv::DtChannel class.
bool myIsUsingTrackballManipulator
Definition: DtOsgChannel.h:539
bool myForceHdrLuminanceOverride
Definition: DtOsgChannel.h:562
VR-Vantage specific subclass of OSG camera.
Definition: DtCameraNode.h:29
ProjectionUnits
Definition: DtChannelConfiguration.h:39
osg::ref_ptr< DtCameraNode > mySceneCamera
Definition: DtOsgChannel.h:521
virtual DtOsgChannelSensor * findChannelSensor()
Definition: DtOsgChannel.h:364
boost::signalslib::signal< void(int, int, int, int)> signal_viewportChanged
Emitted when the channel's viewport changes dimensions.
Definition: DtOsgChannel.h:286
osg::ref_ptr< DtCameraNode > myRTTCamera
Slave camera configured to render to myRenderTexture.
Definition: DtOsgChannel.h:537
Configuration for a single channel Serialized and sent to remote displays as necessary to configure r...
Definition: DtChannelConfiguration.h:26
std::map< int, DtChannelSpecificGroup * > VisualTypeMap
Definition: DtOsgChannel.h:499
Class for generic lights This holds per-light data such as range, attenuation factors, colors, etc.
Definition: DtLight.h:48
bool myDepthTextureUsesStencilBuffer
Definition: DtOsgChannel.h:534
double myPreviousClampedNearClipDistance
Definition: DtOsgChannel.h:575
DtLight * myFlashlight
Definition: DtOsgChannel.h:550
bool myRenderTextureFormatDirty
Definition: DtOsgChannel.h:511
osg::ref_ptr< DtCameraNode > my2DCamera
Definition: DtOsgChannel.h:524
int myLastFocusPointAttempted
Definition: DtOsgChannel.h:581
The DtDe is the core component of any VR-Vantage application. It owns a DtRenderer, DtDeCommunicator, as well as a DtDisplay and other things.
Definition: DtDe.h:70
int myRenderTextureSourceFormat
Definition: DtOsgChannel.h:507
Contains makVrv::DtOsgRenderer class.
Definition: DtIntersector.h:33
ProjectionResizePolicy
Definition: DtChannelConfiguration.h:46
This abstract base class defines the interface for OS-specific keyboard and mouse event listeners...
Definition: DtOsgObserverObject.h:48
A basic OSG display window, used to get the osg context for a display window.
Definition: DtOsgWindow.h:36
osg::ref_ptr< osg::Texture > myDepthTexture
Definition: DtOsgChannel.h:531
bool myLastMirrorMode
Definition: DtOsgChannel.h:570