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
    • Recent
    • Tags
    • Users
    • Login

    Normals when exporting using Melange

    Scheduled Pinned Locked Moved SDK Help
    5 Posts 0 Posters 431 Views
    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.
    • H Offline
      Helper
      last edited by

      THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

      On 03/12/2010 at 09:19, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   12 
      Platform:   Windows  ;   
      Language(s) :     C++  ;

      ---------
      Hello!

      I'm writing an exporter to write c4d files from an application using melange. I'm missing the function MakeVariableTag to generate a Tnormal tag. My first thought was, that you could use MakeTag for all tags in melange. But the newly created tag doesn't allocate any normals. What is the right way in melange to generate a normals tag?

      I'm using the newest melange sdk: Build #36137 - Nov 25 2010

      Cheers
      Frank

      1 Reply Last reply Reply Quote 0
      • H Offline
        Helper
        last edited by

        THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

        On 03/12/2010 at 09:46, xxxxxxxx wrote:

        I haven't really looked into Melange yet, but most of the MakeVariableTag() variants were replaced by explicit new tag-types in the regular SDK... see if there's a NormalTag::Alloc() that you can use.

        1 Reply Last reply Reply Quote 0
        • H Offline
          Helper
          last edited by

          THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

          On 04/12/2010 at 00:51, xxxxxxxx wrote:

          Two ways that should work:
          BaseTag *bt = BaseTag::Alloc(Tnormal);
          NormalTag *tag = (NormalTag * )bt;
          OR
          NormalTag *tag = NormalTag::Alloc();

          1 Reply Last reply Reply Quote 0
          • H Offline
            Helper
            last edited by

            THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

            On 06/12/2010 at 01:02, xxxxxxxx wrote:

            Thanks for the infos. Unfortunately NormalTag doesn't have an Alloc function in melange, but after looking at the header (instead of only looking at the docs 😉 ), I found, that there is a Resize function:

            _melange_::NormalTag* nTag = static_cast<_melange_::NormalTag*>(node->MakeTag(Tnormal));
            if(nTag!=NULL) {
              nTag->Resize(numPolys);
              .....
            }

            1 Reply Last reply Reply Quote 0
            • H Offline
              Helper
              last edited by

              THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED

              On 06/12/2010 at 12:31, xxxxxxxx wrote:

              Surely, you can use the Alloc() method found in the base classes that NormalTag is derived from? (BaseTag, BaseList2D, etc...)

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