python and settings

Maxon Cinema 4D (Export script developed by abstrax, Integrated Plugin developed by aoktar)

Moderators: ChrisHekman, aoktar

User avatar
aoktar
Octane Plugin Developer
Posts: 16066
Joined: Tue Mar 23, 2010 8:28 pm
Location: Türkiye
Contact:

I've started a new topic with a good example
viewtopic.php?f=87&t=56039
Octane For Cinema 4D developer / 3d generalist

3930k / 16gb / 780ti + 1070/1080 / psu 1600w / numerous hw
wayart
Licensed Customer
Posts: 3
Joined: Sat Mar 26, 2016 12:24 pm

code is not working now.where can I found the 'myOctaneSettings' obj?
I found some script from the forum, but I can't change the value.

or How can I set it? so that when I open c4d, auto change setting to my preset.

Code: Select all


ID_OCTANE_LIVEPLUGIN = 1029499

def main():
    d=doc.GetDataInstance()
    bc=d.GetContainer(ID_OCTANE_LIVEPLUGIN)
    bc.SetData(3001, 0)    #this is not working

    print bc
    print "Octane version=",bc[c4d.SET_OCTANE_VERSION]
    print "Lock resolution=", bc[c4d.SET_LOCKRES]
    print "Check camera updates=", bc[c4d.SET_CHECK_CAMERA]
    print "Default environment color=", bc[c4d.SET_DEF_ENV_COLOR]
    print "DL Max samples=", bc[c4d.SET_DIRECT_MAXSAMPLES]
    print "Kernel tip=", bc[c4d.SET_KERNEL_TYPE]
    print "PT Max samples=", bc[c4d.SET_PATHTRACE_MAXSAMPLES]

    #bc[c4d.SET_KERNEL_TYPE]=1#not working

    c4d.EventAdd()

if __name__=='__main__':
    main()
    c4d.EventAdd()

Post Reply

Return to “Maxon Cinema 4D”