[BUG] Isaac Sim render does not listen to MDL material_geometry displacement

Dear NVIDIA Community.

Isaac Sim 4.1.0

I have encountered a bug while designing an MDL material.

From official NVIDIA MDL handbook:
https://mdlhandbook.com/mdl_handbook/index.html#displace#displacement-mapping-moving-a-surface-point

I took a waves_as_displacement material from Listing 12.5

My mdl code as copy from handbook:

mdl 1.8;

import ::base::*;
import ::df::*;
import ::anno::*;
import ::state::*;
import ::math::*;
import ::tex::*;
import ::scene::*;

float fit(
    float v,
    float old_min, float old_max,
    float new_min, float new_max)
{
    float scale = (v - old_min) / (old_max - old_min);
    return new_min + scale * (new_max - new_min);
}


float sinusoid(
    float f,
    float frequency = 1.0,
    float minval = -1.0,
    float maxval = 1.0)
{
    float fraction = math::frac(f);
    float angle = fraction * 2.0 * math::PI;
    float scaled = angle * frequency;
    float sine_value = math::sin(scaled);
    float result = fit(sine_value, -1.0, 1.0, minval, maxval);

    return result;
}


float uv_wave(float2 frequency = float2(1.0), float2 minval = float2(-1.0), float2 maxval = float2(1.0))
{
    float3 p = state::texture_coordinate(0);
    float u_component = sinusoid(p[0], frequency[0], minval[0], maxval[0]);
    float v_component = sinusoid(p[1], frequency[1], minval[1], maxval[1]);
    return u_component + v_component;
}


export material waves_as_grayscale (
   uniform float2 frequency = float2(1.0),
   uniform float2 gray_max = float2(0.5)

) = let {
   color tint = color(uv_wave(frequency, float2(0.0), gray_max));
} in material (
   surface: material_surface (
      scattering: df::diffuse_reflection_bsdf(tint: tint)
    )
);


export material waves_as_displacement (
    uniform float2 frequency = float2(1.0),
    uniform float2 distance = float2(0.1),
    color tint = color(0.7)

) = let {
    float displacement_distance = uv_wave(frequency, -distance, distance);
    float3 displaced_normal = state::normal() * displacement_distance;

} in material (
    surface: material_surface (
        scattering: df::diffuse_reflection_bsdf(tint: tint)),
    geometry: material_geometry(
        displacement: displaced_normal)
);

Material waves_as_grayscale shows perfectly using both RTX - Real-Time and RTX- Interactive (Path Tracing)

However waves_as_displacement does not work at all in any settings

@pcallender
MDL Displacement is not supported in Isaac Sim renderer or this is a bug?

Dear NVIDIA team, could you please comment on this feature?

cc @VickNV

Thank you for reporting this issue. I’m currently checking it with our team and will provide an update as soon as I have more information. I appreciate your patience.

RTX in Isaac Sim does not currently support displacement, regardless of MDL capabilities. Displacement support for RTX is in development and will be implemented in a future release.

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.