jquery - Chrome incredibly laggy, compared to Firefox and IE -


im developing web browser game , progressing seeing lot of fps drops during animations - draggable in chrome. getting worried ill have rewrite , becoming heavy, when ran app in firefox or ie11, runs smooth can, without noticable lags!

i cant believe chrome not handle type of rendering, possible turned in console makes chrome laggy hell? logging etc?

the app uses quiet lot of opacities, text , box shadows etc etc.

thanks

fox

-- profile update --

so happens

when user opens inventory

_theatre('sub', '.character-panel', 1); $('.character-panel').show() _loadinventory(); _loadplayerstats(); _loadequipment(); 

what believe problem _theatre() function. creates full page fixed div has 0.8 opacity.

function _theatre(t, e, a){  if(a == 1){      window.paused = 1;      $('html').css('overflow', 'hidden');      $(e).wrap('<div class="theatre-' + t + '"></div>');  } else{      window.paused = 0;      $('html').css('overflow', 'auto');      $(e).unwrap('<div class="theatre-' + t + '"></div>');  }  } 

if comment _theatre() function out, dragging noticably smoother.

i tried removing opacity div no better results. whats going on? :/

div.theatre-sub {top:0; left:0; right:0; bottom:0; position:fixed; z-index:9996; background-color:rgba(0,0,0,0.8)} div.theatre-dom {top:0; left:0; right:0; bottom:0; position:fixed; z-index:9998; background-color:rgba(0,0,0,0.8)} 

profiler data http://imageshack.com/a/img819/8601/jbf2.png

without knowing issue suggest start using console.profile() test performance of code. should pinpoint issue.

for example:

console.profile("profile one");  function yourcode() {    // code }  console.profileend("profile one"); 

enter image description here demo:

http://jsfiddle.net/nmbg4/5/

similar can use console.time() in same format track how long function taking in milliseconds.


Comments

Popular posts from this blog

android - Get AccessToken using signpost OAuth without opening a browser (Two legged Oauth) -

org.mockito.exceptions.misusing.InvalidUseOfMatchersException: mockito -

google shop client API returns 400 bad request error while adding an item -