Environment Mapping

To change default environment mapping image, use this code:

viewportLayout1.Rendered.EnvironmentMappingImage = myImage;
viewportLayout1.CompileUserInterfaceElements();

 

To enable material specific environment mapping, use this code:

viewportLayout1.Materials["matName"].EnvironmentMappingImage = myImage;
viewportLayout1.Materials["matName"].Environment = .5f; // reflectance amount
viewportLayout1.Materials["matName"].LoadTexture(viewportLayout1.renderContext);
Have more questions? Submit a request

0 Comments

Please sign in to leave a comment.