Italia Socket Error issue

I’ve encountered a problem trying to use Italia_v1.1.vmod

The problem does not show up with the two other modules I tried, D-Day at Omaha Beach and Triumph and Tragedy.
Vassal Message:

Socket Error

The socket over which the Module Manager communicates has had a fault. Please restart VASSAL.
[This solution, of course, merely repeats the problem]

I have:
Model: iMac 27", Mid 2011
Operating System: Mac OS X Lion 10.7.5 (11G63b)
CPU: 2.7 GHz Intel Core i5
Memory: 4 GB 1333 MHz DDR3
Video Card: AMD Radeon HD 6770M 512 MB
VASSAL Version: 3.2.8
Java 7 version 40
Module: Italia_v1.1vmod
My web browsers are Safari Version 6.0.5 (7536.30.1) and Firefox 23.0.1. I do not have a separate firewall program.
The steps I took were to click on my downloaded VASSSAL 3.2.8, Click Open Module under FIle, find and select the module in the folder I’ve stored it in, click Open. A box opens labelled “Processing Image TIles” which remains at 0% and says below that 0% bar: Tiling images/Base Layer.png. Then the Socket Error window opens.

The details of the error message are in the attached file, the first 10 lines of which are included here:

java.util.concurrent.ExecutionException: java.io.IOException: return value == 1
at java.util.concurrent.FutureTask$Sync.innerGet(FutureTask.java:222)
at java.util.concurrent.FutureTask.get(FutureTask.java:83)
at org.jdesktop.swingworker.SwingWorker.get(Unknown Source)
at VASSAL.launch.AbstractLaunchAction$LaunchTask.done(AbstractLaunchAction.java:620)
at VASSAL.launch.Player$LaunchAction$1.done(Player.java:188)
at org.jdesktop.swingworker.SwingWorker$5.run(Unknown Source)
at org.jdesktop.swingworker.SwingWorker$DoSubmitAccumulativeRunnable.run(Unknown Source)
at org.jdesktop.swingworker.AccumulativeRunnable.run(Unknown Source)
at org.jdesktop.swingworker.SwingWorker$DoSubmitAccumulativeRunnable.actionPerformed(Unknown Source)

I apologize for sending a private message first, without all the needed information-- for some reason I didn’t notice the New Topic button or compute that it was the way to post a new subject.

Thus spake markgame:

I’ve encountered a problem trying to use Italia_v1.1.vmod

The problem does not show up with the two other modules I tried, D-Day
at Omaha Beach and Triumph and Tragedy.
Vassal Message:

Socket Error

The socket over which the Module Manager communicates has had a fault.
Please restart VASSAL.
[This solution, of course, merely repeats the problem]

I have:
Model: iMac 27", Mid 2011
Operating System: Mac OS X Lion 10.7.5 (11G63b)
CPU: 2.7 GHz Intel Core i5
Memory: 4 GB 1333 MHz DDR3
Video Card: AMD Radeon HD 6770M 512 MB
VASSAL Version: 3.2.8
Java 7 version 40
Module: Italia_v1.1vmod
My web browsers are Safari Version 6.0.5 (7536.30.1) and Firefox 23.0.1.
I do not have a separate firewall program.
The steps I took were to click on my downloaded VASSSAL 3.2.8, Click
Open Module under FIle, find and select the module in the folder I’ve
stored it in, click Open. A box opens labelled “Processing Image TIles”
which remains at 0% and says below that 0% bar: Tiling images/Base
Layer.png. Then the Socket Error window opens.

The details of the error message are in the attached file, the first 10
lines of which are included here:

