Obsolete Members for Qt3DRender | Qt 3D | Qt 6.12.0
Description: Contains classes that enable 2D and 3D rendering.
Keywords: auto-generated

- Qt 6.12
- Qt 3D
- Obsolete Members for Qt3DRender
- Qt 6.12.0 Reference Documentation

# Obsolete Members for Qt3DRender

The following members of class Qt3DRender are deprecated. They are provided to keep old source code working. We strongly advise against using them in new code.

## Namespaces

`(deprecated)` namespace | Quick
`(deprecated)` namespace | Render

## Classes

`(deprecated)` class | QAbstractLight
`(deprecated)` class | QAbstractRayCaster
`(deprecated)` class | QAbstractTexture
`(deprecated)` class | QAbstractTextureImage
`(deprecated)` class | QAlphaCoverage
`(deprecated)` class | QAlphaTest
`(deprecated)` class | QBlendEquation
`(deprecated)` class | QBlendEquationArguments
`(deprecated)` class | QBlitFramebuffer
`(deprecated)` class | QBufferCapture
`(deprecated)` class | QCamera
`(deprecated)` class | QCameraLens
`(deprecated)` class | QCameraSelector
`(deprecated)` class | QClearBuffers
`(deprecated)` class | QClipPlane
`(deprecated)` class | QColorMask
`(deprecated)` class | QComputeCommand
`(deprecated)` class | QCullFace
`(deprecated)` class | QDebugOverlay
`(deprecated)` class | QDepthRange
`(deprecated)` class | QDepthTest
`(deprecated)` class | QDirectionalLight
`(deprecated)` class | QDispatchCompute
`(deprecated)` class | QDithering
`(deprecated)` class | QEffect
`(deprecated)` class | QEnvironmentLight
`(deprecated)` class | QFilterKey
`(deprecated)` class | QFrameGraphNode
`(deprecated)` class | QFrontFace
`(deprecated)` class | QFrustumCulling
`(deprecated)` class | QGeometryRenderer
`(deprecated)` class | QGraphicsApiFilter
`(deprecated)` class | QLayer
`(deprecated)` class | QLayerFilter
`(deprecated)` class | QLevelOfDetail
`(deprecated)` class | QLevelOfDetailBoundingSphere
`(deprecated)` class | QLevelOfDetailSwitch
`(deprecated)` class | QLineWidth
`(deprecated)` class | QMaterial
`(deprecated)` class | QMemoryBarrier
`(deprecated)` class | QMesh
`(deprecated)` class | QMultiSampleAntiAliasing
`(deprecated)` class | QNoDepthMask
`(deprecated)` class | QNoDraw
`(deprecated)` class | QNoPicking
`(deprecated)` class | QObjectPicker
`(deprecated)` class | QPaintedTextureImage
`(deprecated)` class | QParameter
`(deprecated)` class | QPickEvent
`(deprecated)` class | QPickLineEvent
`(deprecated)` class | QPickPointEvent
`(deprecated)` class | QPickTriangleEvent
`(since 6.0, deprecated)` class | QPickingProxy
`(deprecated)` class | QPickingSettings
`(deprecated)` class | QPointLight
`(deprecated)` class | QPointSize
`(deprecated)` class | QPolygonOffset
`(deprecated)` class | QProximityFilter
`(deprecated)` class | QRasterMode
`(deprecated)` class | QRayCaster
`(deprecated)` class | QRayCasterHit
`(deprecated)` class | QRenderAspect
`(deprecated)` class | QRenderCapabilities
`(deprecated)` class | QRenderCapture
`(deprecated)` class | QRenderCaptureReply
`(deprecated)` class | QRenderPass
`(deprecated)` class | QRenderPassFilter
`(deprecated)` class | QRenderSettings
`(deprecated)` class | QRenderState
`(deprecated)` class | QRenderStateSet
`(deprecated)` class | QRenderSurfaceSelector
`(deprecated)` class | QRenderTarget
`(deprecated)` class | QRenderTargetOutput
`(deprecated)` class | QRenderTargetSelector
`(deprecated)` class | QSceneLoader
`(deprecated)` class | QScissorTest
`(deprecated)` class | QScreenRayCaster
`(deprecated)` class | QSeamlessCubemap
`(deprecated)` class | QSetFence
`(deprecated)` class | QShaderData
`(deprecated)` class | QShaderImage
`(deprecated)` class | QShaderProgram
`(deprecated)` class | QShaderProgramBuilder
`(deprecated)` class | QSharedGLTexture
`(deprecated)` class | QSortPolicy
`(deprecated)` class | QSpotLight
`(deprecated)` class | QStencilMask
`(deprecated)` class | QStencilOperation
`(deprecated)` class | QStencilOperationArguments
`(deprecated)` class | QStencilTest
`(deprecated)` class | QStencilTestArguments
`(deprecated)` class | QSubtreeEnabler
`(deprecated)` class | QTechnique
`(deprecated)` class | QTechniqueFilter
`(deprecated)` class | QTexture1D
`(deprecated)` class | QTexture1DArray
`(deprecated)` class | QTexture2D
`(deprecated)` class | QTexture2DArray
`(deprecated)` class | QTexture2DMultisample
`(deprecated)` class | QTexture2DMultisampleArray
`(deprecated)` class | QTexture3D
`(deprecated)` class | QTextureBuffer
`(deprecated)` class | QTextureCubeMap
`(deprecated)` class | QTextureCubeMapArray
`(deprecated)` class | QTextureData
`(deprecated)` class | QTextureDataUpdate
`(deprecated)` class | QTextureImage
`(deprecated)` class | QTextureImageData
`(deprecated)` class | QTextureImageDataGenerator
`(deprecated)` class | QTextureLoader
`(deprecated)` class | QTextureRectangle
`(deprecated)` class | QTextureWrapMode
`(deprecated)` class | QViewport
`(deprecated)` class | QWaitFence

## Namespaces

### `[deprecated]` namespace Qt3DRender::Quick

This namespace is deprecated. We strongly advise against using it in new code.

### `[deprecated]` namespace Qt3DRender::Render

This namespace is deprecated. We strongly advise against using it in new code.

## Classes

### `[deprecated]` class Qt3DRender::QAbstractLight

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QAbstractRayCaster

This class is deprecated. We strongly advise against using it in new code.

Qt3DRender::QAbstractRayCaster is an abstract base class for casting rays into a 3d scene. Qt3DRender::QAbstractRayCaster can not be directly instantiated, but rather through its subclasses. QAbstractRayCaster specifies common properties for all ray casters, such as run mode and layer handling, while leaving the actual ray casting details to the subclasses.

Ray castings differs from picking (using Qt3DRender::QObjectPicker) in that it does not require mouse events to trigger.

By default, the instances of Qt3DRender::QAbstractRayCaster are disabled. When enabled, the specified ray will be tested for intersecting objects at every frame. The QAbstractRayCaster::hits property will be updated with the results of the ray casting, even if no objects are found.

The Qt3DRender::QPickingSettings can be used to control the ray casting, such as which primitives are tested and how the results are returned.

Furthermore, Qt3DRender::QLayer components can be used to control how entities, or entity sub-graphs, react to ray casting.

Note: Components derived from QAbstractRayCaster should not be shared amount multiple entities.

See also Qt3DRender::QRayCaster, Qt3DRender::QScreenRayCaster, Qt3DRender::QObjectPicker, Qt3DRender::QPickingSettings, and Qt3DRender::QNoPicking.

### `[deprecated]` class Qt3DRender::QAbstractTexture

This class is deprecated. We strongly advise against using it in new code.

The QAbstractTexture class shouldn't be used directly but rather through one of its subclasses. Each subclass implements a given texture target (2D, 2DArray, 3D, CubeMap ...) Each subclass provides a set of functors for each layer, cube map face and mipmap level. In turn the backend uses those functor to properly fill a corresponding OpenGL texture with data. It is expected the functor does as minimal processing as possible so as not to slow down textures generation and upload. If the content of a texture is the result of a slow procedural generation process, it is recommended not to implement this directly in a functor.

All textures are unique. If you instantiate twice the same texture this will create 2 identical textures on the GPU, no sharing will take place.

### `[deprecated]` class Qt3DRender::QAbstractTextureImage

This class is deprecated. We strongly advise against using it in new code.

QAbstractTextureImage should be used as the means of providing image data to a QAbstractTexture. It contains the necessary information: mipmap level, layer, cube face load at the proper place data into an OpenGL texture.

The actual data is provided through a QTextureImageDataGenerator that will be executed by Aspect jobs in the backend. QAbstractTextureImage should be subclassed to provide a functor and eventual additional properties needed by the functor to load actual data.

Note: : QAbstractTextureImage should never be shared. Expect crashes, undefined behavior at best if this rule is not respected.

### `[deprecated]` class Qt3DRender::QAlphaCoverage

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QAlphaCoverage class enables alpha-to-coverage multisampling mode. When enabled, the fragment alpha value is used as a coverage for the sample and combined with fragment coverage value. Qt3DRender::QAlphaCoverage does nothing if multisampling is disabled. Alpha-to-coverage is most useful when order independent blending is required, for example when rendering leaves, grass and other rich vegetation.

It can be added to a QRenderPass by calling QRenderPass::addRenderState():

     QRenderPass *renderPass = new QRenderPass();

     // Create a alpha coverage render state
     QAlphaCoverage *alphaCoverage = new QAlphaCoverage();
     QMultiSampleAntiAliasing *multiSampleAntialiasing = new QMultiSampleAntiAliasing();

     // Add the render states to the render pass
     renderPass->addRenderState(alphaCoverage);
     renderPass->addRenderState(multiSampleAntialiasing);

