Giter Site home page Giter Site logo

vertex color incorrect about blender3d_import_psk_psa HOT 5 OPEN

 avatar commented on August 11, 2024
vertex color incorrect

from blender3d_import_psk_psa.

Comments (5)

yretenai avatar yretenai commented on August 11, 2024

This is because the mesh does not have smooth shading and is instead relying on normals. Go into edit mode and press F and select "Shade Smooth". However, verify that this is how the game behaves.

from blender3d_import_psk_psa.

 avatar commented on August 11, 2024

(In all images .psk is on the left, .gltf on the right - the quality of my .gif is a bit bad, sorry).

Thank you for your answer, I was afraid that I would not be taken seriously. ^^
Since I think I'm being misunderstood, here's my view:

I create a .psk with any Granblue model with the following versions:

  • umodel
  • umodel custom version with normals
  • fmodel

All three versions, on all models bring incorrect vertex color in Blender. If I manually enable 'Smooth Shading' as suggested, or remove 'Custom Split Data' - it always remains incorrect (also believe that vertex normals are rather unrelated to vertex color). If I use a 'Data Transfer' modifier I can transfer the vertex color from a .glTF mesh to the .psk mesh without changing anything in the shading or the normals - reason more to exclude it (pay attention to the settings).

switch

Whereas .glTF imports correct vertex color for all models.

I use the ArcSystem shader from Aerthas for the models in Blender, where Vertex Color is used as a mask for permanent shadows.

You can see it quite well in this example. The permanent shadow with .glTF vertex color is correct, .psk vertex color is broken.

switch2

To me it looks like this:
The vertex color information that the .psk importer writes to the mesh is somehow incorrect.
(Unfortunately I don't have 3DMax to test if the incorrect vertex color is somehow related to the .psk data itself.)
If it is really only the shading - please make a short .gif and show it to me. I can't reproduce the solution.

I am happy to supply .blends etc if it helps solve the problem.

from blender3d_import_psk_psa.

 avatar commented on August 11, 2024

What is the reason for this? I don't understand enough about Blender's API.

The console shows me a perpetual list of vertices triggered by the piece of code between 1087 - 1093 when importing.

console

from blender3d_import_psk_psa.

yretenai avatar yretenai commented on August 11, 2024

Yeah I see now, it seems FModel (CUE4Parse) and UModel both narrow the number of vertices down by deduplicating according to position and normal. So split tangents and colors will not export correctly if the vertex was merged.

The GLTF exporter just exports the entire vertex stream.

from blender3d_import_psk_psa.

 avatar commented on August 11, 2024

Thank you for your time.
If you are the one person who will fix it that would be great of course. :P : )
Stay with glTF for now.

from blender3d_import_psk_psa.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.