Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: export embedded texture in fbx #5866

Open
copycd opened this issue Nov 6, 2024 · 0 comments
Open

Bug: export embedded texture in fbx #5866

copycd opened this issue Nov 6, 2024 · 0 comments
Labels
Bug Global flag to mark a deviation from expected behaviour

Comments

@copycd
Copy link
Contributor

copycd commented Nov 6, 2024

metalic texture image is excluded when fbx including 4 texture exports.

I fixed code below
FBXExporter.cpp 1615 line.

// Textures
// referenced by material_index/texture_type pairs.
std::map<std::pair<size_t,size_t>,int64_t> texture_uids;
const std::map<aiTextureType,std::string> prop_name_by_tt = {
    {aiTextureType_DIFFUSE,      "DiffuseColor"},
    {aiTextureType_SPECULAR,     "SpecularColor"},
    {aiTextureType_AMBIENT,      "AmbientColor"},
    {aiTextureType_EMISSIVE,     "EmissiveColor"},
    {aiTextureType_HEIGHT,       "Bump"},
    {aiTextureType_NORMALS,      "NormalMap"},
    {aiTextureType_SHININESS,    "ShininessExponent"},
    {aiTextureType_OPACITY,      "TransparentColor"},
    {aiTextureType_DISPLACEMENT, "DisplacementColor"},
    //{aiTextureType_LIGHTMAP, "???"},
    {aiTextureType_REFLECTION,   "ReflectionColor"},
    **{aiTextureType_BASE_COLOR, "BaseColor" },
    {aiTextureType_NORMAL_CAMERA, "NormalCamera" },
    {aiTextureType_EMISSION_COLOR, "EmissionColor" },
    // copycd:: add.
    {aiTextureType_METALNESS,   "MetalnessMap" }**
    //{aiTextureType_UNKNOWN, ""}
};
@copycd copycd added the Bug Global flag to mark a deviation from expected behaviour label Nov 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Global flag to mark a deviation from expected behaviour
Projects
None yet
Development

No branches or pull requests

1 participant