GallenWolf Posted May 21, 2008 Share Posted May 21, 2008 Hey everyone! Couldn't find anything on odf or the sesi forums on a linear to light workflow? Please correct me if I'm wrong, but from what I'm understanding, is that say, textures e.g. jpegs will have a gamma of 2.2 encoded in it for viewing, so for textures we'll need to gamma them to about 0.45 prior to rendering. Then after rendering, I need to view/composite them with the mplay/cop viewer gamma set to 2.2? I assume there is no need to mess around with adding the spare paramater "Gamma" to the mantra rop i'm using? Thanks! GW Quote Link to comment Share on other sites More sharing options...
kodiak Posted May 21, 2008 Share Posted May 21, 2008 Nope, you should render with a gamma of 1.0. As you said, you will need to put your textures to linear space as well beforehand, and use a display gamma of 2.2 in Mplay. Also, the colour picker will need to be set to a gamma of 2.2 as well to show you what you're actually picking by setting this environment variable. Not sure if there is a new/better way in H9. HOUDINI_COLOR_PICKER_GAMMA This variable specifies the gamma exponent for the device specific color correction of the color picker gadgets and color parameters. Quote Link to comment Share on other sites More sharing options...
sibarrick Posted May 21, 2008 Share Posted May 21, 2008 You probably don't want to be using jpegs for textures if you can help it. Also turn them into RAT files for best quality. Quote Link to comment Share on other sites More sharing options...
GallenWolf Posted May 21, 2008 Author Share Posted May 21, 2008 Hey Houdniks! Great, I do have a few more questions! For converting the textures - should I just simply run all my textures through a .45 gamma, or is there a specific LUT available to convert the sRGB images to linear space? I assume that I will use this LUT through the Lookup COP? (Which incidently... seems bugged. Not sure need more testing) Following the first question, if there is a LUT to convert sRGB to linear light, I assume we can't then just use 2.2 gamma for viewing, but also need a sRGB to linear light LUT? si - I do use rat for my textures, but thanks for the tip :thumbsup: Thanks! GW Quote Link to comment Share on other sites More sharing options...
jason_slab Posted May 21, 2008 Share Posted May 21, 2008 (edited) hey, funny i was searching for this yesterday! how can i set my incoming textures at shader level in Houdini to linear? or do i have to convert them in photoshop or something first? thx jason Edited May 21, 2008 by jason_slab Quote Link to comment Share on other sites More sharing options...
kodiak Posted May 21, 2008 Share Posted May 21, 2008 hey, funny i was searching for this yesterday!how can i set my incoming textures at shader level in Houdini to linear? or do i have to convert them in photoshop or something first? thx jason You could do it when you're converting your texture to RAT. Alternatively you could add a color correction VOP (or equivalent shader code) after the texture and change the gamma there. Quote Link to comment Share on other sites More sharing options...
kodiak Posted May 21, 2008 Share Posted May 21, 2008 (edited) Hey Houdniks!Great, I do have a few more questions! For converting the textures - should I just simply run all my textures through a .45 gamma, or is there a specific LUT available to convert the sRGB images to linear space? I assume that I will use this LUT through the Lookup COP? (Which incidently... seems bugged. Not sure need more testing) Following the first question, if there is a LUT to convert sRGB to linear light, I assume we can't then just use 2.2 gamma for viewing, but also need a sRGB to linear light LUT? Depends on if you want to go crazy or not For practical uses, I would say arguably a gamma of 2.2 (or rather correction) should do for texturing. For viewing purposes, making sure you have a screening device that maps this 2.2 gamma to the final screening device (that is projector/screen/print stock/light conditions) and also that you're comping in the right color space and your comp display LUT is setup accordingly (as is your comp output driver). Also, something I've seen happening is for example in Nuke, when you're applying a LUT to the loader, there is an option to pre divide + post multiply with that.. It should be on if there is an alpha involved (ie. a beauty pass, not necessarily with AOVs). For a little more involved setup, you could try to follow this interesting article. Additional comments/corrections welcome as it's an important but overlooked subject (especially at smaller places). Edited May 21, 2008 by kodiak Quote Link to comment Share on other sites More sharing options...
GallenWolf Posted May 22, 2008 Author Share Posted May 22, 2008 kodiak - that link was very helpful! I implemented the stuff in there, and the results were quite interesting. Highlights seem more photographic, but the shadow rolloffs are harsher that what I'm usually expected. I need to find out more about the effects of rendering/compositing in linear space. Cheers dude! GW Quote Link to comment Share on other sites More sharing options...
edward Posted May 25, 2008 Share Posted May 25, 2008 In H9, look in Edit > Color Settings (or similar). There should be multiple gamma controls in there. Quote Link to comment Share on other sites More sharing options...
GallenWolf Posted May 28, 2008 Author Share Posted May 28, 2008 Alright will check Edward, thanks! Quote Link to comment Share on other sites More sharing options...
Mario Marengo Posted May 28, 2008 Share Posted May 28, 2008 Another recent reference on this topic: Book: GPUGems 3 Chapter 24: The Importance of Being Linear, by Larry Gritz and Eugene d'Eon. Basically what Kodiak mentioned, but with a few examples to make the argument very compelling Quote Link to comment Share on other sites More sharing options...
edward Posted May 29, 2008 Share Posted May 29, 2008 I always thought that, even intuitively, once the concept of gamma is explained it would be natural to store all of ones images in linear space. Photoshop even has tools to facilitate this. Houdini has color pickers which one can set the gamma with. The only catch AFAICT, is that you can't store and process linear space colours in 8-bits, use at least 16-bit floating point. For this reason, the mantra output driver in H9 outputs 16-bit floating point by default. What's interesting though is that Shake doesn't seem to support 16-bit floating point .tiff's. Quote Link to comment Share on other sites More sharing options...
GallenWolf Posted May 29, 2008 Author Share Posted May 29, 2008 Hey Mario! Thanks for the heads up. I'll see if I can locate that book somewhere.... Ed, I think I'm usually outputting 16 bit floats from M to use in S, seems to work fine? In any case I think i'm switching over to rendering exrs from today..... Alvin Quote Link to comment Share on other sites More sharing options...
edward Posted May 29, 2008 Share Posted May 29, 2008 Try running iinfo on your .tiff ... if you're rendering to .tiff from mantra, then I think they get converted to 32-bit floating point. Quote Link to comment Share on other sites More sharing options...
GallenWolf Posted May 30, 2008 Author Share Posted May 30, 2008 Hi Ed! iinfo - woo another nugget Yes you are right - tiffs from M are 32bit, and the exrs are 16bit. Which means shake has been eating 32bit tiffs to date. Is this like an automatic conversion by Mantra? Alvin Quote Link to comment Share on other sites More sharing options...
old school Posted May 30, 2008 Share Posted May 30, 2008 Tiff only supports floating point values as 32 bit. tiff only supports 16bits as int's only (as far as I know...). If you want floats, you end up with 32 bits. If you want 16bit floats (half floats?) then consider using OpenEXR in the future. Quote Link to comment Share on other sites More sharing options...
edward Posted May 30, 2008 Share Posted May 30, 2008 tiff does support 16-bit floating point tiff's (albeit it's not part of the baseline specification). Houdini currently doesn't output 16-bit floating point .tiff's due to incompatibilities with other applications. I've heard that Nuke supports 16-bit floating point .tiff's though. Houdini itself will read 16-bit floating point .tiff's however in the next major release of Houdini. Quote Link to comment Share on other sites More sharing options...
GallenWolf Posted June 2, 2008 Author Share Posted June 2, 2008 Jeff, Edwards - thanks for the info! Always good to know. Thanks guys! Alvin Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.