Help compiling for the Mac

classic Classic list List threaded Threaded
37 messages Options
12
CRP
Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

CRP
Changing origin coordinates in .ini file worked.

I will now look into making a fink package for PianoBooster. This way everybody should be able to easily build PianoBooster on the mac regardless of architecture and dependencies.

I will keep you updated, also with regards to the new version.

Chris
CRP
Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

CRP
In reply to this post by Louis B.
About the latest beta: it does not compile on osx out of the box, I still have to add the full path to header files in Draw.h and remove the alsa defines...
Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

lestatcheb
In reply to this post by Louis B.
new version also need fix for GL headers and alsa.
how to fine fix alsa I don't know, I simple replace with old version file CMakeLists.txt.
and this don't compiling.

sh-3.2# make
[  2%] Generating ui_GuiKeyboardSetupDialog.h
[  4%] Generating moc_QtWindow.cxx
[  6%] Generating moc_GlView.cxx
[  9%] Generating moc_GuiTopBar.cxx
[ 11%] Generating moc_GuiSidePanel.cxx
[ 13%] Generating moc_GuiMidiSetupDialog.cxx
[ 16%] Generating moc_GuiKeyboardSetupDialog.cxx
[ 18%] Generating qrc_application.cxx
[ 20%] Generating ui_GuiTopBar.h
/Volumes/lestat/temp/svn/PianoBooster/src/GuiTopBar.ui: An invalid icon property 'windowIcon' was encountered.
[ 23%] Generating ui_GuiSidePanel.h
[ 25%] Generating ui_GuiMidiSetupDialog.h
Scanning dependencies of target pianobooster
[ 27%] Building CXX object CMakeFiles/pianobooster.dir/QtMain.o
In file included from /Volumes/lestat/temp/svn/PianoBooster/src/QtWindow.h:38,
                 from /Volumes/lestat/temp/svn/PianoBooster/src/QtMain.cpp:24:
/Volumes/lestat/temp/svn/PianoBooster/src/GuiPreferencesDialog.h:38:37: error: ui_GuiPreferencesDialog.h: No such file or directory
/Volumes/lestat/temp/svn/PianoBooster/src/GuiPreferencesDialog.h:43: error: expected class-name before '{' token
make[2]: *** [CMakeFiles/pianobooster.dir/QtMain.o] Error 1
make[1]: *** [CMakeFiles/pianobooster.dir/all] Error 2
make: *** [all] Error 2

------------------

Louis B.,

> Do you mean the sound of the midi piano part within the midi music file or do you mean the sound of your own playing on the piano?

I mean the midi piano part from midi file.

My own playing I hear.

P.S. I have Intel Mac.

Thanks.
CRP
Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

CRP
lestatcheb, you just have to:

1) edit src/Draw.h, by replacing

#include <GL/gl.h>
#include <GL/glu.h>

with

#include "/System/Library/Frameworks/OpenGL.framework/Headers/gl.h"
#include "/System/Library/Frameworks/OpenGL.framework/Headers/glu.h"

For Louis: as of now I have no idea how header search paths work with Frameworks. I tried <OpenGL.framework/Headers/gl.h>, <Headers/gl.h> and <Library/OpenGL.framework/Headers/gl.h> but none of these worked.

2) edit src/CMakeFile.txt, by commenting the line

ADD_DEFINITIONS(-Wall -g -D__LINUX_ALSASEQ__)

For Louis: this is inside an "else(win32)" section. I do not know cmake syntax, but would it be possible to replace the else with an "if(linux)" or something like that?

then it compiles fine.

Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

lestatcheb
ok, revision 33

with
#include "/System/Library/Frameworks/OpenGL.framework/Headers/gl.h"
#include "/System/Library/Frameworks/OpenGL.framework/Headers/glu.h"

and commenting
ADD_DEFINITIONS(-Wall -g -D__LINUX_ALSASEQ__)

fine work.

but also on my mac not play midi part from midi file.
maybe I need something tuning in my system...
itunes midi files playing fine.
Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

Louis B.
Administrator
Hi lestatcheb and Christian,

I have just checked in revision 34 for you to try please see this link.

http://pianobooster.svn.sourceforge.net/viewvc/pianobooster/trunk/PianoBooster/src/CMakeLists.txt?view=markup

I have changed the order in these files which hopefully would help.

The critical line is on line 56

INCLUDE_DIRECTORIES( ${CMAKE_BINARY_DIR} ${OPENGL_INCLUDE_DIR})

