stachir's Recent Forum Activity

  • Ashely

    Thank you for answer.

    After investigation, and checking many things I realised platform behavior is not the main cause of my problem and there are many components and factors that can affect on all development process. Certainly, I make many mistakes during game/project assembling.

    You said "it's just reporting the way things have always been". Ok I can understand that, and just want to focus attention on this issue. Maybe it's time to get into it and rewrite legacy code.

    Also, I would like to thank everyone who took part in the discussion.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • 99Instances2Go

    With all tests I got "SYNC FAILURE: Imperfect sync. Try closing all apps and browser tabs. " - with one tab opened on clean Chrome v50.

    Now, after that long conversation (thank you everyone), I know that VSync can be serious problem- some people have it (or something similar), some don't (or don't know about it yet), some people pay attention to it (because of personal perseption), and some don't (they do not see this as an error, or do not see at all). It's not easy to find main reason of that problem, and it's hard to prove. But first of all - it's sad, that vsync-problem exist.. at all.

    I tried to make test on some other machines I had access to. All with different software and hardware configuration- all of them had some vsync issues. Also I read about some bizarre tricks to make browser work a little differently.. yea, but what for - average player know nothing about vsync types, chrome flags and others.

    I am quite abashed - Now I know my current situation is the result of vsync-related-problem, but also I still cannot understand part of platform behavior code in all of it, there is collision detection load part of course, however those frame drops are disproportionately larg, so maybe there is something more,waiting to be discovered...

    R0J0hound

    Do anyone experiance something similar? What can I do to make my games more accessible on web browser? What tools should I use to execute optimalization tests on device with vsync problem? How to messure game performance in such situation? How can I know if bad performance is my fault, or runtime environment?

    ( Maybe I should change topic title to make it more accessible for others ? )

  • 99Instances2Go

    For me it looks like this:

    Graphics Feature Status

    Canvas: Hardware accelerated

    Flash: Hardware accelerated

    Flash Stage3D: Hardware accelerated

    Flash Stage3D Baseline profile: Hardware accelerated

    Compositing: Hardware accelerated

    Multiple Raster Threads: Enabled

    Native GpuMemoryBuffers: Software only. Hardware acceleration disabled

    Rasterization: Software only. Hardware acceleration disabled

    Video Decode: Hardware accelerated

    Video Encode: Hardware accelerated

    WebGL: Hardware accelerated

  • R0J0hound

    Yes, I noticed some flickering.

    According to the preformance graph in test of vsync of my browser, my average inter-frame millisecond time is 17.056. Every second moving picture stops and there is heap on chart out of scale.

    I read the article about the VSYNC synchronization test, and the "bug" in chrome 38+ ... it's really frightening.

    "Under Windows, Chrome 38+, Firefox 32+, and Internet Explorer DO NOT properly synchronize rendered frames to a display's VSYNC refresh signal".

    Honestly, I did not expect that something like this could have happen. How is it possible?

    Also, it looks like it is insoluble problem. Please, tell me I'm wrong.

  • Colludium

    I wrote that my laptop is rendering using webgl, so my graphic card is supported

    I always make tests on vanilla Chrome, with no plugins and one tab, with no other program like Unity or Blender running. This time I close antivir, and nothing happen. Same scenerio on second machine with different graphics, cpu.

    Link to capx file is in first post in topic.

    I checked timeline, and only thing I saw was "long frames" every 1-2 seconds, so there is some jank [#sherlock].

    [update]

    I also tried old fashion restart and check(http://gamedev.stackexchange.com/questi ... -4-seconds), and it did nothing much- drops happen less, but objects are still stuttering

  • Colludium - it's webgl

    I also checked template projects (like platformer temlate), and there I also noticed frame drops. Also I found that, every 1-3 seconds, there is something like 'freezing' - objects that moving stops for a microsecond and appear/'jump' in next frame in another place. I start to believe that something can be wrong with my computer, so I checked on other machine, and there is the same situation.

  • With platform disabled: collision checks per sec = 0 (of course)

    With platform enabled and player does not move: collision checks per sec = 100-110 (sure)

    With platform enabled and player moves: collision checks per sec = 400-500 (yea, why not)

    R0J0hound

    Ok, I get that all things metter- layers, number of objects and instances, effects and so on, I understand that. And maybe that is not direct impact of C2. I just would like to know, why my laptop makes frame drops running project with one layer, four objects and no effects.

    With that simple project I got 60fps with disabled and 55fps with enabled platform bahavior and player stand still. Nothing much? Really? It's so simple, that such situation should hove no place at all.

  • Yes, cpu usage increasing when the platform behavior is enabled is truly expected and undeniably. My point is close to DatapawWolf opinion- what about idle? In my opinion, this situation is more about this behavior runtime file, but for now I couldn't find any other reason, so that is my only clue. I already tried to disable different configuration of modules in my final project, and after many includes enabled and disabled, I have found that something is wrong with this particular behavior.

    I tried to compare exported c2runtime.js files from R192 and R228 - differences are big from end of 2014 and now. Thanks to WinMerge program, I found difference with old and new platform code, but it is not very spectacular- current version include this code inside of cr.behaviors.Platform function:

    behinstProto.onWindowBlur = function ()

    {

    this.leftkey = false;

    this.rightkey = false;

    this.jumpkey = false;

    };

    With my luck, it's probably not related to the problem..

  • Colludium Probably those things (usage caused by engine and drawcalls) are related some way. Frame drops are not so dramatic in example above, but in final project, where platform behavior in use with many objects, this problem is kind of "deal braker".

    In my case, according to the profiler, in this example I get:

    With platform Disabled:

    • Engine 0.9%
    • Draw 0.2%

    With platform Enabled:

    • Engine 2.3%
    • Draw 4.1% ( also 20x )

    First I thought it could be my PC fault. I made some tests on other machines with different configurations- example was reproduced.

    After short investigation, I discovered that platform behavior file is in bad condition- many comments and some unnecessary code- maybe there's problem.

    I tried to get some info about this:

    with no effect.

  • Problem Description

    No metter how few instances and objects are on scene, if there is at least one with active platform behavior, engine makes so many drawcalls, that force CPU to drop some FPS'es

    Attach a Capx

    https://drive.google.com/file/d/0B57pu5 ... ZqY2s/view

    Description of Capx

    .capx has as few as possible objects, and only thing you should do is to switch on and off platform behavior and look at the profiler to see what is going on.

    Steps to Reproduce Bug

    • Run project with debug mode and switch view to profiler
    • With spacebar You can disable and enable platform behavior of pink block

    Observed Result

    In my case, switching pink block's platform behavior on makes much more drawcalls - and it's a small project. In my final game, drawcalls cause like my CPU run at 75%, where drawcalls are +50%

    Expected Result

    no such FPS drops

    Affected Browsers

    • Chrome: (YES)
    • FireFox: (YES)
    • Internet Explorer: (YES)

    Operating System and Service Pack

    • Windows 8.1
    • Windows 10

    Construct 2 Version ID

    R228

  • hi , i have poblems with the draw calls percent in debug , is about 97% , this happend only when i add the character to the layout , the character have 11 frame without loop and pinpong S:, but if i delete the character the layout is about 60 and not 5 like whne i put the character.

    dokannon - I have something similar to Your scenario, but additionally - it's not caused just by animation, but platform behavior instead.

    I was trying to check runtime.js file in platform behavior folder and I didn't find anything strange (except some commented/legacy code about checking overlapping jumpthru? - Ashley -platform/runtime.js, line 655, c2 R227). I guess these objects with enabled platform behaviors make draw call request every tick with somekind of sub-pixel pressision... Is it a bug or maybe I do something wrong? I could switch enable/disable platform behavior for player by checking pressing nad releasing keys/buttons, but maybe it's overthinking?

  • Engine time includes "ticking" objects, such as stepping sprite animations, moving any objects with movements, other behavior tasks e.g. searching for targets with the Turret behavior, and anything else that needs tick-by-tick attention by the engine that is not covered by events.

    Ashley - Is there any way to check exactly what kind of operations / which operations in "Engine time" category affect the CPU usage?

stachir's avatar

stachir

Member since 21 Aug, 2012

None one is following stachir yet!

Connect with stachir

Trophy Case

  • 12-Year Club
  • Popular Game One of your games has over 1,000 players
  • RTFM Read the fabulous manual
  • Email Verified

Progress

15/44
How to earn trophies