CompStart

ProLessonsCoursesElementsSoftware

CompStart

Learn visual effects with cutting-edge techniques.

Learning

CoursesLessonsPro FeaturesAssetsSoftware

Tools

Tech CheckDisplay CheckMotion BlurPhysLightNuke Tools

Company

InstructorMissionSitemapPrivacyTerms

Projects

Moray RenderEXR ConverterOCIO.ccNuke ToolsDerekVFX

Follow

YouTubeInstagramTikTokThreadsContact

© 2026 CompStart. All rights reserved.

Letterbox Trim

ToolSets / Utility
Utility

2026-09-07

ToolSets/utility/letterBoxTrim.nk

utility
crop
letterbox
bbox
format
trim
View on GitHub

Trims top and bottom from the input bounding box so you can remove letterbox bars without touching the left and right edges.

Letterbox Trim adjusts the input’s bounding box by cutting in from the top and bottom. Left and right stay locked to the incoming bbox; only vertical margins change.

Use it when letterboxed plates or renders carry black bars you want out of the format before framing, transforms, or downstream crops. Top and Bottom control how many pixels are removed from each edge.

A Crop runs with crop disabled, so the node redefines the data window from the input bbox rather than painting outside black. Defaults trim one pixel top and bottom; raise the knobs to match the bar height in your plate.

Script code

set cut_paste_input [stack 0]
version 12.1 v5
push $cut_paste_input
Group {
 name letterboxTrim
 tile_color 0x421010ff
 selected true
 xpos 15476
 ypos 4843
 addUserKnob {20 letterboxTrim}
 addUserKnob {41 top T Crop1.top}
 addUserKnob {41 bottom T Crop1.bottom}
 addUserKnob {26 "" +STARTLINE}
 addUserKnob {26 lbl l "" +STARTLINE T "Letterbox Trim v0.1"}
}
 Input {
  inputs 0
  name Input
  xpos 444
  ypos 258
 }
 Crop {
  box {{input.bbox.x} {"input.bbox.y + bottom"} {"input.bbox.width + input.bbox.x"} {"input.bbox.height + input.bbox.y - top"}}
  crop false
  name Crop1
  xpos 444
  ypos 298
  addUserKnob {20 User}
  addUserKnob {3 top}
  top 1
  addUserKnob {3 bottom}
  bottom 1
 }
 Output {
  name Output1
  xpos 444
  ypos 398
 }
end_group