Or to a QRenderStateSet by calling QRenderStateSet::addRenderState():

     QRenderStateSet *renderStateSet = new QRenderStateSet();

     // Create a alpha coverage render state
     QAlphaCoverage *alphaCoverage = new QAlphaCoverage();
     QMultiSampleAntiAliasing *multiSampleAntialiasing = new QMultiSampleAntiAliasing();

     // Add the render states to the render state set
     renderStateSet->addRenderState(alphaCoverage);
     renderStateSet->addRenderState(multiSampleAntialiasing);

See also Qt3DRender::QMultiSampleAntiAliasing.

### `[deprecated]` class Qt3DRender::QAlphaTest

This class is deprecated. We strongly advise against using it in new code.

As the OpenGL documentation explains; The alpha test discards a fragment conditional on the outcome of a comparison between the incoming fragment's alpha value and a constant reference value.

### `[deprecated]` class Qt3DRender::QBlendEquation

This class is deprecated. We strongly advise against using it in new code.

The blend equation is used to determine how a new pixel is combined with a pixel already in the framebuffer.

### `[deprecated]` class Qt3DRender::QBlendEquationArguments

This class is deprecated. We strongly advise against using it in new code.

OpenGL pre-3.0: Set the same blend state for all draw buffers (one QBlendEquationArguments) OpenGL 3.0-pre4.0: Set the same blend state for all draw buffers, but can disable blending for particular buffers (one QBlendEquationArguments for setting glBlendFunc, n QBlendEquationArgumentss for enabling/disabling Draw Buffers) OpenGL 4.0+: Can set blend state individually for each draw buffer.

### `[deprecated]` class Qt3DRender::QBlitFramebuffer

This class is deprecated. We strongly advise against using it in new code.

This node inserts a `glBlitFrameBuffer` or an equivalent into the command stream. This provides a more efficient method for copying rectangles between textures or surface backbuffers wrapped by QRenderTarget than drawing textured quads. It also supports scaling with the specified interpolation method.

Note: In practice the QBlitFramebuffer node will often be used in combination with QNoDraw since a blit should not involve issuing draw calls for any entities.

### `[deprecated]` class Qt3DRender::QBufferCapture

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QCamera

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QCameraLens

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QCameraSelector

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QCameraSelector can be used to select the camera, which is used by the FrameGraph when drawing the entities.

### `[deprecated]` class Qt3DRender::QClearBuffers

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QClearBuffers FrameGraph node enables clearing of the specific render target buffers with specific values.

### `[deprecated]` class Qt3DRender::QClipPlane

This class is deprecated. We strongly advise against using it in new code.

By default, OpenGL supports up to 8 additional clipping planes. Qt3DCore::QClipPlane allows to enable one of these additional planes. These planes can then be manipulated in the shaders using gl_ClipDistance[i] where i varies between 0 and 7. The underlying implementation may support more than 8 clip planes, but it is not guaranteed.

### `[deprecated]` class Qt3DRender::QColorMask

This class is deprecated. We strongly advise against using it in new code.

By default, the property for each color component (red, green, blue, alpha) is set to `true` which means they will be written to the frame buffer. Setting any of the color component to `false` will prevent it from being written into the frame buffer.

### `[deprecated]` class Qt3DRender::QComputeCommand

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QComputeCommand is used to issue work for the compute shader. The compute shader is specified in the QMaterial component of the same entity the QComputeCommand is added to. The workGroupX, workGroupY and workGroupZ properties specify the work group sizes for the compute shader invocation. Qt3DRender::QDispatchCompute node needs to be present in the FrameGraph to actually issue the commands.

Note: If the rendering policy is set to Qt3DRender::QRenderSettings::OnDemand and there are no changes to the scene, the ComputeCommand will not be invoked repeatedly. The Qt3DRender::QRenderSettings::Always render policy must be set for the ComputeCommand to be repeatedly invoked if there are no other changes to the scene that triggers rendering a new frame.

### `[deprecated]` class Qt3DRender::QCullFace

This class is deprecated. We strongly advise against using it in new code.

QCullFace sets whether the front or back facets are culled. Facets include triangles, quadrilaterals, polygons and rectangles.

It can be added by calling the addRenderState() method on a QRenderPass:

     // using namespace Qt3DRender;

     QRenderPass *renderPass = new QRenderPass();

     // Create a front face culling render state
     QCullFace *cullFront = new QCullFace();
     cullFront->setMode(QCullFace::Front);

     // Add the render state to the render pass
     renderPass->addRenderState(cullFront);

Or by calling the addRenderState() method on a QRenderStateSet:

     // using namespace Qt3DRender;

     QRenderStateSet *renderStateSet = new QRenderStateSet();

     // Create a front face culling render state
     QCullFace *cullFront = new QCullFace();
     cullFront->setMode(QCullFace::Front);

     // Add the render state to the render pass
     renderStateSet->addRenderState(cullFront);

See also QFrontFace.

### `[deprecated]` class Qt3DRender::QDebugOverlay

This class is deprecated. We strongly advise against using it in new code.

Placing a QDebugOverlay in one branch of a custom framegraph will cause an overlay with scene details to be rendered along with the scene.

The standard QForwardRenderer includes a QDebugOverlay node that can be enabled via the QForwardRenderer::showDebugOverlay property.

### `[deprecated]` class Qt3DRender::QDepthRange

This class is deprecated. We strongly advise against using it in new code.

By default, OpenGL writes scene depth information into the depth buffer in the range [0.0, 1.0] with 0.0 corresponding to the near clip plane and 1.0 to the far clip plane. QDepthRange allows mapping these values into a different range so parts of the scene are always rendered in front of or behind other parts. Valid values for near and far are between 0 and 1.

### `[deprecated]` class Qt3DRender::QDepthTest

This class is deprecated. We strongly advise against using it in new code.

A QDepthTest class is used to enable depth testing with a given depth test function. The depth test enables writing fragment color values when the depth test passes, and reject fragments which fail the test. The depth test uses the depth function to test the fragments depth value to the value against z-buffer. If the underlying surface does not have z-buffer, then QDepthTest does nothing.

See also QAlphaTest and QStencilTest.

### `[deprecated]` class Qt3DRender::QDirectionalLight

This class is deprecated. We strongly advise against using it in new code.

A directional light is a light source that behaves similar to sunlight. The light from a directional light hits all objects from the same direction and with the same intensity, regardless of where they are in the scene.

### `[deprecated]` class Qt3DRender::QDispatchCompute

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QDispatchCompute allows work to be issued for the compute shader to run on the GPU. The workGroupX, workGroupY and workGroupZ properties specify the work group sizes for the compute shader invocation. QComputeCommand components need to be added to entities to instruct Qt3D to select the materials and geometry from the entities for the compute invocation. The work group sizes for the shader invocation will be the maximum of the work group sizes specified in QDispatchCompute and QComputeCommand.

### `[deprecated]` class Qt3DRender::QDithering

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QDithering class enables dithering. Dithering adds noise to the color values to randomize quantization error in order to prevent large scale patterns in the final image, such as banding. Dithering is most useful when rendering to a surface with low color bit depth, such as RGB565 or RGBA4444.

### `[deprecated]` class Qt3DRender::QEffect

This class is deprecated. We strongly advise against using it in new code.

The QEffect class combines a set of techniques and parameters used by those techniques to produce a rendering effect for a material.

An QEffect instance should be shared among several QMaterial instances when possible.

Note: QEffect node can not be disabled.

     QEffect *effect = new QEffect();

     // Create technique, render pass and shader
     QTechnique *gl3Technique = new QTechnique();
     QRenderPass *gl3Pass = new QRenderPass();
     QShaderProgram *glShader = new QShaderProgram();

     // Set the shader on the render pass
     gl3Pass->setShaderProgram(glShader);

     // Add the pass to the technique
     gl3Technique->addRenderPass(gl3Pass);

     // Set the targeted GL version for the technique
     gl3Technique->graphicsApiFilter()->setApi(QGraphicsApiFilter::OpenGL);
     gl3Technique->graphicsApiFilter()->setMajorVersion(3);
     gl3Technique->graphicsApiFilter()->setMinorVersion(1);
     gl3Technique->graphicsApiFilter()->setProfile(QGraphicsApiFilter::CoreProfile);

     // Add the technique to the effect
     effect->addTechnique(gl3Technique);

A QParameter defined on a QEffect overrides parameter (of the same name) defined in QTechnique and QRenderPass, but are overridden by parameter in QRenderPassFilter, QTechniqueFilter and QMaterial.

See also QMaterial, QTechnique, and QParameter.

### `[deprecated]` class Qt3DRender::QEnvironmentLight

This class is deprecated. We strongly advise against using it in new code.

QEnvironmentLight uses cubemaps to implement image-based lighting (IBL), a technique often used in conjunction with physically-based rendering (PBR). The cubemaps are typically expected be based on high dynamic range (HDR) images, with a suitable OpenGL format (such as RGBA16F) that can handle the increased range of values.

There are a variety of tools that can be used to produce the cubemaps needed by QEnvironmentLight. Some examples include

- cmftStudio
- IBLBaker
- Lys

HDRI Haven provides many CC0-licensed HDR images that can be used as source material for the above tools.

### `[deprecated]` class Qt3DRender::QFilterKey

This class is deprecated. We strongly advise against using it in new code.

Filter keys are used by QTechnique and QRenderPass to specify at which stage of rendering the technique or the render pass is used.

Note: QFilterKey node can not be disabled.

