<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Mit MCI WAVE-Datei aufnehmen]]></title><description><![CDATA[<p>Ja hallo, ich bins schon wieder.</p>
<p>Mein Problem diesmal nicht so gravierend, es fehlt nur der letzte Hinweis.<br />
Und zwar, ich habe eigentlich schon alles geschafft:<br />
- Ich kann aufnehmen<br />
- Ich kann speichern</p>
<p>Aber:</p>
<p>- Der Media-Player will die Datei nicht abspielen!<br />
(Nero Wave-Editor &amp; Audio Recoder tun das!)</p>
<p>Hier erstmal mein Code:<br />
[cpp]Case IDREC:<br />
mciSendString(&quot;OPEN NEW TYPE WAVEAUDIO ALIAS mysound&quot;, NULL, 0, NULL);<br />
mciSendString(&quot;SET mysound TIME FORMAT MILLISECONDS BITSPERSAMPLE 16 CHANNELS 2 SAMPLESPERSEC 44100 BYTESPERSEC 5000 ALIGNMENT 4&quot;,NULL,128,NULL);<br />
mciSendString(&quot;RECORD mysound&quot;, NULL, 0, NULL);<br />
return TRUE;</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/153704/mit-mci-wave-datei-aufnehmen</link><generator>RSS for Node</generator><lastBuildDate>Thu, 23 Jul 2026 08:33:32 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/153704.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 19 Jul 2006 21:04:44 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Mit MCI WAVE-Datei aufnehmen on Wed, 19 Jul 2006 21:04:44 GMT]]></title><description><![CDATA[<p>Ja hallo, ich bins schon wieder.</p>
<p>Mein Problem diesmal nicht so gravierend, es fehlt nur der letzte Hinweis.<br />
Und zwar, ich habe eigentlich schon alles geschafft:<br />
- Ich kann aufnehmen<br />
- Ich kann speichern</p>
<p>Aber:</p>
<p>- Der Media-Player will die Datei nicht abspielen!<br />
(Nero Wave-Editor &amp; Audio Recoder tun das!)</p>
<p>Hier erstmal mein Code:<br />
[cpp]Case IDREC:<br />
mciSendString(&quot;OPEN NEW TYPE WAVEAUDIO ALIAS mysound&quot;, NULL, 0, NULL);<br />
mciSendString(&quot;SET mysound TIME FORMAT MILLISECONDS BITSPERSAMPLE 16 CHANNELS 2 SAMPLESPERSEC 44100 BYTESPERSEC 5000 ALIGNMENT 4&quot;,NULL,128,NULL);<br />
mciSendString(&quot;RECORD mysound&quot;, NULL, 0, NULL);<br />
return TRUE;</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1100652</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1100652</guid><dc:creator><![CDATA[-=Chris=-]]></dc:creator><pubDate>Wed, 19 Jul 2006 21:04:44 GMT</pubDate></item><item><title><![CDATA[Reply to Mit MCI WAVE-Datei aufnehmen on Wed, 19 Jul 2006 21:06:42 GMT]]></title><description><![CDATA[<p>[/cpp]</p>
<pre><code class="language-cpp">case IDSTOP:
mciSendString(&quot;STOP mysound&quot;, NULL, 0, NULL);
return TRUE;

case 3:
mciSendString(&quot;SAVE mysound test.wav&quot;, NULL, 0, NULL);
mciSendString(&quot;CLOSE mysound&quot;, NULL, 0, NULL);
return TRUE;
</code></pre>
<p>Ich denke ich mache was bei dem Setzen der Eigenschaften was falsch, aber vielleciht weiß einer Rat.</p>
<p>mfg Chris</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1100654</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1100654</guid><dc:creator><![CDATA[-=Chris=-]]></dc:creator><pubDate>Wed, 19 Jul 2006 21:06:42 GMT</pubDate></item><item><title><![CDATA[Reply to Mit MCI WAVE-Datei aufnehmen on Wed, 19 Jul 2006 22:14:38 GMT]]></title><description><![CDATA[<p>So ist das schwer nachvollziehbar...prüf mal die Return Werte, um den Fehler zu lokalisieren.</p>
<p>Etwas genauer: Wann tritt der Fehler denn GENAU auf...Wo steht die Funktion, deren Return-Wert als erstes ein Fehler signalisiert.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1100683</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1100683</guid><dc:creator><![CDATA[CodeFinder]]></dc:creator><pubDate>Wed, 19 Jul 2006 22:14:38 GMT</pubDate></item><item><title><![CDATA[Reply to Mit MCI WAVE-Datei aufnehmen on Thu, 20 Jul 2006 01:44:13 GMT]]></title><description><![CDATA[<p><a class="plugin-mentions-user plugin-mentions-a" href="https://www.c-plusplus.net/forum/uid/12048">@CodeFinder</a>: Genau lesen! Er kann doch Wave-Dateien erstellen, welche sich auch mit allem möglichem <em>außer</em> dem Windows Media Player Abspielen lassen. Also wird sein Code schon laufen <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f4a1.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--light_bulb"
      title=":bulb:"
      alt="💡"
    /></p>
<p>@-=Chris=-: Was sagt den der WMP zu der von dir erstellten Datei?</p>
<p>Greetz, Swordfish</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1100709</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1100709</guid><dc:creator><![CDATA[Swordfish]]></dc:creator><pubDate>Thu, 20 Jul 2006 01:44:13 GMT</pubDate></item><item><title><![CDATA[Reply to Mit MCI WAVE-Datei aufnehmen on Thu, 20 Jul 2006 06:15:14 GMT]]></title><description><![CDATA[<p>Hallo und danke für die Rückmeldung (trotz des etwas zerstückelten Code),</p>
<p>ich habe die Datei nun einmal mit dem &quot;Windows Media Player 11 Beta&quot; getestet,<br />
der dann behauptete es sei kein richtiger Codec vorhanden. Ich vermutete, dass<br />
das an der Beta-Version liegt. Der &quot;Windows Media Classic&quot; allerdings sagte ebenso,<br />
dass ein Fehler vorliegt, nannte es aber so:</p>
<blockquote>
<p>Ein Vorgang ist aufgrund eines<br />
Zertifizierungsfehlers fehlgeschlagen.</p>
<p>Ein entsprechendes Dekomprimierprogramm konnte für diese Datei nicht gedownloadet werden. (Fehler=80040200)</p>
<p>Ein entsprechendes Dekomprimierprogramm konnte für diese Datei nicht gedownloadet werden. (Fehler=80040200)</p>
<p>Ein Vorgang ist aufgrund eines Zertifizierungsfehlers fehlgeschlagen. (Fehler=80040295)</p>
</blockquote>
<p>(Eigentlich sagt der auch, dass kein Codec da ist, drückt es nur anders aus.<br />
Aber wie gesagt, andere Programme spielen die Datei ab.)</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1100734</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1100734</guid><dc:creator><![CDATA[-=Chris=-]]></dc:creator><pubDate>Thu, 20 Jul 2006 06:15:14 GMT</pubDate></item><item><title><![CDATA[Reply to Mit MCI WAVE-Datei aufnehmen on Fri, 21 Jul 2006 19:07:30 GMT]]></title><description><![CDATA[<p>So,</p>
<p>da mein Problem echt kompliziert zu sein scheint und mir eben keiner weiterhelfen<br />
konnte, habe ich mich den halben Tag lang damit befasst. Und vor ein paar Minuten<br />
habe ich sie gefunden, die Lösung!</p>
<p>Man muss um eine &quot;saubere&quot; WAVE-Datei zu erzeugen aus den Werten:</p>
<p>Bits, Channels und Sampling-Rate die Bytes pro Sekunde errechnen</p>
<p>und aus</p>
<p>Bits und Channels das Alignment (keine Ahnung wie die deutsche Übersetzung ist)<br />
errechnen.</p>
<p>Das geht so:</p>
<pre><code class="language-cpp">include &lt;stdio.h&gt;
include &lt;mmsystem.h&gt;

int iChannels=2;
int iBits=16;
int iAlignment=0;
unsigned int uiAvgBytes=0;
unsigned int uiSamplingRate=44100;
char szSetParms[256];

			...

	uiAvgBytes = (iBits * iChannels * uiSamplingRate) / 8;
	iAlignment = (iBits * iChannels) / 8;

	mciSendString(&quot;OPEN NEW TYPE waveaudio ALIAS mysound&quot;, NULL, 0, NULL); 

	sprintf(szSetParms,&quot;SET mysound BITSPERSAMPLE %i CHANNELS %i ALIGNMENT %i SAMPLESPERSEC %u BYTESPERSEC %u FORMAT TAG pcm,
	iBits,iChannels,iAlignment,uiSamplingRate,uiAvgBytes);

	mciSendString(szSetParms,NULL,0,NULL);

			...
</code></pre>
<p>Und danach dann wie schon oben aufnehmen und speichern. Und der WMP nervt auch<br />
net mehr.</p>
<p>P.S. Wenn einer eine Funktion der WinAPI kennt, die wie &quot;sprintf&quot; ist kann er<br />
mir diese gerne posten <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f603.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--grinning_face_with_big_eyes"
      title=":D"
      alt="😃"
    /></p>
]]></description><link>https://www.c-plusplus.net/forum/post/1102005</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1102005</guid><dc:creator><![CDATA[-=Chris=-]]></dc:creator><pubDate>Fri, 21 Jul 2006 19:07:30 GMT</pubDate></item><item><title><![CDATA[Reply to Mit MCI WAVE-Datei aufnehmen on Fri, 21 Jul 2006 22:25:06 GMT]]></title><description><![CDATA[<pre><code class="language-cpp">wsprintf(
         LPTSTR lpOut,	  // pointer to buffer for output 
         LPCTSTR lpFmt,    // pointer to format-control string 
         ...	           // optional arguments
         );
</code></pre>
<p>is das sowas was du brauchst statt sprintf? ich weiß grad net genau was sprintf ist aber es müsst eigentlich das sein was du meinst (vom Aussehen her...^^)</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1102056</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1102056</guid><dc:creator><![CDATA[kingofmovies]]></dc:creator><pubDate>Fri, 21 Jul 2006 22:25:06 GMT</pubDate></item><item><title><![CDATA[Reply to Mit MCI WAVE-Datei aufnehmen on Fri, 21 Jul 2006 22:27:06 GMT]]></title><description><![CDATA[<p>-=Chris=- schrieb:</p>
<blockquote>
<p>P.S. Wenn einer eine Funktion der WinAPI kennt, die wie &quot;sprintf&quot; ist kann er<br />
mir diese gerne posten <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f603.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--grinning_face_with_big_eyes"
      title=":D"
      alt="😃"
    /></p>
</blockquote>
<p>WinAPI basiert auf der Programmiersprache C, sprintf ist wie wsprintf eine C-Funktion.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1102059</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1102059</guid><dc:creator><![CDATA[CodeFinder]]></dc:creator><pubDate>Fri, 21 Jul 2006 22:27:06 GMT</pubDate></item></channel></rss>