<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.multitheftauto.com/wiki/PT-BR/RGBToDecimal?action=history&amp;feed=atom</id>
	<title>PT-BR/RGBToDecimal - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.multitheftauto.com/wiki/PT-BR/RGBToDecimal?action=history&amp;feed=atom"/>
	<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=PT-BR/RGBToDecimal&amp;action=history"/>
	<updated>2026-04-10T10:53:44Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.39.3</generator>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=PT-BR/RGBToDecimal&amp;diff=74620&amp;oldid=prev</id>
		<title>LODS: Created page with &quot;{{PT-BR/Função Útil}} Essa função converte uma cor em RGB para Decimal.  ==Sintaxe== &lt;syntaxhighlight lang=&quot;lua&quot;&gt;RGBToDecimal( float r, float g, float b )&lt;/syntaxhighlight&gt;  ==Argumentos== * '''r''': O valor Red * '''g''': O valor Green * '''b''': O valor Blue  ==Retorno== Retorna um inteiro convertido dos valores RGB especificados  ==Código== &lt;section name=&quot;Code&quot; class=&quot;both&quot; show=&quot;true&quot;&gt; &lt;syntaxhighlight lang=&quot;lua&quot;&gt; function RGBToDecimal(r, g, b)...&quot;</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=PT-BR/RGBToDecimal&amp;diff=74620&amp;oldid=prev"/>
		<updated>2022-05-20T23:30:41Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;{{PT-BR/Função Útil}} Essa função converte uma cor em RGB para Decimal.  ==Sintaxe== &amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;RGBToDecimal( float r, float g, float b )&amp;lt;/syntaxhighlight&amp;gt;  ==Argumentos== * &amp;#039;&amp;#039;&amp;#039;r&amp;#039;&amp;#039;&amp;#039;: O valor Red * &amp;#039;&amp;#039;&amp;#039;g&amp;#039;&amp;#039;&amp;#039;: O valor Green * &amp;#039;&amp;#039;&amp;#039;b&amp;#039;&amp;#039;&amp;#039;: O valor Blue  ==Retorno== Retorna um &lt;a href=&quot;/wiki/PT-BR/Int&quot; title=&quot;PT-BR/Int&quot;&gt;inteiro&lt;/a&gt; convertido dos valores RGB especificados  ==Código== &amp;lt;section name=&amp;quot;Code&amp;quot; class=&amp;quot;both&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt; &amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt; function RGBToDecimal(r, g, b)...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{PT-BR/Função Útil}}&lt;br /&gt;
Essa função converte uma cor em RGB para Decimal.&lt;br /&gt;
&lt;br /&gt;
==Sintaxe==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;RGBToDecimal( float r, float g, float b )&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Argumentos==&lt;br /&gt;
* '''r''': O valor Red&lt;br /&gt;
* '''g''': O valor Green&lt;br /&gt;
* '''b''': O valor Blue&lt;br /&gt;
&lt;br /&gt;
==Retorno==&lt;br /&gt;
Retorna um [[PT-BR/Int|inteiro]] convertido dos valores RGB especificados&lt;br /&gt;
&lt;br /&gt;
==Código==&lt;br /&gt;
&amp;lt;section name=&amp;quot;Code&amp;quot; class=&amp;quot;both&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
function RGBToDecimal(r, g, b)&lt;br /&gt;
    return (bitLShift(r, 16)) + (bitLShift(g, 8)) + b&lt;br /&gt;
end&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Exemplo==&lt;br /&gt;
&amp;lt;section name=&amp;quot;Code&amp;quot; class=&amp;quot;both&amp;quot; show=&amp;quot;true&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local r, g, b = 255, 0, 0&lt;br /&gt;
&lt;br /&gt;
print(RGBToDecimal(r, g, b)) -- output: 16711680&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&amp;lt;/section&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Autor==&lt;br /&gt;
[[User:Lettify|Lettify]]&lt;br /&gt;
&lt;br /&gt;
==Veja também==&lt;br /&gt;
{{Useful_Functions}}&lt;br /&gt;
&lt;br /&gt;
[[en:rGBToDecimal]]&lt;/div&gt;</summary>
		<author><name>LODS</name></author>
	</entry>
</feed>