### `[deprecated]` class Qt3DRender::QFrameGraphNode

This class is deprecated. We strongly advise against using it in new code.

This class is rarely instanced directly since it doesn't provide any frame graph specific behavior, although it can be convenient to use for grouping other nodes together in dynamic frame graphs. The actual behavior comes from the subclasses.

The subclasses are:

class | description
--- | ---
Qt3DRender::QCameraSelector | Select camera from all available cameras in the scene
Qt3DRender::QClearBuffers | Specify which buffers to clear and to what values
Qt3DRender::QDispatchCompute | Specify Compute operation kernels
Qt3DRender::QFrustumCulling | Enable frustum culling
Qt3DRender::QLayerFilter | Select which layers to draw
Qt3DRender::QNoDraw | Disable drawing
Qt3DRender::QRenderPassFilter | Select which render passes to draw
Qt3DRender::QRenderStateSet | Set render states
Qt3DRender::QRenderSurfaceSelector | Select which surface to draw to
Qt3DRender::QRenderTargetSelector | Select which QRenderTarget to draw to
Qt3DRender::QSortPolicy | Specify how entities are sorted to determine draw order
Qt3DRender::QTechniqueFilter | Select which techniques to draw
Qt3DRender::QViewport | Specify viewport
Qt3DRender::QMemoryBarrier | Places a memory barrier

### `[deprecated]` class Qt3DRender::QFrontFace

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QFrontFace sets the winding direction of the front facing polygons.

See also QCullFace.

### `[deprecated]` class Qt3DRender::QFrustumCulling

This class is deprecated. We strongly advise against using it in new code.

A QFrustumCulling class enables frustum culling of the drawable entities based on the camera view and QGeometry bounds of the entities. If QFrustumCulling is present in the FrameGraph, only the entities whose QGeometry bounds intersect with the camera frustum, i.e. the view of the camera, are drawn. If QFrustumCulling is not present, all drawable entities will be drawn. The camera is selected by a QCameraSelector frame graph node in the current hierarchy. Frustum culling can save a lot of GPU processing time when the rendered scene is complex.

See also QCameraSelector.

### `[deprecated]` class Qt3DRender::QGeometryRenderer

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QGeometryRenderer holds all the information necessary to draw a Qt3DCore::QGeometry. A QGeometry holds the coordinates of the geometry data - QGeometryRenderer specifies how to interpret that data.

### `[deprecated]` class Qt3DRender::QGraphicsApiFilter

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QLayer

This class is deprecated. We strongly advise against using it in new code.

Qt3DRender::QLayer works in conjunction with the Qt3DRender::QLayerFilter in the FrameGraph.

A QLayer can be applied to a subtree of entities by setting the recursive property to true.

      #include <Qt3DCore/QEntity>
      #include <Qt3DRender/QGeometryRenderer>
      #include <Qt3DRender/QLayer>
      #include <Qt3DRender/QLayerFilter>
      #include <Qt3DRender/QViewport>

     // Scene
     Qt3DCore::QEntity *rootEntity = new Qt3DCore::Qt3DCore::QEntity;

     Qt3DCore::QEntity *renderableEntity = new Qt3DCore::Qt3DCore::QEntity(rootEntity);
     Qt3DRender::QGeometryRenderer *geometryRenderer = new Qt3DCore::QGeometryRenderer(renderableEntity);
     Qt3DRender::QLayer *layer1 = new Qt3DCore::QLayer(renderableEntity);
     layer1->setRecursive(true);
     renderableEntity->addComponent(geometryRenderer);
     renderableEntity->addComponent(layer1);

     ...

     // FrameGraph
     Qt3DRender::QViewport *viewport = new Qt3DRender::QViewport;
     Qt3DRender::QLayerFilter *layerFilter = new Qt3DRender::QLayerFilter(viewport);
     layerFilter->addLayer(layer1);

     ...

See also Qt3DRender::QLayerFilter.

### `[deprecated]` class Qt3DRender::QLayerFilter

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QLayerFilter can be used to instruct the renderer as to which layer(s) to draw in that branch of the frame graph. QLayerFilter selects which entities to draw based on the QLayer instance(s) added to the QLayerFilter and as components to Qt3DCore::QEntity.

QLayerFilter can be configured to select or discard entities with a specific QLayer depending on the filterMode property. By default, entities referencing one of the QLayer objects that are also being referenced by the QLayerFilter are selected (AcceptAnyMatchingLayers).

Within the FrameGraph tree, multiple QLayerFilter nodes can be nested within a branch going from root to a leaf. In that case the filtering will first operate on all entities of the scene using the filtering method specified by the first declared QLayerFilter. Then the filtered subset of entities will be filtered again based on the filtering method set on the second QLayerFilter declared. This is then repeated until all QLayerFilter nodes of the branch have been consumed.

### `[deprecated]` class Qt3DRender::QLevelOfDetail

This class is deprecated. We strongly advise against using it in new code.

QLevelOfDetail can be used to control the representation of an entity based on distance from the observer or size on the screen.

In order to improve rendering performance, objects that are very small can be rendered using far fewer details, in geometry or texture.

The component is controlled by specifying thresholds of values which are interpreted as either distances from the camera or screen size.

As the point of view changes, the currentIndex property will change to reflect matching value in the range array.

The currentIndex property can then be used, for example, to enable or disable entities, change material, etc.

The LevelOfDetail component is not shareable between multiple entities.

      #include <Qt3DCore/QEntity>
      #include <Qt3DRender/QGeometryRenderer>
      #include <Qt3DRender/QLevelOfDetail>

     // Scene
     Qt3DCore::QEntity *rootEntity = new Qt3DCore::Qt3DCore::QEntity;

     Qt3DCore::QEntity *renderableEntity = new Qt3DCore::QEntity(rootEntity);
     Qt3DRender::QGeometryRenderer *geometryRenderer = new Qt3DCore::QGeometryRenderer(renderableEntity);
     renderableEntity->addComponent(geometryRenderer);
     Qt3DRender::QLevelOfDetail* lod = new Qt3Render::QLevelOfDetail(renderableEntity);
     QList<qreal> thresholds = {20, 35, 50, 65};
     lod->setThresholds(thresholds);
     lod->setCamera(mainCamera);
     renderableEntity->addComponent(lod);

     // connect to QLevelOfDetail::currentIndexChanged to toggle rendering
     ...

### `[deprecated]` class Qt3DRender::QLevelOfDetailBoundingSphere

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QLevelOfDetailSwitch

This class is deprecated. We strongly advise against using it in new code.

This component is assigned to an entity. When the entity changes distance relative to the camera, the QLevelOfDetailSwitch will disable all the child entities except the one matching index Qt3DRender::QLevelOfDetailSwitch::currentIndex.

### `[deprecated]` class Qt3DRender::QLineWidth

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QMaterial

This class is deprecated. We strongly advise against using it in new code.

QMaterial provides a way to specify the rendering of an entity. Any aspect can define its own subclass of QMaterial so that a Material can be used to describe a visual element; for example, the way sound should reflect off an element, the temperature of a surface, and so on.

In itself, a QMaterial doesn't do anything. It's only when it references a QEffect node that a QMaterial becomes useful.

In practice, it often happens that a single QEffect is being referenced by several QMaterial components. This allows to only create the effect, techniques, passes and shaders once while allowing to specify the material by adding QParameter instances.

A QParameter defined on a QMaterial overrides parameter (of the same name) defined in a QEffect, QTechnique and QRenderPass, but are overridden by parameter in QRenderPassFilter and QTechniqueFilter.

     QMaterial *material1 = new QMaterial();
     QMaterial *material2 = new QMaterial();

     // Create effect, technique, render pass and shader
     QEffect *effect = new QEffect();
     QTechnique *gl3Technique = new QTechnique();
     QRenderPass *gl3Pass = new QRenderPass();
     QShaderProgram *glShader = new QShaderProgram();

     // Set the shader on the render pass
     gl3Pass->setShaderProgram(glShader);

     // Add the pass to the technique
     gl3Technique->addRenderPass(gl3Pass);

     // Set the targeted GL version for the technique
     gl3Technique->graphicsApiFilter()->setApi(QGraphicsApiFilter::OpenGL);
     gl3Technique->graphicsApiFilter()->setMajorVersion(3);
     gl3Technique->graphicsApiFilter()->setMinorVersion(1);
     gl3Technique->graphicsApiFilter()->setProfile(QGraphicsApiFilter::CoreProfile);

     // Add the technique to the effect
     effect->addTechnique(gl3Technique);

     // Set the effect on the materials
     material1->setEffect(effect);
     material2->setEffect(effect);

     // Set different parameters on the materials
     const QString parameterName = QStringLiteral("color");
     material1->addParameter(new QParameter(parameterName, QColor::fromRgbF(0.0f, 1.0f, 0.0f, 1.0f)));
     material2->addParameter(new QParameter(parameterName, QColor::fromRgbF(1.0f, 1.0f, 1.0f, 1.0f)));

See also QEffect, QTechnique, and QParameter.

### `[deprecated]` class Qt3DRender::QMemoryBarrier

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QMemoryBarrier FrameGraph node is used to emplace a specific memory barrier at a specific time of the rendering. This is required to properly synchronize drawing and compute commands on the GPU.

The barrier defines the ordering of memory operations issued by a prior command. This means that if command1 is manipulating a buffer that is to be used as a vertex attribute buffer in a following command2, then the memory barrier should be placed after command1 and setting the appropriate barrier type for vertex attribute buffer.

When a QMemoryBarrier node is found in a FrameGraph branch, the barrier will be enforced prior to any draw or compute command even if these are defined deeper in the branch.

