RPG Maker MV Debugging

editor lag and music delay after using the new patch

Greport.rar
Thank you!
Continued from last page:

Kane Hart (i4770k, Geforce GTX 780 ti, Win 10 x64):

Geforce 355.80 driver. Your computer is nearly identical to mine(i7-4770, 760, win 10, 32gb ram), so I'm thinking it might be a difference in GPU settings set by Geforce Experience, as everything on mine is running stock. I'm using the latest driver is 358.50 which was updated to support OpenGL ES 3.2, so unless that changed OpenGL ES substantially, this seems odd how you with a better video card are experiencing a lag that I'm not with the slower card.

I have FXAA turned off globally which is the default. Turning it on seems to increase the initial paint lag time (from initial click to drag), but I'm going to say this is probably input latency as there is always going to be such a thing when the GPU is used and is up to Chromium developers to resolve it.

JAD94:

Intel Pentium T4300 with ICH-9 onboard video, manufactured in 2009. Installed drivers are 2009, latest drivers are 2014, however like Grimoire LD on the previous page, these old graphics drivers don't have hardware vertex shaders, so they will perform poorly.

kaine:

Intel® Core2 CPU T5200, same as JAD95 and Grimoire LD. Onboard Graphics chip from 2009, stock graphics drivers.

There are no Intel-provided drivers for Windows 10 for the 945/Series 4 onboard graphics. 
http://file:///C:/Users/murilo/Documents/MURILO-PC.html

Editor lag,and animations in battle too.
Issue type: Audio Crash

Description: Some weird MV-related process crashed in editor only with no lags what-so-ever. And only occurs when testing BGMs in the editor at random. (Already reported in PMs)

Specs are attached with this post.
Issue type: Audio Crash

Description: Some weird MV-related process crashed in editor only with no lags what-so-ever. And only occurs when testing BGMs in the editor at random. (Already reported in PMs)