java.util.concurrent.ExecutionException: java.io.IOException: return
value == 1
at java.util.concurrent.FutureTask$Sync.innerGet(FutureTask.java:222)
at java.util.concurrent.FutureTask.get(FutureTask.java:83)
at org.jdesktop.swingworker.SwingWorker.get(Unknown Source)
at
VASSAL.launch.AbstractLaunchAction$LaunchTask.done(AbstractLaunchAction.java:620)
at VASSAL.launch.Player$LaunchAction$1.done(Player.java:188)
at org.jdesktop.swingworker.SwingWorker$5.run(Unknown Source)
at
org.jdesktop.swingworker.SwingWorker$DoSubmitAccumulativeRunnable.run(Unknown
Source)
at org.jdesktop.swingworker.AccumulativeRunnable.run(Unknown Source)
at
org.jdesktop.swingworker.SwingWorker$DoSubmitAccumulativeRunnable.actionPerformed(Unknown
Source)

I apologize for sending a private message first, without all the needed
information-- for some reason I didn’t notice the New Topic button or
compute that it was the way to post a new subject.

This doesn’t provide sufficient context for determining what’s wrong.
Please post the complete error log:

vassalengine.org/wiki/Error_Logs


J.

Could not find folder you suggest, but possibly what you are looking for is one of these two things:

Error details:

java.util.concurrent.ExecutionException: java.io.IOException: return value == 1
at java.util.concurrent.FutureTask$Sync.innerGet(FutureTask.java:222)
at java.util.concurrent.FutureTask.get(FutureTask.java:83)
at org.jdesktop.swingworker.SwingWorker.get(Unknown Source)
at VASSAL.launch.AbstractLaunchAction$LaunchTask.done(AbstractLaunchAction.java:620)
at VASSAL.launch.Player$LaunchAction$1.done(Player.java:188)
at org.jdesktop.swingworker.SwingWorker$5.run(Unknown Source)
at org.jdesktop.swingworker.SwingWorker$DoSubmitAccumulativeRunnable.run(Unknown Source)
at org.jdesktop.swingworker.AccumulativeRunnable.run(Unknown Source)
at org.jdesktop.swingworker.SwingWorker$DoSubmitAccumulativeRunnable.actionPerformed(Unknown Source)
at javax.swing.Timer.fireActionPerformed(Timer.java:291)
at javax.swing.Timer$DoPostEvent.run(Timer.java:221)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:715)
at java.awt.EventQueue.access$400(EventQueue.java:82)
at java.awt.EventQueue$2.run(EventQueue.java:676)
at java.awt.EventQueue$2.run(EventQueue.java:674)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:86)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:685)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:205)
at java.awt.Dialog$1.run(Dialog.java:1049)
at java.awt.Dialog$3.run(Dialog.java:1101)
at java.security.AccessController.doPrivileged(Native Method)
at java.awt.Dialog.show(Dialog.java:1099)
at java.awt.Component.show(Component.java:1615)
at java.awt.Component.setVisible(Component.java:1567)
at java.awt.Window.setVisible(Window.java:843)
at java.awt.Dialog.setVisible(Dialog.java:984)
at VASSAL.launch.TilingHandler$3.run(TilingHandler.java:266)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:715)
at java.awt.EventQueue.access$400(EventQueue.java:82)
at java.awt.EventQueue$2.run(EventQueue.java:676)
at java.awt.EventQueue$2.run(EventQueue.java:674)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:86)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:685)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
Caused by: java.io.IOException: return value == 1
at VASSAL.launch.TilingHandler.runSlicer(TilingHandler.java:305)
at VASSAL.launch.TilingHandler.sliceTiles(TilingHandler.java:374)
at VASSAL.launch.AbstractLaunchAction$LaunchTask.doInBackground(AbstractLaunchAction.java:280)
at VASSAL.launch.AbstractLaunchAction$LaunchTask.doInBackground(AbstractLaunchAction.java:243)
at org.jdesktop.swingworker.SwingWorker$1.call(Unknown Source)
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
at java.util.concurrent.FutureTask.run(FutureTask.java:138)
at org.jdesktop.swingworker.SwingWorker.run(Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918)
at java.lang.Thread.run(Thread.java:680)

