Playing around with PxrSeExpr

This got started from a question on the Renderman forums about the difference between ST and UV. Renderman uses UV and ST to differiate between “implicit” and “explicit” texture coordinates. Implicit is automatically defined by the geometric shape and explicit is manually defined by the user.

With polygons and subdivision geometry, Renderman uses ST coordinates for texture mapping (it converts Maya UVs to Renderman STs behind the scenes). But it also automatically assigns UV coordinates to each face on the geometry, you might ask why would you need this?

For fun and profit!


Heat Map

Useful if you ever want to better visualize data images.

Basic idea is to put the data in the red channel, normalize it between zero and one, then make sure the green and blue channel are both set to one and convert the colourspace from HSV to Linear.

Blackpoint and Whitepoint are set to the minimum and maximum samples from the render. Gain is set to 0.666667 so that the range is mapped from Red to Blue, rather than Red through to Red.

Linux for CG – “easily goto directories, even if they don’t exist yet”

Quick little tidbit. This tests to see if a specific directory exists, if it does it goes to that directory, otherwise it creates the directory and then goes to it.

alias makeshot 'test -d /prj/$PROJECT/$SHOT/ && cd /prj/$PROJECT/$SHOT || mkdir -p /prj/$PROJECT/$SHOT; cd /prj/$PROJECT/$SHOT'

The first part ‘test -d’ checks if the directory exists, the command after && runs what happens if that check is true, the command after || runs if the check is false.

Renderman Denoising

A few little tips and tricks for Denoising stuff in Renderman…

Most of this comes from here…, you’ll need to make sure your environment variables are set correct to do this in the shell.

Note: This is using Windows, a lot of it is similar to Linux/Mac, there might be some syntax differences.

For all examples, we have a directory which contains the following image sequences…

RIS_denoised_variance.####.exr (the main render pass)
RIS_denoised_variance_directdiffuse1.####.exr (key light diffuse)
RIS_denoised_variance_directdiffuse2.####.exr (environment light diffuse)
RIS_denoised_variance_directspecular1.####.exr (key light specular)
RIS_denoised_variance_directspecular2.####.exr (environment light specular)

To denoise several frames (0001-0007) of the beauty render using single-frame denoising. Include the { } brackets around the frame numbers, wildcards * don’t seem to work for me in Windows.

denoise RIS_denoised_variance.{0001,0002,0003,0004,0005,0006,0007}.exr

To denoise the same seven frames (0001-0003) using cross-frame denoising.

denoise --crossframe -v variance RIS_denoised_variance.{0001,0002,0003,0004,0005,0006,0007}.exr

To denoise the AOVs as well, only on three frames this time…

denoise --override filterLayersIndependently true -- RIS_denoised_variance.{0001,0002,0003}.exr RIS_denoised_variance_directdiffuse1.{0001,0002,0003}.exr RIS_denoised_variance_directdiffuse2.{0001,0002,0003}.exr RIS_denoised_variance_directspecular1.{0001,0002,0003}.exr RIS_denoised_variance_directspecular2.{0001,0002,0003}.exr


VFX and Animation by some Numbers

If you’ve ever wondered how big the VFX and Animation industry is – this might give you some idea – and I have no idea how accurate this is.

I searched Linkedin for the most visible studios in the industry and recorded down how many employees were listed for each studio. Keep in mind a few things…

  • This only includes employees who are on Linkedin.
  • Relies on people entering the correct name of their employer and/or keeping their information up-to-date.
  • If your wondering why Lucasfilm is on there – lot’s of ILM people put it down as their employer (it technically is I guess). Impossible to know how much of those are ILM people versus other Lucas companies.



Text Values in Nuke for Wedge Renders

This is more a reminder for myself, as I can never remember the syntax for outputting values to Text nodes in Nuke.

Strength [format %0.2f [value strength]]

Often use this when doing wedge renders during lookdev. A wedge render is a render where you render several frames of the same thing but only change a few specific values to see what effect the change has.


A few things to note…

  • In this case the “strength” attribute to look up comes from a custom user knob on the same knob.
  • The format %0.2f statement is used to format the value. See the printf reference for more details.