15#ifndef QGSPOINT3DBILLBOARDMATERIAL_H
16#define QGSPOINT3DBILLBOARDMATERIAL_H
23#include <Qt3DRender/QParameter>
24#include <Qt3DRender/QTexture>
55 PixelOffsets = 1 << 3,
56 VerticalOffset = 1 << 4,
105 void setTexture2DFromTextureImage( Qt3DRender::QAbstractTextureImage *textureImage );
107 Qt3DRender::QParameter *mSize =
nullptr;
108 Qt3DRender::QParameter *mViewportSize =
nullptr;
109 Qt3DRender::QParameter *mTexture2D =
nullptr;
110 Qt3DRender::QParameter *mVerticalOffset =
nullptr;
BillboardScaleMode
3D billboard scaling modes.
@ ViewIndependent
Billboard has a fixed pixel size on the screen, regardless of the camera distance.
Rendering context for preparation of 3D entities.
A marker symbol type, for rendering Point and MultiPoint geometries.
QgsMaterial(Qt3DCore::QNode *parent=nullptr)
Constructor for QgsMaterial, with the specified parent node.
void useDefaultSymbol(const Qgs3DRenderContext &context, bool selected=false)
Set default symbol for the texture with context and selected parameter for rendering.
QFlags< ExtraAttribute > ExtraAttributes
static QImage renderSymbolToImage(const QgsMarkerSymbol *markerSymbol, const Qgs3DRenderContext &context, bool selected=false)
Renders a marker symbol to an image.
void setVerticalOffset(float offset)
Set the vertical offset.
QSizeF windowSize() const
Returns the size of the view port.
void setTexture2DFromImage(const QImage &image)
Set the texture2D of the billboard from an image.
~QgsPoint3DBillboardMaterial() override
QSizeF size() const
Returns the billboard size.
QgsPoint3DBillboardMaterial(ExtraAttributes attributes=ExtraAttributes(), Qgis::BillboardScaleMode scaleMode=Qgis::BillboardScaleMode::ViewIndependent)
Constructor for QgsPoint3DBillboardMaterial, using the specified additional attributes.
void setTexture2DFromSymbol(const QgsMarkerSymbol *markerSymbol, const Qgs3DRenderContext &context, bool selected=false)
Set markerSymbol for the texture with context and selected parameter for rendering.
void setViewportSize(const QSizeF size)
Set the size of the view port.
void setSize(const QSizeF size)
Set the billboard size.
ExtraAttribute
Additional material attributes.