Archive for the ‘Notes’ Category

If you’re a developer of 3D games, then you’ve probably come across the terms forward rendering and deferred rendering in your research of modern graphics engines. And, often, you’ll have to choose one to use in your game. But what are they, how do they differ, and which one should you pick?

The difference between forward rendering and deferred renderingDeferred Rendering for many lights (Image courtesy of Hannes Nevalainen)



Read Full Post »

Reference: from siggraph 2004 and ATI presentation from Thorsten Scheuermann

kajiya-kay and Marschner lighting model



Read Full Post »

parallex hair

Fluffy fur used for this helmet.
Polycount Forum thread Fur breakdown.
Image by Joost Vanhoutte.

Read Full Post »

Read Full Post »

Oren Nayar reflection

This post is a complete copy and paste directly from “Renderman Portfolio” All credits go to Kevin George.

Source: https://sdm.scad.edu/faculty/mkesson/vsfx755/wip/best/spring2012/kevin_george/final/index.html

The dielectric shader I created earlier in the quarter afforded me an opportunity to re-learn the relevant computer graphics maths, but was not particularly concerned with physical correctness. My blurry reflection and refraction was just due to a large number of samples in a widening cone around the reflection/transmission direction, with all samples weighed equally. As I have continued my explorations with shading, I have discovered that this is not particularly physically-based, nor is it efficient.

For my independent project, I plan to build on these concepts and create a physically-plausible material along the lines of the mia_material_x (mental ray) material. There are several stages to implementing a shader of this type. First, I plan to implement a number of diffuse and specular models to better understand the underlying maths and practice implementation of a microfacet-based BRDF. Next, I will add reflection functionality, but by importance sampling the specular BRDF instead of the standard cone around the reflection vector.


Read Full Post »

Source: http://www.vfxmill.com/

Read Full Post »

[notes] vray

Presets can be found at http://vray-maya-materials.com/

Due to the comment problem about glowing frensel.  There are 2 groups of 3rd party ppl are working on it.  Here are the result: https://www.flickr.com/photos/adanmq/sets/72157672161857525/with/28559201220/

OSL: http://www.rensheeren.com/
ALsurface: https://github.com/ChaosGroup/vray_al_surface/releases

  1. Copy the file vray_BRDFAlSurface.dll to the folder with the rest of the V-Ray plugins (f.e. C:\program files\autodesk\maya2016\vray\vrayplugins)
  2. usage in Maya: You can create the new material from Create > V-Ray > Create from V-Ray plugin > BRDF material

Full discussion can be found(login required): http://forums.chaosgroup.com/showthread.php?89466-Rough-Specular-reduces-specularity-amount/page15

Image Linearize: because vray adds 2.2 gamma on VFB, so all sRGB image texture should gamma corrected

  1. select the file node with the texture on it
  2. attribute >vray > texture input gamma
  3. attribute > vray > allow negative colour
  4. go down to extra vray attribute
  5. If the input image is an sRGB, leave it as is (or switch it to sRGB under colour space)
  6. if it is a 32bit displacement map > switch color space to linear or adjust the texture gamma to 1

To globally adding 2.2 gamma to all image input to render view: note that VFB adds a global 2.2 gamma on the render.  This option only effects maya render view

  1. Under render settings > vray common > render view > convert image to sRGB for renderview

Dynamic memory limits(MBs):  The value should be set to half of the system RAM capacity.  32gb ram should set to 1680,etc

  1. render view > settings >system >dnamic memory limits

Vray Settings principle: Idea is to use anti-alias(AA) for thin lines textures and edge of object but to use higher sample rate for the body of the object, reflections, shadow. Vray will try to balance itself to have the best looking image.  If the sample subdivision in light and material is set too low.  AA will try to take over to make it a smooth render.  But AA renders take way longer than sample subdivision.  So in most cases rather up the sample in light and material when needed in majority of area.  Leave AA to calculate just for the edge of object or straight line.  To do that:

  1. add sample rate in render element to check the render.  Blue area means render is using minimum value of the AA value (as set) red means max AA value (as set) green is somewhere in between.  The ideal outcome of the sample rate pass is to have majority of things render as blue.  Only straight lines and object edge or texture edge are render in red.
  2. under render settings v-ray tab under progressive rendering set min 1 max 4 or 8 (drop max value significantly but the smaller the number the slower the render)
  3. turn off AA filter (uncheck).  99% are useless
  4. Progressive noise threshold can be higher.  Depend on the sample subdivision fireflies.  The higher the number the greater colour differences tolerant between 2 pixels.  If one pixel is 255 255 255 another is 128 128 128.  And if the threshold is very high like 100.  The render will probably skip AA ing these 2 pixel.  The smaller the threshold the bigger range of the pixel value difference will be consider as to fix by adding AA.  So tweak this number start from a big number to a smaller number until the fireflies are gone. but most cases if it is not fireflies, just some noise, by adding material and light sample subdivision should fix it.
  5. up sample rate subdivision in material and light
  6. by adding GI it may adding some bounce light to ease off the contrast of the samples noisy dot.  Make sure the sample rate subdivision under GI Bruite force GI is up to at least what the material sample rate subdivision is (add GI render element as render pass to check the noise)
  7. DMC sampler amount is the overal sample relatively to light and material and GI
  8. usually don’t need to touch the amount but the adaptive threshold can go up or down according to how many sample needed to be added to blur out the sample noise. those noise can also be blur out with AA threshold.
  9. under render option > settings > render region division.  set it lower to about 8-16 to cut it down smaller square to render.  each block of square will use a thread to render.  So if a big block of square are taking too long to render by breaking it down to smaller block can divide into more threads to render.


Read Full Post »

Older Posts »

%d bloggers like this: