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

    Change icon of object-plugin

    Scheduled Pinned Locked Moved PYTHON Development
    3 Posts 0 Posters 360 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

      On 26/03/2013 at 05:11, xxxxxxxx wrote:

      Hey guys.
      I was just wondering if it's possible to change the icon of an object-plugin depending on its function. A good example would be the connector-object which changes it's icon depending if it works as a hinge, a cardan or slider. Is this possible with python or limited to the C++ SDK?
      To go even a bit further: is it possible to give an icon a color overlay like the null and light-objects are now able to?
      Thanx
      Phil

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

        On 26/03/2013 at 05:17, xxxxxxxx wrote:

        ObjectData.Message() and MSG_GETCUSTOMICON

        Cheers,
        -Niklas

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

          On 26/03/2013 at 06:12, xxxxxxxx wrote:

          Thanks Niklas for the hint.
          It works, although I'm not sure if it is the correct way (this is still without checking for any mode-change, only for testing if it's working) :

            def Message(self, node, type, data) :  
          if type == c4d.MSG_GETCUSTOMICON:  
          data['bmp'] = icon1  
          data['filled'] = True  
               
          return True
          

          Is this the right way to do it (because it looks way more complicated in C++ ... as everything does)?

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