<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic SETCOLORRGB in Intel® Fortran Compiler</title>
    <link>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060956#M117514</link>
    <description>&lt;P&gt;I am working through some examples in the book "Compaq Visual Fortran A Guide to Creating Windows Applications' &amp;nbsp;in which this code is given:&lt;/P&gt;

&lt;PRE class="brush:fortran;"&gt;    ibackcolor=rgb(255,255,255)     ! white
    ifrontcolor=rgb(0,0,0)          ! black
     iret = setcolorrgb(ifrontcolor)
     iret = setbkcolorrgb(ibackcolor)
     iret = settextcolorrgb(ifrontcolor)
&lt;/PRE&gt;

&lt;P&gt;This is equivalent to the following given in the Intel documentation:&lt;/P&gt;

&lt;PRE class="brush:fortran;"&gt;     iret = setcolorrgb(Z'00000000')
     iret = setbkcolorrgb(Z'00FFFFFF')
     iret = settextcolorrgb(Z'00000000')
&lt;/PRE&gt;

&lt;P&gt;My question is where in the Intel documentation do I find a description of the RGB function? &amp;nbsp; Where can I find documentation for other functions like RGB that are built into Intel Visual Fortran?&amp;nbsp;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 1em; line-height: 1.5;"&gt;Thank you.&lt;/SPAN&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 30 Jan 2015 04:12:52 GMT</pubDate>
    <dc:creator>Robert</dc:creator>
    <dc:date>2015-01-30T04:12:52Z</dc:date>
    <item>
      <title>SETCOLORRGB</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060956#M117514</link>
      <description>&lt;P&gt;I am working through some examples in the book "Compaq Visual Fortran A Guide to Creating Windows Applications' &amp;nbsp;in which this code is given:&lt;/P&gt;

&lt;PRE class="brush:fortran;"&gt;    ibackcolor=rgb(255,255,255)     ! white
    ifrontcolor=rgb(0,0,0)          ! black
     iret = setcolorrgb(ifrontcolor)
     iret = setbkcolorrgb(ibackcolor)
     iret = settextcolorrgb(ifrontcolor)
&lt;/PRE&gt;

&lt;P&gt;This is equivalent to the following given in the Intel documentation:&lt;/P&gt;

&lt;PRE class="brush:fortran;"&gt;     iret = setcolorrgb(Z'00000000')
     iret = setbkcolorrgb(Z'00FFFFFF')
     iret = settextcolorrgb(Z'00000000')
&lt;/PRE&gt;

&lt;P&gt;My question is where in the Intel documentation do I find a description of the RGB function? &amp;nbsp; Where can I find documentation for other functions like RGB that are built into Intel Visual Fortran?&amp;nbsp;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 1em; line-height: 1.5;"&gt;Thank you.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 30 Jan 2015 04:12:52 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060956#M117514</guid>
      <dc:creator>Robert</dc:creator>
      <dc:date>2015-01-30T04:12:52Z</dc:date>
    </item>
    <item>
      <title>Look up any of these</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060957#M117515</link>
      <description>&lt;P&gt;Look up any of these functions in Intel Fortran help. It will tell you that the argument "color" is INTEGER(4), I.e. 24 bits, and it gives you the color mapping. In simple terms, the rightmost 8 bits represent the "amount" of the color Red, where 00000000 indicates no color at all and 11111111 represents full intensity Red. In practice no one uses the bit representation, but rather hex: Z'00 &amp;nbsp;represents no color and Z'FF' represents full intensity. Two-digit groupings represent Red, Green, Blue from right to left. I usually abbreviate these as #00, #FF, etc. Thus, for example,&lt;/P&gt;

&lt;P&gt;Intense red = #0000FF&lt;BR /&gt;
	Intense green = #00FF00&lt;BR /&gt;
	Intense blue = #BB0000&lt;BR /&gt;
	Medium intensity cyan = #808000 (equal parts green and blue)&lt;/P&gt;</description>
      <pubDate>Fri, 30 Jan 2015 05:14:45 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060957#M117515</guid>
      <dc:creator>dboggs</dc:creator>
      <dc:date>2015-01-30T05:14:45Z</dc:date>
    </item>
    <item>
      <title>Some background can be found</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060958#M117516</link>
      <description>&lt;P&gt;Some background can be found in the sections of :&amp;nbsp;&lt;/P&gt;

&lt;P&gt;&lt;A href="https://software.intel.com/en-us/node/535311" target="_blank"&gt;https://software.intel.com/en-us/node/535311&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 30 Jan 2015 08:16:56 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060958#M117516</guid>
      <dc:creator>andrew_4619</dc:creator>
      <dc:date>2015-01-30T08:16:56Z</dc:date>
    </item>
    <item>
      <title>Thank you dboggs and app4619</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060959#M117517</link>
      <description>&lt;P&gt;Thank you dboggs and app4619 for your reply. that expalins RGB function.&lt;/P&gt;

