Closed nikoprotic closed 6 months ago
:tada: This issue has been resolved in version 2.30.1 :tada:
The release is available on:
Your semantic-release bot :package::rocket:
@CodyJasonBennett insane turn-around speed, thank you! Though I am a bit salty that I couldn't get a chance to contribute a fix myself...
You're welcome to make it a shared constant so this doesn't regress with future code. Fixed this issue before in a few spots. We hardcode SRGBColorSpace
, LinearSRGBColorSpace
and the older sRGBEncoding
and LinearEncoding
all around. Can't import it from three.js since it's unknown whether the export is there.
three
version: 0.164.1@types/three
version: 0.164.1three-stdlib
version: 2.30.0Problem description:
calling
new Lut()
crashes my program.Relevant code:
Suggested solution:
It seems like the issue is here: https://github.com/pmndrs/three-stdlib/blame/bdfe295d6e725a8109b49d7ccf266a2b05ab4424/src/math/Lut.js#L60C57-L60C57. ThreeJS expects a
LinearSRGBColorSpace
of "srgb-linear", not "linear-srgb". This can be seen in their repo here: https://github.com/mrdoob/three.js/blob/0bc990f5f728552c6cc3931d1b44afa9718aef40/src/constants.js#L162. This results in the error being thrown from here: https://github.com/mrdoob/three.js/blob/0bc990f5f728552c6cc3931d1b44afa9718aef40/src/math/ColorManagement.js#L93.