<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.1" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>cocos2d for iPhone &#187; Tag: unloadBuffer - Recent Topics</title>
		<link>http://www.cocos2d-iphone.org/forum/tags/unloadbuffer</link>
		<description>A fast, easy to use, free, and community supported 2D game engine</description>
		<language>en-US</language>
		<pubDate>Fri, 10 Feb 2012 04:24:49 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.1</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>http://www.cocos2d-iphone.org/forum/search.php</link>
		</textInput>
		<atom:link href="http://www.cocos2d-iphone.org/forum/rss/tags/unloadbuffer/topics" rel="self" type="application/rss+xml" />

		<item>
			<title>Blue Ether on "&quot;error deleting buffer&quot;"</title>
			<link>http://www.cocos2d-iphone.org/forum/topic/4350#post-25999</link>
			<pubDate>Mon, 08 Feb 2010 20:37:29 +0000</pubDate>
			<dc:creator>Blue Ether</dc:creator>
			<guid isPermaLink="false">25999@http://www.cocos2d-iphone.org/forum/</guid>
			<description><p>So, I've previously been using my own OpenAL code but I recently started using CD instead, because I didn't have anything written to clean up and reload sounds.  We're adding levels to a game and will have many sounds for each level with little to no overlap.  So, I'm writing code so that all the buffers are cleared and then reloaded when a new level is loaded.</p>
<p>Problem I'm getting is that some buffers refuse to unload.  Im stopping all sounds prior to the unload loop, which iterates through the 32 buffers and calls unloadBuffer on each.  The log results are as follows:<br />
<pre><code>2010-02-08 15:14:17.444 [5686:207] Denshion error deleting buffer: a003
2010-02-08 15:14:17.445 [5686:207] Denshion buffer 1 successfully unloaded
2010-02-08 15:14:17.445 [5686:207] Denshion buffer 2 successfully unloaded
2010-02-08 15:14:17.445 [5686:207] Denshion error deleting buffer: a004
2010-02-08 15:14:17.446 [5686:207] Denshion error deleting buffer: a004
2010-02-08 15:14:17.446 [5686:207] Denshion error deleting buffer: a004
2010-02-08 15:14:17.447 [5686:207] Denshion buffer 6 successfully unloaded
2010-02-08 15:14:17.447 [5686:207] Denshion buffer 7 successfully unloaded
2010-02-08 15:14:17.447 [5686:207] Denshion buffer 8 successfully unloaded
2010-02-08 15:14:17.448 [5686:207] Denshion buffer 9 successfully unloaded
2010-02-08 15:14:17.448 [5686:207] Denshion buffer 10 successfully unloaded
2010-02-08 15:14:17.448 [5686:207] Denshion buffer 11 successfully unloaded
2010-02-08 15:14:17.449 [5686:207] Denshion buffer 12 successfully unloaded
2010-02-08 15:14:17.449 [5686:207] Denshion buffer 13 successfully unloaded
2010-02-08 15:14:17.449 [5686:207] Denshion buffer 14 successfully unloaded
2010-02-08 15:14:17.450 [5686:207] Denshion buffer 15 successfully unloaded
2010-02-08 15:14:17.450 [5686:207] Denshion buffer 16 successfully unloaded
2010-02-08 15:14:17.451 [5686:207] Denshion buffer 17 successfully unloaded
2010-02-08 15:14:17.451 [5686:207] Denshion buffer 18 successfully unloaded
2010-02-08 15:14:17.452 [5686:207] Denshion buffer 19 successfully unloaded
2010-02-08 15:14:17.452 [5686:207] Denshion buffer 20 successfully unloaded
2010-02-08 15:14:17.453 [5686:207] Denshion buffer 21 successfully unloaded
2010-02-08 15:14:17.453 [5686:207] Denshion buffer 22 successfully unloaded
2010-02-08 15:14:17.453 [5686:207] Denshion buffer 23 successfully unloaded
2010-02-08 15:14:17.454 [5686:207] Denshion buffer 24 successfully unloaded
2010-02-08 15:14:17.454 [5686:207] Denshion buffer 25 successfully unloaded
2010-02-08 15:14:17.455 [5686:207] Denshion buffer 26 successfully unloaded
2010-02-08 15:14:17.455 [5686:207] Denshion buffer 27 successfully unloaded
2010-02-08 15:14:17.455 [5686:207] Denshion buffer 28 successfully unloaded
2010-02-08 15:14:17.456 [5686:207] Denshion buffer 29 successfully unloaded
2010-02-08 15:14:17.457 [5686:207] Denshion buffer 30 successfully unloaded
2010-02-08 15:14:17.457 [5686:207] Denshion buffer 31 successfully unloaded</code></pre>
<p>If I leave out the unload and instead let loadBuffer handle the unloadBuffer call, I get the same errors.  For example:</p>
<pre><code>2010-02-08 15:14:17.480 [5686:a517] Denshion: Loading openAL buffer 0 tap.caf
2010-02-08 15:14:17.487 [5686:a517] Denshion: non empty buffer, regenerating
2010-02-08 15:14:17.488 [5686:a517] Denshion: error deleting buffer: a004</code></pre>
<p>Since I stop all sounds prior to unloading, I don't imagine the sound playing to be an issue.</p>
<p>Each time I unload and load buffers, more of them throw errors on load.</p>
<p>Anyone have experience with this or have any suggestions?  Much appreciated.
</p></description>
		</item>

	</channel>
</rss>

