Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lighting Performance Regression versus 1.3b91 #45

Closed
mlangsdorf opened this issue Dec 23, 2017 · 8 comments
Closed

Lighting Performance Regression versus 1.3b91 #45

mlangsdorf opened this issue Dec 23, 2017 · 8 comments
Assignees
Labels
bug fixed bug fix is committed for next release MapTool issue relates to MapTool code vs 3rd party libs

Comments

@mlangsdorf
Copy link

Maps with large background images and large numbers (like 40+) of light sources are reasonably usable in 1.3b91. There is a slight lag when moving tokens but it's less than a few seconds.

The same map, loaded into 1.4.4, is completely unusable. There is a delay of 40-90 seconds between dragging a token and the map being updated to reflect the movement.

Steps to reproduce:

  1. Load https://www.prismnet.com/~mlangsdo/eastern-theatre.cmpgn in MapTools 1.3.b91.
  2. Go to the "Eastern Campaign" map and start dragging tokens. Notice a 1-3 second delay between releasing the token and the map being updated.
  3. Load the same campaign in MapTool 1.4.4.
  4. Go to the "Eastern Campaign" map and start dragging tokens. Notice a 60-120 second delay.
@JamzTheMan JamzTheMan self-assigned this Dec 25, 2017
@JamzTheMan
Copy link
Owner

Thanks for that map/campaign! Something bad indeed is going on here! I'll dig into this asap.

@JamzTheMan JamzTheMan added bug investigating researching if issue is valid and/or reasonable MapTool issue relates to MapTool code vs 3rd party libs labels Dec 25, 2017
@Syndaryl
Copy link

I am subscribing to this issue as I'm also having big trouble with it. My map is four large (page sized) PNGs with black for the walls, transparent for the not-walls, and I used the token auto VBL feature to set up my vbl one click. Well, five clicks but still.

When it was one PNG, it was OK.
When I placed a second, it got worse.
When I placed the third and fourth it got impossible.

Turning vision to Day removes the problem, but I was rather appreciating that my players couldn't see the big picture, and didn't realize how big the space they were in really was. Once I set it to Day so we could play they kinda flipped out :)

@JamzTheMan
Copy link
Owner

JamzTheMan commented Dec 26, 2017

@Syndaryl Your issue may be separate as you are using "new" functionality, namely TokenVBL. TokenVBL is more intense as it has to calculate it more often since it can "move".

Try transferring it to the normal VBL layer using a macro like:

[r: transferVBL(1)]
[r: finalVblData = "{'shape':'none'}"]
[r: setTokenVBL(finalVblData)] 

FYI: You can transfer VBL to the token via from the map layer:

[r: transferVBL(0)]

Also, Auto-Generated VBL can be very poor performing if too detailed. Like, if you manually drew around every single pixel, it would also be bad. If it's basically just straight walls, auto-generation should be ok.

FYI: You can drag/drop files right into the "issue" here so feel free to supply the campaign file for testing.

@dracwyrm
Copy link

I hadn't had a lot of time as of late, but maybe I should revisit the idea of using faster math operations for VBL? Default math in Java is set to high precision, but that is not needed for this, so the faster math libraries can be used. Trouble is, you can't override the math library with your own.

@JamzTheMan JamzTheMan added the fixed bug fix is committed for next release label Jun 5, 2018
@JamzTheMan
Copy link
Owner

I made some improvements to Lights for the next release. This campaign file should be usable under 1.4.5.0 (just tested it) and I'll continue to look into this. There may still be room for additional improvements.

Note: You may want to clear FoW to see the best improvements. The fix involves changing lights from a true circle to a polygon which is 10-100 times faster to calculate the intersection with existing FoW. But if existing FoW already has "curves", performance may be poor. YMMV.

@mlangsdorf
Copy link
Author

is there a beta build of 1.4.5 that I could test?

@JamzTheMan
Copy link
Owner

JamzTheMan commented Jun 6, 2018

I just created one for Windows/Mac. Appveyor isn't uploading the deb package for linux for some reason and looking into it...

https://github.com/JamzTheMan/MapTool/releases/tag/1.4.5.0-beta2

@JamzTheMan JamzTheMan removed the investigating researching if issue is valid and/or reasonable label Sep 29, 2018
@JamzTheMan
Copy link
Owner

Should be fixed as of 1.4.5.3.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug fixed bug fix is committed for next release MapTool issue relates to MapTool code vs 3rd party libs
Projects
None yet
Development

No branches or pull requests

4 participants