which if comment commented out I get exactly the same errors as you (GuiPreferencesDialog.h:38:37: error: ui_GuiPreferencesDialog.h: No such file or directory )

If this does not work perhaps you could email me your best working version of CMakeLists.txt.


Regarding your sound problems it is meant to mute the current part in follow mode so that you can play that part yourself. (unckecking the "mute your part when playing" in the beta allows you to hear the current part)

If you have other sound problems then try uncommenting line 183 in file MidiDevice.cpp to dump the midi events to the console.

    //event.printDetails(); // usefull for debuging

Thanks

L o u i s
CRP
Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

CRP
Louis, I found that in order to get rev 34 to compile on the mac out of the box you need to modify Draw.h with these lines:

#ifdef __APPLE__
  #include <OpenGL/gl.h>
  #include <OpenGL/glu.h>
#else
  #include <GL/gl.h>
  #include <GL/glu.h>
#endif

Ok, now I will start working on the fink package ;)
Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

Louis B.
Administrator
Brilliant, just up dated to rev 35

Try deleting the ini file does it start up ok now?

lestatcheb does rev 35 compile OK on your Intel Mac?

L o u i s
Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

lestatcheb
Louis B.,

yes, rev 35 compile ok out the box! fine!


but I still in skill "Listen" can't listen the midi part from midi part :(

click checkbox "Listen", click button "play" and just listen silence...


Thanks!
Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

Louis B.
Administrator
Hi lestatcheb,

Just updated to (rev 36) to use RtMidi 1.0.8 just incase this helps.


Does any other program work with the SimpleSynth that you are using. please can you try SimpleSynth using a different midi file player so we know SimpleSynth works OK on your machine.

Have you tried PB with different midi files eg the
EasyToPlayDemoMidiFiles.zip on this page

http://www.pianobooster.pwp.blueyonder.co.uk/

It might also be useful to compile and run Rtmidi available from this page

http://www.music.mcgill.ca/~gary/rtmidi/index.html#download

in the test dir run ./midiout and you should hear a single note on the piano.

Hope this helps

Louis


Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

lestatcheb
I'm compile rtmidi, try midiout, but not hear any note.

sh-3.2# ./midiout

Would you like to open a virtual output port? [y/N]
  Output port #0: USB Keystation 61es
  Output port #1: SimpleSynth virtual input

Choose a port number: 0


I try and 0, and 1.


h-3.2# ./midiprobe

There are 1 MIDI input sources available.
  Input Port #1: USB Keystation 61es

There are 2 MIDI output ports available.
  Output Port #1: USB Keystation 61es
  Output Port #2: SimpleSynth virtual input


Also I try playing different midi files in Piano Booster, not hear music when it playing midi file.
All midi files in iTunes playing fine.
Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

Louis B.
Administrator
Sorry, I am running out ideas. It looks like a problem with your SimpleSynth setup. but as i don't have a Mac so I cannot really help you further. I don't think that iTunes uses SimpleSynth. You need to try/test out SimpleSynth with another program e.g. midi sequencer. Maybe there are some other Mac users out there that can help you.

Thanks

L o u i s
Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

Louis B.
Administrator
In reply to this post by lestatcheb
Does this help.

from Pete Yandell

From the thread, I can guess what's happening.

He needs to:

a) Select "SimpleSynth virtual input" as the MIDI Source in SimpleSynth (it will probably default to his USB Keystation 61es)
b) Select "SimpleSynth virtual input" as the Output port when he runs midioout

I think he's done b, but not a.

He says he can play the MIDI files in iTunes, but that doesn't really tell you anything, as iTunes plays MIDI files directly. It doesn't send them to SimpleSynth.

Pete Yandell
http://notahat.com/
Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

lestatcheb
Louis B. wrote
a) Select "SimpleSynth virtual input" as the MIDI Source in SimpleSynth (it will probably default to his USB Keystation 61es)
b) Select "SimpleSynth virtual input" as the Output port when he runs midioout
Thanks!

This works :)

Now PianoBooster plays midi files fine!
CRP
Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

CRP
Hi lestatcheb, do you use fink? If yes, can I send you a pianobooster.info file to test?
Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

lestatcheb
CRP wrote
Hi lestatcheb, do you use fink? If yes, can I send you a pianobooster.info file to test?
yes, I use fink, please send .info at my mail lestatcheb@gmail.com
Reply | Threaded
Open this post in threaded view
|

Re: Help compiling for the Mac

romul
In reply to this post by Louis B.
MAC developers are welcome: https://github.com/captnfab/PianoBooster
12