AppDebug.log, lines after attempting to load module:
10/4/13 10:00:23.740 AM mdworker: Unable to talk to lsboxd
10/4/13 10:03:24.960 AM Firewall: JavaApplicationS is listening from ::ffff:127.0.0.1:49694 proto=6
10/4/13 10:03:25.695 AM Firewall: java is listening from ::ffff:0.0.0.0:0 proto=6

The whole AppDebug.log is much longer, and I’m not sure it’s what you are looking for.

Thus spake markgame:

Could not find folder you suggest, but possibly what you are looking for
is one of these two things:

No, it’s neither. You can also get the errorLog contents from Help >
Error Log in the Module Manager.


J.

Is this it?

2013-10-20 21:37:35,571 [0-main] INFO VASSAL.launch.StartUp - Starting
2013-10-20 21:37:35,577 [0-main] INFO VASSAL.launch.StartUp - OS Mac OS X 10.7.5
2013-10-20 21:37:35,577 [0-main] INFO VASSAL.launch.StartUp - Java version 1.6.0_51
2013-10-20 21:37:35,577 [0-main] INFO VASSAL.launch.StartUp - VASSAL version 3.2.8
2013-10-20 21:37:36,739 [0-AWT-EventQueue-0] INFO VASSAL.launch.ModuleManager - Manager

Thus spake markgame:

Is this it?

2013-10-20 21:37:35,571 [0-main] INFO VASSAL.launch.StartUp - Starting
2013-10-20 21:37:35,577 [0-main] INFO VASSAL.launch.StartUp - OS Mac OS
X 10.7.5
2013-10-20 21:37:35,577 [0-main] INFO VASSAL.launch.StartUp - Java
version 1.6.0_51
2013-10-20 21:37:35,577 [0-main] INFO VASSAL.launch.StartUp - VASSAL
version 3.2.8
2013-10-20 21:37:36,739 [0-AWT-EventQueue-0] INFO
VASSAL.launch.ModuleManager - Manager

Yes, but that can’t be the complete contents of the errorLog from a
run where you had the problem. There’s no error here.


J.

OK. I freshly opened VASSAL, opened the module, got the Error, and copied the Error Log – it looks more substantial this time.

