VR-Engage  2.2
Loading...
Searching...
No Matches
makVre::DtQtQuickFileData Class Reference

Detailed Description

This class stores all the necessary information about a QML file to be rendered, including its target window, initialization function, file path, root item, and render-to-texture settings.

#include <vreQtQuickFileData.h>

Public Member Functions

 DtQtQuickFileData ()
 
 ~DtQtQuickFileData ()
 
virtual void setTargetWindow (const std::string &windowName)
 
virtual const std::string & getTargetWindow ()
 
virtual void setDocInitFunction (const std::function< void(QQuickItem *)> &func)
 
virtual const std::function< void(QQuickItem *)> & getDocInitFunction ()
 
virtual void setFileToLoad (const std::string &filePath)
 
virtual const std::string & getFileToLoad ()
 
virtual void setRoot (QQuickItem *root)
 
virtual QQuickItem * getRoot ()
 
virtual void setOwner (QObject *owner)
 
virtual QObject * getOwner ()
 
virtual void setRTTdata (DtPerWindowQtQuickData *data)
 
virtual DtPerWindowQtQuickDatagetRTTdata ()
 
virtual void setRTTtarget (bool isRTT)
 
virtual bool getRTTtarget ()
 
virtual void setFboSize (int w, int h)
 
virtual void getFboSize (int &w, int &h)
 
virtual int getFboWidth ()
 
virtual int getFboHeight ()
 
virtual void setFboSamples (int samples)
 
virtual int getFboSamples ()
 
virtual void setOsgRenderTexture (osg::Texture2D *texture)
 
virtual osg::Texture2D * getOsgRenderTexture ()
 

Protected Attributes

DtPerWindowQtQuickDatamyRTTdata
 
QObject * myOwner
 
QQuickItem * myRoot
 
bool myRTTtarget
 
int myFboSamples
 
int myFboWidth
 
int myFboHeight
 
osg::ref_ptr< osg::Texture2D > myOsgTarget
 
std::function< void(QQuickItem *)> myDocInitFunction
 
std::string myCurrentWarnings
 
std::string myFileToLoad
 
std::string myTargetWindow
 

Constructor & Destructor Documentation

◆ DtQtQuickFileData()

makVre::DtQtQuickFileData::DtQtQuickFileData ( )

Default constructor.

◆ ~DtQtQuickFileData()

makVre::DtQtQuickFileData::~DtQtQuickFileData ( )

Destructor.

Member Function Documentation

◆ setTargetWindow()

virtual void makVre::DtQtQuickFileData::setTargetWindow ( const std::string & windowName)
virtual

Sets the target window name for rendering.

Parameters
windowNameName of the target window

◆ getTargetWindow()

virtual const std::string & makVre::DtQtQuickFileData::getTargetWindow ( )
virtual

Gets the target window name.

Returns
Reference to the target window name

◆ setDocInitFunction()

virtual void makVre::DtQtQuickFileData::setDocInitFunction ( const std::function< void(QQuickItem *)> & func)
virtual

Sets the document initialization function.

Parameters
funcCallback function to be called when the QML file is loaded

◆ getDocInitFunction()

virtual const std::function< void(QQuickItem *)> & makVre::DtQtQuickFileData::getDocInitFunction ( )
virtual

Gets the document initialization function.

Returns
Reference to the initialization function

◆ setFileToLoad()

virtual void makVre::DtQtQuickFileData::setFileToLoad ( const std::string & filePath)
virtual

Sets the path of the QML file to load.

Parameters
filePathPath to the QML file

◆ getFileToLoad()

virtual const std::string & makVre::DtQtQuickFileData::getFileToLoad ( )
virtual

Gets the path of the QML file to load.

Returns
Reference to the file path

◆ setRoot()

virtual void makVre::DtQtQuickFileData::setRoot ( QQuickItem * root)
virtual

Sets the root QML item.

Parameters
rootPointer to the root QML item

◆ getRoot()

virtual QQuickItem * makVre::DtQtQuickFileData::getRoot ( )
virtual

Gets the root QML item.

Returns
Pointer to the root QML item

◆ setOwner()

virtual void makVre::DtQtQuickFileData::setOwner ( QObject * owner)
virtual

Sets the owner object.

Parameters
ownerPointer to the owner object

◆ getOwner()

virtual QObject * makVre::DtQtQuickFileData::getOwner ( )
virtual

Gets the owner object.

