<?xml version="1.0"?>
<rss version="2.0">
	<channel>
		<title>Linux 24 bit depth issue</title>
		<link>http://www.allegro.cc/forums/view/618796</link>
		<description>Allegro.cc Forum Thread</description>
		<webMaster>matthew@allegro.cc (Matthew Leverton)</webMaster>
		<lastBuildDate>Sun, 19 Mar 2023 22:24:49 +0000</lastBuildDate>
	</channel>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Im doing some basic low level things with allegro like locking bitmaps and manipulating the memory inside.<br />The thing is that linux says it&#39;s in 24 bit depth and i drive my things in 32 bit depths. I need 32 bit support for linux. <br />I have searched how to change config to linux to 32 bit depth but nothing answer my question.<br />So how do i do 32 bit dev in linux?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Lucas Dalmasso)</author>
		<pubDate>Sat, 18 Mar 2023 01:54:54 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>Have you tried using al_set_new_bitmap_flags and choosing one of the 32-but flags ?
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Dizzy Egg)</author>
		<pubDate>Sat, 18 Mar 2023 20:19:03 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>IIRC you either get 24 or 32 bit modes depending on the system. You should be able to create a video bitmap with 32 bits in any case and work on that.</p><p>But trying to force it as Dizzy Egg suggested is worth a try.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Polybios)</author>
		<pubDate>Sun, 19 Mar 2023 22:14:23 +0000</pubDate>
	</item>
	<item>
		<description><![CDATA[<div class="mockup v2"><p>It&#39;s possible your machine doesn&#39;t support 32-bit depth.  My MacBook Pro M1 has a 32-bit depth, but my MacMini only has 24.  Same with my Windows laptop which only supports 24-bit depth.  All of them are relatively new devices.</p><p>Similar to what Dizzy said, you can pass <span class="source-code"><span class="n">32</span></span> when creating your display and see if it sticks:
</p><div class="source-code snippet"><div class="inner"><pre><span class="k1">int</span> preferred_depth_size <span class="k3">=</span> <span class="n">32</span><span class="k2">;</span>
<a href="http://www.allegro.cc/manual/al_set_new_display_option"><span class="a">al_set_new_display_option</span></a><span class="k2">(</span>ALLEGRO_DEPTH_SIZE, preferred_depth_size, ALLEGRO_SUGGEST<span class="k2">)</span><span class="k2">;</span>
<a href="http://www.allegro.cc/manual/ALLEGRO_DISPLAY"><span class="a">ALLEGRO_DISPLAY</span></a> <span class="k3">*</span>al_display <span class="k3">=</span> <a href="http://www.allegro.cc/manual/al_create_display"><span class="a">al_create_display</span></a><span class="k2">(</span><span class="n">1920</span>, <span class="n">1080</span><span class="k2">)</span><span class="k2">;</span>
<span class="k1">if</span> <span class="k2">(</span><span class="k3">!</span>al_display<span class="k2">)</span> print<span class="k2">(</span><span class="s">"Display could not be created"</span><span class="k2">)</span><span class="k2">;</span>
<span class="k1">int</span> actual_depth_size <span class="k3">=</span> <a href="http://www.allegro.cc/manual/al_get_display_option"><span class="a">al_get_display_option</span></a><span class="k2">(</span>al_display, ALLEGRO_DEPTH_SIZE<span class="k2">)</span><span class="k2">;</span>

<a href="http://www.delorie.com/djgpp/doc/libc/libc_624.html" target="_blank">printf</a><span class="k2">(</span><span class="s">"Display depth info:\n  - expected:%d\n  - actual:%d"</span>, preferred_depth_size, actual_depth_size<span class="k2">)</span><span class="k2">;</span>
</pre></div></div><p>

What do you need specifically a 32 bit depth for, I&#39;m curious.
</p></div>]]>
		</description>
		<author>no-reply@allegro.cc (Mark Oates)</author>
		<pubDate>Sun, 19 Mar 2023 22:24:49 +0000</pubDate>
	</item>
</rss>