For OpenGL rendering, this page gives more info about the Memory Model

### `[deprecated]` class Qt3DRender::QMesh

This class is deprecated. We strongly advise against using it in new code.

Loads mesh data from external files in a variety of formats. Qt3DRender::QMesh loads data into a single mesh.

In Qt3D 5.9, QMesh supports the following formats:

- Wavefront OBJ
- Stanford Triangle Format PLY
- STL (STereoLithography)

QMesh will also support the following format if the SDK is installed and the fbx geometry loader plugin is built and found:

- Autodesk FBX

If you wish to load an entire scene made of several objects, you should rather use the Qt3DRender::QSceneLoader instead.

See also Qt3DRender::QSceneLoader.

### `[deprecated]` class Qt3DRender::QMultiSampleAntiAliasing

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QMultiSampleAntiAliasing class enables multisample antialiasing.

It can be added to a QRenderPass by calling QRenderPass::addRenderState():

     QRenderPass *renderPass = new QRenderPass();

     QMultiSampleAntiAliasing *msaa = new QMultiSampleAntiAliasing();
     renderPass->addRenderState(msaa);

Or a QRenderStateSet by calling QRenderStateSet::addRenderState():

     QRenderStateSet *renderStateSet = new QRenderStateSet();

     QMultiSampleAntiAliasing *msaa = new QMultiSampleAntiAliasing();
     renderStateSet->addRenderState(msaa);

For multisampling to take effect, the render target must have been allocated with multisampling enabled:

     QTexture2DMultisample *colorTex = new QTexture2DMultisample;
     colorTex->setFormat(QAbstractTexture::RGBA8_UNorm);
     colorTex->setWidth(1024);
     colorTex->setHeight(1024);

     QRenderTargetOutput *color = new QRenderTargetOutput;
     color->setAttachmentPoint(QRenderTargetOutput::Color0);
     color->setTexture(colorTex);

     QTexture2DMultisample *depthStencilTex = new QTexture2DMultisample;
     depthStencilTex->setFormat(QAbstractTexture::RGBA8_UNorm);
     depthStencilTex->setWidth(1024);
     depthStencilTex->setHeight(1024);

     QRenderTargetOutput *depthStencil = new QRenderTargetOutput;
     depthStencil->setAttachmentPoint(QRenderTargetOutput::DepthStencil);
     depthStencil->setTexture(depthStencilTex);

     Qt3DRender::QRenderTarget *renderTarget = new Qt3DRender::QRenderTarget;
     renderTarget->addOutput(color);
     renderTarget->addOutput(depthStencil);

Further, the shader code must use multisampling sampler types and texelFetch() instead of texture().

For example, if you have code like

     #version 150

     uniform sampler2D colorTexture;
     in vec2 texCoord;
     out vec4 fragColor;

     void main()
     {
         fragColor = texture(colorTexture, texCoord);
     }

you can rewrite it as

     #version 150

     uniform sampler2DMS colorTexture;
     in vec2 texCoord;
     out vec4 fragColor;

     void main()
     {
         ivec2 tc = ivec2(floor(textureSize(colorTexture) * texCoord));
         vec4 c = texelFetch(colorTexture, tc, 0) +
                     texelFetch(colorTexture, tc, 1) +
                     texelFetch(colorTexture, tc, 2) +
                     texelFetch(colorTexture, tc, 3);
         fragColor = c / 4.0;
     }

Note: When using OpenGL as the graphics API, glEnable(GL_MULTISAMPLE) will be called if QMultiSampleAntiAliasing has been added to the render states.

### `[deprecated]` class Qt3DRender::QNoDepthMask

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QNoDepthMask class disables fragment depth write to depth buffer.

See also Qt3DRender::QDepthTest.

### `[deprecated]` class Qt3DRender::QNoDraw

This class is deprecated. We strongly advise against using it in new code.

Qt3DRender::QNoDraw should be used when the FrameGraph needs to set up some render states or clear some buffers without requiring any mesh to be drawn. It has the same effect as having a Qt3DRender::QRenderPassFilter that matches none of available Qt3DRender::QRenderPass instances of the scene without the overhead cost of actually performing the filtering.

When disabled, a Qt3DRender::QNoDraw node won't prevent the scene from being rendered. Toggling the enabled property is therefore a way to make a Qt3DRender::QNoDraw active or inactive.

Qt3DRender::QNoDraw is usually used as a child of a Qt3DRendeR::QClearBuffers node to prevent from drawing the scene when there are multiple render passes.

     Qt3DRender::QViewport *viewport = new Qt3DRender::QViewport();
     Qt3DRender::QCameraSelector *cameraSelector = new Qt3DRender::QCameraSelector(viewport);

     Qt3DRender::QClearBuffers *clearBuffers = new Qt3DRender::QClearBuffers(cameraSelector);
     clearBuffers->setBuffers(Qt3DRender::QClearBuffers::ColorDepthBuffer);

     Qt3DRender::QNoDraw *noDraw = new Qt3DRender::QNoDraw(clearBuffers);

     Qt3DRender::QRenderPassFilter *mainPass = new Qt3DRender::QRenderPassFilter(cameraSelector);
     ....
     Qt3DRender::QRenderPassFilter *previewPass = new Qt3DRender::QRenderPassFilter(cameraSelector);
     ....

### `[deprecated]` class Qt3DRender::QNoPicking

This class is deprecated. We strongly advise against using it in new code.

When disabled, a Qt3DRender::QNoPicking node won't prevent picking from being performed. Toggling the enabled property is therefore a way to make a Qt3DRender::QNoPicking active or inactive.

When using multiple subviewports in the FrameGraph, QNoPicking can be useful to prevent picking conflicts between overlapping viewports or non visual ones. It can also be used as an optimization to prevent unnecessary work for hidden viewports or for sections of the scenes which don't require any picking.

     Qt3DRender::QViewport *viewport = new Qt3DRender::QViewport();
     Qt3DRender::QCameraSelector *cameraSelector = new Qt3DRender::QCameraSelector(viewport);
     Qt3DRender::QNoPicking *noPicking = new Qt3DRender::QNoPicking(cameraSelector);

     Qt3DRender::QClearBuffers *clearBuffers = new Qt3DRender::QClearBuffers(noPicking);
     clearBuffers->setBuffers(Qt3DRender::QClearBuffers::ColorDepthBuffer);

     Qt3DRender::QRenderPassFilter *mainPass = new Qt3DRender::QRenderPassFilter(cameraSelector);
     ....
     Qt3DRender::QRenderPassFilter *previewPass = new Qt3DRender::QRenderPassFilter(cameraSelector);
     ....

See also Qt3DRender::QObjectPicker, Qt3DRender::QRayCaster, and Qt3DRender::QScreenRayCaster.

### `[deprecated]` class Qt3DRender::QObjectPicker

This class is deprecated. We strongly advise against using it in new code.

For every combination of viewport and camera, picking casts a ray through the scene to find entities who's bounding volume intersects the ray. The bounding volume is computed using the values in the attribute buffer specified by the boundingVolumePositionAttribute of the geometry.

The signals pressed(), released(), clicked(), moved(), entered(), and exited() are emitted when the bounding volume defined by the pickAttribute property intersects with a ray.

Most signals carry a QPickEvent instance. If QPickingSettings::pickMode() is set to QPickingSettings::TrianglePicking, the actual type of the pick parameter will be QPickTriangleEvent.

Pick queries are performed on mouse press and mouse release. If drag is enabled, queries also happen on each mouse move while any button is pressed. If hover is enabled, queries happen on every mouse move even if no button is pressed.

For generalised ray casting queries, see Qt3DRender::QRayCaster and Qt3DRender::QScreenRayCaster.

Note: Instances of this component shouldn't be shared, not respecting that condition will most likely result in undefined behavior.

Note: The camera far plane value affects picking and produces incorrect results due to floating-point precision if it is greater than ~100 000.

See also Qt3DRender::QPickingSettings, Qt3DCore::QGeometry, Qt3DCore::QAttribute, Qt3DRender::QPickEvent, Qt3DRender::QPickTriangleEvent, and Qt3DRender::QNoPicking.

### `[deprecated]` class Qt3DRender::QPaintedTextureImage

This class is deprecated. We strongly advise against using it in new code.

A QPaintedTextureImage provides a way to specify a texture image (and thus an OpenGL texture) through a QPainter. The width and height of the texture image can be specified through the width and height or size properties.

A QPaintedTextureImage must be subclassed and the virtual paint() function implemented. Each time update() is called on the QPaintedTextureImage, the paint() function is invoked and the resulting image is uploaded.

The QPaintedTextureImage must be attached to some QAbstractTexture.

### `[deprecated]` class Qt3DRender::QParameter

This class is deprecated. We strongly advise against using it in new code.

A QParameter can be referenced by a QRenderPass, QTechnique, QEffect, QMaterial, QTechniqueFilter, QRenderPassFilter. At runtime, depending on which shader is selected for a given step of the rendering, the value contained in a QParameter will be converted and uploaded if the shader contains a uniform with a name matching that of the QParameter.

     QParameter *param = new QParameter();
     param->setName(QStringLiteral("diffuseColor"));
     param->setValue(QColor::fromRgbF(0.0f, 0.0f, 1.0f, 1.0f));

     // Alternatively you can create and set a QParameter this way
     QParameter *param2 = new QParameter(QStringLiteral("diffuseColor"), QColor::fromRgbF(0.0f, 0.0f, 1.0f, 1.0f));

     // Such QParameters will work with the following GLSL uniform shader declarations
     // uniform vec4 diffuseColor;
     // uniform vec3 diffuseColor;
     // uniform vec2 diffuseColor;
     // uniform float diffuseColor;

Note: some care must be taken to ensure the value wrapped by a QParameter can actually be converted to what the real uniform expect. Giving a value stored as an int where the actual shader uniform is of type float could result in undefined behaviors.

Note: when the targeted uniform is an array, the name should be the name of the uniform with [0] appended to it.

Note: QParameter node can not be disabled.

     QParameter *param = new QParameter();
     QVariantList values = QVariantList() << 0.0f << 1.0f << 2.0f << 3.0f << 4.0f << 883.0f << 1340.0f << 1584.0f;

     param->setName(QStringLiteral("diffuseValues[0]"));
     param->setValue(values);

     // Matching GLSL shader uniform  declaration
     // uniform float diffuseValues[8];

When it comes to texture support, the QParameter value should be set to the appropriate QAbstractTexture subclass that matches the sampler type of the shader uniform.

     QTexture2D *texture = new QTexture2D();
     ...
     QParameter *param = new QParameter();
     param->setName(QStringLiteral("diffuseTexture"));
     param->setValue(QVariant::fromValue(texture));

     // Works with the following GLSL uniform shader declaration
     // uniform sampler2D diffuseTexture

See also QAbstractTexture.

### `[deprecated]` class Qt3DRender::QPickEvent

This class is deprecated. We strongly advise against using it in new code.

This is received as a parameter in most of the QObjectPicker component signals when picking succeeds.

See also QPickingSettings, QPickTriangleEvent, and QObjectPicker.

### `[deprecated]` class Qt3DRender::QPickLineEvent

This class is deprecated. We strongly advise against using it in new code.

See also QPickEvent.

### `[deprecated]` class Qt3DRender::QPickPointEvent

This class is deprecated. We strongly advise against using it in new code.

See also QPickEvent.

### `[deprecated]` class Qt3DRender::QPickTriangleEvent

This class is deprecated. We strongly advise against using it in new code.

When QPickingSettings::pickMode() is set to QPickingSettings::TrianglePicking, the signals on QObjectPicker will carry an instance of QPickTriangleEvent.

This contains the details of the triangle that was picked.

Note: In the case of indexed rendering, the point indices are relative to the array of coordinates, not the array of indices.

See also QPickingSettings, QPickEvent, and QObjectPicker.

### `[since 6.0, deprecated]` class Qt3DRender::QPickingProxy

This class is deprecated. We strongly advise against using it in new code.

Picking can be an expensive operation, especially if the mesh has a lot of vertices. QPickProxy can be used to provide an alternative geometry, usually with fewer primitives, which will be used for picking, while the GeometryRenderer instance will be used for rendering.

Note: Do not use a QPickingProxy if the application requires picking coordinates to match the rendered mesh.

Note: The picking algorithm uses a bounding volume hierarchy to optimize out entities who's bounding volume does not intersect the picking ray. For that hierarchy, the bounding volume of the renderered entity is used (or one explicitly set using a QBoundingVolume component) will be used rather than the one of the proxy.

This class was introduced in Qt 6.0.

### `[deprecated]` class Qt3DRender::QPickingSettings

This class is deprecated. We strongly advise against using it in new code.

The picking settings determine how the entity picking is handled. For more details about entity picking, see QObjectPicker and QRayCaster component documentation.

When using QObjectPicker components, picking is triggered by mouse events.

When using QRayCaster or QScreenRayCaster components, picking can be explicitly triggered by the application.

In both cases, a ray will be cast through the scene to find geometry intersecting the ray.

See also QObjectPicker, QPickEvent, QPickTriangleEvent, QRayCaster, and QScreenRayCaster.

### `[deprecated]` class Qt3DRender::QPointLight

This class is deprecated. We strongly advise against using it in new code.

A point light is a light source that emits light in all directions, from a single point. Conceptually, this is similar to light given off by a standard light bulb.

A point light uses three attenuation factors to describe how the intensity of the light decreases over distance. These factors are designed to be used together in calcuating total attenuation. For the materials in Qt3D Extras the following formula is used, where distance is the distance from the light to the surface being rendered:

     totalAttenuation = 1.0 / (constantAttenuation + (linearAttenuation * distance) + (quadraticAttenuation * distance * distance));

Custom materials may choose to interpret these factors differently.

### `[deprecated]` class Qt3DRender::QPointSize

This class is deprecated. We strongly advise against using it in new code.

When the sizeMode property is set to SizeMode::Fixed, the value is set using glPointSize(), if available. When using SizeMode::Programmable, gl_PointSize must be set within shader programs, the value provided to this RenderState is ignored in that case.

### `[deprecated]` class Qt3DRender::QPolygonOffset

This class is deprecated. We strongly advise against using it in new code.

A QPolygonOffset class adds an offset to the fragment depth value prior to depth test and depth write. The offset can be used to avoid z-fighting when rendering polygons with very close depth values such as decals.

### `[deprecated]` class Qt3DRender::QProximityFilter

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QProximityFilter can be used to select entities to render when they are placed within a given distance threshold of another entity.

### `[deprecated]` class Qt3DRender::QRasterMode

This class is deprecated. We strongly advise against using it in new code.

The QRasterMode class is used to control the rasterization step of the primitives at render time. This can be used to choose whether we only want to show points, edges or fill a primitive.

Note: This is not supported when rendering on OpenGL ES 2.0 platforms.

See also QAlphaTest and QStencilTest.

### `[deprecated]` class Qt3DRender::QRayCaster

This class is deprecated. We strongly advise against using it in new code.

The 3d ray is defined by its origin, direction and length. It will be affected by the transformations applied to the entity it belongs to.

Ray casting tests will be performed every frame as long as the component is enabled. The hits property will be updated with the list of intersections.

See also QAbstractRayCaster, QScreenRayCaster, and QNoPicking.

### `[deprecated]` class Qt3DRender::QRayCasterHit

This class is deprecated. We strongly advise against using it in new code.

Qt3DRender::QRayCasterHit contains the details of a successful hit when casting a ray through a model using a Qt3DRender::QRayCaster or Qt3DRender::QScreenRayCaster component.

See also Qt3DRender::QRayCaster, Qt3DRender::QScreenRayCaster, and Qt3DRender::QPickingSettings.

### `[deprecated]` class Qt3DRender::QRenderAspect

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QRenderCapabilities

This class is deprecated. We strongly advise against using it in new code.

QRenderCapabilities provides details of graphical features that are available at runtime. It can be used to decide which code path to use for some algorithms, for example, depending on whether compute shaders are available or not.

### `[deprecated]` class Qt3DRender::QRenderCapture

This class is deprecated. We strongly advise against using it in new code.

The QRenderCapture is used to capture rendering into an image at any render stage. Capturing must be initiated by the user and one image is returned per capture request. User can issue multiple render capture requests simultaniously, but only one request is served per QRenderCapture instance per frame.

### `[deprecated]` class Qt3DRender::QRenderCaptureReply

This class is deprecated. We strongly advise against using it in new code.

An object, which receives the image from QRenderCapture::requestCapture.

### `[deprecated]` class Qt3DRender::QRenderPass

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QRenderPass specifies a single rendering pass - an instance of shader program execution - used by Qt3DRender::QTechnique. Render pass consists of a Qt3DRender::QShaderProgram and a list of Qt3DRender::QFilterKey objects, a list of Qt3DRender::QRenderState objects and a list of Qt3DRender::QParameter objects.

QRenderPass executes the QShaderProgram using the given QRenderState and QParameter nodes when at least one of QFilterKey nodes being referenced matches any of the QFilterKey nodes in QRenderPassFilter or when no QFilterKey nodes are specified and no QRenderPassFilter is present in the FrameGraph.

If the QRenderPass defines a QParameter, it will be overridden by a QParameter with the same name if it exists in any of the QTechnique, QEffect, QMaterial, QTechniqueFilter, QRenderPassFilter associated with the pass at runtime. This still can be useful to define sane default values.

At render time, for each leaf node of the FrameGraph a base render state is recorded by accumulating states defined by all QRenderStateSet nodes in the FrameGraph branch. Each QRenderPass can overload this base render state by specifying its own QRenderState nodes.

     // Create the render passes
     QRenderPass *pass = new QRenderPass();

     // Create shader program
     QShaderProgram *glShader = new QShaderProgram();

     // Set the shader on the render pass
     pass->setShaderProgram(glShader);

     // Create a FilterKey
     QFilterKey *filterKey = new QFilterKey();
     filterKey->setName(QStringLiteral("name"));
     fitlerKey->setValue(QStringLiteral("zFillPass"));

     // Add the FilterKey to the pass
     pass->addFilterKey(filterKey);

     // Create a QParameter
     QParameter *colorParameter = new QParameter(QStringLiteral("color"), QColor::fromRgbF(0.0f, 0.0f, 1.0f, 1.0f));

     // Add parameter to pass
     pass->addParameter(colorParameter);

     // Create a QRenderState
     QDepthTest *depthTest = new QDepthTest();

     // Add the render state to the pass
     pass->addRenderState(depthTest);

See also QRenderPassFilter, QFilterKey, QParameter, QRenderState, QEffect, and QTechnique.

### `[deprecated]` class Qt3DRender::QRenderPassFilter

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QRenderPassFilter FrameGraph node is used to select which Qt3DRender::QRenderPass objects are selected for drawing. QRenderPassFilter specifies a list of Qt3DRender::QFilterKey objects and Qt3DRender::QParameter objects. When QRenderPassFilter is present in the FrameGraph, only the QRenderPass objects, whose Qt3DRender::QFilterKey objects match the keys in QRenderPassFilter are selected for rendering. If no QRenderPassFilter is present, then all QRenderPass objects are selected for rendering. The parameters in the list can be used to set values for shader parameters. The parameters in QRenderPassFilter override parameters in QTechniqueFilter, QMaterial, QEffect, QTechnique and QRenderPass.