Returns
Pointer to the owner object

◆ setRTTdata()

virtual void makVre::DtQtQuickFileData::setRTTdata ( DtPerWindowQtQuickData * data)
virtual

Sets the render-to-texture data.

Parameters
dataPointer to the per-window Qt Quick data

◆ getRTTdata()

virtual DtPerWindowQtQuickData * makVre::DtQtQuickFileData::getRTTdata ( )
virtual

Gets the render-to-texture data.

Returns
Pointer to the per-window Qt Quick data

◆ setRTTtarget()

virtual void makVre::DtQtQuickFileData::setRTTtarget ( bool isRTT)
virtual

Sets whether this is a render-to-texture target.

Parameters
isRTTTrue if this is a render-to-texture target, false otherwise

◆ getRTTtarget()

virtual bool makVre::DtQtQuickFileData::getRTTtarget ( )
virtual

Checks if this is a render-to-texture target.

Returns
True if this is a render-to-texture target, false otherwise

◆ setFboSize()

virtual void makVre::DtQtQuickFileData::setFboSize ( int w,
int h )
virtual

Sets the framebuffer size.

Parameters
wWidth of the framebuffer in pixels
hHeight of the framebuffer in pixels

◆ getFboSize()

virtual void makVre::DtQtQuickFileData::getFboSize ( int & w,
int & h )
virtual

Gets the framebuffer size.

Parameters
wOutput parameter for the framebuffer width
hOutput parameter for the framebuffer height

◆ getFboWidth()

virtual int makVre::DtQtQuickFileData::getFboWidth ( )
virtual

Gets the framebuffer width.

Returns
Width of the framebuffer in pixels

◆ getFboHeight()

virtual int makVre::DtQtQuickFileData::getFboHeight ( )
virtual

Gets the framebuffer height.

Returns
Height of the framebuffer in pixels

◆ setFboSamples()

virtual void makVre::DtQtQuickFileData::setFboSamples ( int samples)
virtual

Sets the number of framebuffer samples for multisampling.

Parameters
samplesNumber of samples

◆ getFboSamples()

virtual int makVre::DtQtQuickFileData::getFboSamples ( )
virtual

Gets the number of framebuffer samples.

Returns
Number of samples for multisampling

◆ setOsgRenderTexture()

virtual void makVre::DtQtQuickFileData::setOsgRenderTexture ( osg::Texture2D * texture)
virtual

Sets the OSG render texture.

Parameters
texturePointer to the OSG texture for rendering

◆ getOsgRenderTexture()

virtual osg::Texture2D * makVre::DtQtQuickFileData::getOsgRenderTexture ( )
virtual

Gets the OSG render texture.

Returns
Pointer to the OSG texture for rendering

Member Data Documentation

◆ myRTTdata

DtPerWindowQtQuickData* makVre::DtQtQuickFileData::myRTTdata
protected

Render-to-texture data for this file.

◆ myOwner

QObject* makVre::DtQtQuickFileData::myOwner
protected

Owner object for this QML file.

◆ myRoot

QQuickItem* makVre::DtQtQuickFileData::myRoot
protected

Root QML item.

◆ myRTTtarget

bool makVre::DtQtQuickFileData::myRTTtarget
protected

Flag indicating if this is a render-to-texture target.

◆ myFboSamples

int makVre::DtQtQuickFileData::myFboSamples
protected

Number of samples for framebuffer multisampling.

◆ myFboWidth

int makVre::DtQtQuickFileData::myFboWidth
protected

Width of the framebuffer in pixels.

◆ myFboHeight

int makVre::DtQtQuickFileData::myFboHeight
protected

Height of the framebuffer in pixels.

◆ myOsgTarget

osg::ref_ptr<osg::Texture2D> makVre::DtQtQuickFileData::myOsgTarget
protected

OSG texture for rendering.

◆ myDocInitFunction

std::function<void(QQuickItem*)> makVre::DtQtQuickFileData::myDocInitFunction
protected

Document initialization function.

◆ myCurrentWarnings

std::string makVre::DtQtQuickFileData::myCurrentWarnings
protected

Current warning messages.

◆ myFileToLoad

std::string makVre::DtQtQuickFileData::myFileToLoad
protected

Path to the QML file to load.

◆ myTargetWindow

std::string makVre::DtQtQuickFileData::myTargetWindow
protected

Name of the target window.


The documentation for this class was generated from the following file: