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
    • Unread
    • Recent
    • Tags
    • Users
    • Login

    renderpal submission integration

    Plugin Requests
    0
    1
    488
    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 14/03/2014 at 06:16, xxxxxxxx wrote:

      anyone working on a python plugin to integrate renderpal with C4D?
      I have a basic framework started, but as I dont want to reinvent the wheel. maybe someone has already done some work on it, and wants to share.

      the basic engine is working, but I am struggling with the gui part in C4D.

      I dont seem to be able to publish text inputs or buttons on the canvas of my GeDialog() I opened.

      I also tried the example script, but that doesnt display anything in the pop up window as well.

      import c4d
      from c4d import gui

      GROUP_ID=1000
      TEXTBOX=1001
      BUTTON1=1002
      BUTTON2=1003

      class exampleDlg(gui.GeDialog) :
      def CreateLayout(self) :
      #create the layout of the dialog
      self.GroupBegin(GROUP_ID1, c4d.BFH_SCALEFIT, 3, 1)
      self.AddEditText(TEXTBOX, c4d.BFH_SCALEFIT)
      self.AddButton(BUTTON1, c4d.BFH_SCALE, name="MessageDialog")
      self.AddButton(BUTTON2, c4d.BFH_SCALE, name="Close")
      self.GroupEnd()
      return True

      def InitValues(self) :
      	self.SetString(TEXTBOX, "Hello World")
      	return True
      
      
      def Command(self, id, msg) :
      	if id == BUTTON1:
      		gui.MessageDialog(self.GetString(TEXTBOX))
      	elif id == BUTTON2:
      		self.Close()
      	return True
      

      dlg = ExampleDlg()
      dlg.Open(c4d.DLG_TYPE_MODAL, defaultw=300, defaulth=50)

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