2013-10-22 13:56:45,727 [0-main] INFO VASSAL.launch.StartUp - Starting
2013-10-22 13:56:45,731 [0-main] INFO VASSAL.launch.StartUp - OS Mac OS X 10.7.5
2013-10-22 13:56:45,731 [0-main] INFO VASSAL.launch.StartUp - Java version 1.6.0_51
2013-10-22 13:56:45,731 [0-main] INFO VASSAL.launch.StartUp - VASSAL version 3.2.8
2013-10-22 13:56:46,440 [0-AWT-EventQueue-0] INFO VASSAL.launch.ModuleManager - Manager
2013-10-22 13:57:07,308 [0-SwingWorker-pool-615125244-thread-1] INFO VASSAL.launch.AbstractLaunchAction - Loading module file /Users/markmccandlessflat/Desktop/VASSAL Modules/Anzio/Italia_v1.1.vmod
2013-10-22 13:57:07,953 [0-SwingWorker-pool-615125244-thread-1] INFO VASSAL.tools.io.ProcessLauncher - launching /System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/bin/java -classpath /Users/markmccandlessflat/Desktop/VASSAL Modules/VASSAL-3.2.8.app/Contents/Resources/Java/Vengine.jar -Xmx292M -DVASSAL.id=2 -Duser.home=/Users/markmccandlessflat -DVASSAL.port=50793 VASSAL.tools.image.tilecache.ZipFileImageTiler /Users/markmccandlessflat/Desktop/VASSAL Modules/Anzio/Italia_v1.1.vmod /Users/markmccandlessflat/Library/Application Support/VASSAL/tiles/ce344055962fd29f5a4867ae094a6e5ec722c5a8 256 256
2013-10-22 13:57:08,567 [2-main] INFO VASSAL.tools.image.tilecache.ZipFileImageTiler - Starting
2013-10-22 13:57:08,596 [2-main] INFO VASSAL.tools.image.tilecache.FileArchiveImageTiler - Tiling images/Base Layer.png
2013-10-22 13:57:09,579 [2-main] INFO VASSAL.tools.image.FallbackImageTypeConverter - Switching to FileImageTypeConverter…
2013-10-22 13:57:13,337 [2-main] INFO VASSAL.tools.image.tilecache.ZipFileImageTiler - Exiting
2013-10-22 13:57:13,371 [2-main] ERROR VASSAL.tools.image.tilecache.ZipFileImageTiler - main
java.lang.OutOfMemoryError: Java heap space
at java.awt.image.DataBufferInt.(DataBufferInt.java:41) ~[na:1.6.0_51]
at java.awt.image.Raster.createPackedRaster(Raster.java:455) ~[na:1.6.0_51]
at java.awt.image.DirectColorModel.createCompatibleWritableRaster(DirectColorModel.java:1015) ~[na:1.6.0_51]
at java.awt.image.BufferedImage.(BufferedImage.java:345) ~[na:1.6.0_51]
at VASSAL.tools.image.FileImageTypeConverter.convert(FileImageTypeConverter.java:121) ~[Vengine.jar:na]
at VASSAL.tools.image.FallbackImageTypeConverter.convert(FallbackImageTypeConverter.java:87) ~[Vengine.jar:na]
at VASSAL.tools.image.ImageIOImageLoader.load(ImageIOImageLoader.java:342) ~[Vengine.jar:na]
at VASSAL.tools.image.tilecache.FileArchiveImageTiler.run(FileArchiveImageTiler.java:77) ~[Vengine.jar:na]
at VASSAL.tools.image.tilecache.ZipFileImageTiler.main(ZipFileImageTiler.java:167) ~[Vengine.jar:na]
2013-10-22 13:57:13,824 [0-AWT-EventQueue-0] ERROR VASSAL.tools.ProblemDialog -
java.util.concurrent.ExecutionException: java.io.IOException: return value == 1
at java.util.concurrent.FutureTask$Sync.innerGet(FutureTask.java:222) ~[na:1.6.0_51]
at java.util.concurrent.FutureTask.get(FutureTask.java:83) ~[na:1.6.0_51]
at org.jdesktop.swingworker.SwingWorker.get(Unknown Source) ~[swing-worker-1.2.jar:na]
at VASSAL.launch.AbstractLaunchAction$LaunchTask.done(AbstractLaunchAction.java:620) ~[Vengine.jar:na]
at VASSAL.launch.Player$LaunchAction$1.done(Player.java:188) [Vengine.jar:na]
at org.jdesktop.swingworker.SwingWorker$5.run(Unknown Source) [swing-worker-1.2.jar:na]
at org.jdesktop.swingworker.SwingWorker$DoSubmitAccumulativeRunnable.run(Unknown Source) [swing-worker-1.2.jar:na]
at org.jdesktop.swingworker.AccumulativeRunnable.run(Unknown Source) [swing-worker-1.2.jar:na]
at org.jdesktop.swingworker.SwingWorker$DoSubmitAccumulativeRunnable.actionPerformed(Unknown Source) [swing-worker-1.2.jar:na]
at javax.swing.Timer.fireActionPerformed(Timer.java:291) [na:1.6.0_51]
at javax.swing.Timer$DoPostEvent.run(Timer.java:221) [na:1.6.0_51]
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209) [na:1.6.0_51]
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:715) [na:1.6.0_51]
at java.awt.EventQueue.access$400(EventQueue.java:82) [na:1.6.0_51]
at java.awt.EventQueue$2.run(EventQueue.java:676) [na:1.6.0_51]
at java.awt.EventQueue$2.run(EventQueue.java:674) [na:1.6.0_51]
at java.security.AccessController.doPrivileged(Native Method) [na:1.6.0_51]
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:86) [na:1.6.0_51]
at java.awt.EventQueue.dispatchEvent(EventQueue.java:685) [na:1.6.0_51]
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296) [na:1.6.0_51]
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211) [na:1.6.0_51]
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:205) [na:1.6.0_51]
at java.awt.Dialog$1.run(Dialog.java:1049) [na:1.6.0_51]
at java.awt.Dialog$3.run(Dialog.java:1101) [na:1.6.0_51]
at java.security.AccessController.doPrivileged(Native Method) [na:1.6.0_51]
at java.awt.Dialog.show(Dialog.java:1099) [na:1.6.0_51]
at java.awt.Component.show(Component.java:1615) [na:1.6.0_51]
at java.awt.Component.setVisible(Component.java:1567) [na:1.6.0_51]
at java.awt.Window.setVisible(Window.java:843) [na:1.6.0_51]
at java.awt.Dialog.setVisible(Dialog.java:984) [na:1.6.0_51]
at VASSAL.launch.TilingHandler$3.run(TilingHandler.java:266) [Vengine.jar:na]
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209) [na:1.6.0_51]
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:715) [na:1.6.0_51]
at java.awt.EventQueue.access$400(EventQueue.java:82) [na:1.6.0_51]
at java.awt.EventQueue$2.run(EventQueue.java:676) [na:1.6.0_51]
at java.awt.EventQueue$2.run(EventQueue.java:674) [na:1.6.0_51]
at java.security.AccessController.doPrivileged(Native Method) [na:1.6.0_51]
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:86) [na:1.6.0_51]
at java.awt.EventQueue.dispatchEvent(EventQueue.java:685) [na:1.6.0_51]
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296) [na:1.6.0_51]
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211) [na:1.6.0_51]
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201) [na:1.6.0_51]
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196) [na:1.6.0_51]
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188) [na:1.6.0_51]
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122) [na:1.6.0_51]
java.io.IOException: return value == 1
at VASSAL.launch.TilingHandler.runSlicer(TilingHandler.java:305) ~[Vengine.jar:na]
at VASSAL.launch.TilingHandler.sliceTiles(TilingHandler.java:374) ~[Vengine.jar:na]
at VASSAL.launch.AbstractLaunchAction$LaunchTask.doInBackground(AbstractLaunchAction.java:280) ~[Vengine.jar:na]
at VASSAL.launch.AbstractLaunchAction$LaunchTask.doInBackground(AbstractLaunchAction.java:243) ~[Vengine.jar:na]
at org.jdesktop.swingworker.SwingWorker$1.call(Unknown Source) ~[swing-worker-1.2.jar:na]
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) ~[na:1.6.0_51]
at java.util.concurrent.FutureTask.run(FutureTask.java:138) ~[na:1.6.0_51]
at org.jdesktop.swingworker.SwingWorker.run(Unknown Source) ~[swing-worker-1.2.jar:na]
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:895) ~[na:1.6.0_51]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:918) ~[na:1.6.0_51]
at java.lang.Thread.run(Thread.java:680) ~[na:1.6.0_51]

