>From the emscripten-side you can call emscripten_set_canvas_size(new_width, 
new_height).

>From the HTML-side you should be able to resize the canvas 'as usual' (e.g. 
by setting the width and height properties), and get notified about any 
size changes on the emscripten-side by registering a callback function via 
emscripten_set_resize_callback() defined in emscripten/html5.h

Cheers,
-Floh.

Am Donnerstag, 5. November 2015 07:58:06 UTC+1 schrieb ZengRui Wang:
>
> Hi
> Is there any way to resize the canvas at runtime in Javascript? Current I 
> use EGL to create the rendering surface and hard code the width and height, 
> can I resize it after the intialization?
>
> Thanks!
>

-- 
You received this message because you are subscribed to the Google Groups 
"emscripten-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to