From: Dominique F. <fo...@gr...> - 2015-11-28 07:27:10
|
Hi Robert, The java GuidoViewer doesn’t support MusicXML format natively (nor the Guido Engine) but through conversion to GMN format. There is a tool for that, named xml2guido, which is part of the libmusicxml library. See at : https://github.com/dfober/libmusicxml <https://github.com/dfober/libmusicxml> Note that the library provides also an API for the conversion but yet there is no JNI. Best, — Dominique > Le 27 nov. 2015 à 23:05, Robert Jobbagy <job...@gm...> a écrit : > > Hi Dominique, > > Thanks your help, it compiled and run , but when I downloaded some example xml from here : > > http://www.musicxml.com/music-in-musicxml/example-set/ <http://www.musicxml.com/music-in-musicxml/example-set/> > > It didn't works :( > > I saw this in command line : > > cd .. && javac guidoviewer.java > Note: guidoviewer.java uses or overrides a deprecated API. > Note: Recompile with -Xlint:deprecation for details. > cd .. && java -Djava.library.path=build guidoviewer > GUIDOEngine version 1.5.7 - JNI interface version 1.2.1 initialized. > error line: 1 col: 1: syntax error, unexpected STARTPARAM, expecting STARTSEQ > error line: 1 col: 1: syntax error, unexpected STARTPARAM, expecting STARTSEQ > error line: 1 col: 1: syntax error, unexpected STARTPARAM, expecting STARTSEQ > error line: 1 col: 1: syntax error, unexpected STARTPARAM, expecting STARTSEQ > > and on gui wrote that is a memory error. > > What's wrong ? Maybe wrong xml format ? > > > 2015-11-27 10:30 GMT+01:00 Dominique Fober <fo...@gr... <mailto:fo...@gr...>>: > >> Le 27 nov. 2015 à 10:16, Robert Jobbagy <job...@gm... <mailto:job...@gm...>> a écrit : >> >> Hi Dominique, >> >> I download guido jdk from sourceforge it's GuidoJava-v.1.23 and I download latest src from sourceforge too and made .so. > > I didn’t check with the jdk but with the ‘dev' branch of the src code. > could you try try the following (from the root of the repo and from the ‘dev’ branch) : > > cd build > > make linux > > sudo make -C linux install > > cd ../lang/java/build > > make > > make guidoviewer > >> >> First System.load is working but guido.init throw this error. >> >> 2015-11-27 9:37 GMT+01:00 Dominique Fober <fo...@gr... <mailto:fo...@gr...>>: >> Hi Robert, >> >> I’ve just tried on ubuntu (version 14.04 but I don’t think it matters) and it works on my side. >> What version of guido are you using ? did you download the latest guido jdk from sourceforge ? (GuidoJava-v.1.23) >> or are you using the src code from the git repository ? >> — >> Dominique >> >> >> > Le 27 nov. 2015 à 01:26, Robert Jobbagy <job...@gm... <mailto:job...@gm...>> a écrit : >> > >> > Hi Guys, >> > >> > I try to use GUIDO lib with java on linux (Ubuntu 15.04). >> > >> > I have a problem in guidoviewer.java static constructor : >> > >> > static { >> > try { >> > System.setProperty("java.library.path", "/usr/lib/"); >> > System.loadLibrary("GUIDOEngine"); >> > System.err.println("Native lib loading success"); >> > guido.Init("Guido2", "Times"); // guido engine initailization is required before calling any guidoscore API >> > if (guido.xml2gmn()) // check if musicxml support is available >> > System.out.println("libMusicXML v." + guido.musicxmlversion() + >> > " with GMN converter v." + guido.musicxml2guidoversion()); >> > } catch (UnsatisfiedLinkError e) { >> > System.err.println("Native code library failed to load.\n" + e); >> > System.exit(-1); >> > } >> > } >> > >> > It's failed when guido.init called I see this Exception : >> > >> > Native lib loading success >> > GUIDOEngine native code library initialization failed. >> > java.lang.UnsatisfiedLinkError: guidoengine.guidolayout.Init()V >> > Native code library failed to load. >> > java.lang.UnsatisfiedLinkError: guidoengine.guido.Init(Ljava/lang/String;Ljava/lang/String;)I >> > >> > What's wrong ? >> > >> > Thanks your time. >> > >> > -- >> > Best Regards, >> > >> > Robert >> > ------------------------------------------------------------------------------ >> > _______________________________________________ >> > Guidolib-devel mailing list >> > Gui...@li... <mailto:Gui...@li...> >> > https://lists.sourceforge.net/lists/listinfo/guidolib-devel <https://lists.sourceforge.net/lists/listinfo/guidolib-devel> >> >> >> >> >> -- >> Best Regards, >> >> Robert > > > > > -- > Best Regards, > > Robert |