LeprovostQuentin / mt4j

Automatically exported from code.google.com/p/mt4j
GNU General Public License v2.0
0 stars 0 forks source link

library import failed (JSyn) #3

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. go to http://www.softsynth.com/jsyn/developers/ and download JSynth
2. add jsyn.jar and SoftSynthTools.jar as libraries in MT4J-buildpath
3. as you see here: http://www.softsynth.com/jsyn/docs/installation.html
   --> for windows put the JSynV144.dll in C:\Windows or
C:\Windows\System32 flder
4. Create new Example and try to call Synth.startEngine(0);

What is the expected output? What do you see instead?
Jsyn should run as it is doing in a blank "not MT4J-project" and NOT throw
these exception 

"JSyn error: Could not access JSyn synthesis engine.  -  JSyn not properly
installed, or web page is not calling smart_embed_jsyn.js!, 0x0=0, 0x0=0"

The exception occures when libs or dll file can not be found. I assume that
MT4J is blocking or redirecting something that the dll file can not be found

What version of the product are you using? On what operating system?

- MT4J rev25 
- Windows 7 Professional 64-bit

Please provide any additional information below.

I put the dll file in C:\Windows created a new Java-Project included the 2
libs called Synth.startEngine(0); and it worked.

When i try to do it with the mt4j project and include the 2 libs the
exception occures.
Not tutorial how to include other libs is not provided so i assumed to do
it the ususal way. ich tried to copy the dll file in the project path
(where other mt4j dlls are located) with the same result

Original issue reported on code.google.com by maigra...@googlemail.com on 31 Mar 2010 at 12:39

GoogleCodeExporter commented 8 years ago
here the complete exception:

INFO - Initializing TUIO input on port: 3333
Caught java.lang.UnsatisfiedLinkError: no JSynV144 in java.library.path
Caught java.lang.UnsatisfiedLinkError: no JSynNative in java.library.path
Exception in thread "Animation Thread" com.softsynth.jsyn.SynthException: JSyn 
error:
Could not access JSyn synthesis engine.  -  JSyn not properly installed, or web 
page
is not calling smart_embed_jsyn.js!, 0x0=0, 0x0=0
    at com.softsynth.jsyn.SynthContext.checkEngineAccess(SynthContext.java:60)
    at com.softsynth.jsyn.SynthContext.<init>(SynthContext.java:48)
    at com.softsynth.jsyn.Synth.initialize(Synth.java:361)
    at com.softsynth.jsyn.Synth.startEngine(Synth.java:251)
    at com.softsynth.jsyn.Synth.startEngine(Synth.java:299)
    at TestTable.<init>(TestTable.java:44)
    at Starter.startUp(Starter.java:14)
    at org.mt4j.MTApplication.setup(MTApplication.java:382)
    at processing.core.PApplet.handleDraw(PApplet.java:1400)
    at processing.core.PApplet.run(PApplet.java:1328)
    at java.lang.Thread.run(Unknown Source)

Original comment by maigra...@googlemail.com on 31 Mar 2010 at 12:45

GoogleCodeExporter commented 8 years ago
You have to add the directory where the JSynV144.dll is to the java library 
path via
command line, for example: 
"Djava.library.path=C:\Workspace\MT4jProject\windows";

If you use the Eclipse IDE you can do that automatically by going to the project
properties->Java Build Path->Select and expand the jsyn.jar->Native library
location->Edit..->enter the path to the .dll file

Im not sure why it dosent work when put into the MT4j root folder because that 
folder
is already added as a library path..anyway, this way should work.

Original comment by sirhc.f...@gmail.com on 31 Mar 2010 at 11:24

GoogleCodeExporter commented 8 years ago
Thanks for your help. Of cause I am using eclipse.
I changed the Native library location and i works know.
I changed it to the Project-Root-folder (where the other dlls are and where the
JSyn.dll is as well). It works the same way when i change it to C:\Windows

I don't unterstand why the project-root is not a Native library location by 
default
as it is in other projects (like in my JSyn test Project)....

So you might want to investigate why it is not working by default with the Mt4J 
root
folder or you might write it in the tutorial that you have to edit the path 
manually
for other progammers who have the same issue

Thank you very much! Great project! *Frauenhofer rulez* ;)

Original comment by maigra...@googlemail.com on 1 Apr 2010 at 10:05

GoogleCodeExporter commented 8 years ago

Original comment by sirhc.f...@gmail.com on 5 Apr 2010 at 8:40