### `[deprecated]` class Qt3DRender::QRenderSettings

This class is deprecated. We strongly advise against using it in new code.

The QRenderSettings component must be set as a component of the scene root entity. It specifies render policy and picking settings, as well as hosts the active FrameGraph.

### `[deprecated]` class Qt3DRender::QRenderState

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QRenderState class is abstract base class for all render states. One can not instantiate QRenderState directly, but through its subclasses.

### `[deprecated]` class Qt3DRender::QRenderStateSet

This class is deprecated. We strongly advise against using it in new code.

States set on a QRenderStateSet are set globally, contrary to the per-material states that can be set on a QRenderPass. By default, an empty QRenderStateSet will result in all render states being disabled when executed. Adding a QRenderState state explicitly enables that render state at runtime.

The RenderStateSet is enabled when added to the active frame graph:

     // using namespace Qt3DRender;

     Qt3DCore::QEntity *rootEntity = new Qt3DCore::QEntity();

     QRenderSettings *renderSettings = new QRenderSettings();

     QViewport *viewport = new QViewport();
     QCameraSelector *cameraSelector = new QCameraSelector(viewport);

     QClearBuffers *clearBuffers = new QClearBuffers(cameraSelector);
     clearBuffers->setBuffers(QClearBuffers::ColorDepthBuffer);

     QRenderStateSet *renderStateSet = new QRenderStateSet(cameraSelector);
     QCullFace *cullFace = new QCullFace(renderStateSet);
     cullFace->setMode(QCullFace::Front);
     renderStateSet->addRenderState(cullFace);

     renderSettings->setActiveFrameGraph(viewport);

     rootEntity->addComponent(renderSettings);

See also QRenderState and QRenderPass.

### `[deprecated]` class Qt3DRender::QRenderSurfaceSelector

This class is deprecated. We strongly advise against using it in new code.

The Qt3DRender::QRenderSurfaceSelector can be used to select the surface, where Qt3D renders the content. The surface can either be window surface or offscreen surface. The externalRenderTargetSize is used to specify the actual size of the surface when offscreen surface is used.

When DPI scaling is used by the system, the logical surface size, which is used by mouse events, and the actual 'physical' size of the surface can differ. The surfacePixelRatio is the factor to convert the logical size to the physical size.

See also QWindow, QOffscreenSurface, and QSurface.

### `[deprecated]` class Qt3DRender::QRenderTarget

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QRenderTarget comprises of Qt3DRender::QRenderTargetOutput objects, which specify the the buffers the render target is rendering to. The user can specify MRT(Multiple Render Targets) by attaching multiple textures to different attachment points. The results are undefined if the user tries to attach multiple textures to the same attachment point. At render time, only the draw buffers specified in the Qt3DRender::QRenderTargetSelector are used.

### `[deprecated]` class Qt3DRender::QRenderTargetOutput

This class is deprecated. We strongly advise against using it in new code.

A QRenderTargetOutput specifies the attachment point and parameters for texture that is attached to render target. In addition to the attachment point, texture miplevel, layer and cubemap face can be specified. The texture attached to the QRenderTargetOutput must be compatible with the given parameters.

Note: Left and Right attachment points are special values. They do not refer to render target objects to be either of the back buffers used for stereo rendering.

### `[deprecated]` class Qt3DRender::QRenderTargetSelector

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QRenderTargetSelector is used to select active Qt3DRender::QRenderTarget for the FrameGraph. When QRenderTargetSelector is present in the FrameGraph, the rendering is directed into QTexture objects or draw buffers instead of the surface specified in the Qt3DRender::QRenderSurfaceSelector.

### `[deprecated]` class Qt3DRender::QSceneLoader

This class is deprecated. We strongly advise against using it in new code.

Given a 3D source file, the Qt3DRender::QSceneLoader will try to parse it and build a tree of Qt3DCore::QEntity objects with proper Qt3DRender::QGeometryRenderer, Qt3DCore::QTransform and Qt3DRender::QMaterial components.

The loader will try to determine the best material to be used based on the properties of the model file. If you wish to use a custom material, you will have to traverse the tree and replace the default associated materials with yours.

As the name implies, Qt3DRender::QSceneLoader loads a complete scene subtree. If you wish to load a single piece of geometry, you should rather use the Qt3DRender::QMesh instead.

Qt3DRender::QSceneLoader internally relies on the use of plugins to support a wide variety of 3D file formats. Here is a list of formats that are supported by Qt3D.

Note: this component shouldn't be shared among several Qt3DCore::QEntity instances. Undefined behavior will result.

See also Qt3DRender::QMesh and Qt3DRender::QGeometryRenderer.

### `[deprecated]` class Qt3DRender::QScissorTest

This class is deprecated. We strongly advise against using it in new code.

A QScissorTest class enables scissor test, which discards fragments outside the rectangular area of the screen specified by the left, bottom, width and height properties.

### `[deprecated]` class Qt3DRender::QScreenRayCaster

This class is deprecated. We strongly advise against using it in new code.

QScreenRayCaster can be used to perform ray casting tests by specifying coordinates in screen space, which will be used to construct an actual 3D ray between the near and far planes.

See also QRayCaster and QNoPicking.

### `[deprecated]` class Qt3DRender::QSeamlessCubemap

This class is deprecated. We strongly advise against using it in new code.

When present in a state set, enables the seamless cubemap texture filtering as provided by the GL_ARB_seamless_cubemap extension (if available).

### `[deprecated]` class Qt3DRender::QSetFence

This class is deprecated. We strongly advise against using it in new code.

Fence allow to synchronosize GPU and CPU workloads. GPU commands usually are non-blocking. When issued, commands are inserted in command buffers which will be read at a later time by the GPU. In some cases, you want to continue processing or issue specific command only when you are sure a command has been executed by the hardware. Fences are a way to do so. This is especially important when using 3rd party engines with Qt3D, Qt3D should only access shared resources when we know the other engine command are done modifying the resource.

QSetFence is a FrameGraph node that inserts a fence into the command stream. It can then be used in conjunction with QWaitFence or by extracting the underlying handle.

The handle property will be updated once the renderer has created the underlying fence resource. The handle will remain valid as long as it remains in the unsignaled state. Once it has reached the signaled state, it will be destroyed and a new handle will be created. That means that depending on how long it takes for the fence to be signaled, the same handle could be used over several frames.

### `[deprecated]` class Qt3DRender::QShaderData

This class is deprecated. We strongly advise against using it in new code.

Note: When subclassing and adding properties to QShaderData, note that if you need to nest an inner Qt3DRender::QShaderData, the data type of the property should be Qt3DRender::QShaderData* instead of the name of your subclass.

### `[deprecated]` class Qt3DRender::QShaderImage

This class is deprecated. We strongly advise against using it in new code.

To make the content of textures available for read and write operations in a shader, they need to exposed as QShaderImage. Textures can be composed of several mip levels, layers and faces. Additionally declaring a QShaderImage allows specifying which level, layer or face of the texture content we want to access.

QShaderImage has to be assigned as a QParameter's value and reference a valid Qt3DRender::QAbstractTexture to work properly.

If the referenced texture is a one-dimensional array, two-dimensional array, three-dimensional, cube map, cube map array, or two-dimensional multisample array texture, it is possible to bind either the entire texture level or a single layer or face of the texture level. This can be controlled with the layered property.

Support for QShaderImage is only supported with OpenGL 4 and partially with OpenGL ES 3.1 and 3.2.

OpenGL 4 supports the following image types:

GLSL Type | OpenGL Type Enum | Texture Type
--- | --- | ---
image1D | GL_IMAGE_1D | QTexture1D
image2D | GL_IMAGE_2D | QTexture2D
image3D | GL_IMAGE_3D | QTexture3D
image2DRect | GL_IMAGE_2D_RECT | QTextureRectangle
imageCube | GL_IMAGE_CUBE | QTextureCubeMap
imageBuffer | GL_IMAGE_BUFFER | QTextureBuffer
image1DArray | GL_IMAGE_1D_ARRAY | QTexture1DArray
image2DArray | GL_IMAGE_2D_ARRAY | QTexture2DArray
imageCubeArray | GL_IMAGE_CUBE_MAP_ARRAY | QTextureCubeMapArray
image2DMS | GL_IMAGE_2D_MULTISAMPLE | QTexture2DMultisample
image2DMSArray | GL_IMAGE_2D_MULTISAMPLE_ARRAY | QTexture2DMultisampleArray
iimage1D | GL_INT_IMAGE_1D | QTexture1D
iimage2D | GL_INT_IMAGE_2D | QTexture2D
iimage3D | GL_INT_IMAGE_3D | QTexture3D
iimage2DRect | GL_INT_IMAGE_2D_RECT | QTextureRectangle
iimageCube | GL_INT_IMAGE_CUBE | QTextureCubeMap
iimageBuffer | GL_INT_IMAGE_BUFFER | QTextureBuffer
iimage1DArray | GL_INT_IMAGE_1D_ARRAY | QTexture1DArray
iimage2DArray | GL_INT_IMAGE_2D_ARRAY | QTexture2DArray
iimageCubeArray | GL_INT_IMAGE_CUBE_MAP_ARRAY | QTextureCubeMapArray
iimage2DMS | GL_INT_IMAGE_2D_MULTISAMPLE | QTexture2DMultisample
iimage2DMSArray | GL_INT_IMAGE_2D_MULTISAMPLE_ARRAY | QTexture2DMultisampleArray
uimage1D | GL_UNSIGNED_INT_IMAGE_1D | QTexture1D
uimage2D | GL_UNSIGNED_INT_IMAGE_2D | QTexture2D
uimage3D | GL_UNSIGNED_INT_IMAGE_3D | QTexture3D
uimage2DRect | GL_UNSIGNED_INT_IMAGE_2D_RECT | QTextureRectangle
uimageCube | GL_UNSIGNED_INT_IMAGE_CUBE | QTextureCubeMap
uimageBuffer | GL_UNSIGNED_INT_IMAGE_BUFFER | QTextureBuffer
uimage1DArray | GL_UNSIGNED_INT_IMAGE_1D_ARRAY | QTexture1DArray
uimage2DArray | GL_UNSIGNED_INT_IMAGE_2D_ARRAY | QTexture2DArray
uimageCubeArray | GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY | QTextureCubeMapArray
uimage2DMS | GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE | QTexture2DMultisample
uimage2DMSArray | GL_UNSIGNED_INT_IMAGE_2D_MULTISAMPLE_ARRAY | QTexture2DMultisampleArray

OpenGL ES 3.1 supports the following image types:

GLSL Type | OpenGL Type Enum | Texture Type
--- | --- | ---
image2D | GL_IMAGE_2D | QTexture2D
image3D | GL_IMAGE_3D | QTexture3D
imageCube | GL_IMAGE_CUBE | QTextureCubeMap
image2DArray | GL_IMAGE_2D_ARRAY | QTexture2DArray
iimage2D | GL_INT_IMAGE_2D | QTexture2D
iimage3D | GL_INT_IMAGE_3D | QTexture3D
iimageCube | GL_INT_IMAGE_CUBE | QTextureCubeMap
iimage2DArray | GL_INT_IMAGE_2D_ARRAY | QTexture2DArray
uimage2D | GL_UNSIGNED_INT_IMAGE_2D | QTexture2D
uimage3D | GL_UNSIGNED_INT_IMAGE_3D | QTexture3D
uimageCube | GL_UNSIGNED_INT_IMAGE_CUBE | QTextureCubeMap
uimage2DArray | GL_UNSIGNED_INT_IMAGE_2D_ARRAY | QTexture2DArray

OpenGL ES 3.2 supports all of the OpenGL ES 3.1 image types as well as the following:

GLSL Type | OpenGL Type Enum | Texture Type
--- | --- | ---
imageBuffer | GL_IMAGE_BUFFER | QTextureBuffer
imageCubeArray | GL_IMAGE_CUBE_MAP_ARRAY | QTextureCubeMapArray
iimageBuffer | GL_IMAGE_BUFFER | QTextureBuffer
iimageCubeArray | GL_INT_IMAGE_CUBE_MAP_ARRAY | QTextureCubeMapArray
uimageBuffer | GL_UNSIGNED_INT_IMAGE_BUFFER | QTextureBuffer
uimageCubeArray | GL_UNSIGNED_INT_IMAGE_CUBE_MAP_ARRAY | QTextureCubeMapArray

Expected use would look like:

     Qt3DRender::QTexture2D *tex2D = new Qt3DRender::QTexture2D();
     ...
     Qt3DRender::QMaterial *material = new Qt3DRender::QMaterial();
     ...
     Qt3DRender::QParameter *imageParameter = new Qt3DRender::QParameter();
     Qt3DRender::QShaderImage *shaderImage = new Qt3DRender::QShaderImage();

     shaderImage->setTexture(tex2D);

     imageParameter->setName("imageUniformName");
     imageParameter->setValue(QVariant::fromValue(shaderImage));

     material->addParameter(imageParamenter);

### `[deprecated]` class Qt3DRender::QShaderProgram

This class is deprecated. We strongly advise against using it in new code.

A shader program consists of several different shaders, such as vertex and fragment shaders.

Qt3D will automatically populate a set of default uniforms if they are encountered during the shader instrospection phase.

Default Uniform | Associated Qt3D Parameter name | GLSL declaration
--- | --- | ---
ModelMatrix | modelMatrix | uniform mat4 modelMatrix;
ViewMatrix | viewMatrix | uniform mat4 viewMatrix;
ProjectionMatrix | projectionMatrix | uniform mat4 projectionMatrix;
ModelViewMatrix | modelView | uniform mat4 modelView;
ViewProjectionMatrix | viewProjectionMatrix | uniform mat4 viewProjectionMatrix;
ModelViewProjectionMatrix | modelViewProjection mvp | uniform mat4 modelViewProjection; uniform mat4 mvp;
InverseModelMatrix | inverseModelMatrix | uniform mat4 inverseModelMatrix;
InverseViewMatrix | inverseViewMatrix | uniform mat4 inverseViewMatrix;
InverseProjectionMatrix | inverseProjectionMatrix | uniform mat4 inverseProjectionMatrix;
InverseModelViewMatrix | inverseModelView | uniform mat4 inverseModelView;
InverseViewProjectionMatrix | inverseViewProjectionMatrix | uniform mat4 inverseViewProjectionMatrix;
InverseModelViewProjectionMatrix | inverseModelViewProjection | uniform mat4 inverseModelViewProjection;
ModelNormalMatrix | modelNormalMatrix | uniform mat3 modelNormalMatrix;
ModelViewNormalMatrix | modelViewNormal | uniform mat3 modelViewNormal;
ViewportMatrix | viewportMatrix | uniform mat4 viewportMatrix;
InverseViewportMatrix | inverseViewportMatrix | uniform mat4 inverseViewportMatrix;
AspectRatio (surface width / surface height) | aspectRatio | uniform float aspectRatio;
Exposure | exposure | uniform float exposure;
Gamma | gamma | uniform float gamma;
Time (in nano seconds) | time | uniform float time;
EyePosition | eyePosition | uniform vec3 eyePosition;
SkinningPalette | skinningPalette[0] | const int maxJoints = 100; uniform mat4 skinningPalette[maxJoints];

### RHI Support

When writing GLSL 450 shader code to use with Qt 3D's RHI backend, the default uniforms will be provided as 2 uniform buffer objects.

The binding locations for these is set to bindings 0 for RenderView uniforms and 1 for Command uniforms.

     #version 450 core

     layout(location = 0) in vec3 vertexPosition;

     layout(std140, binding = 0) uniform qt3d_render_view_uniforms {
       mat4 viewMatrix;
       mat4 projectionMatrix;
       mat4 uncorrectedProjectionMatrix;
       mat4 clipCorrectionMatrix;
       mat4 viewProjectionMatrix;
       mat4 inverseViewMatrix;
       mat4 inverseProjectionMatrix;
       mat4 inverseViewProjectionMatrix;
       mat4 viewportMatrix;
       mat4 inverseViewportMatrix;
       vec4 textureTransformMatrix;
       vec3 eyePosition;
       float aspectRatio;
       float gamma;
       float exposure;
       float time;
       float yUpInNDC;
       float yUpInFBO;
     };

     layout(std140, binding = 1) uniform qt3d_command_uniforms {
       mat4 modelMatrix;
       mat4 inverseModelMatrix;
       mat4 modelViewMatrix;
       mat3 modelNormalMatrix;
       mat4 inverseModelViewMatrix;
       mat4 modelViewProjection;
       mat4 inverseModelViewProjectionMatrix;
     };

     void main()
     {
         gl_Position = (projectionMatrix * viewMatrix * modelMatrix * vertexPosition);
     }

For user defined uniform buffer object, use binding starting at 2 or auto to let Qt 3D work out the binding automatically. Make sure to remain consistent between the different shader stages.

     #version 450 core

     layout(std140, binding = auto) uniform my_uniforms {
       vec4 myColor;
     };

     layout(location=0) out vec4 fragColor;

     void main()
     {
         fragColor = myColor;
     }

There is no change involved when it comes to feeding values to uniforms.

For the above example, setting myColor could be done with:

     QParameter *parameter = new QParameter();
     parameter->setName("myColor");
     parameter->setValue(QVariant::fromValue(QColor(Qt::blue)));

Textures still have to be defined as standalone uniforms.

     #version 450 core

     layout(binding=0) uniform sampler2D source;

     layout(location=0) out vec4 fragColor;

     void main()
     {
         fragColor = texture(source, vec2(0.5, 0.5));
     }

### `[deprecated]` class Qt3DRender::QShaderProgramBuilder

This class is deprecated. We strongly advise against using it in new code.

A shader program builder consists of several different shader graphs used to generate shader code.

A cache of generated shader code is maintained. Generated shaders are by defaults saved in QStandardPaths::writableLocation(QStandardPaths::TempLocation)). This path can be overridden by setting environment variable QT3D_WRITABLE_CACHE_PATH to a valid writable path.

The use of the cache can be disabled by setting environment variable QT3D_DISABLE_SHADER_CACHE.

In most cases, changes made to a graph are detected by Qt 3D and a new cache entry will be generated. One case were this will not happen is when code snippets included by a graphs are changed. To work around that, clearing the cache directory or setting environment variable QT3D_REBUILD_SHADER_CACHE can be used to force shader code to be generated again.

### `[deprecated]` class Qt3DRender::QSharedGLTexture

This class is deprecated. We strongly advise against using it in new code.

Depending on the rendering mode used by Qt 3D, the shared context will either be:

- qt_gl_global_share_context when letting Qt 3D drive the rendering. When setting the attribute Qt::AA_ShareOpenGLContexts on the QApplication class, this will automatically make QOpenGLWidget instances have their context shared with qt_gl_global_share_context.
- the shared context from the QtQuick scene. You might have to subclass QWindow or use QtQuickRenderControl to have control over what that shared context is though as of 5.13 it is qt_gl_global_share_context.

Any 3rd party engine that shares its context with the Qt 3D renderer can now provide texture ids that will be referenced by the Qt 3D texture.

You can omit specifying the texture properties, Qt 3D will try at runtime to determine what they are. If you know them, you can of course provide them, avoid additional work for Qt 3D.

Keep in mind that if you are using custom materials and shaders, you need to specify the correct sampler type to be used.

### `[deprecated]` class Qt3DRender::QSortPolicy

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QSortPolicy class stores the sorting type used by the FrameGraph. The sort types determine how drawable entities are sorted before drawing to determine the drawing order. When QSortPolicy is present in the FrameGraph, the sorting mechanism is determined by the sortTypes list. Multiple sort types can be used simultaneously. If QSortPolicy is not present in the FrameGraph, entities are drawn in the order they appear in the entity hierarchy.

### `[deprecated]` class Qt3DRender::QSpotLight

This class is deprecated. We strongly advise against using it in new code.

A spotlight is a light source that emits a cone of light in a particular direction.

A spotlight uses three attenuation factors to describe how the intensity of the light decreases over distance. These factors are designed to be used together in calcuating total attenuation. For the materials in Qt3D Extras the following formula is used, where distance is the distance from the light to the surface being rendered:

     totalAttenuation = 1.0 / (constantAttenuation + (linearAttenuation * distance) + (quadraticAttenuation * distance * distance));

Custom materials may choose to interpret these factors differently.

### `[deprecated]` class Qt3DRender::QStencilMask

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QStencilMask class specifies a write mask for the stencil values after the stencil test. Mask can be specified separately for the front-facing and back-facing polygons. The fragment stencil value is and'd with the mask before it is written to the stencil buffer.

See also Qt3DRender::QStencilTest.

### `[deprecated]` class Qt3DRender::QStencilOperation

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QStencilOperation class specifies the stencil operations for the front- and back-facing polygons. The stencil operation control what is done to fragment when the stencil and depth test pass or fail.

See also Qt3DRender::QStencilTest.

### `[deprecated]` class Qt3DRender::QStencilOperationArguments

This class is deprecated. We strongly advise against using it in new code.

The Qt3DRender::QStencilOperationArguments class specifies the arguments for the stencil operations.

See also Qt3DRender::QStencilOperation.

### `[deprecated]` class Qt3DRender::QStencilTest

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QStencilTest class specifies argument for the stencil test. The stencil test comprises of three arguments: stencil test function, stencil test mask and stencil reference value. QStencilTest allows these arguments to be set for both front- and back-facing polygons separately.

See also Qt3DRender::QStencilMask and Qt3DRender::QStencilOperation.

### `[deprecated]` class Qt3DRender::QStencilTestArguments

This class is deprecated. We strongly advise against using it in new code.

The Qt3DRender::QStencilTestArguments class specifies the arguments for the stencil test.

### `[deprecated]` class Qt3DRender::QSubtreeEnabler

This class is deprecated. We strongly advise against using it in new code.

While QFrameGraphNodes can be individually enabled and disabled via the `enabled` property, this can become tedious when an entire path needs to be turned on or off. QSubtreeEnabler is a convenience node that makes this use case trivial, allowing all of its children to be controlled by a single switch.

QSubtreeEnabler is enabled by default.

### `[deprecated]` class Qt3DRender::QTechnique

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QTechnique specifies a set of Qt3DRender::QRenderPass objects, Qt3DRender::QFilterKey objects, Qt3DRender::QParameter objects and a Qt3DRender::QGraphicsApiFilter, which together define a rendering technique the given graphics API can render. The filter keys are used by Qt3DRender::QTechniqueFilter to select specific techniques at specific parts of the FrameGraph. A QParameter defined on a QTechnique overrides parameter (of the same name) defined in QRenderPass, but are overridden by parameter in QRenderPassFilter, QTechniqueFilter, QMaterial and QEffect.

When creating an QEffect that targets several versions of a graphics API, it is useful to create several QTechnique nodes each with a graphicsApiFilter set to match one of the targeted GL versions. At runtime, the Qt3D renderer will select the most appropriate QTechnique based on which graphics API versions are supported and (if specified) the QFilterKey nodes that satisfy a given QTechniqueFilter in the FrameGraph.

Note: When using OpenGL as the graphics API for rendering, Qt3D relies on the QSurfaceFormat returned by QSurfaceFormat::defaultFormat() at runtime to decide what is the most appropriate GL version available. If you need to customize the QSurfaceFormat, do not forget to apply it with QSurfaceFormat::setDefaultFormat(). Setting the QSurfaceFormat on the view will likely have no effect on Qt3D related rendering.

Note: QTechnique node can not be disabled.

     QTechnique *gl3Technique = new QTechnique();

     // Create the render passes
     QRenderPass *firstPass = new QRenderPass();
     QRenderPass *secondPass = new QRenderPass();

     // Add the passes to the technique
     gl3Technique->addRenderPass(firstPass);
     gl3Technique->addRenderPass(secondPass);

     // Set the targeted GL version for the technique
     gl3Technique->graphicsApiFilter()->setApi(QGraphicsApiFilter::OpenGL);
     gl3Technique->graphicsApiFilter()->setMajorVersion(3);
     gl3Technique->graphicsApiFilter()->setMinorVersion(1);
     gl3Technique->graphicsApiFilter()->setProfile(QGraphicsApiFilter::CoreProfile);

     // Create a FilterKey
     QFilterKey *filterKey = new QFilterKey();
     filterKey->setName(QStringLiteral("name"));
     fitlerKey->setValue(QStringLiteral("zFillPass"));

     // Add the FilterKey to the Technique
     gl3Technique->addFilterKey(filterKey);

     // Create a QParameter
     QParameter *colorParameter = new QParameter(QStringLiteral("color"), QColor::fromRgbF(0.0f, 0.0f, 1.0f, 1.0f));

     // Add parameter to technique
     gl3Technique->addParameter(colorParameter);

See also QEffect, QRenderPass, and QTechniqueFilter.

### `[deprecated]` class Qt3DRender::QTechniqueFilter

This class is deprecated. We strongly advise against using it in new code.

A Qt3DRender::QTechniqueFilter specifies which techniques are used by the FrameGraph when rendering the entities. QTechniqueFilter specifies a list of Qt3DRender::QFilterKey objects and Qt3DRender::QParameter objects. When QTechniqueFilter is present in the FrameGraph, only the techiques matching the keys in the list are used for rendering. The parameters in the list can be used to set values for shader parameters. The parameters in QTechniqueFilter override parameters in QMaterial, QEffect, QTechnique and QRenderPass, but are overridden by parameters in QRenderPassFilter.

### `[deprecated]` class Qt3DRender::QTexture1D

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QTexture1DArray

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QTexture2D

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QTexture2DArray

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QTexture2DMultisample

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QTexture2DMultisampleArray

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QTexture3D

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QTextureBuffer

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QTextureCubeMap

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QTextureCubeMapArray

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QTextureData

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QTextureDataUpdate

This class is deprecated. We strongly advise against using it in new code.

The actual data content is contained in a QTextureImageDataPtr member. Additional members allow to specify the x, y, z offset of the content update as well as the eventual layer, mipLevel and face.

See also QAbstractTexture.

### `[deprecated]` class Qt3DRender::QTextureImage

This class is deprecated. We strongly advise against using it in new code.

It contains the necessary information mipmap level, layer, cube face and source URL to load at the proper place data into an OpenGL texture.

### `[deprecated]` class Qt3DRender::QTextureImageData

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QTextureImageDataGenerator

This class is deprecated. We strongly advise against using it in new code.

QTextureImageDataGenerator is a data provider for QAbstractTexture. QTextureImageDataGenerator can be used to expand Qt3D with more ways to load texture image data as well as support user-defined formats and formats Qt3D does not natively support. The data is returned by the QTextureImageDataPtr which contains the data that will be loaded to the texture. QTextureImageDataGenerator is executed by Aspect jobs in the backend.

### `[deprecated]` class Qt3DRender::QTextureLoader

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QTextureRectangle

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QTextureWrapMode

This class is deprecated. We strongly advise against using it in new code.

### `[deprecated]` class Qt3DRender::QViewport

This class is deprecated. We strongly advise against using it in new code.

Qt3DRender::QViewport of the scene specifies at which portion of the render surface Qt3D is rendering to. Area outside the viewport is left untouched. It also controls global parameters to the rendering in that viewport like gamma.

### `[deprecated]` class Qt3DRender::QWaitFence

This class is deprecated. We strongly advise against using it in new code.

Fence allow to synchronosize GPU and CPU workloads. GPU commands usually are non-blocking. When issued, commands are inserted in command buffers which will be read at a later time by the GPU. In some cases, you want to continue processing or issue specific command only when you are sure a command has been executed by the hardware. Fences are a way to do so. This is especially important when using 3rd party engines with Qt3D, Qt3D should only access shared resources when we know the other engine command are done modifying the resource.

QWaitFence is a FrameGraph node that will force to wait for it to become signaled before subsequent commands are inserted into the command stream. It can then be used in conjunction with QSetFence and contains properties to configure how long it should wait and whether it should block on the CPU side.

Note: Qt 3D uploads GPU resources (Texture, Shaders, Buffers) before issuing draw calls.