Thus spake markgame:

OK. I freshly opened VASSAL, opened the module, got the Error, and
copied the Error Log – it looks more substantial this time.

2013-10-22 13:56:45,727 [0-main] INFO VASSAL.launch.StartUp - Starting
2013-10-22 13:56:45,731 [0-main] INFO VASSAL.launch.StartUp - OS Mac OS
X 10.7.5
2013-10-22 13:56:45,731 [0-main] INFO VASSAL.launch.StartUp - Java
version 1.6.0_51
2013-10-22 13:56:45,731 [0-main] INFO VASSAL.launch.StartUp - VASSAL
version 3.2.8
2013-10-22 13:56:46,440 [0-AWT-EventQueue-0] INFO
VASSAL.launch.ModuleManager - Manager
2013-10-22 13:57:07,308 [0-SwingWorker-pool-615125244-thread-1] INFO
VASSAL.launch.AbstractLaunchAction - Loading module file
/Users/markmccandlessflat/Desktop/VASSAL Modules/Anzio/Italia_v1.1.vmod
2013-10-22 13:57:07,953 [0-SwingWorker-pool-615125244-thread-1] INFO
VASSAL.tools.io.ProcessLauncher - launching
/System/Library/Java/JavaVirtualMachines/1.6.0.jdk/Contents/Home/bin/java
-classpath /Users/markmccandlessflat/Desktop/VASSAL
Modules/VASSAL-3.2.8.app/Contents/Resources/Java/Vengine.jar -Xmx292M
-DVASSAL.id=2 -Duser.home=/Users/markmccandlessflat -DVASSAL.port=50793
VASSAL.tools.image.tilecache.ZipFileImageTiler
/Users/markmccandlessflat/Desktop/VASSAL Modules/Anzio/Italia_v1.1.vmod
/Users/markmccandlessflat/Library/Application
Support/VASSAL/tiles/ce344055962fd29f5a4867ae094a6e5ec722c5a8 256 256
2013-10-22 13:57:08,567 [2-main] INFO
VASSAL.tools.image.tilecache.ZipFileImageTiler - Starting
2013-10-22 13:57:08,596 [2-main] INFO
VASSAL.tools.image.tilecache.FileArchiveImageTiler - Tiling images/Base
Layer.png
2013-10-22 13:57:09,579 [2-main] INFO
VASSAL.tools.image.FallbackImageTypeConverter - Switching to
FileImageTypeConverter…
2013-10-22 13:57:13,337 [2-main] INFO
VASSAL.tools.image.tilecache.ZipFileImageTiler - Exiting
2013-10-22 13:57:13,371 [2-main] ERROR
VASSAL.tools.image.tilecache.ZipFileImageTiler - main
java.lang.OutOfMemoryError: Java heap space

