EffectThe Effect item defines simple effects within the QML/3D environment. Examples of such effects include textures, simple material and lighting effects, and so on. More... Inherits QtObject Inherited by ShaderProgram. This type was introduced in Qt 4.8. Properties
Detailed DescriptionDefining an EffectEffects can be defined within QML using the normal syntax for creating any QML/3d object. To create a default effect with no extra information, for example, we can simply using the following: Effect {} More complex effects use the usual QML syntax for accessing and updating properties. In order to specify a texture, for example, the following could be used: Effect {
id: myTextureEffect
texture: "texture.png"
}
Property DocumentationThis property should be set to true if alpha blending should be enabled when this effect is active, or false otherwise. The default is false. This property overrides the viewport-specific blending setting that is specified by Viewport::blending. The color of the object for simple non-texture effects. The default value for this property is white. Defines the material to apply to items that use this effect. Tracks how much of a remote resource has been downloaded, where 0.0 is no progress, and 1.0 is completion. Texture effects are defined by this property. A texture is provided by means of a QUrl which is then used for texturing. Textures can also be defined directly as images using the textureImage property. If the value is non-empty, and the texture could not be loaded from the QUrl for any reason, then the property will not be changed. See also textureImage. The lighting control parameter; true if this effect should use lighting or false if this effect should use flat colors and textures. The default value for this property is true. |