Thread: [Nuke6] Import chan from script

Reply to Thread
Results 1 to 2 of 2
  1. #1 [Nuke6] Import chan from script 
    Join Date
    Jul 2010
    Location
    Italy
    Posts
    7
    Hello folks,
    I'm working on a python script that imports cameras from a stereo maya scene.
    It worked all well since I was using Nuke5, but now that I've upgraded to Nuke6 I have the following problem:

    These lines used to work:
    Code:
    camera_lx.knob("import_chan").setValue("import_chan_file " + chan_path)
    camera_lx.knob("import_chan").execute()
    camera_lx.knob("import_chan").setValue("import_chan")
    But... the "import_chan" knob on the Camera node is not working anymore!
    Now it's an "Obsolete_knob" and I can't execute it.

    To import a chan manually, I have to click on "file_menu" icon and then "import chan file".. But I don't have any idea of how this can be done by script!

    Can you guys help me?

    Thanks in advance,

    Dora
    Reply With Quote  

  2. #2  
    Join Date
    Jul 2010
    Location
    Italy
    Posts
    7
    I found the solution, maybe it can be helpful to anyone:
    Code:
    nuke.tcl('in %s {import_chan_file %s}' % (camera_lx.name(), chan_path))
    where camera_lx is the nuke node of the camera.
    Thanks!
    Reply With Quote  

Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Similar Threads

  1. run nuke.scriptNew() with its own python script attached to it
    By MrSlash in forum Nuke Plugins & Scripts
    Replies: 11
    Last Post: November 29th, 2010, 02:43 PM
  2. I made a scene collection script for Nuke
    By cgbeige in forum NUKE from The Foundry
    Replies: 0
    Last Post: November 20th, 2010, 12:39 PM
  3. Nuke 5.1 v1 Released
    By shot_grable in forum NUKE from The Foundry
    Replies: 36
    Last Post: July 17th, 2010, 01:33 AM
  4. Refrencing a Script within a script
    By Dotcommer in forum NUKE from The Foundry
    Replies: 6
    Last Post: November 17th, 2009, 06:47 PM
  5. python script problem
    By donat2 in forum NUKE from The Foundry
    Replies: 3
    Last Post: August 6th, 2008, 03:40 PM
Tags for this Thread

View Tag Cloud

Bookmarks
Bookmarks
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts