I am working on a JavaFX program and want to speed up my application. After reading about large images and issues related to them here, I decided to follow the advice there and allocate more VRAM. I am not quite sure how to do this, however, although I have an idea of how to do it I would like specific instructions to do so. The parameter I need to use is Dprism.maxvram=XX. I am using the eclipse IDE and would like to know where in it do I insert the parameter and will the parameter be carried when exporting to a jar file?
In Eclipse, to change build arguments, go to Run -> Run configurations... and then select Arguments.
Add -Dprism.maxvram=whatever
to your VM arguments (not Program arguments, these are the args[]
passed to your main
method)
This will not carry over to your .JAR file, because parameters must be passed through the command line and are not stored in the file itself.
You could create a batch file to run the JAR for you with your specified arguments, though.
Example batch file:
java -Dprism.maxvram=90M -jar MyJar.jar
Then you'd just have to double click your bat file to run your JAR with 90MB of VRAM.