score:1
as you just found out java returns different default synthesizer when running the jar file outside of eclipse.
this might be caused by the javax.sound.midi.synthesizer
property or a sound.properties
file in the classpath.
as a workaround you could print the property value when running the application inside of eclipse and set it manually so the jar file uses the same synthesizer.
edit:
if you want to use com.sun.media.sound.mixersynth
as default create the property
javax.sound.midi.synthesizer=com.sun.media.sound.mixersynth
example:
properties props = system.getproperties();
props.setproperty("javax.sound.midi.synthesizer", "com.sun.media.sound.mixersynth");
synthesizer synth = midisystem.getsynthesizer();
....
more information: http://docs.oracle.com/javase/7/docs/api/javax/sound/midi/midisystem.html)
Source: stackoverflow.com
Related Query
- MIDI instruments sound different when exported to .jar file
- Java project working on Eclipse but not working when exported to runnable jar file
- Marathon JAVA Driver - Error when running inside an exported JAR file from Eclipse
- setIconImage only works in eclipse, doesnt work when exported as runnable jar file
- Different behavior in JAR file vs Runnable JAR file exported from Eclipse
- Program runs completely in Eclipse but does not run when exported as a Runnable JAR file
- Error when trying to run jar file exported from Eclipse
- "Could not find the main class" error when running jar exported by Eclipse
- URL getResource not working when in JAR file
- Sign a jar file exported from Eclipse 3.5?
- UnsatisfiedLinkError in exported (Eclipse) executable jar file
- Exported runnable JAR file from Eclipse doesn't seem to execute
- Java Eclipse--.txt File Not Found When Exported To .jar
- newKieSession() returns null when project is exported to JAR
- Exported JAR file doesn't detect serial ports
- Program runs in Eclipse, but exported runnable jar file will not open?
- create executable jar file when making businessobjects SAP BI SDK app
- .txt file seems to be different when opened on my computer. It seems to be OK on any other mobile device
- Unsupported major.minor version 51.0 Error With Eclipse When Trying to Reference Jar File
- Error when running JAR file
- Eclipse launch configuration is missing when exporting a Spring boot project to a runnable jar file
- Runnable jar file generated with java eclipse wont run when double clicked
- Buffered Images not rendering when project is built as an executable jar file in eclipse
- Jar file can run from Gradle Run but got NoClassDefFoundError when running within Eclipse
- JNA finds library running in Eclipse but not when a built JAR file
- Java Eclipse, JavaSE-1.7 or jre7 when creating Runnable JAR File
- Java: file path when running from as JAR
- How to open and run an exported JAR file
- Unicode characters not rendered when running jar file in terminal ( Eclipse / MacOS )
- Finding a file in a root directory of jar exported from Eclipse for JUNIT testing
More Query from same tag
- How to determine memory corruption in web app deployed to T/C 6?
- Eclipse plugin fragment dependency
- How to enable Memory monitors in Eclipse (Java project)?
- How to wadl2java these days?
- server not showing in runtime enviroment while adding server(tomcate) in eclipse
- Is there a JQuery(mobile plugin) for Eclipse?
- Eclipse: does not show Android Icons in current ADT
- How to find out which dependency a class belongs to?
- Reference to undefined variable jrebel_args
- Restore Eclipse Toolbar in Mac
- How can I subtract minutes from the time I input?
- Eclipse - how to set javadoc warnings only to specific folders, not the whole project
- Sip Error on Emulator
- Unable to generate tables from entities
- How do remove maven from eclipse?
- create sequence on pydev for postgres database
- Windows or components do not show up in Java Swing
- Content assist on pointcut definition using Eclipse and AspectJ (AJDT)
- Maven not adding JAR to project when using mvn compile but does when using mvn eclipse:eclipse
- Grid Layout on Android?
- Eclipse Workspace build while saving JSPs and XML files
- Error during post inflation process for TabHost
- What is the best way to include another (non-android) project in an android project under eclipse
- Eclipse/EGit Import From Local Git Repo?
- Eclipse: create Gradle project but make Eclipse "accept" Groovy for app files
- Draw on a photo
- Adding GUI and Functions to Android drawer Fragment
- Share private key in android development
- How to make the run button run the project, not the file, in Eclipse
- Could not find appcompat_v7.apk and android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1880)