Skip to content

Instantly share code, notes, and snippets.

@herronelou
herronelou / MyWidget.cpp
Created November 11, 2024 23:12
Partial example for custom Qt Widget in Nuke
MyWidget::MyWidget(MyKnob* knob) : _knob(knob), _value(knob->_data), _dragging(false)
{
setFixedSize(60, 30);
_switchRect = rect();
_knob->addCallback(WidgetCallback, this);
}
MyWidget::~MyWidget()
{
if (_knob)
@herronelou
herronelou / audiogen.nk
Created May 26, 2025 04:56
Nuke Audio generator
set cut_paste_input [stack 0]
version 14.1 v5
push $cut_paste_input
Expression {
channel0 {rgba.red -rgba.green rgba.blue}
name Expression5
selected true
xpos 2349
ypos -55
addUserKnob {20 User}
@herronelou
herronelou / layout_manager.py
Last active July 27, 2025 04:58
Nuke Workspace from File
import nuke
import os
def parse_nuke_layout(filepath):
"""
Parses the XML window layout from the header of a Nuke (.nk) script file.
Args:
filepath (str): The full path to the .nk script file.