View Full Version : FGU Freezes Briefly Every 10 Seconds
rocketvaultgames
January 16th, 2024, 17:54
With no extensions loaded (D&D 5E) on a high-end machine, I'm experiencing FGU freezing for about 1/4 - 1/2 second or so every 10 seconds on the nose.
This momentary hitch looks terrible with any FX on a map. Additionally it is brutal when drawing in LOS, or just attempting to click on anything and having the click register where the cursor is after it unfreezes, or having the game not recognize that I'm holding down shift/control/alt.
Is there anything that can be done about this?
Thanks much for all you do!
Nylanfs
January 16th, 2024, 18:28
Do you happen to have the Steam Overlay on at the same time, if installed from Steam of course.
rocketvaultgames
January 16th, 2024, 19:09
Not installed from Steam. I double checked and Steam is not open, either. Or at least not showing in the tray, or in processes seen in Task Manager (Windows 11).
I just checked the same campaign on a less powerful (but still beefy) laptop and the same thing is happening but every 20 seconds on the nose instead of 10 seconds (Windows 10).
Zacchaeus
January 16th, 2024, 19:09
Another possibility is that you have a controller attached to your computer maybe.
rocketvaultgames
January 16th, 2024, 20:22
I do have a USB NES controller on the desktop but nothing on the laptop. Is that what you mean? I can try unplugging that tonight.
Elvedui
January 16th, 2024, 21:01
I have had the same issue for a long time. I have the latest computer with a 4090 and 64GB Ram and 4 SSD drives, etc...but at times when you open something it freezes.
Zacchaeus
January 16th, 2024, 21:33
I do have a USB NES controller on the desktop but nothing on the laptop. Is that what you mean? I can try unplugging that tonight.
Yes. Wild guess, like. Sounds like something that requires a lot of CPU or GPU time is taking focus away from FG. Could be something that causes a loop whilst it searches for something and then releases everything back to FG once it doesn't find it. Might be some kind of background process.
Laerun
January 16th, 2024, 22:15
With no extensions loaded (D&D 5E) on a high-end machine, I'm experiencing FGU freezing for about 1/4 - 1/2 second or so every 10 seconds on the nose.
This momentary hitch looks terrible with any FX on a map. Additionally, it is brutal when drawing in LOS, or just attempting to click on anything and having the click register where the cursor is after it unfreezes, or having the game not recognize that I'm holding down shift/control/alt.
Is there anything that can be done about this?
Thanks much for all you do!
Try to Limit your FPS on your computer and the app, there is a discussion that might be related to this issue.
https://fantasygroundsunity.atlassian.net/wiki/spaces/FGCP/pages/1638006786/Reducing+GPU+Usage
https://www.fantasygrounds.com/forums/showthread.php?79908-High-GPU-usage-issues-with-Unity-Games-(includes-Fantasy-Grounds)
Best of luck,
Laerun
Moon Wizard
January 17th, 2024, 01:44
Also, we've seen some performance issues with specific graphics configurations when using mask blur on FX layers. Not sure if that is relevant to this situation, but you can try turning off FX mask blurring if you have it on.
Regards,
JPG
pindercarl
January 17th, 2024, 01:52
With no extensions loaded (D&D 5E) on a high-end machine, I'm experiencing FGU freezing for about 1/4 - 1/2 second or so every 10 seconds on the nose.
This momentary hitch looks terrible with any FX on a map. Additionally it is brutal when drawing in LOS, or just attempting to click on anything and having the click register where the cursor is after it unfreezes, or having the game not recognize that I'm holding down shift/control/alt.
Is there anything that can be done about this?
Thanks much for all you do!
Regular, periodic freezes could be garbage collection. I'm not aware of any internal routines that are run every 10 seconds. Especially with the different interval testing on another computer tells us that it isn't driven by the system clock. Can you provide a copy of the campaign?
rocketvaultgames
January 17th, 2024, 04:45
I ran a session from the laptop today... (same campaign) RTX 2060 - when I started (with extensions) I was getting the same stutter every 20 seconds. I checked again at the end of the session, 5 hours or so later and it was doing it every 30 seconds.
Loaded back up on main machine RTX 4070 TI (same campaign)(with extensions) and same stutter every 11.8 seconds.
No blur on FX. Latest NVIDIA drivers. G-Sync Off. Application decides settings.
Unplugged NES controller, turned off Backblaze... no difference.
Tried messing with vsync and imagequality settings with no difference.
There is a drop in 3D on the card every time it stutters.
https://imgur.com/BHrtSyG
Restarted with no extensions and the problem seemed to disappear if I wouldn't do anything to the map (just watch it for stutters). If I scrolled around at all, I'd get a stutter once sometime in the next 5 seconds or so.
This is way better, and now I wonder what it could be, as I definitely was having the issue earlier today with ZERO extensions loaded - it was happening every 10 seconds exactly.
I'll see if I can narrow down an extension when I have time, likely tomorrow.
I am curious if you guys can reproduce this though as ELVEDUI mentions a similar problem above.
https://www.dropbox.com/s/qof9xrqmrx0g0bt/Forgotten%20Realms%202020.zip?dl=0
Sincere thanks for your time.
Laerun
January 17th, 2024, 14:00
I ran a session from the laptop today... (same campaign) RTX 2060 - when I started (with extensions) I was getting the same stutter every 20 seconds. I checked again at the end of the session, 5 hours or so later and it was doing it every 30 seconds.
Loaded back up on main machine RTX 4070 TI (same campaign)(with extensions) and same stutter every 11.8 seconds.
No blur on FX. Latest NVIDIA drivers. G-Sync Off. Application decides settings.
Unplugged NES controller, turned off Backblaze... no difference.
Tried messing with vsync and imagequality settings with no difference.
There is a drop in 3D on the card every time it stutters.
https://imgur.com/BHrtSyG
Restarted with no extensions and the problem seemed to disappear if I wouldn't do anything to the map (just watch it for stutters). If I scrolled around at all, I'd get a stutter once sometime in the next 5 seconds or so.
This is way better, and now I wonder what it could be, as I definitely was having the issue earlier today with ZERO extensions loaded - it was happening every 10 seconds exactly.
I'll see if I can narrow down an extension when I have time, likely tomorrow.
I am curious if you guys can reproduce this though as ELVEDUI mentions a similar problem above.
https://www.dropbox.com/s/qof9xrqmrx0g0bt/Forgotten%20Realms%202020.zip?dl=0
Sincere thanks for your time.
Is this your entire campaign folder? It's five GB+. Do you have a ton of maps, tokens, and assets in this folder? Having huge swaths of assets can create issues. Try to clean this up and run without tons of third-party content, see if that helps any. This is a rather huge image library. I have never had more than a GB or less in one campaign folder and my FG Data folder is rather excessive. Try to place most of those assets in a different archive and just grab the art you need. Likely that almost any computer would be trying to chug along and index ALL of these files and images, and after 4.7 GB, things get weird, even though we might have a 64 bit OS.
Suggestions, is possible:
1.) Optimize the images for FG. Convert to .webp format for images that are not attached to any campaign sessions.
2.) Be careful moving and renaming files, especially if they are attached to your gaming sessions.
3.) Sort the images into subfolders for easier indexing in the assets window.
4.) Try to use only what you need. Over time (2020?) this type of thing can get out of hand and become harder to manage.
I have been through this before myself. Windows 10 was horrible at indexing large folders of data too, adding to my situation.
@moderator, please delete the attached file as it contains 5+GB of personal copies of this user's library and artwork after you assess this.
Trenloe
January 17th, 2024, 14:07
I am curious if you guys can reproduce this though as ELVEDUI mentions a similar problem above.
Based of their comment, I think this is a different situation:
I have had the same issue for a long time. I have the latest computer with a 4090 and 64GB Ram and 4 SSD drives, etc...but at times when you open something it freezes.
They don't mention regular stuttering, they mention freezes when opening something - I'm guessing a module, or could be a data record with a lot of GUI controls (e.g. a PC with spells).
When you open a module, FG has to parse out the XML data and load it into the various data lists - which may also trigger additional code. If you open a large data module you will absolutely see freezes - this is expected while FG does a lot of intense processing.
Also, when you open a record with lots of GUI controls, FG (and the underlying Unity engine) need to build the GUI - for complex records (e.g. the spell list for a spellcaster) this can take a few seconds, and FG won't respond during that time.
rocketvaultgames
January 17th, 2024, 14:38
Is there maximum campaign folder size that should be observed?
You are correct, I misread Elvedui's message.
I do see those same delays in those exact instances. The stutter is completely different.
Side question related to the freezing when opening a large module, PC action tab with a lot of spells, or even a large map... is there any way to have a specified group of these built when FGU is launched?
For example, every session I eventually open a large world map that takes 3-4 seconds to open. Once I've done that, I can open and close it instantly. It would be great to have that loaded in memory when FGU launches for a number of things.
Trenloe
January 17th, 2024, 14:50
Is there maximum campaign folder size that should be observed?
There's not anything documented that I'm aware of. But campaign db.xml files that are 20MB+ are quite large - I'd be concerned if there's something a lot larger than that.
Side question related to the freezing when opening a large module, PC action tab with a lot of spells, or even a large map... is there any way to have a specified group of these built when FGU is launched?
For example, every session I eventually open a large world map that takes 3-4 seconds to open. Once I've done that, I can open and close it instantly. It would be great to have that loaded in memory when FGU launches for a number of things.
There's not a way to do that automatically - all you can do is open those windows, which performs all the database and GUI loading, with associated coding. Once loaded they are cached for the session - although I seem to remember from discussions a while ago that image data may be reset after some time period of the image not being open.
pindercarl
January 17th, 2024, 14:51
Thanks for providing the campaign. I was not able to reproduce the error as you described. You noted that the GPU drops whenever there is a stutter. This tells me that the CPU is stalling, not the GPU. When the main thread is locked, the GPU is performing very few tasks.
Looking at your campaign I can offer some advice. You have 210 tokens in the Combat Tracker and 95 modules loaded. Try removing inactive tokens from the Combat Tracker and unload any modules that you are not using.
I ran a session from the laptop today... (same campaign) RTX 2060 - when I started (with extensions) I was getting the same stutter every 20 seconds. I checked again at the end of the session, 5 hours or so later and it was doing it every 30 seconds.
Loaded back up on main machine RTX 4070 TI (same campaign)(with extensions) and same stutter every 11.8 seconds.
No blur on FX. Latest NVIDIA drivers. G-Sync Off. Application decides settings.
Unplugged NES controller, turned off Backblaze... no difference.
Tried messing with vsync and imagequality settings with no difference.
There is a drop in 3D on the card every time it stutters.
https://imgur.com/BHrtSyG
Restarted with no extensions and the problem seemed to disappear if I wouldn't do anything to the map (just watch it for stutters). If I scrolled around at all, I'd get a stutter once sometime in the next 5 seconds or so.
This is way better, and now I wonder what it could be, as I definitely was having the issue earlier today with ZERO extensions loaded - it was happening every 10 seconds exactly.
I'll see if I can narrow down an extension when I have time, likely tomorrow.
I am curious if you guys can reproduce this though as ELVEDUI mentions a similar problem above.
https://www.dropbox.com/s/qof9xrqmrx0g0bt/Forgotten%20Realms%202020.zip?dl=0
Sincere thanks for your time.
rocketvaultgames
January 17th, 2024, 15:05
Trenloe:
You are correct, they are un cached after some amount of time... I'm not sure how long but I'd be interested to know... and to have the option to turn that off. I frequently have half of my 64GB of RAM sitting unused and I'd LOVE to fill it up upfront rather than wait the few seconds to load things during a live session.
Pindercarl:
Thanks. It is helpful to know that the CPU (i7-13700KF) is the likely culprit. Maybe a single core is hitting 100% but I'm only seeing the aggregate usage of all 16 cores...
I'll tinker around some more, but honestly I'd rather deal with the stutter than loading/unloading modules and CT actors.
Thank you to everyone for taking the time to answer my questions.
Trenloe
January 17th, 2024, 15:11
Maybe a single core is hitting 100% but I'm only seeing the aggregate usage of all 16 cores...
To see utilization of individual processors, right-click on the CPU graph in task manager and select: Change graph to -> Logical processors.
Trenloe
January 17th, 2024, 15:12
https://www.dropbox.com/s/qof9xrqmrx0g0bt/Forgotten%20Realms%202020.zip?dl=0
Thanks for uploading the campaign. Is there a specific image that usually displays the stuttering issue?
rocketvaultgames
January 17th, 2024, 15:19
Thanks... I was going to Resource Monitor... this is a much better view!
I was testing it with "Map - Yartar Foothills", but I've noticed it on any map with FX. It seems to happen even without FX, it's just not visually noticeable, until the stutter happens and you click on something that wasn't intended (like the unlocked CT and drag it across the screen..., or toggle LOS and show everyone the whole map!)
pindercarl
January 17th, 2024, 15:33
The images are polled every 5 minutes and removed if they are unused for 10 minutes or longer. Images in FGU are not stored in RAM but are loaded to the GPU. There is a performance cost to move images from main memory to the GPU and it can only be performed on the main thread. So, when an image is first loaded from disk it is compressed and sent to the GPU. It is then cleared from main memory.
Trenloe:
You are correct, they are un cached after some amount of time... I'm not sure how long but I'd be interested to know... and to have the option to turn that off. I frequently have half of my 64GB of RAM sitting unused and I'd LOVE to fill it up upfront rather than wait the few seconds to load things during a live session.
Pindercarl:
Thanks. It is helpful to know that the CPU (i7-13700KF) is the likely culprit. Maybe a single core is hitting 100% but I'm only seeing the aggregate usage of all 16 cores...
I'll tinker around some more, but honestly I'd rather deal with the stutter than loading/unloading modules and CT actors.
Thank you to everyone for taking the time to answer my questions.
rocketvaultgames
January 17th, 2024, 16:01
Great to know all of that. Thanks much!
I'm sure it would be low to zero priority, but I wouldn't mind a console command along the lines of:
/imagecachetime n
with n being number of minutes or just a few options of:
never cache (unload upon close)
default - 10 minutes
1 hour
3 hours
6 hours
no limit
Zacchaeus
January 17th, 2024, 18:01
I suspect that if you kept things in memory you would be even more required to make sure that your image sizes were more reasonable. At least one of your images will, if my calculation is correct, take up half a gigabyte of memory.
You may want to think about reducing some of those image sizes. If you load the image into FG and then unlock it you will see an export icon at the bottom of the panel. Click on that and then in the drop down select webp. By converting the images to webp you will considerably reduce the files sizes.
Trenloe
January 17th, 2024, 18:08
I've loaded up the campaign and opened the "Map - Yartar Foothills" map, enable lighting, LoS, Player View and selected a token - basically I've enabled all of the stuff that would hit the CPU/GPU. I don't see any regular/brief freezes.
I ran a session from the laptop today... (same campaign) RTX 2060 - when I started (with extensions) I was getting the same stutter every 20 seconds. I checked again at the end of the session, 5 hours or so later and it was doing it every 30 seconds.
Loaded back up on main machine RTX 4070 TI (same campaign)(with extensions) and same stutter every 11.8 seconds.
Doing Internet searches for both of these graphics cards and "stuttering" gives quite a few threads where people have experienced stuttering. As this can't be readily recreated, then it is pointing to a local driver/config issue. I know that doesn't really help you, but it is worth a check through some troubleshooting threads for these types of issues with your graphics card.
rocketvaultgames
January 17th, 2024, 18:15
I think you are right. I appreciate everyone's time. Thank you!
Trenloe
January 17th, 2024, 19:17
Additionally, GPU usage is directly related to the number of pixels that the GPU has to process.
Here's an example video that shows how the GPU utilization can significantly change - based off the base image pixels being shown: https://www.dropbox.com/scl/fi/90zgjvhxz9ixi8elr2e5g/GPU-image-use-pixels-displayed.mp4?rlkey=t1xgxeusj0o3nkvp69lcdgrbm&dl=0 Sorry, it stops abruptly at the end...
What I'd like you to try is zoom in on your map, so that the tokens are pretty large - do you see a reduction in GPU usage? And, if so, do you still see the stuttering?
As an aside, following on from this video... The maximum recommended image file size for FG is 4,000 x 4,000 (16 million) pixels, details here: https://fantasygroundsunity.atlassian.net/wiki/spaces/FGCP/pages/2037547009/Developer+Guide+-+Product+Guidelines A lot of the images in your campaign directory are way above this. The example used in the video is 5343 x 5343 (28.5 million pixel) - so 178% of the recommended maximum, and there are some images in your campaign that are much larger than this! Whereas your computer may be able to handle these, not all players will have high-spec PCs and may slow to a crawl.
You can notice in my video that when I used an image within the recommended size, then the effect of zooming to extents and zooming in/out weren't as noticeable as they were for the image that had 1.78 times the pixels. However, this effect may not be as noticeable on your much higher spec GPU than it was on mine - but it probably would be very noticeable on some player computers.
So - summary:
1) I'd be interested if zooming right in on your map reduces the GPU utilization as significantly as it did in my video, and if it does - is there any effect on the stuttering?
2) As a side task, you're probably going to want to reduce the dimensions of some of the images - especially the ones that get shared to players.
rocketvaultgames
January 17th, 2024, 22:38
Alright... I restarted the machine and got today's NVIDIA drivers... I now cannot reproduce the regular interval stutters without any extensions loaded.
Occasional stutters still occur, but I'm not blaming FGU. I can get regular stutters to occur now with only "Better Menus" extension loaded. I'll take that up with the developer.
I did try zooming way in and out and there is no appreciable increase in GPU utilization.
I will work on following the developer image guidelines where possible.
Thanks for all your help. I definitely learned some things.
Trenloe
January 17th, 2024, 23:05
Alright... I restarted the machine and got today's NVIDIA drivers... I now cannot reproduce the regular interval stutters without any extensions loaded.
That's promising!
I did try zooming way in and out and there is no appreciable increase in GPU utilization.
I had wondered if you'd see any difference as your GPU is streets ahead of mine.
Thanks for all your help. I definitely learned some things.
You're very welcome. These edge cases can be hard to get a handle on. Glad we made some progress it seems...
rocketvaultgames
January 18th, 2024, 00:16
Is there full/reduced/zero CPU/GPU cost for an image that is open but covered up completely by another open image?
I know it takes GPU memory, but does it actually impact CPU/GPU performance when it can't be seen?
I'm thinking I might want to keep some larger images (world and city maps) open just to save the reload time when they get cleaned up after being closed for 10 minutes.
pindercarl
January 18th, 2024, 01:04
Is there full/reduced/zero CPU/GPU cost for an image that is open but covered up completely by another open image?
I know it takes GPU memory, but does it actually impact CPU/GPU performance when it can't be seen?
I'm thinking I might want to keep some larger images (world and city maps) open just to save the reload time when they get cleaned up after being closed for 10 minutes.
I would have to do some profiling to confirm, but the cost of an image that is opened and covered should be the same or nearly the same as when the image is exposed.
Trenloe
January 18th, 2024, 12:24
I'm thinking I might want to keep some larger images (world and city maps) open just to save the reload time when they get cleaned up after being closed for 10 minutes.
Please provide some examples from our campaign that take a while to open.
Elvedui
January 18th, 2024, 14:33
I own many assets and when i open the asset tab for either tokens or portraits, i almost always get a delay and i have the highest end computer you can get. Actually, let me clarify. I open say a token bag and moving between screens left or right causes a freeze or serious lag.
Trenloe
January 18th, 2024, 14:42
I own many assets and when i open the asset tab for either tokens or portraits, i almost always get a delay and i have the highest end computer you can get. Actually, let me clarify. I open say a token bag and moving between screens left or right causes a freeze or serious lag.
I appreciate you're seeing delays while FG processes assets/data - but that is very different to the issue the OP is having, and what we're discussing and troubleshooting in this thread. If you have specific issues that aren't 100% the same as what's being discussed in a thread, please start a new thread - this helps prevent confusion and keeps the discussion on topic to try to deal with the issue at hand.
rocketvaultgames
January 18th, 2024, 15:14
Please provide some examples from our campaign that take a while to open.
I know these are above recommended sizes so I'm not surprised they take awhile to open:
These are the 2 that I use the most:
Map - Faerun
Map - Elturel in Avernus
It is usually just a few seconds to open, but even that is a little disruptive to keeping the game flowing as smoothly as possible as a GM. I usually need to open at least one of these multiple times per session and seemingly always more than 10 minutes apart.
Trenloe
January 18th, 2024, 15:29
Yeah, those maps or at least 4 times the recommended size, so the "fix" for long loading times is to reduce the dimensions of the map. Sorry, I know this isn't what you want to hear.
It would be a bad programming approach for FG to code something to allow larger maps to stay in memory longer (even if that is user controlled) as keeping massive maps in memory has a knock on effect to general FG performance. And keeping those maps open to avoid re-opening delays would also not be such a great approach, for the same reasons. There's a reason why the recommend image size is 16 million pixels, as that's been found to be a good size of images that doesn't have an excessive resource impact on users.
rocketvaultgames
January 18th, 2024, 15:46
Makes perfect sense. I have to say I wish "Map - Faerun" was even larger!
No idea how hard something like this would be to implement, but most big video games auto select and let you manually select performance levels based on PC specs.
Maybe a Low/Med/High/Ultra toggle could allow higher-end machines to take advantage of their power, but I suspect that would be a lot of work and very low priority.
Regardless, I truly appreciate all of this discussion. It is helpful to know more about how FGU works.
LordEntrails
January 18th, 2024, 15:54
I will say out group tend to put large regional maps, or links to them, in Discord. They certainly can be in FG, but we like to open them up on second or third monitors. Something to consider if it might work for your group.
rocketvaultgames
January 18th, 2024, 15:58
It's worth thinking about...
It is nice to be able to see who has the map open in FGU, and I have a thousand pins on the world map for myself... and we draw arrows and circles on it all the time when traveling...
LordEntrails
January 18th, 2024, 16:09
In that case, probably not a use case for you. But was worth thinking about.
Trenloe
January 18th, 2024, 16:09
Map - Faerun
Looking at this one in particular, in the campaign you provided yesterday. This map also has two other large map images within it - off to the right and below the map of Faerun. Maps for Chult and Mulhorand.
My recommendation for this specific map would be to remove the additional images not part of the main map and reduce the size of the base map by 50% in each dimension - this gets it down to within a few percent of the recommended 16 million pixels. In my testing this reduced the load time to half (from 12 seconds to 6 seconds on my computer).
There are also a lot of other images on this map that will impact loading time - for example, "Giant Overlay (1).png" is 10,200 x 6,600 pixels! Looking at the image (a few labels for giant population) this could be done a lot more efficiently. Spirit mounds is another example.
Ultimately, loading anything in an application is going to take an amount of time - the more data to be loaded, the more time that's going to take. Being aware of the recommended image sizes for Fantasy Grounds, and working to those recommendations (as well as being efficient for things like labels and overlays) will go a long way to improving image opening time and also resource usage - which will help FG, and your game, run more smoothly.
rocketvaultgames
January 18th, 2024, 16:15
If Chult/Mulhorand are hidden from GM and Player, they would still affect load time, correct?
For Giant Overlay and Spirit Mounds, all of the transparent pixels still affect performance? They have very little actual data showing, and I structured them that way to easily align them.
Trenloe
January 18th, 2024, 16:26
If Chult/Mulhorand are hidden from GM and Player, they would still affect load time, correct?
For Giant Overlay and Spirit Mounds, all of the transparent pixels still affect performance? They have very little actual data showing, and I structured them that way to easily align them.
An FG developer will need to comment on what end performance result transparent pixels have once all of the images are loaded. But in terms of initial loading, FG still needs to go through 67 million pixels (in the example of the giant overlay) working out which pixel is transparent and which isn't.
pindercarl
January 18th, 2024, 16:49
If Chult/Mulhorand are hidden from GM and Player, they would still affect load time, correct?
For Giant Overlay and Spirit Mounds, all of the transparent pixels still affect performance? They have very little actual data showing, and I structured them that way to easily align them.
1) The image file is loaded from when the image is opened whether or not it is hidden.
2) Pixels are pixels. You will, however, get better compression and performance on the GPU for images that have no transparency.
Powered by vBulletin® Version 4.2.1 Copyright © 2026 vBulletin Solutions, Inc. All rights reserved.