-- Leo's gemini proxy
-- Connecting to git.thebackupbox.net:1965...
-- Connected
-- Sending request
-- Meta line: 20 text/gemini
repo: janusweb action: commit revision: path_from: revision_from: 26650a1ef714222d6260079f3c9730d4e0546a8b: path_to: revision_to:
commit 26650a1ef714222d6260079f3c9730d4e0546a8b Author: spyduck <flock.of.murkrows@gmail.com> Date: Thu Apr 12 15:29:29 2018 -0400 flip skybox 180 degrees to match native diff --git a/scripts/room.js b/scripts/room.js
--- a/scripts/room.js +++ b/scripts/room.js @@ -269,9 +269,22 @@ elation.require([ images[i].width = width; images[i].height = height; } + // flip skybox 180 degrees + if (images[i] instanceof HTMLCanvasElement) { + var ctx = images[i].getContext('2d'); + if (i == 2 || i == 3) { // Y+ or Y- + // Y+ + ctx.translate(images[i].width/2, images[i].height/2); + ctx.rotate(Math.PI); + ctx.translate(-images[i].width/2, -images[i].height/2); + } + ctx.drawImage(images[i],0,0,images[i].width,images[i].height); + } } } if (images[0] && images[1] && images[2] && images[3] && images[4] && images[5]) { + // flip skybox 180 degrees + images = [images[1],images[0],images[2],images[3],images[5],images[4]]; var texture = new THREE.CubeTexture( images ); texture.needsUpdate = true; this.skyboxtexture = texture;
-----END OF PAGE-----
-- Response ended
-- Page fetched on Sun Jun 2 16:46:29 2024