![]() |
Stellarium
0.17.0
|
Extension of StelOBJ::Material which provides Scenery3d specific stuff.
#include <S3DScene.hpp>
Data Structures | |
| struct | Traits |
Public Member Functions | |
| Material (const StelOBJ::Material &stelMat) | |
| void | loadTexturesAsync () |
| Starts loading the textures in this material asynchronously. | |
| void | fixup () |
| Re-calculates the material traits, and sets invalid material fields to valid values. More... | |
| bool | updateFadeInfo (double currentJD) |
| Re-calculates time fade info, returns true if the object should be rendered. | |
Data Fields | |
| struct S3DScene::Material::Traits | traits |
| StelTextureSP | tex_Kd |
| StelTextureSP | tex_Ke |
| StelTextureSP | tex_bump |
| StelTextureSP | tex_height |
| bool | bAlphatest |
| bool | bBackface |
| float | fAlphaThreshold |
| Vec2d | vis_fadeIn |
| Vec2d | vis_fadeOut |
| float | vis_fadeValue |
| Updated by S3DRenderer when necessary, otherwise always 1.0. | |
Data Fields inherited from StelOBJ::Material | |
| enum StelOBJ::Material::Illum | illum |
| QString | name |
| Name of the material as defined in the .mtl, default empty. | |
| QVector3D | Ka |
| Ambient coefficient. Contains all -1 if not set by .mtl. | |
| QVector3D | Kd |
| Diffuse coefficient. Contains all -1 if not set by .mtl. | |
| QVector3D | Ks |
| Specular coefficient. Contains all -1 if not set by .mtl. | |
| QVector3D | Ke |
| Emissive coefficient. Contains all -1 if not set by .mtl. | |
| float | Ns |
| Specular shininess (exponent), should be > 0. Default 8.0. | |
| float | d |
| Alpha value (1 means opaque). More... | |
| QString | map_Ka |
| The ambient texture map file path. | |
| QString | map_Kd |
| The diffuse texture map file path. | |
| QString | map_Ks |
| The specular texture map file path. | |
| QString | map_Ke |
| The emissive texture map file path. | |
| QString | map_bump |
| The bump/normal texture map file path. | |
| QString | map_height |
| The height map texture file path. | |
| ParamsMap | additionalParams |
| Contains all other material parameters that are not recognized by this class, but can still be accessed by class users this way. More... | |
Additional Inherited Members | |
Public Types inherited from StelOBJ::Material | |
| enum | Illum { I_NONE =-1, I_DIFFUSE =0, I_DIFFUSE_AND_AMBIENT =1, I_SPECULAR =2, I_TRANSLUCENT =9 } |
| MTL Illumination models, see the developer doc for info. More... | |
| typedef QMap< QString, QStringList > | ParamsMap |
Static Public Member Functions inherited from StelOBJ::Material | |
| static QVector< Material > | loadFromFile (const QString &filename) |
| Loads all materials contained in an .mtl file. More... | |
Static Protected Member Functions inherited from StelOBJ::Material | |
| static bool | parseBool (const QStringList ¶ms, bool &out) |
| Parses a bool from a parameter list (like included in the ::additionalParams) using the same logic StelOBJ uses internally. More... | |
| static bool | parseFloat (const QStringList ¶ms, float &out) |
| Parses a float from a parameter list (like included in the ::additionalParams) using the same logic StelOBJ uses internally. More... | |
| static bool | parseVec2d (const QStringList ¶ms, Vec2d &out) |
| Parses a Vec2d from a parameter list (like included in the ::additionalParams) using the same logic StelOBJ uses internally. More... | |
| struct S3DScene::Material::Traits |
| void S3DScene::Material::fixup | ( | ) |
This requires all textures to be fully loaded.
1.8.11