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

    Checking Object Manager Filtering

    Cinema 4D SDK
    r23 python
    2
    3
    473
    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.
    • CairynC
      Cairyn
      last edited by

      Hello once again;

      I was looking for a way to check whether an Object Manager has the Filter, Root, or Search modes active. (I suppose not... window control is a bit underrepresented in the API... but since the Viewport does have methods to check and control the filter, maybe...?)

      And, consequently, how to check whether an object is actually visible in the OM. (We already talked about the NBIT_OHIDE flag in a different thread, but that does not apply here.) The above filters may hide any object or tag, but the objects do not reflect that in their local state, apparently.

      Methods to set, clear, or query the content in these modes (e.g. the search string) would also be appreciated 😉

      (Searching the forum only revealed one similar question from long ago that was never answered.)

      1 Reply Last reply Reply Quote 0
      • ManuelM
        Manuel
        last edited by

        Hi,

        Unfortunately, this is not exposed. As you can test yourself, you can have multiple object manager with different filter and/or path search. This is usually not a good sign.

        But i can create an entry to see if this is possible for the futur.

        Cheers,
        Manuel

        MAXON SDK Specialist

        MAXON Registered Developer

        CairynC 1 Reply Last reply Reply Quote 0
        • CairynC
          Cairyn @Manuel
          last edited by

          @m_magalhaes Thanks for the confirmation.

          I have meanwhile found that while the API doesn't cover the OM window states, you can still call CallCommand and IsCommandChecked on the functions.

              c4d.CallCommand(100004762) # Show Search Bar
              c4d.CallCommand(100004719) # Show Path Bar
              c4d.CallCommand(100004746) # Show Filter
          

          They only address the last used OM though; it doesn't seem to be possible to target a specific OM (like it is possible with the Open/Close flags which are stored as NBITs). And of course it doesn't tell me anything about the current visibility of an object in the OM.

          If the developers will think about commands to cover the filter/search/root conditions, they may want to go one step back and think about a more general concept to handle the multi-copy windows (Object Manager, Attribute Manager, Timeline) in some way that allows me to ask what was the last window, the active window, a window by index.

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