HTML5/JS drops FPS on maximized window?

Started by
6 comments, last by Ectara 11 years, 2 months ago

I'm playing with HTML5/JavaScript using canvas, I've noticed a huge drops on FPS whenever the browser windows get maximized. Initially I thought it was on the specific browser I'm using, but I test all the browser IE,FF,OP,CH all drops the frames per seconds when maximized at least 50% or more. Any hint why is this the case? thanks.

Advertisement

I know that it may come off as an insult, and I don't intend it to be that way, but is the drawing area scaled in any way based on the browser window's size? If so, then the rendering simply requires more work to draw whatever is being displayed.

Hi Ectara, thanks for the fast reply ^_^y. I'm playing with HTML5 using Canvas with "fixed" 800 x 600 window size.

Try posting a link so we can see what is happening, Ectara's answer is the best we can do without more information.

Dan Mayor

Professional Programmer & Hobbyist Game Developer

Seeking team for indie development opportunities, see my classifieds post

Hello Dan,

My canvas size is fixed to 800x600 window size, I already tried changing the margin from left or right and my default setting is always on the middle.

It has no problem when the browser window is in normal, resize or even in full screen mode. The frame only drops when the window size of the browser resized by clicking the maximized control box button.

Currently I dont have a working site sample over the internet, I have this video feeds on youtube that shows whats happening.

">


Hm... Does the same effect happen in you manually resize the window by clicking and dragging on the border to most of the display's viewport?

No sir T.T resizing the window thru dragging up to the edge of the screen does not drops the FPS, it only happens when clicking the maximize button of most popular browser I've tested.

Have you checked if your memory consumption increases drastically with the resized window? It shouldn't by too much, but if the fixed size viewport is achieved by getting the window's dimensions, and then drawing a black background around it, that can affect performance.

This topic is closed to new replies.

Advertisement