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

    Creat a new HUD element

    SDK Help
    0
    6
    514
    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
      Helper
      last edited by

      On 21/02/2016 at 14:12, xxxxxxxx wrote:

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

      ---------
      Hi,
      i want to add a HUD Textbox to the editorview.
      I found out that i need the lib_viewport.h and the ViewportHUD class  to do this, but there is zero Documentation how to use it.

      A quick example how to add a HUD element would be realy great.

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

        On 22/02/2016 at 09:25, xxxxxxxx wrote:

        Hi,

        I'm sorry, we currently have neither documentation nor examples for lib_viewport. Actually it is not made to be used by 3rd party developers.
        Perhaps you can tell us, what exactly you are trying to achieve? Maybe we can find some other solution or a workaround.

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

          On 22/02/2016 at 11:25, xxxxxxxx wrote:

          Ok , i am currently doing my A levels with a focus on math and informatics.In this context i need to make a custom Software project and present it .So its a rather educational Project . I like the C4D sdk and thought that it would be nice to creat and  implement a particle system for C4D. So far everything works quite good. But now i need some nice way to show the audience (My class) ,the enormous amount of particles processed by my plugin.Also the current thread count + the thread usage would be very nice.

          I could use a Parameter for this and add it manual to the viewport.But since its a programming/math projekt it is not good to do it this way.

          First i thought of using a the BaseDraw method DrawTexture with number bitmaps.But this is ugly to write and to understand.

          So at the end a HUD element would be the perfect solution to make my persentation good and shiny.
          I think X-Particls also does it this way so there is way to do it .

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

            On 22/02/2016 at 12:14, xxxxxxxx wrote:

            Originally posted by xxxxxxxx

            So at the end a HUD element would be the perfect solution to make my persentation good and shiny.I think X-Particls also does it this way so there is way to do it .

            I'm afraid X-Particles does not use the ViewportHUD class. You'll have to go back to basics and write to the viewport yourself to emulate the inbuilt HUD.

            Steve

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

              On 22/02/2016 at 12:42, xxxxxxxx wrote:

              You will need to Draw() into the viewport through the BaseDraw.  Here is a tutorial/code from c4d-jack about drawing text into the viewport:

              https://c4dprogramming.wordpress.com/2012/11/20/drawing-text-in-the-viewport/

              Best of luck with your A levels!

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

                On 22/02/2016 at 12:47, xxxxxxxx wrote:

                Thanks for the support.

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