&lt;P&gt;Now a follow up question: F&lt;SPAN style="font-size: 1em; line-height: 1.5;"&gt;ortran does not have a RGB function and I cannot find the RGB function mentioned in any of the Intel documentation, but it compiles so the function is an Intel add on somewhere. &amp;nbsp;&lt;/SPAN&gt;&lt;SPAN style="font-size: 1em; line-height: 1.5;"&gt;How does one get a list of the undocumented functions in Intel Fortran? I want to know what other undocumented useful functions there are.&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;Thank you, Bob&lt;/P&gt;</description>
      <pubDate>Fri, 30 Jan 2015 18:49:39 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060959#M117517</guid>
      <dc:creator>Robert</dc:creator>
      <dc:date>2015-01-30T18:49:39Z</dc:date>
    </item>
    <item>
      <title>You will find RGB, and some</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060960#M117518</link>
      <description>&lt;P&gt;You will find RGB, and some other functions that correspond to C macros in the Microsoft-supplied C header files, in ifwbase.f90 in the compiler Includes folder. These are used the same way they are in C and we don't document them separately as they are effectively part of the Windows API SDK.&lt;/P&gt;</description>
      <pubDate>Fri, 30 Jan 2015 19:09:08 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060960#M117518</guid>
      <dc:creator>Steven_L_Intel1</dc:creator>
      <dc:date>2015-01-30T19:09:08Z</dc:date>
    </item>
    <item>
      <title>Thank you!</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060961#M117519</link>
      <description>&lt;P&gt;Thank you!&lt;/P&gt;</description>
      <pubDate>Fri, 30 Jan 2015 19:16:38 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060961#M117519</guid>
      <dc:creator>Robert</dc:creator>
      <dc:date>2015-01-30T19:16:38Z</dc:date>
    </item>
    <item>
      <title>Robert, fyi: The "official"</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060962#M117520</link>
      <description>&lt;P&gt;Robert, fyi: The "official" IVF functions that replaced the CVF RGB function described in Lawrence's Compaq Visual Fortran book are INTEGERtoRGB and RGBtoINTEGER. You can find these in the regular Intel Fortran documentation. The older RGB function still works, as noted by Steve, but using these is more cochere now and actually documented (although it took me a long time to find them).&lt;/P&gt;

&lt;P&gt;For example, result = RGBtoINTEGER (red, green, blue) can be used to provide an integer argument to various other functions like SETCOLORRGB. But once you understand the hex representation of colors it is easier to simply call SETCOLORRGB (#bbggrr).&lt;/P&gt;

&lt;P&gt;The reverse procedure, i.e. to inquire the current color in use, is not correspondingly simple. &amp;nbsp;You first need to use a function like GETCOLORRGB&amp;nbsp; () to get the INTEGER(4) color number. That can be used to, say, save the current color and stash it away for later restoration; but if you really want the relative red green and blue intensities of the current color you can either (a) write your own routine to convert between integers and hex values, or (b) call the function INTEGERtoRGB. I opt for the latter (this programming is driving me crazy but I'm not there yet).&lt;/P&gt;</description>
      <pubDate>Fri, 30 Jan 2015 23:18:21 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060962#M117520</guid>
      <dc:creator>dboggs</dc:creator>
      <dc:date>2015-01-30T23:18:21Z</dc:date>
    </item>
    <item>
      <title>The conversion functions are</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060963#M117521</link>
      <description>&lt;P&gt;The conversion functions are pretty simple: red = ibits(rgb,0,8), green = ibits(rgb,8,8), blue = ibits(rgb,16,8), rgb = iany(ishft([red,green,blue],[0,8,16])). There is an expanded zip file with all the&amp;nbsp;code for Lawrence's book somewhere on Elsevier's web site, although I can't seem to find it just now. There is also a 64-bit clean version of his OpenGL example; I can find that: &lt;A href="http://home.comcast.net/~kmbtib/Fortran_stuff/gridview.zip"&gt;http://home.comcast.net/~kmbtib/Fortran_stuff/gridview.zip&lt;/A&gt; . Looks like it needs a little work to be 32-bit clean on ifort, though :)&lt;/P&gt;</description>
      <pubDate>Sat, 31 Jan 2015 02:23:43 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060963#M117521</guid>
      <dc:creator>JVanB</dc:creator>
      <dc:date>2015-01-31T02:23:43Z</dc:date>
    </item>
    <item>
      <title>These comments are all very</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060964#M117522</link>
      <description>&lt;P&gt;These comments are all very good and helpful. Thank you.&lt;/P&gt;

&lt;P&gt;Regards,&lt;/P&gt;

&lt;P&gt;Robert_M&lt;/P&gt;</description>
      <pubDate>Mon, 02 Feb 2015 04:48:07 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/SETCOLORRGB/m-p/1060964#M117522</guid>
      <dc:creator>Robert</dc:creator>
      <dc:date>2015-02-02T04:48:07Z</dc:date>
    </item>
  </channel>
</rss>

