<?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[RGB Auslese gibt falsch aus]]></title><description><![CDATA[<p>Hi folgendes Problem warum wird mir hier immer 255 255 255 ausgegeben?<br />
Danke im Voraus</p>
<pre><code class="language-cpp">void __fastcall TForm1::Timer1Timer(TObject *Sender)
{
  POINT p;

GetCursorPos(&amp;p);  //x und y Koordinaten von Maus auslesen

int x;
int y;
x = p.x;
y = p.y;
Label1-&gt;Caption = x;
Label2-&gt;Caption = y;   //x und y Anzeigen lassen

int rot,gruen,blau;
	char colour[9];
	COLORREF rgb;
	HDC test;
int r;
int g;
int b;
	rgb=GetPixel(test,x,y);
     r = GetRValue (rgb);
     g = GetGValue (rgb);
     b = GetBValue (rgb);

Label3-&gt;Caption = r;        //Und den Pixel in RGB anzeigen lassen
Label4-&gt;Caption = g;
Label5-&gt;Caption = b;
}
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/topic/172263/rgb-auslese-gibt-falsch-aus</link><generator>RSS for Node</generator><lastBuildDate>Fri, 14 Aug 2026 11:03:12 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/172263.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 03 Feb 2007 01:41:17 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to RGB Auslese gibt falsch aus on Sat, 03 Feb 2007 01:41:17 GMT]]></title><description><![CDATA[<p>Hi folgendes Problem warum wird mir hier immer 255 255 255 ausgegeben?<br />
Danke im Voraus</p>
<pre><code class="language-cpp">void __fastcall TForm1::Timer1Timer(TObject *Sender)
{
  POINT p;

GetCursorPos(&amp;p);  //x und y Koordinaten von Maus auslesen

int x;
int y;
x = p.x;
y = p.y;
Label1-&gt;Caption = x;
Label2-&gt;Caption = y;   //x und y Anzeigen lassen

int rot,gruen,blau;
	char colour[9];
	COLORREF rgb;
	HDC test;
int r;
int g;
int b;
	rgb=GetPixel(test,x,y);
     r = GetRValue (rgb);
     g = GetGValue (rgb);
     b = GetBValue (rgb);

Label3-&gt;Caption = r;        //Und den Pixel in RGB anzeigen lassen
Label4-&gt;Caption = g;
Label5-&gt;Caption = b;
}
</code></pre>
]]></description><link>https://www.c-plusplus.net/forum/post/1222038</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1222038</guid><dc:creator><![CDATA[Fanta]]></dc:creator><pubDate>Sat, 03 Feb 2007 01:41:17 GMT</pubDate></item><item><title><![CDATA[Reply to RGB Auslese gibt falsch aus on Sat, 03 Feb 2007 02:10:05 GMT]]></title><description><![CDATA[<p>hopala falsches forum <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f61b.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--face_with_tongue"
      title=":-P"
      alt="😛"
    /></p>
]]></description><link>https://www.c-plusplus.net/forum/post/1222040</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1222040</guid><dc:creator><![CDATA[Fanta]]></dc:creator><pubDate>Sat, 03 Feb 2007 02:10:05 GMT</pubDate></item><item><title><![CDATA[Reply to RGB Auslese gibt falsch aus on Sat, 03 Feb 2007 08:08:42 GMT]]></title><description><![CDATA[<p>Hallo</p>
<p>Zunächst einmal wird test kein gültiger Wert zugewiesen, was aber notwendig ist.</p>
<blockquote>
<p>HDC test;<br />
...<br />
rgb=GetPixel(test,x,y);</p>
</blockquote>
<p>Wenn du den Pixel eines Forms aus deinem eigenen Programm willst, warum benutzt du dann nicht Canvas?</p>
<p>bis bald<br />
akari</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1222062</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1222062</guid><dc:creator><![CDATA[akari]]></dc:creator><pubDate>Sat, 03 Feb 2007 08:08:42 GMT</pubDate></item><item><title><![CDATA[Reply to RGB Auslese gibt falsch aus on Sat, 03 Feb 2007 14:17:48 GMT]]></title><description><![CDATA[<p>Ich hab gerade n schwachen moment was muss ich mit test tun damit es gültig wird?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1222230</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1222230</guid><dc:creator><![CDATA[Fanta]]></dc:creator><pubDate>Sat, 03 Feb 2007 14:17:48 GMT</pubDate></item><item><title><![CDATA[Reply to RGB Auslese gibt falsch aus on Sat, 03 Feb 2007 14:22:11 GMT]]></title><description><![CDATA[<p>aso<br />
test = GetWindowDC(0);</p>
<p>Google 2 Win^^</p>
<p>Danke akari</p>
]]></description><link>https://www.c-plusplus.net/forum/post/1222231</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/1222231</guid><dc:creator><![CDATA[Fanta]]></dc:creator><pubDate>Sat, 03 Feb 2007 14:22:11 GMT</pubDate></item></channel></rss>