<?xml version="1.0"?>
<rss version="2.0">
	<channel>
		<title>[A5] Mac magic main initialization</title>
		<link>http://www.allegro.cc/forums/view/611721</link>
		<description>Allegro.cc Forum Thread</description>
		<webMaster>matthew@allegro.cc (Matthew Leverton)</webMaster>
		<lastBuildDate>Sat, 29 Dec 2012 21:07:46 +0000</lastBuildDate>
	</channel>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Hello,<br />  I was trying to get Allegro 5 working on a Mac<br />with the allua Lua bindings.  The allua dynamic library<br />compiles fine, but when trying to call al_create_display()<br />via the Lua allegro5.display.create() binding, I get<br />the following exception:</p><p>Initialized allegro<br />2012-12-28 23:08:46.916 lua[60096:707] *** Terminating app due to uncaught exception &#39;NSInternalInconsistencyException&#39;, reason: &#39;Error (1000) creating CGSWindow on line 259&#39;</p><p>I&#39;m assuming this is because the lua script does not<br />go through the proper Allegro magic main initialization.<br />Does anyone know if there is a way to make explicit function<br />calls to initialize the Allegro NSApplication properly<br />on Mac OS X?<br />Thanks!
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (DanielDLee)</author>
		<pubDate>Sat, 29 Dec 2012 10:11:59 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Yes, <span class="source-code"><a href="http://www.allegro.cc/manual/al_run_main"><span class="a">al_run_main</span></a></span>. It will never return, but you pass it a C function which we be called from another thread. Call al_init and so on from that other function then as if it was your main() function.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Elias)</author>
		<pubDate>Sat, 29 Dec 2012 21:07:46 +0000</pubDate>
	</item>
</rss>