Specs are attached with this post.
you seem too to have this weird bug?
you seem too to have this weird bug?
The weird thing is in my laptop, everything seems smooth. (Or perhaps I hadn't spent enough time on there to have issues.) But on my desktop pc it's so random. (Irony: Both uses the same exact OS and my laptop's specs are much weaker than my desktop's. (Well my desktop's more cluttered but still runs smooth! 😛 ) )

And I'm glad I'm not the only one with the issue. It was annoying when I tried to test bgms. If it continues on, I'll have to test bgms in an external media player then blindly select BGMs until a solution is found hopefully. Hassle but last resort since it's been crashing several times a day and mostly when I switch BGMs too quickly and/or play too many BGMs at once.
Hello this link won't work since it's in your local pc
I was experiencing some play test lag until I found out it's a resolution issue for me mainly. I'm running the trial version so I'm unable to update the program at the moment so I still do get some lag when the map is flooded with water however if I run the Playtest on my main monitor (Which is my TV) with a resolution of 1768x992 My game will range from 20-30 FPS but if I move my Playtest screen to my secondary monitor with a resolution of 1440x900 my FPS jumps up to 60 which is exactly where it should be. So part of my lag appears to be version related but the main cause is simply screen size/resolutions not being fully supported at the moment. So for those of you only experiencing Playtest Lag, that could be your problem there. Hope this helps!
Not sure why I can't share this image here, but the link:

http://imgur.com/Q9MhHvx

I seem to be eternally bottlecapped at 29 FPS and I can't for the life of me figure out how to chage that, or fix it. I can't imagine it's a hardware issue, but I'll post more details if need be. Both playtesting methods ( battle tests, and the actual game ) lag terribly, but the framerate doesn't seem to reflect that, it's pretty smooth about staying at 29, almost unflinchingly. I've been scouring to find suggestions/tips, and have followed the guide provided tweaks a few times over in fact, as well as resolution changes, etc. This one has me stumped - if you guys can lend a hand, I'd appreciate it!
Not sure why I can't share this image here, but the link:

http://imgur.com/Q9MhHvx

I seem to be eternally bottlecapped at 29 FPS and I can't for the life of me figure out how to chage that, or fix it. I can't imagine it's a hardware issue, but I'll post more details if need be. Both playtesting methods ( battle tests, and the actual game ) lag terribly, but the framerate doesn't seem to reflect that, it's pretty smooth about staying at 29, almost unflinchingly. I've been scouring to find suggestions/tips, and have followed the guide provided tweaks a few times over in fact, as well as resolution changes, etc. This one has me stumped - if you guys can lend a hand, I'd appreciate it!
Do you have a screen larger than 1920x1200 connected via HDMI? For example 4K screens don't operate at 60fps if connected via HDMI but do if connected via Displayport.
I do in fact have every of that going on.. >_> ; I'll try making some changes and get back to you if it works out with my actual monitor with display port.

EDIT: To confirm, Kisai was correct, and this advice has helped me to resolve the issue. Now running at 60 FPS and everything looks so smooth. Time to create, I hope this helps out someone else who might be having the same issue!~ <3
The weird thing is in my laptop, everything seems smooth. (Or perhaps I hadn't spent enough time on there to have issues.) But on my desktop pc it's so random. (Irony: Both uses the same exact OS and my laptop's specs are much weaker than my desktop's. (Well my desktop's more cluttered but still runs smooth! 😛 ) )

And I'm glad I'm not the only one with the issue. It was annoying when I tried to test bgms. If it continues on, I'll have to test bgms in an external media player then blindly select BGMs until a solution is found hopefully. Hassle but last resort since it's been crashing several times a day and mostly when I switch BGMs too quickly and/or play too many BGMs at once.
Actually I was expecting some weird bug too but for that ask a sound driver update and it's will fix the delay and also remove the double song in your folder it's make the system slow down :/

ALSO 

I had audio issue but after my computer done a general update (who mean's update all the component) my engine don't crash sound anymore and don't lag while getting text

so for people I might suggest for your debugging to checkup a update for your system and make sure to update your drivers so it's make the system work smoother
I'd like to say that other than these 2 issues, both my editor and game run flawlessly at 60 FPS.

1st Issue) Whenever starting a test play there is a 2 second lag spike after about 3 seconds of game-play in the menu.

(this lag also occurs if I test a battle through the editor) (This issue has been resolved as of about 2 weeks ago)

2nd Issue) Whenever I load into the title screen or a map, the audio (BGM, ME, SFX) don't start working until about 3-5 seconds pass.

These problem occur every single time, even if I export the game and play it "officially".

First.html
I think I'm on to something...

If you have Chrome, as in the web browser, type "chrome://GPU"

If you look in Chrome (the browser) you'll see this:

Problems Detected
Always call glUseProgram after a successful link to avoid a driver bug: 349137
Applied Workarounds: use_current_program_after_successful_link
Some drivers are unable to reset the D3D device in the GPU process sandbox
Applied Workarounds: exit_on_context_lost
TexSubImage is faster for full uploads on ANGLE
Applied Workarounds: texsubimage_faster_than_teximage
Clear uniforms before first program use on all platforms: 124764, 349137
Applied Workarounds: clear_uniforms_before_first_program_use
Always rewrite vec/mat constructors to be consistent: 398694
Applied Workarounds: scalarize_vec_and_mat_constructor_args
NVIDIA drivers before 337 lack features in NV_path_rendering and related extensions to implement driver level path rendering.: 344330
Applied Workarounds: disable_gl_path_rendering
Accelerated rasterization has been disabled, either via about:flags or command line.
Disabled Features: rasterization
Right, so that means by default if you have an nVidia card, Chrome isn't using the most efficient path anyway. You can still force it on. ( chrome://flags/#enable-gpu-rasterization )

BUT what about node-webkit which is what game.exe is?

Load up the toolbar:

You will get something like this:
 

You can also access this on game.exe, if you edit packagejson and turn on the toolbar.Problems Detected
GPU rasterization is blacklisted on non-Android: 362779
Disabled Features: gpu_rasterization

So that means game.exe ALSO isn't using the GPU right?

Go back to Chrome again and look at the top:

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
Rasterization: Software only. Hardware acceleration disabled
Video Decode: Hardware accelerated
Video Encode: Hardware accelerated
WebGL: Hardware accelerated
Right.... now game.exe:

Canvas: Hardware accelerated
Flash: Hardware accelerated
Flash Stage3D: Hardware accelerated
Flash Stage3D Baseline profile: Hardware accelerated
Compositing: Hardware accelerated
Multiple Raster Threads: Enabled
Rasterization: Software only, hardware acceleration unavailable
Threaded Rasterization: Enabled
Video Decode: Hardware accelerated
Video Encode: Hardware accelerated
WebGL: Hardware accelerated
*sad trombone

So you might be wondering what this means. It means that the hardware acceleration is likely not working anyway. I'm not talking about WebGL falling back to Canvas2D, but rather that no hardware rasterization support except in bleeding-edge versions. This actually shouldn't be impacting WebGL itself, rather it's likely impacting the process of loading bitmaps and the layering of the two canvas layers in the HTML part. Most people shouldn't be experiencing slowdowns.

However if you edit package.json

{ "name": "KADOKAWA/RPGMV", "main": "www/index.html", "js-flags": "--expose-gc", "chromium-args" : "--enable-gpu-rasterization", "window": { "title": "", "width": 816, "height": 624, "icon": "www/icon/icon.png" }}That should force GPU-rasterization, but that doesn't promise it won't crash.
Wow.........OK I'll have it tested out!
I'm not sure if this is the right place for it, but I just noticed a quirk with the editor... If you alter a tileset and hit cancel and you are on the map that uses that tileset, it will visibly apply those changes. If you load the database and hit cancel (and probably OK), it reverts it to what you had because you canceled and didn't actually change the tileset, even though the visual changes happened.

Replication steps:

  1. Choose a map in a project and note the tileset that it uses.
  2. Open the Database and go to Tilesets.
  3. Choose the noted tileset and change a tileset image that will have obvious visual changes on the map. I used A2.
  4. Click the Cancel button on the Database window.
  5. At this point the map should change to display the new tileset, despite hitting Cancel.
  6. Open the Database again and immediately hit Cancel.
  7. At this point, the tileset should revert to what was previously set.
Obviously, this is not a world-ending bug, but certainly unexpected behaviour.
Problem: Framerate affects game speed directly. If playing on a higher refresh monitor (ie. 144hz) the game runs at 144fps and all movement and animations are over double normal speed (60fps). Example video.

Hardware report: https://dl.dropboxusercontent.com/u/73268/HEIMDALL.html

Monitor additional info: Asus VG248QE set to 144hz refresh rate using DVI.

I'll just double report this here so you have all my specs too. My problem is that MV games are running at a max frame rate equal to the refresh rate of the screen, which is ok in and of itself, but not when game logic (ie. amount of pixels the character should move over a given time and the speed of animations) is also tied intrinsically to the frame rate. In this example video, I'm playing a completely new project on my monitor that is set to 144hz refresh rate, making all movement and animations in the game over twice as fast as normal.

If anyone gets below 60fps, game speed would equally be below 100% game speed. At 30fps, everything would move at 50% normal speed.
Problem: Framerate affects game speed directly. If playing on a higher refresh monitor (ie. 144hz) the game runs at 144fps and all movement and animations are over double normal speed (60fps). Example video.

Hardware report: https://dl.dropboxusercontent.com/u/73268/HEIMDALL.html

Monitor additional info: Asus VG248QE set to 144hz refresh rate using DVI.

I'll just double report this here so you have all my specs too. My problem is that MV games are running at a max frame rate equal to the refresh rate of the screen, which is ok in and of itself, but not when game logic (ie. amount of pixels the character should move over a given time and the speed of animations) is also tied intrinsically to the frame rate. In this example video, I'm playing a completely new project on my monitor that is set to 144hz refresh rate, making all movement and animations in the game over twice as fast as normal.

If anyone gets below 60fps, game speed would equally be below 100% game speed. At 30fps, everything would move at 50% normal speed.
This sounds like the answer for "why does the sound lag, why is the framerate awful" too. This tells me that there needs to be an implicit framerate setting.

SceneManager.requestUpdate = function() { if (!this._stopped) { requestAnimationFrame(this.update.bind(this)); }};Notice there is no frame setting control here.

SceneManager.updateMain = function() { this.changeScene(); this.updateScene(); this.renderScene(); this.requestUpdate();};Nor here.

SceneManager.run = function(sceneClass) { try { this.initialize(); this.goto(sceneClass); this.requestUpdate(); } catch (e) { this.catchException(e); }};Nor here either.

So pretty much something like this is needed:

var fps = 60; function animate() { setTimeout(function() { requestAnimFrame(animate); // Draw stuff }, 1000 / fps); }There's a post out there that shows an improvement on this as well:

http://codetheory.in/controlling-the-frame-rate-with-requestanimationframe/
@KisaiTenshi: This would solve it for refresh rates > 60 and hardware that can push above 60fps, but it won't solve the problem of someone running the game on a 50hz monitor who'd be restricted to 50fps, which would in turn cause all gameplay to occur at 83% of normal speed. The only proper solution is to disentangle rendering frame updates from game logic, where game logic is telling a sprite where it should be, and the rendering is displaying it. Optimally I'd use a proper timestep setup (note that the example is talking about physics, but really, any movement benefits from this). This way even if someone's unlucky and run the game at 30fps, game speed will still be close to 100%, it'll just be less smooth visually.

Original thread: https://forums.rpgmakerweb.com/threads/rpg-maker-mv-debugging.47503/