<?xml version="1.0"?>
<rss version="2.0">
	<channel>
		<title>Does get_gfx_mode_list work with AllegroGL?</title>
		<link>http://www.allegro.cc/forums/view/586549</link>
		<description>Allegro.cc Forum Thread</description>
		<webMaster>matthew@allegro.cc (Matthew Leverton)</webMaster>
		<lastBuildDate>Mon, 24 Jul 2006 21:37:45 +0000</lastBuildDate>
	</channel>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>I&#39;m using some code based on a snippet ReyBrujo posted some time ago.</p><p>First I get the list of drivers and write them out to a logifle and I get these options:
</p><div class="quote_container"><div class="title">Quote:</div><div class="quote"><p>
name: AllegroGL Windowed (Win32)<br />ID: 1330072663<br />name: AllegroGL Fullscreen (Win32)<br />ID: 1330072646<br />name: AllegroGL Default Driver<br />ID: 1330072644
</p></div></div><p>

However, when I call get_gfx_mode_list with any of these ID&#39;s it just returns NULL indicating failure. I get the same thing when I try to use the DIRECTX drivers instead.</p><p>Anyone else had this problem?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Richard Phipps)</author>
		<pubDate>Wed, 19 Jul 2006 16:12:11 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>A little example program would help. And yes, it should work. Did you init allegro and allegroGL?</p><p>Also, from the manual: &quot;Note that the card parameter must refer to a <u>real</u> driver. this  function  fails  if you pass GFX_SAFE, GFX_AUTODETECT, or any other &quot;magic&quot; driver.&quot;
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Milan Mimica)</author>
		<pubDate>Thu, 20 Jul 2006 00:21:01 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>I don&#39;t think we implemented this, but it would be trivial to do so - AGL already builds up a list internally to pick the right graphics mode.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Bob)</author>
		<pubDate>Mon, 24 Jul 2006 00:37:27 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>
I might as well ask. Is AllegroGL still being worked on Bob?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Richard Phipps)</author>
		<pubDate>Mon, 24 Jul 2006 02:45:41 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Yes, but not by me.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Bob)</author>
		<pubDate>Mon, 24 Jul 2006 02:49:09 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>
Oh.. <img src="http://www.allegro.cc/forums/smileys/sad.gif" alt=":(" /></p><p>Who is now working on it then?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Richard Phipps)</author>
		<pubDate>Mon, 24 Jul 2006 02:49:57 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Elias, Peter and me mostly.</p><p>get_gfx_mode_list is implemented. I did it for Windows. At least it should work with DirecX drivers which has nothing to do with AGL.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Milan Mimica)</author>
		<pubDate>Mon, 24 Jul 2006 12:45:21 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>
I&#39;ve found the directX part, but I presume their needs to be an equal part in the OpenGL side.</p><p>What are the plans for AllegroGL then? <img src="http://www.allegro.cc/forums/smileys/smiley.gif" alt=":)" />
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Richard Phipps)</author>
		<pubDate>Mon, 24 Jul 2006 13:34:34 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>So, does get_gfx_mode_list(GFX_OPENGL_FULLSCREEN) return something other than NULL, like it is supposed to?</p><p>The plan is to release AllegroGL-0.4.0 when Allegro-4.2.1 comes out. AGL-0.4.0 will work only with Allegro &gt;= 4.2.0. Then I don&#39;t know, AGL should be merged in Allegro as a ordinary display driver.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Milan Mimica)</author>
		<pubDate>Mon, 24 Jul 2006 17:36:19 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>
I tried the 3 ID&#39;s I found:
</p><div class="source-code snippet"><div class="inner"><pre>name: AllegroGL Windowed <span class="k2">(</span>Win32<span class="k2">)</span>
ID: <span class="n">1330072663</span>
name: AllegroGL Fullscreen <span class="k2">(</span>Win32<span class="k2">)</span>
ID: <span class="n">1330072646</span>
name: AllegroGL Default Driver
ID: <span class="n">1330072644</span>
</pre></div></div><p>
But none of them worked. I didn&#39;t try GFX_OPENGL_FULLSCREEN, but that seems to be the second choice.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Richard Phipps)</author>
		<pubDate>Mon, 24 Jul 2006 17:43:21 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>This works for me:
