Skip to content

THREE.WebGLProgram: Unsupported encoding: undefined #20935

@ezewu

Description

@ezewu

Describe the bug

Console three.module.js?5a89:16731 THREE.WebGLProgram: Unsupported encoding: undefined

Code

const TextureLod = new THREE.TextureLoader()
const mapImage = TextureLod.load('static/demo4/textures/001.jpg')
mapImage.wrapS = mapImage.wrapT = THREE.RepeatWrapping
mapImage.encoding = THREE.sRGBEncoding

const material2 = new Nodes.MeshStandardNodeMaterial()
material2.roughness = new Nodes.FloatNode(0.8)
material2.metalness = new Nodes.FloatNode(0)

const map = new Nodes.TextureNode(mapImage)
map.uv = new Nodes.UVTransformNode()
map.uv.setUvTransform(0, 0, 6, 6, 0)
material2.map = map
material2.normalMap = TextureLod.load('static/demo4/textures/normal2.png')

Platform:

  • OS: [Windows, MacOS, Linux, Android, iOS]
  • Browser: [Chrome, Firefox, Safari, Edge]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions