Page 1 of 8 123 ... LastLast
Results 1 to 10 of 74

Thread: iray Matte Objects

  1. #1
    Join Date
    Apr 2010
    Location
    Berlin
    Posts
    61

    Default iray Matte Objects

    Here is the file referred to by the blog post for matte objects in 3ds Max 2013:

    http://blog.irayrender.com/post/2165...n-3ds-max-2013

    First time viewers, please note,
    to download as anonymous you may use the FTP link below. Alternatively, copy'n'paste the text from the post further down, and save it into a file on your computer. If you are already an approved forum user you should be able to download the file directly by clicking the attachment to this post.


    Download via anonymous FTP

    ftp://ftp.mentalimages.com/pub/iray_...environment.mi.

    Copy 'n' Paste

    If you can't download the file, copy & paste the file contents from this post further down.

    daniel, steve
    iray dev
    nvidia arc
    Attached Files Attached Files
    Last edited by steve; August 30th, 2013 at 10:47. Reason: reorder download options

  2. #2
    Join Date
    Apr 2010
    Location
    Berlin
    Posts
    61

    Default

    Here are the contents of the file, in case anyone else has problems. Simply copy & paste into a file named iray_matte_environment.mi

    #************************************************* ****************************
    # Copyright 1986, 2012 NVIDIA Corporation. All rights reserved.
    #************************************************* ****************************

    $ifndef "iray_matte_environment_included"
    set "iray_matte_environment_included" "true"

    declare phenomenon
    color "iray_matte_environment"(
    shader "environment_map",
    boolean "enable_matte",
    boolean "force_black_background",
    color "shadow_color",
    scalar "env_shadow_mix",
    boolean "light_color_affects_shadow",
    array geometry "matte_objects",
    array light "matte_lights",

    struct "ground_plane"
    {
    boolean "ground_enabled",
    vector "ground_up_vector",
    scalar "ground_height",
    scalar "ground_reflectivity",
    scalar "ground_gloss_exponent"
    }
    )

    shader "passthrough" "adsk_Utility_Shader_PassThrough"
    (
    "the_shader" = interface "environment_map",
    "type" 0
    )

    root = "passthrough"

    version 101014011
    apply environment, texture

    gui "gui_iray_matte_environment" {
    control "Global" "Global" (
    "uiName" "iray Matte Environment",
    "category" "iray"
    )
    control "environment_map" "shader" ("uiName" "Environment/Backplate", "helpText" "This is where the spherical environment or environment/background switcher is assigned.")
    control "enable_matte" "boolean" ("uiName" "Enable Matte Objects", "value" 1, "nonConnectable", "helpText" "This enables or disables the matte objects functionality.")
    control "force_black_background" "boolean" ("uiName" "Render for Compositing", "value" 0, "nonConnectable", "helpText" "Forces the background color to black to faciliate post-render compositing.")
    control "shadow_color" "color" ("uiName" "Matte Shadow Color", "value" 0 0 0, "nonConnectable", "helpText" "The color of matte shadows, useful to account for some ambient lighting.")
    control "env_shadow_mix" "scalar" ("uiName" "Environment Shadow Mixer", "value" 1.0, "range" 0.0 2.0, "nonConnectable", "helpText" "Changes the relative weight of shadows from the environment verus light sources. At 0.0 there are no environment shadows, at 2.0 there are no light source shadows, at 1.0 the behavior is unaffected.")
    control "light_color_affects_shadow" "boolean" ("uiName" "Light Color Affects Shadow", "value" 1, "nonConnectable", "helpText" "When enabled, the matte shadow color is tinted by the complement of the light color.")
    control "matte_objects" "array geometry" ("uiName" "Matte Objects", "nonConnectable")
    control "matte_lights" "array light" ("uiName" "Matte Lights", "nonConnectable")
    control "ground_plane" "struct" ("uiName" "Ground Plane")
    {
    control "ground_enabled" "boolean" ("uiName" "Enable", "value" 0, "nonConnectable", "helpText" "Enables a simple procedural matte ground plane.")
    control "ground_up_vector" "vector" ("uiName" "Up Direction", "value" 0 0 1, "nonConnectable", "helpText" "Orientation (normal) of the matte ground plane, in world space.")
    control "ground_height" "scalar" ("uiName" "Ground Height", "value" 0, "nonConnectable", "units" "world", "helpText" "Height at which the ground plane is created, in world units.")
    control "ground_reflectivity" "scalar" ("uiName" "Ground Reflectivity", "value" 0, "range" 0.0 1.0, "nonConnectable", "helpText" "Reflectivity of the ground plane")
    control "ground_gloss_exponent" "scalar" ("uiName" "Ground Gloss Exponent", "value" 500, "range" 0.0 1000000.0, "nonConnectable", "helpText" "Glossiness of the ground plane, as an exponent (0 = specular).")
    }
    }

    end declare

    $endif

  3. #3
    Join Date
    Jan 2009
    Location
    Berlin/Germany
    Posts
    1,147

    Lightbulb forum member permission

    Quote Originally Posted by lele View Post
    I can't download it. The forum tells me that i don't have enough privileges..!!
    Dear Junior Members,

    you, our new members, get approved typically with your first post in our forum, which gives the moderator a clue if this is spam or not. Sorry for the inconvenience, but this procedure helps us to keep the forum clean.

    I think you have passed this barrier in the meantime

    Best, Steve.

  4. #4
    Join Date
    Apr 2012
    Posts
    69

    Default

    I was wondering if the new matte feature can be used for nighttime renderings (with street or other lighting in the backplate).

    Specifically, I was wondering if there was any advantage of taking two separate pictures for the backplate, one during daytime and one set to during the scene's time (evening or night time). I figured the materials would not show very well during the night if you were to light them with synthetic lights, so the matte feature could be impeded.

    I haven't done any testing yet, but I was wondering about general opinion and experience about the use of matte textures for night (dark) backplate scenes. Thanks!

  5. #5
    Join Date
    Apr 2010
    Location
    Berlin
    Posts
    61

    Default

    Quote Originally Posted by SamuelAB View Post
    I was wondering if the new matte feature can be used for nighttime renderings (with street or other lighting in the backplate).

    Specifically, I was wondering if there was any advantage of taking two separate pictures for the backplate, one during daytime and one set to during the scene's time (evening or night time). I figured the materials would not show very well during the night if you were to light them with synthetic lights, so the matte feature could be impeded.

    I haven't done any testing yet, but I was wondering about general opinion and experience about the use of matte textures for night (dark) backplate scenes. Thanks!
    Night rendering should work fine. The trick is to get the lighting right: you either need a linearly scaled HDR image, or you can use a LDR image and simulate the lighting using emissive matte objects or matte light sources.

    I've made some tests with interior scenes, with an LDR environment, and used some light sources to complement it. It worked out nicely.

    daniel
    iray dev

  6. #6
    Join Date
    Apr 2012
    Posts
    69

    Default

    Thanks for the tips Daniel,

    I'll look into these particular image formats and do some testing. If you have any of your result images, I'd be interested in seeing them.

  7. #7
    Join Date
    Apr 2012
    Location
    Russia, Spb
    Posts
    15

    Default

    Thanks, but it does not work correctly in 3ds Max 2013...

  8. #8
    Join Date
    May 2012
    Posts
    1

    Default same proble

    Quote Originally Posted by Byteman View Post
    Same privilage problem here,too. With copy paste method, Max gets stuck after the interface appears and before the splash screen disappears. What may be wrong?
    same problem here, pasted file doesn't work

  9. #9
    Join Date
    Apr 2010
    Location
    Berlin
    Posts
    61

    Default

    Please provide more details on what's not working.

    Could it be that you need to enable the "Show Incompatible" flag in the material/map browser?

    daniel
    iray dev

  10. #10
    Join Date
    Feb 2006
    Location
    France
    Posts
    87

    Default

    I succeed in making it work into maya 2013 but i only catch the alpha when assigned to camera environement shader with object list defined, meaning the illumilation of sperical lookup or HDR is not taken into account in RGB channels.
    Can someone help to make a proper shading network ?

    thanks.
    Visualization Team | Digital Rendering Process
    Renault Design

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •