Skip to content

WebGPU: CubeTextureNode applies envMapRotation on arbitrary cube maps #34521

Description

@Mirei3D

Description

I didn't actually run into the problem, but I noticed this while reading the source code. If a material has an envMapRotation property, it will be applied to all cube textures bound to the material and not just the actual environment map. This could become a problem when writing a custom shader (extending directly from NodeMaterial or i.e. MeshStandardNodeMaterial) that uses envMap and envMapRotation but also binds custom cube maps.

Reproduction steps

  1. create a cube map
  2. bind it to a NodeMaterial
  3. setup an envMapRotation on the material

Code

// code goes here

Live example

https://jsfiddle.net/ytef53j1/

Screenshots

No response

Version

r186

Device

No response

Browser

No response

OS

No response

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions