File tree Expand file tree Collapse file tree 2 files changed +4
-0
lines changed Expand file tree Collapse file tree 2 files changed +4
-0
lines changed Original file line number Diff line number Diff line change @@ -2329,6 +2329,7 @@ class LDrawLoader extends Loader {
23292329 material . premultipliedAlpha = true ;
23302330 material . opacity = alpha ;
23312331 material . depthWrite = ! isTransparent ;
2332+ material . color . convertSRGBToLinear ( ) ;
23322333
23332334 material . polygonOffset = true ;
23342335 material . polygonOffsetFactor = 1 ;
@@ -2350,6 +2351,7 @@ class LDrawLoader extends Loader {
23502351 } ) ;
23512352 edgeMaterial . userData . code = code ;
23522353 edgeMaterial . name = name + ' - Edge' ;
2354+ edgeMaterial . color . convertSRGBToLinear ( ) ;
23532355
23542356 // This is the material used for conditional edges
23552357 edgeMaterial . userData . conditionalEdgeMaterial = new LDrawConditionalLineMaterial ( {
@@ -2361,6 +2363,7 @@ class LDrawLoader extends Loader {
23612363 opacity : alpha ,
23622364
23632365 } ) ;
2366+ edgeMaterial . userData . conditionalEdgeMaterial . color . convertSRGBToLinear ( ) ;
23642367
23652368 }
23662369
Original file line number Diff line number Diff line change 8888 renderer = new THREE . WebGLRenderer ( { antialias : true } ) ;
8989 renderer . setPixelRatio ( window . devicePixelRatio ) ;
9090 renderer . setSize ( window . innerWidth , window . innerHeight ) ;
91+ renderer . outputEncoding = THREE . sRGBEncoding ;
9192 renderer . toneMapping = THREE . ACESFilmicToneMapping ;
9293 container . appendChild ( renderer . domElement ) ;
9394
You can’t perform that action at this time.
0 commit comments