<?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[CBitmap in IPicture]]></title><description><![CDATA[<p>Hallo!</p>
<p>Ich habe eine CBitmap und möchte das ganze gerne in ein IPicture umwandeln.</p>
<p>Hab da mal ein bischen was gefunden, nur funktionierts nicht so richtig:</p>
<pre><code>//Do the conversion from a HBITMAP to IPicture
	PICTDESC picture_desc;
	picture_desc.cbSizeofstruct = sizeof(picture_desc);
	picture_desc.picType = PICTYPE_BITMAP;
	picture_desc.bmp.hbitmap = (HBITMAP)m_bmp;
	picture_desc.bmp.hpal = NULL;
	HRESULT hr = OleCreatePictureIndirect(&amp;picture_desc, IID_IPicture, TRUE, (void**)m_pPic-&gt;GetIPicture());
</code></pre>
<p>m_pPic = CPicture.<br />
GetIPicture() liefert das IPicture Objekt aus der CPicture Klasse.</p>
<p>Ich hab die Bitmap nicht als File.</p>
<p>Kann mir bitte wer weiterhelfen?</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/202410/cbitmap-in-ipicture</link><generator>RSS for Node</generator><lastBuildDate>Mon, 06 Apr 2026 06:48:40 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/202410.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 11 Jan 2008 10:46:46 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to CBitmap in IPicture on Fri, 11 Jan 2008 10:46:46 GMT]]></title><description><![CDATA[<p>Hallo!</p>
<p>Ich habe eine CBitmap und möchte das ganze gerne in ein IPicture umwandeln.</p>
<p>Hab da mal ein bischen was gefunden, nur funktionierts nicht so richtig:</p>
<pre><code>//Do the conversion from a HBITMAP to IPicture
	PICTDESC picture_desc;
	picture_desc.cbSizeofstruct = sizeof(picture_desc);
	picture_desc.picType = PICTYPE_BITMAP;
	picture_desc.bmp.hbitmap = (HBITMAP)m_bmp;
	picture_desc.bmp.hpal = NULL;
	HRESULT hr = OleCreatePictureIndirect(&amp;picture_desc, IID_IPicture, TRUE, (void**)m_pPic-&gt;GetIPicture());
</code></pre>
<p>m_pPic = CPicture.<br />
GetIPicture() liefert das IPicture Objekt aus der CPicture Klasse.</p>
<p>Ich hab die Bitmap nicht als File.</p>
<p>Kann mir bitte wer weiterhelfen?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1434783</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1434783</guid><dc:creator><![CDATA[Da-Nic]]></dc:creator><pubDate>Fri, 11 Jan 2008 10:46:46 GMT</pubDate></item></channel></rss>