Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware API
      • ZBrush Python API
      • ZBrush GoZ API
      • Code Examples on Github
    • Forum
    • Downloads
    • Support
      • Support Procedures
      • Registered Developer Program
      • Plugin IDs
      • Contact Us
    • Categories
      • Overview
      • News & Information
      • Cinema 4D SDK Support
      • Cineware SDK Support
      • ZBrush 4D SDK Support
      • Bugs
      • General Talk
    • Unread
    • Recent
    • Tags
    • Users
    • Login

    Read Alembic tag's data

    Scheduled Pinned Locked Moved Cinema 4D SDK
    r212025c++
    3 Posts 2 Posters 577 Views 1 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • B Offline
      BruceC
      last edited by

      Hi,
      Could you please help me find out how to read data from a Talembic tag?

      There is an object with a vertex color tag, then the object is baked as Alembic by using the "Bake as Alembic" menu item popped by right click on the object.
      Then the backed Alembic file is imported automatically. However, the original vertex color tag becomes an Alembic tag.

      Can you please help me find out how to read the vertex color data from the new Alembic tag?
      Thank you very much!

      1 Reply Last reply Reply Quote 0
      • M Offline
        m_adam
        last edited by

        Hey @BruceC in order to get the real tag data under the alembic tag you need to send MSG_GETREALTAGDATA message to it.

        BaseTag* alembicTag = obj->GetTag(Talembic);
        if (!alembicTab)
          return;
        
        GetRealTagData realTag;
        alembicTag->Message(MSG_GETREALTAGDATA, &realTag);
        if (realTag.res && realTag.res.GetType() == Tvertexcolor)
        {
          VertexColorTag* const vct = static_cast<VertexColorTag*>(realTag.res);
          // Do something with it
        }
        

        Cheers,
        Maxime.

        MAXON SDK Specialist

        Development Blog, MAXON Registered Developer

        1 Reply Last reply Reply Quote 0
        • B Offline
          BruceC
          last edited by

          @m_adam, Thank you very much, this works for me!

          1 Reply Last reply Reply Quote 0
          • First post
            Last post