</p><div class="source-code"><div class="toolbar"></div><div class="inner"><table width="100%"><tbody><tr><td class="number">1</td><td><span class="p">#define ALLEGRO_USE_CONSOLE 1</span></td></tr><tr><td class="number">2</td><td>&#160;</td></tr><tr><td class="number">3</td><td><span class="p">#include &lt;allegro.h&gt;</span></td></tr><tr><td class="number">4</td><td><span class="p">#include &lt;alleggl.h&gt;</span></td></tr><tr><td class="number">5</td><td><span class="p">#include &lt;stdio.h&gt;</span></td></tr><tr><td class="number">6</td><td>&#160;</td></tr><tr><td class="number">7</td><td><span class="k1">int</span> main<span class="k2">(</span><span class="k2">)</span></td></tr><tr><td class="number">8</td><td><span class="k2">{</span></td></tr><tr><td class="number">9</td><td>  <a href="http://www.allegro.cc/manual/GFX_MODE_LIST" target="_blank"><span class="a">GFX_MODE_LIST</span></a> <span class="k3">*</span>l<span class="k2">;</span></td></tr><tr><td class="number">10</td><td>  </td></tr><tr><td class="number">11</td><td>  <a href="http://www.allegro.cc/manual/allegro_init" target="_blank"><span class="a">allegro_init</span></a><span class="k2">(</span><span class="k2">)</span><span class="k2">;</span></td></tr><tr><td class="number">12</td><td>  install_allegro_gl<span class="k2">(</span><span class="k2">)</span><span class="k2">;</span></td></tr><tr><td class="number">13</td><td>  </td></tr><tr><td class="number">14</td><td>  l <span class="k3">=</span> <a href="http://www.allegro.cc/manual/get_gfx_mode_list" target="_blank"><span class="a">get_gfx_mode_list</span></a><span class="k2">(</span><span class="n">1330072646</span><span class="k2">)</span><span class="k2">;</span></td></tr><tr><td class="number">15</td><td>  <a href="http://www.delorie.com/djgpp/doc/libc/libc_624.html" target="_blank">printf</a><span class="k2">(</span><span class="s">"%i\n"</span>, l<span class="k2">)</span><span class="k2">;</span></td></tr><tr><td class="number">16</td><td>  <a href="http://www.delorie.com/djgpp/doc/libc/libc_624.html" target="_blank">printf</a><span class="k2">(</span><span class="s">"%i\n"</span>, l-&gt;num_modes<span class="k2">)</span><span class="k2">;</span></td></tr><tr><td class="number">17</td><td>  </td></tr><tr><td class="number">18</td><td>  <span class="k1">return</span> <span class="n">0</span><span class="k2">;</span></td></tr><tr><td class="number">19</td><td><span class="k2">}</span></td></tr><tr><td class="number">20</td><td><a href="http://www.allegro.cc/manual/END_OF_MAIN" target="_blank"><span class="a">END_OF_MAIN</span></a><span class="k2">(</span><span class="k2">)</span></td></tr></tbody></table></div></div><p>

Quering mode list of other two drivers makes no sense because the first one supports any resolution (window sizes) and the third one is ambiguous.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Milan Mimica)</author>
		<pubDate>Mon, 24 Jul 2006 19:47:44 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>
The only thing that might be important is I tried this with OpenLayer (about setting up Allegro and OpenLayer, but before opening a screen).</p><p>I just got 0 or NULL back from get_gfx_mode_list.. <img src="http://www.allegro.cc/forums/smileys/undecided.gif" alt=":-/" />
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Richard Phipps)</author>
		<pubDate>Mon, 24 Jul 2006 19:52:10 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>You didn&#39;t mention the version of AGL you are using. 0.4.0RC4 should do, older versions won&#39;t work because it was implemented recently.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Milan Mimica)</author>
		<pubDate>Mon, 24 Jul 2006 21:33:56 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>
Ah! It might be that. I just use OpenLayer, so not sure what version it links into. The .a file in the OpenLayer folders seems to be about a year old though..</p><p>I&#39;m not sure if OpenLayer works with the newest AllegroGL lib. I&#39;ve always been reluctant to use new versions of libraries while I&#39;m in the middle of a project using them! <img src="http://www.allegro.cc/forums/smileys/smiley.gif" alt=":)" />
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Richard Phipps)</author>
		<pubDate>Mon, 24 Jul 2006 21:37:45 +0000</pubDate>
	</item>
</rss>
