forked from liballeg/allegro5
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathREADME_macosx.txt
57 lines (42 loc) · 2.31 KB
/
README_macosx.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
Mac OS X-specific notes
=======================
Building Allegro on Mac OS X is the same as on other Unix-like operating systems.
See README_make.txt.
Building with Xcode
-------------------
You may also use Xcode to build Allegro. This works similar to the instructions
in README_make.txt, except add the parameter -GXcode when invoking cmake.
Instead of creating a makefile this will create an Xcode project which you can
double click and open in Xcode and then hit the arrow button to compile.
Using the Clang compiler (OS X 10.6+)
-------------------------------------
It is possible to build Allegro using the Clang compiler that ships with OS
X 10.6 (Snow Leopard). Clang is installed in /Developer/usr/bin.
To use it, you have to tell Cmake to use Clang instead of gcc. From the
terminal, this is most easily accomplished by the commands
export PATH=/Developer/usr/bin:$PATH
export CC=clang
before you run Cmake. If you use the graphical version of Cmake, you will
be given the option of selecting the C compiler to use. Simply select
/Developer/usr/bin/clang.
The installation otherwise continues as usual.
Retina display support (OS X 10.7+)
-----------------------------------
Allegro has an option to support high DPI displays by treating them as a regular
high-resolution display. To do so, use XCode to set the NSHighResolutionCapable
property in the Info.plist of your bundled app to YES. Alternatively, add these
two lines to the Info.plist using a text editor:
<key>NSHighResolutionCapable</key>
<true/>
If you are making an unbundled app this feature appears to be enabled by
default, but it is not recommended to rely on this working: make a bundled
app for the most predictable performance.
When changing the display DPI or moving the window between two displays with
different DPIs, Allegro displays behave in the following way:
- If the ALLEGRO_DISPLAY was created with the ALLEGRO_RESIZABLE flag it will
send an ALLEGRO_DISPLAY_RESIZE event. This will have the effect of your app's
window remaining visually the same, while the display size in pixels will
increase or decrease. This is the recommended situation.
- If the ALLEGRO_DISPLAY was not created with the ALLEGRO_RESIZABLE flag, then
the display size in pixels will remain the same, but the app's window will
appear to grow or shrink.