You can use this group to kick out an spi1d lut from a curve. (its just a
wrapper around some of the OCIO sample code).
>From spi1d you can go lots of places with OCIO.
-Alex
set cut_paste_input [stack 0]
version 7.0 v6
push $cut_paste_input
Group {
name spi1Dexport
tile_color 0x2cc091ff
selected true
xpos 1436
ypos -19
addUserKnob {20 User}
addUserKnob {26 notes l "" +STARTLINE T "exports master channel only"}
addUserKnob {41 lut l "" +STARTLINE T ColorLookup.lut}
addUserKnob {26 ""}
addUserKnob {2 exportPath}
exportPath
/jobs/alfx/kragle/dev_admin/alexf/LegoACES/legoScreenCaptureIDT/testLut_v005.spi1d
addUserKnob {22 export l "export spi1d" -STARTLINE T "\ndef
WriteSPI1D(filename, fromMin, fromMax, data):\n f = file(filename,'w')\n
f.write(\"Version 1\\n\")\n f.write(\"From %s %s\\n\" % (fromMin,
fromMax))\n f.write(\"Length %d\\n\" % len(data))\n
f.write(\"Components 1\\n\")\n f.write(\"\{\\n\")\n for value in
data:\n f.write(\" %s\\n\" % value)\n f.write(\"\}\\n\")\n
f.close()\n\n\nknob = nuke.thisNode()\['lut']\n\nSIZE = 2**10\n\ndata =
\[]\nfor i in xrange(SIZE):\n x = i/(SIZE-1.0)\n
data.append(knob.getValueAt(x))\n\nexportPath =
nuke.thisNode().knob('exportPath').getValue()\nrangeMin =
nuke.thisNode().knob('rangeMin').getValue()\nrangeMax =
nuke.thisNode().knob('rangeMax').getValue()\n\nWriteSPI1D(exportPath,
rangeMin, rangeMax, data)\n"}
addUserKnob {20 Range n 1}
Range 0
addUserKnob {7 rangeMin l Min R -1 0}
addUserKnob {7 rangeMax l Max R 1 10}
rangeMax 1
addUserKnob {20 endGroup n -1}
}
Input {
inputs 0
name Input1
xpos 462
ypos 79
}
ColorLookup {
name ColorLookup
selected true
xpos 462
ypos 110
}
Output {
name Output1
xpos 462
ypos 219
}
end_group
On Sat, Jul 27, 2013 at 2:01 PM, Michael Garrett <[email protected]>wrote:
> I second using the Sampler. For example, create a linear ramp with an
> expression node using the expression x/width, then do some colour
> grading to it. Then run the Sampler node and export the lut.
>
>
> On 26 July 2013 10:39, Jonathan Egstad <[email protected]> wrote:
> > It's usually easier to handle 1D luts by using the Sampler node and the
> export curve options in the curve editor. There's an export discreet lut
> in there for example.
> >
> > -jonathan
> >
> > On Jul 26, 2013, at 7:25 AM, "Schneider, Abraham" <[email protected]>
> wrote:
> >
> >> Hi there!
> >>
> >> I'm just wondering about how to generate LUTs in Nuke. In the
> documentation it's said that the CMSTestPattern and GenerateLUT nodes are
> able to generate 3D and 1D LUTs. Creating 3D Luts works fine. But how do I
> create 1D only LUTs with Nuke? Is this dependent of the output file format
> I choose. I'd like to create a 1D LUT as .cube. The documentation says,
> .cube is able to be 1D or 3D. But everything I try, I always end up with a
> 3D LUT.
> >>
> >> Thanks, Abraham
> >>
> >>
> >> Abraham Schneider
> >> Head of VFX pipeline / VFX Supervisor
> >>
> >>
> >> Türkenstr. 89, 80799 München /
> >> Phone +49 89 3809-1096
> >>
> >> EMail [email protected]
> >>
> >> Visit us on Facebook!________________________________
> >>
> >>
> >> ARRI Film & TV Services GmbH
> >> Sitz: München Registergericht: Amtsgericht München
> >> Handelsregisternummer: HRB 69396
> >> Geschäftsführer: Helge Jürgens, Josef Reidinger
> >> _______________________________________________
> >> Nuke-users mailing list
> >> [email protected], http://forums.thefoundry.co.uk/
> >> http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users
> > _______________________________________________
> > Nuke-users mailing list
> > [email protected], http://forums.thefoundry.co.uk/
> > http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users
> _______________________________________________
> Nuke-users mailing list
> [email protected], http://forums.thefoundry.co.uk/
> http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users
>
_______________________________________________
Nuke-users mailing list
[email protected], http://forums.thefoundry.co.uk/
http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users