Will I gain boost in performance if I stretch canvas in javascript? And is video rendering slower inside canvas? -


let's assume run html5 game on 1920x1080 display.

if set canvas half of 960x540, , stretch width , height of 100% via css, run fullscreen, game run faster?

do effect changing actual resolution of display?

(for don't know, css stretches canvas, not set actual width , height of canvas)

and 1 more question, video rendering inside canvas slower normal video rendering?

if set canvas half of 960x540, , stretch width , height of 100% via css, run fullscreen, game run faster?

with size of 1920*1080 pixels won't difference because context image data natively bigger, containing a lot of rgba colors. it'd more faster represent graphics, it'd (more or less) slow proccess graphics yet (or fast, depends on user computer).

do effect changing actual resolution of display?

this depend on user computer... short answer, no.

and 1 more question, video rendering inside canvas slower normal video rendering?

yes... web video player faster it's native , contain less information image data (colors format rgb), etc.


Comments