cubing.js icon indicating copy to clipboard operation
cubing.js copied to clipboard

Various issues with 3D and resizing

Open rokicki opened this issue 6 years ago • 1 comments

In Chrome (and not Safari or Firefox) if you resize too small, you get an unending series of increase size events that cause the rendered puzzle to "drop" out of the window.

In Safari (and not Chrome or Firefox), setting the aspect ratio doesn't work (resizing causes the cube to change aspect ratio).

In all browsers, when hitting the "full size" twisty button in the lower left, all UI elements except the twisty display and its controls disappear (so the alg input and the buttons on the top all go away).

rokicki avatar Dec 07 '19 00:12 rokicki

The Safari aspect ratio problems are because we are using ResizeObserver and Safari doesn't implement this, so our resize code never gets called; instead our webgl is rendered to a canvas at the original size and scaled (ugly).

I have not yet figured out how to resolve the problem with Chrome looping when the canvas size gets too small.

rokicki avatar Dec 09 '19 22:12 rokicki