Resize the scale of scene

I have little issue with resizing of scene. When I am change the size of Chrome Browser, the scale of my window don’t change. When I refresh the page, the size of scene stay equal of my (See below).

I know that exist such function

  • window.addEventListener( ‘resize’, onWindowResize, false );
    , but my scene inside div, that include canvas:

I tried use the different variant of function that above:

  • canvas.addEventListener( ‘resize’, onWindowResize, false );

In my code canvas embed into with id=“Scene3D”.

Can you help me solve this problem?12

Do you mean that the size of the blue area in the middle does not scale when you resize the browser window? If so, i would say it’s maybe a CSS issue. Can you please provide a link to your application?

As an option, you can try to adapt the 4th example from here:

1 Like

So, I solve my problem by set new size of render each time in cycle of animate function. Maybe it awful decision , but worked!)