Home Adobe Substance

PBR BaseColor/Metallic to Vray (3.2) / Corona / Redshift / Arnold converter

1
polycounter lvl 13
Offline / Send Message
NicolasW polycounter lvl 13
Here is a filter to convert baseColor/Metallic/roughness to Vray/Corona/Redshift/Arnold

This filter is now by default in SD library (search for PBR converter).


Limitations:
- in Vray/Corona the fresnel is colored, it's not in SD
- a 100% black metal renders black/no reflection in Vray/Corona, in SD the fresnel is still visible.
- in Redshift, materials with in between gray values in Metallic are rendered with a slightly different color than in SD


wigewBRjpg



Vray 3.2

  • for the glossiness and 1/ior texture make sure the gamma for these maps is set to 1.0
  • diffuse and specular (reflection) should be left to default (gamma 2.2)
  • select the "Microfacet GTR (GGX)" brdf (Vray 3.2 only).
simple scene example :http://1drv.ms/1MXUgOa

2ZAI9Bzpng


Corona 1.2

  • for the glossiness and 1/ior texture make sure the gamma for these maps is set to 1.0
  • for the ior texture, create a CoronaMix, Set the Mix Operation to Divide, put the ior texture in the Top Layer, set the Base Layer to White
  • I put a simple curve on the glossiness to approximately compensate their internal curve (they gave me the function I'll try to make something more accurate later). Or maybe they'll just get rid of their curve, that'd be the best solution
simple scene example : http://1drv.ms/1MXUrco

hX7bTC2png


Redshift

  • for the glossiness and f0 textures make sure the gamma for these maps is set to "linear sRGB"
  • plug the f0 map to the "Facing Reflectivity" input
  • curve is also applied because Redshift seems to use a Blinn-Phong BRDF
ciLlOBOpng


Arnold 1.2.3.1
  • color profile on native 2D texture is not taken into account by Arnold
    • apply gamma correction (2.2) on roughness and f0 if texture gamma is set to 2.2 in the renderer settings
    • apply gamma correction (2.2) on diffuse and specular if texture gamma is set to 1 in the renderer settings
  • roughness does not perfectly matches: Arnold uses a Cook-Torrence brdf, closer to GGX than Blinn-Phong but still a bit different
wUSUdWlpng

Replies

  • ActionDawg
    Offline / Send Message
    ActionDawg greentooth
    This is super cool. Would love to see the same thing for Corona
  • Visceral
    This is just perfect thank you so much.
  • xtrm3d
    Offline / Send Message
    xtrm3d polycounter lvl 9
    super great !!

    could we get one for redshift ?

    je peux t aider si tu veux :-)
  • NicolasW
    Offline / Send Message
    NicolasW polycounter lvl 13
    somedoggy wrote: »
    This is super cool. Would love to see the same thing for Corona

    I've tested Corona, it does not support IOR < 1. Even though you can plug a bitmap in the IOR input, it looks like it's stuck to 1.

    The ior is mandatory for the conversion.. :/
    In vray, the values bellow 1 represents 1/ior, allowing users to input a texture. Maybe you could ask the devs for that ? :)

    I'm downloading the demo of Redshift, I'll see what the shader offers!
  • xtrm3d
    Offline / Send Message
    xtrm3d polycounter lvl 9
    ""I'm downloading the demo of Redshift, I'll see what the shader offers!""

    i could send you the part about rendering in redshift that i did for my gnomon video

    could be a good start ..
    i managed to get close to 90/95 %

    christophe
  • NicolasW
    Offline / Send Message
    NicolasW polycounter lvl 13
    Got the demo but don't have maya installed ;)

    I'll do that tomorrow.
    Sure, send me the video!
  • xtrm3d
    Offline / Send Message
    xtrm3d polycounter lvl 9
    even better i would send you the maya files
    ( would need redshift installed )
  • ActionDawg
    Offline / Send Message
    ActionDawg greentooth
    NicolasW wrote: »
    I've tested Corona, it does not support IOR < 1. Even though you can plug a bitmap in the IOR input, it looks like it's stuck to 1.

    The ior is mandatory for the conversion.. :/
    In vray, the values bellow 1 represents 1/ior, allowing users to input a texture. Maybe you could ask the devs for that ? :)

    I'm downloading the demo of Redshift, I'll see what the shader offers!
    You should be able to use a composite node or something as a multiplier. Think that would allow you to map the values? I did a test on the free version and it worked, but I don't know what the correct conversion would be from a metallic roughness setup would be.
  • xtrm3d
    Offline / Send Message
    xtrm3d polycounter lvl 9
    the result of my parity test between substance painter and redshift render in maya

    left . painter right . redhsift

    driver-compar.jpg
  • NicolasW
    Offline / Send Message
    NicolasW polycounter lvl 13
    Ok, I have something for both Corona and Redshift.

    Corona:
    As you suggested making (1 / (1/ior map)) allows to retrieve the correct value.
    Their is one problem though: Corona shader seems to use a blinn/phong brdf (we use GGX in SD/SP). So we can apply a curve to try to match the glossiness but it can't work for very rough values (blinn/phong is limited for representing very rough surface).

    Redshift:
    We can do the same thing as in corona (the division in the ior channel) or simply use a F0 map in the "Facing Reflectivity" channel.
    Same problem as Corona: Redshift shader uses blinn/phong brdf.
    Also colored reflection on F0 is a bit different, it's less "colored" than in SD for values in between dielectric and metal. But anyway we are not supposed to have gray in metallic, right ? ;)

    I'll update the PBR converter and add a "target" parameter with Vray, Corona and Redshift and put some illustrations ;)
  • ActionDawg
    Offline / Send Message
    ActionDawg greentooth
    NicolasW wrote: »
    Ok, I have something for both Corona and Redshift.

    Corona:
    As you suggested making (1 / (1/ior map)) allows to retrieve the correct value.
    Their is one problem though: Corona shader seems to use a blinn/phong brdf (we use GGX in SD/SP). So we can apply a curve to try to match the glossiness but it can't work for very rough values (blinn/phong is limited for representing very rough surface).

    Redshift:
    We can do the same thing as in corona (the division in the ior channel) or simply use a F0 map in the "Facing Reflectivity" channel.
    Same problem as Corona: Redshift shader uses blinn/phong brdf.
    Also colored reflection on F0 is a bit different, it's less "colored" than in SD for values in between dielectric and metal. But anyway we are not supposed to have gray in metallic, right ? ;)

    I'll update the PBR converter and add a "target" parameter with Vray, Corona and Redshift and put some illustrations ;)
    Awesome that you figured it out :) I also had problems with remapping roughness correctly, but they claim to use ggx so there should be some curve that fits. https://corona-renderer.com/features/materials/

    I have noticed some inconsistencies with roughness, which may be part of the problem. Mainly when using displacement maps corona seems to get glossier as you get close up. I haven't been able to see a pattern in that behavior unfortunately.
  • NicolasW
    Offline / Send Message
    NicolasW polycounter lvl 13
    somedoggy wrote: »
    Awesome that you figured it out :) I also had problems with remapping roughness correctly, but they claim to use ggx so there should be some curve that fits. https://corona-renderer.com/features/materials/

    They probably put a curve on the glossiness.. we should be able to get a much rougher surface when gloss = 0..
    We implemented ggx without any changes from the original paper, seems like vray did the same, it perfectly matches with vray.
  • xtrm3d
    Offline / Send Message
    xtrm3d polycounter lvl 9
    any chance to get the exporter working in SUBSTANCE PAINTER ?
  • NicolasW
    Offline / Send Message
    NicolasW polycounter lvl 13
    I'll discuss that with the team !
  • xtrm3d
    Offline / Send Message
    xtrm3d polycounter lvl 9
    ""I'll discuss that with the team !""

    lol .. i am already bugging jeremie and alexis right now
  • ActionDawg
    Offline / Send Message
    ActionDawg greentooth
    I created a ticket on the Corona helpdesk to get in contact with someone who knows more about their ggx implementation. Hopefully they'll get someone in touch!
  • Sektar
    Offline / Send Message
    Sektar polycounter lvl 8
    Hi, thanks a lot, but can i see material settings or can u send 3ds max scene? ty
  • Sektar
    Offline / Send Message
    Sektar polycounter lvl 8
    NicolasW wrote: »
    I'll discuss that with the team !
    can u post vray material settings please?
  • Sektar
    Offline / Send Message
    Sektar polycounter lvl 8
    Hi can u show vray material settings please?
  • NicolasW
    Offline / Send Message
    NicolasW polycounter lvl 13
    No need to spam.. I've edited the first post with images/scene examples.
  • outtoplay
    Offline / Send Message
    outtoplay polycounter lvl 3
    This is terrific news! I have a rather advanced student that tested SP PBR output with The NonCommercial (free), version of Renderman utilizing their DIsney/Pixar Shader. He said it looked really good. As it's free, any chance you could take a peek at how your setup might work with Maya/Renderman?

    This is a great and desperately needed workflow addition to your great product line.
  • NicolasW
    Offline / Send Message
    NicolasW polycounter lvl 13
    Just tested Renderman: nothing special to do for the PxrDisney shader, just plug the maps in the slots and you get the same result as in SD/SP.

    Make sure the roughness and metallic map color profile is set to "Linear sRGB".

    b36HxjX.jpg
  • MDiamond
    Offline / Send Message
    MDiamond polycounter lvl 11
    Since we're talking about a lot of renders, I found this thread on the Allego Foruns, about Painter>OctaneRender, I tried and it seem ok, but if someone has a better alternative, it would be most welcome.:poly121:

    https://forum.allegorithmic.com/index.php?topic=4023.0
  • toren3d
    Offline / Send Message
    toren3d polycounter lvl 7
    Thanks so much for doing all this work NicolasW!

    I was curious if this will work with earlier versions of VRay, such as 1.5 and/or 2?
  • NicolasW
    Offline / Send Message
    NicolasW polycounter lvl 13
    @MDiamond I'll take a look at Octane tomorrow. I only have a 1.x license, do you know if they changed the brdf in 2.x ?

    @toren3d The main "problem" with earlier version of vray is the brdf: it's the key. If the brdf is different, the glossiness will be different. Vray 3.2 has the same brdf (ggx) than SD/SP, so the glossiness perfectly matches. With 1.x/2.x you can only choose between blinn, phong or ward, each would require a specific curve to approximately convert the glossiness. Blinn/Phong generally can't be as rough as ggx, but I think Ward can. I'll see what I can do ;)
  • CognizanCe
    Offline / Send Message
    CognizanCe polycounter lvl 11
    So metal roughness workflow creates a base color, metallic, and roughness map.
    But this filter is asking for a "Specular Level" map?
    Do I leave that node alone or am I supposed to provide a specular map?

    EDIT: Was having a "Cannot load Substance binary file" error, but I that was resolved. I was using an older version of the file you provided :s.
  • NicolasW
    Offline / Send Message
    NicolasW polycounter lvl 13
    The SpecularLevel map is optional, it allows you to adjust the F0 (reflectance at fresnel 0) for dielectrics. It's the "Specular" input you have in UE4. It's totally different from the "specular" in the diffuse/spec workflow.

    The SpecularLevel map is a grayscale texture which is remapped inside the shader to 0.02 -> 0.08. The default value for this map is 0.5 gray and corresponds to a 0.04 (4%) reflectance value at f0. It's the most common value for dielectrics. UE4 uses the same convention.

    Few people actually create this map, but it can be needed in specific cases so I had to take it into account.
  • noncarbon
    Planning to support Blender's Cycles somehow? Would it be just a .blend with the PBR Material and HDR setup or would any converted maps actually be necessary? I believe I read on your Twitter maybe this would happen.
  • NicolasW
    Offline / Send Message
    NicolasW polycounter lvl 13
    Yes, I've made a cycles Material that takes basecolor/metallic/roughness maps as input. No conversion needed, you'll get the same result as in SD/SP. I'll share it soon.
  • noncarbon
    Thanks a ton Nicolas! It'll be hugely helpful.
  • tungerz
    Offline / Send Message
    tungerz polygon
    NicolasW wrote: »
    Yes, I've made a cycles Material that takes basecolor/metallic/roughness maps as input. No conversion needed, you'll get the same result as in SD/SP. I'll share it soon.

    Nicolas my friend, you are cranking out great ports to all (or at least most) of the render engines :)

    Keep working your magic brother!
    Rock on (
  • MDiamond
    Offline / Send Message
    MDiamond polycounter lvl 11
    NicolasW wrote: »
    @MDiamond I'll take a look at Octane tomorrow. I only have a 1.x license, do you know if they changed the brdf in 2.x ?

    I don't think it did, in fact I'm not even sure if it will change in the 3.0 release, they seem more focused on VR and Volumetrics for now. I always wanted to know the name of the BRDF Octane uses but never found anything.
  • Fingus
    Offline / Send Message
    Fingus polycounter lvl 11
    Can I make a request for Mental Ray? :D
  • Jerc
    Offline / Send Message
    Jerc interpolator
    Kind of like this? :D

    gA7NuFt.png
  • tungerz
    Offline / Send Message
    tungerz polygon
    @ Jerc, that is a sexy lookin viewport (¤¿¤)
  • MDiamond
    Offline / Send Message
    MDiamond polycounter lvl 11
    Well damn. Just look at those "Lights" and "Cameras" buttons.
  • Araiel
    Offline / Send Message
    Araiel polycounter lvl 10
    I have a request - can someone save vray 3.2 3ds max file in format compatible with 2014 version? Because it was made in newer one and I can't open it.
  • bbigger
    Any news on this getting into the Export menu for Painter? I tried publishing the .sbs file to .sbsar to use in Maya with Vray, but the file archive won't load. I think I saw there was an update to Substances that would need a new integration plugin for Maya....? That right?

    Great job on spearheading this workflow!
  • NicolasW
    Offline / Send Message
    NicolasW polycounter lvl 13
    Export presets will be added to Painter, it won't require this substance.
  • bbigger
    @NicolasW Sweet! I'm working on a simple UI to properly assign the images to the right slots in Vray for Maya. Next I want to setup the scene to mimic Painter and maybe even vice versa. Is there any SDK/API for Painter to get at it's camera info, IBL image, scene settings, etc.? That'll make it nice and easy to do synchronization y'know. Or maybe that's Substance Painter 2.0.
  • NicolasW
    Offline / Send Message
    NicolasW polycounter lvl 13
    No, not for the moment..
  • NicolasW
    Offline / Send Message
    NicolasW polycounter lvl 13
    This PBR converter is now packaged with SD 5.2.0.
  • fatrobotsneedlove
    Is the Octane export preset still a possibility?
  • NicolasW
    Offline / Send Message
    NicolasW polycounter lvl 13
    I'm afraid it won't be possible. At least not in a simple form: octane does not support textures for the ior, so it's not possible to get both metal and dielectric on the same material.

    But right now a more complicated setup is possible:
    - a mix between a dielectric material (ior 1.4) and a specular material in function of the metallic map.
    - use basecolor as color for both
    - may need adjustments on the roughness/glossiness
  • alecmorris
    I was afraid of that. It's a feature that has been requested, but the Octane dev team said they wouldn't be putting it in until maybe V3 through some kind of OSL implementation.

    Thanks for trying Nicolas. I'll give the complicated setup a try.
  • MDiamond
    Offline / Send Message
    MDiamond polycounter lvl 11
    Yeah, Octane requires a lot more tweaks than the export from Painter itself. I use a similar approach that I posted in the previous page, that is:

    -Paint in Metal/Roughness(my preferred workflow), but convert and export to Spec/Gloss from Painter
    -Change my normal format to OpenGL
    -Create a Glossy Material for your textures in Octane with IOR=1
    -Change the gamma for your imported textures accordingly(1 or 2.2 depending on bit-depth)
    -If you export a Gloss Map, invert it in the Roughness input
    -The gamma for the roughness map that more closely matches Painter seems to be 1.250

    That's the setup that has been working for me.
  • Danwnewlands
    Hey guys, I've been testing the new vray filter that convert maps from SD into Maya/Vray. I've found that the diffuse become a lot darker when used with the vraymtl. I've got the gamma setup correctly, as diffuse is srgb and the rest are linear. They look exactly how they should on a surface shader when rendered with Vray just not with the vraymtl?

    I've tried various shader settings and nothing seems to be changing things. Any ideas?

    Thanks
  • NicolasW
    Offline / Send Message
    NicolasW polycounter lvl 13
    It appears vray does not take the gamma settings from the bitmap file, so you probably have to create an additionnal gamma node and set the gamma to 0.4545.
  • noncarbon
    Hey Nicolas. Any update on when you might release the Cycles setup?
  • Tzur_H
    Offline / Send Message
    Tzur_H polycounter lvl 9
    I'm trying to use the node to convert for use with Arnold, I'm really not sure if I'm setting everything up correctly. Can someone help please?

    I got Maya 2015, EXT 1, I have Color Management on, I don't know if it messes things up?

    in Maya Color Management I'm using:
    Rendering Space: scene-linear Rec 709/sRGB
    View Transform: sRGB Gamma
    Default Input Color Space: sRGB
    Output Transform: sRGB

    In Arnold settings I use:
    Display Driver Gamma: 1
    Light: 2.2
    Shaders: 2.2
    Textures: 1

    I brought in the files, set all of them to RAW (Maya Color Management) except for F0 and Roughness, which I set to sRGB - is that the right setup?

    Also, can't seem to get the tangent normal map to work, Arnold renders completely black, do I need to flip channels if exported from SD using DirectX?

    I usually work with game engines, so this is a new territory for me :poly142:

    I wish there was a written guide on how to set it up for inexperienced users :)
1
Sign In or Register to comment.