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

    Draw vertices like C4D?

    Scheduled Pinned Locked Moved SDK Help
    2 Posts 0 Posters 196 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 26/12/2012 at 00:40, xxxxxxxx wrote:

      User Information:
      Cinema 4D Version:   R13-R14 
      Platform:   Windows  ;   Mac OSX  ; 
      Language(s) :     C++  ;

      ---------
      Quick question: how would one go about drawing polygon object vertices similar to the way Cinema 4D does it (that is, camera-aligned/screen-relative squares).  There is no DrawBox2D() and DrawBox() is a 3D box.  In order for it always to have the same face facing the screen/camera and nearly planar seems like more work than should be required.  A code example would be amazing!

      Thanks,

      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 26/12/2012 at 03:09, xxxxxxxx wrote:

        I think that I figure it out.  It looks exactly like the C4D vertices anywhoo - and they can be sized interactively.

        // note: Vector* verts = op->GetPointW();  
        Matrix            m;  
        Real            spSize =        bc->GetReal(TSYMMORPHY_SOURCEPOINTS_SIZE);  
        bd->LineZOffset(32L);  
        bd->SetMatrix_Screen();  
        if (bc->GetBool(TSYMMORPHY_SHOW_SOURCEPOINTS))  
        {  
          Vector            spColor =        bc->GetVector(TSYMMORPHY_SOURCEPOINTS_COLOR);  
          for (LONG i = 0L; i != vcnt; ++i)  
          {  
              if (!sp[i].use)    continue;  
              m.off =            bd->WS(verts[sp[i].index] * op->GetMg());  
              bd->DrawBox(m, spSize, spColor, FALSE);  
          }  
        }  
        bd->SetMatrix_Matrix(NULL, Matrix(), 0L);
        
        1 Reply Last reply Reply Quote 0
        • First post
          Last post