Your problem is here. The image tiler is running out of memory.
When I open the same module for the first time on my system, the
image tiler has the same max heap (292MB, which you can see above),
but doesn’t run out of memory. What this tells me is that the same
code uses less memory on my machine than it does on yours.

Have you had this problem with any other modules?


J.

No, but have only tried D-Day at Omaha Beach and Triumph and Tragedy.

The full story is this: Java requires that you specify a maximum amount of memory a program will use before you start it. This is obviously problematic when your program loads user-supplied images, because you have no idea how large they will be beforehand. As a workaround, the Module Manager checks the sizes of the images which will be loaded and then starts the image tiler as a separate process, which permits us to specify a maximum amount of memory for the image tiler which is appropriate to the images it will be loading. (This is also the reason why the Module Manager and Player/Editor are not the same process.) So far, so good.

Unfortunately, Java gives you no reliable way of determining the sizes objects will have in memory—this, despite that Java requires you to set the maximum amount of memory you will use when you start a program! This is utterly braindead, but it is a constraint we must suffer under so long as we’re using Java. Recall that running the tiler in a separate process was a workaround for not knowing how much memory we’d need. Now we need a workaround for our workaround, in order to estimate the amount of memory it will need.

To arrive at that estimate, I ran the tiler on images of various sizes, measured (from the outside) the amount of memory (in MB) being used by the JVM in which the tiler was running, and fit a line to the data points. It turns out that 2.85(4p)/(2^20) + 50, where p is the number of pixels, gives you a line which is a bit above the data points I collected. (You’ll note that this is a disgusting amount of overhead, due to the JVM itself and because Java forces us to copy the image at one point in the process simply to convert the data from a byte array to an int array.)

This estimate mostly works—except for a few images on OS X, which take more memory to load than on Linux and Windows USING THE SAME CODE. So, clearly the JVM on OS X is doing something different behind the scenes sometimes on OS X, but I can’t guess what, as image loading is just data manipulation. It really should not differ significantly in memory requirements from platform to platform.

Here’s a build which increases the constant factor from 2.85 to 3. Does it work for you?

Success! The map appears! Thanks!

Thus spake markgame:

Success! The map appears! Thanks!

A workaround for your problem will go into 3.2.9. Let us know if
the problem recurrs with 3.2.9 or later.


J.