diff options
author | Gaia Clary <gaia.clary@machinimatrix.org> | 2019-06-04 15:31:22 +0300 |
---|---|---|
committer | Gaia Clary <gaia.clary@machinimatrix.org> | 2019-06-05 13:42:54 +0300 |
commit | eda377c223cfc0460e3294c95771313f8d4388c3 (patch) | |
tree | d8c7d5d74a74f19b993ad18f09d098f5ed039549 /source/blender/collada/EffectExporter.h | |
parent | 98cea7edcefa58d5eb7e2350461b8efe33fe7d9e (diff) |
update Collada Importer: reworked export and import of Materials
- added import of transparency and emission into principled BSDF Shader
- added support for importing all default collada material parameters
* diffuse
* emission
* index_of_refraction
* shininess (mapped to BSDF Roughness)
* reflectivity (mapped to BSDF Metallic)
* transparency + transparent mapped to BSDF Alpha)
* ambient (creates unconnected texture node)
* specular (creates unconnected texture node)
* reflective(creates unconnected texture node)
- added support for exporting collada material parameters:
* diffuse
* emission
* index_of_refraction
* shininess (mapped to BSDF Roughness)
* reflectivity (mapped to BSDF Metallic)
* transparency + transparent mapped to BSDF Alpha)
- prepared support for exporting the following parameters
but currently commented out:
* ambient (creates unconnected texture node)
* specular (creates unconnected texture node)
* reflective(creates unconnected texture node)
Problem: For now we only allow export of principled BSDF based
materials. I am not sure from where to get ambient, specular
and reflective as those values are not included in the
principled BSDF Shader (wip).
Diffstat (limited to 'source/blender/collada/EffectExporter.h')
-rw-r--r-- | source/blender/collada/EffectExporter.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/source/blender/collada/EffectExporter.h b/source/blender/collada/EffectExporter.h index 75511800081..57df844233c 100644 --- a/source/blender/collada/EffectExporter.h +++ b/source/blender/collada/EffectExporter.h @@ -55,10 +55,17 @@ class EffectsExporter : COLLADASW::LibraryEffects { private: void set_shader_type(COLLADASW::EffectProfile &ep, Material *ma); - void set_transparency(COLLADASW::EffectProfile &ep, Material *ma); + void set_diffuse_color(COLLADASW::EffectProfile &ep, Material *ma); - void set_reflectivity(COLLADASW::EffectProfile &ep, Material *ma); void set_emission(COLLADASW::EffectProfile &ep, Material *ma); + void set_ior(COLLADASW::EffectProfile &ep, Material *ma); + void set_shininess(COLLADASW::EffectProfile &ep, Material *ma); + void set_reflectivity(COLLADASW::EffectProfile &ep, Material *ma); + void set_transparency(COLLADASW::EffectProfile &ep, Material *ma); + void set_ambient(COLLADASW::EffectProfile &ep, Material *ma); + void set_specular(COLLADASW::EffectProfile &ep, Material *ma); + void set_reflective(COLLADASW::EffectProfile &ep, Material *ma); + void get_images(Material *ma, KeyImageMap &uid_image_map); void create_image_samplers(COLLADASW::EffectProfile &ep, KeyImageMap &uid_image_map, |