Maxon Developers Maxon Developers
    • Documentation
      • Cinema 4D Python API
      • Cinema 4D C++ API
      • Cineware 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

    Accessing Parameters of Filters in a Volume Builder

    Cinema 4D SDK
    windows python 2023
    2
    3
    516
    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.
    • D
      datamilch
      last edited by

      Hi there,

      I'd like to access some parameters of the filters in a Volume Builder, like 'dilate and erode > offset' or the fields parameter of the smooth filter. But I don't know how.
      There is nothing really in the documentation or the forum.

      The only thing related filters, that I found, was 'volume.SendVolumeCommand()' but suppose, this is not meant to be used with the volume builder.
      VolumeBuilder.GetSettingsContainerForIndex() will return None for filter layers - but that's also what the documentation says. I attached a file to demonstrate this.

      def main() -> None:
          settings = op.GetObject()
          volume_builder = settings[c4d.ID_USERDATA,1]
      
          for i in range( volume_builder.GetInputObjectCount() ):
              bc = volume_builder.GetSettingsContainerForIndex(i)
              print (bc)
      
      # returns:
      None   # the filter layer
      <c4d.BaseContainer object at 0x0000024296092D40> # the cube object
      

      When I drag the parameter, that I want to change, in the console it is called 'SDFDilateandErode[c4d.ID_VOLUMEFILTER_RESHAPE_OFFSET]' but again, I have no idea how to access it.

      Help would be much appreciated.

      volume builder filters 01.c4d

      D 1 Reply Last reply Reply Quote 0
      • D
        datamilch @datamilch
        last edited by

        Oh shit! I just realized the filters exist as objects in c4d ... * facepalm *
        I suppose this will resolve my problems for now.

        Should I delete the topic?

        ferdinandF 1 Reply Last reply Reply Quote 0
        • ferdinandF
          ferdinand @datamilch
          last edited by

          Hey @datamilch,

          Thank you for reaching out to us and answering your own question. In general we prefer it when topics do not get deleted, so that other users can benefit from a topic. You should also not be able to delete this topic anymore since more than three hours have passed since you posted and because your topic has replies.

          Cheers,
          Ferdinand

          MAXON SDK Specialist
          developers.maxon.net

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