Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / HTML 5 - reduced FPS

Author
Message
haliop_New
User Banned
Posted: 22nd May 2016 07:14 Edited at: 22nd May 2016 07:19
hi.
why is that happening ?
are there ways to improve it ?
can I open a different APP stationary on the client side ?

basicly asking whats going on with the fps drop , is it as of this version or all html apps works slower?

maybe if I'd know what to tweak it will run better

can I open 2 different html 5 instances , one will gather from the other any information needed so pherhaps I wont have to overload one app by opening two , one will take care of all the hard calculations while the other just present them visual..

edit : ok I just saw RUNAPP() command which is actually what I wanted ... cheers.
would this work with HTML 5 if im on a windows machine ? as stated in the document ?
Could this be possible , cause with this routine I can max fps on html5 using it only to fetch data ?..

one can only dream, and do with AGK.
Paul Johnston
TGC Developer
21
Years of Service
User Offline
Joined: 16th Nov 2002
Location: United Kingdom
Posted: 22nd May 2016 21:50
It depends what you are doing.

Graphically it should be near the performance of the native device as WebGL is hardware accelerated. For logic we use asm.js which can achieve near native performance, or so I've heard. But if you're doing lots of memory manipulation, for example memblocks or large arrays, then I think it's not so good in that area.
mrradd
9
Years of Service
User Offline
Joined: 24th Feb 2015
Location: CA, USA
Posted: 25th May 2016 17:18
One thing I noticed is that if you go to maximum size the framerate was cut in half (from 60 to 30 in my case). I exited full screen, and the fps was still 30. I just took the resize option out of the html.
kaband
20
Years of Service
User Offline
Joined: 22nd May 2003
Location: Chicago
Posted: 25th May 2016 17:27
My game runs at 180 FPS (avg) on my windows machine with a fair amount of sprites. I get 20 FPS when running in HTML. I'm not doing any memblock stuff and don't think I really have large arrays. I'm going to try and narrow it down, but its definitely a large difference.
Digital Awakening
AGK Developer
21
Years of Service
User Offline
Joined: 27th Aug 2002
Location: Sweden
Posted: 26th May 2016 10:39
My game started to lag in full-screen too. And I got a decent gaming PC. It wasn't a lot, but it got noticeable micro freezes here and there.
Preben
AGK Studio Developer
19
Years of Service
User Offline
Joined: 30th Jun 2004
Location:
Posted: 26th May 2016 15:11
Paul: if SetVSync(1) is used in AppGameKit i think you need to call: emscripten_set_main_loop_timing(EM_TIMING_RAF,1)

http://kripken.github.io/emscripten-site/docs/api_reference/emscripten.h.html?highlight=vsync#c.emscripten_set_main_loop_timing

In my test it looks like it always use setTimeout.
best regards Preben Eriksen,

Login to post a reply

Server time is: 2024-04-18 16:06:35
Your offset time is: 2024-04-18 16:06:35