Code Monkey home page Code Monkey logo

Comments (6)

FractalFir avatar FractalFir commented on July 18, 2024 1

Support for custom float attributes added in a164eb2.

from tmf.

FractalFir avatar FractalFir commented on July 18, 2024

Supporting arbitrary vertex attributes would not be hard, but those attributes would receive little to no size reduction due to the compression algorithm requiring a lot of insight into data stored. Since knowing what is stored accounts for most of the savings (normals being unit vectors, uvs being in the range 0.0-1.0), a lot of savings comes from code which differs for each attribute. So custom vertex attributes would be mostly compression-less. The compression-less variant could be added in a couple of work hours.

A much better approach would be to have dedicated format segments for those attributes. Knowing their properties could allow for them to be compressed. Would you mind opening issues for each kind of data your use case requires?

from tmf.

FractalFir avatar FractalFir commented on July 18, 2024

d9a5be3 adds some groundwork for supporting custom mesh data. API will be a bit more involved than the one proposed (many kinds of CustomData), but all custom data will be compressed.

Planned supported data kinds:

  1. CustomIndex
  2. CustomFloat
  3. CustomVetor2
  4. CustomVector3
  5. CustomVector4
  6. CustomColor(Vector4 with components of between 0.0 and 1.0)
  7. CustomUnit2(Vector2 of length 1)
  8. CustomUnit3(Vector3 of length 1)

This data may reuse some of the compression architecture and would be compressed to comparable levels as other mesh data.
Each custom segment should have a unique name of between 1 and 255 characters.

from tmf.

nicopap avatar nicopap commented on July 18, 2024

Awesome. This is way beyond any expectation. It's definitively not a deal breaker to not have access to extra attributes, but it's very handy. I'll open a feature request for tangents.

from tmf.

FractalFir avatar FractalFir commented on July 18, 2024

d38894d adds support for saving/reading custom indices with a name of up to 255 characters. All the groundwork for saving other data types is there, only thing left to implement is the glue code to decode the data in other types of custom segments.

from tmf.

FractalFir avatar FractalFir commented on July 18, 2024

Support for RGBA colors added in 6f7598a.

from tmf.

Related Issues (12)

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.