These forums are CLOSED. Please visit the new forums HERE
PHP and RGB ... HELP!!!! Please |
|
Catasbrina Dragonfly
Registered User
Join date: 16 Aug 2004
Posts: 1
|
10-05-2004 22:37
I have been unable to find anything that tells what to put into the PHP scripts I am using to get the colors I want. The script goes from 0,0,0 (black) to 100,100,100 (white) and nothing I try looks like what I want. Anyone got any info on this?
|
Driftwood Nomad
Registered User
![]() Join date: 10 May 2003
Posts: 451
|
10-05-2004 22:49
PHP? If you are scripting in PHP, then you are most likely generating HTML, which requires RGB colors in hex (such as #000000 for black, #FFFFFF for white)
If you mean LSL, then the RGB colors are represented as a vector, with each value ranging from 0.0 to 1.0, so green, for example, would be <0.0,1.0,0.0>. A great reference is the LSL Wiki page http://www.badgeometry.com/wiki/llSetColor Hope this helps! _____________________
Driftwood Nomad
D&D Dogs Co-founder "Second Life’s first AI companion animal" The Second Opinion, 08/05/2003 D&D Dogs HQ Pawaii (127, 63) Mainland Store Kuula (214, 124) http://www.sldogs.com SL Dogs Zazzle store! ![]() |
Samhain Broom
Registered User
![]() Join date: 1 Aug 2004
Posts: 298
|
10-06-2004 07:36
Another thing to remember, is that the colors are light spectrum, not like the colors you learned about in art class where blue and yellow are mixed together to make green. Light spectrum primary colors are RGB, you will notice that red and green make yellow.
Is that what you meant? There are a lot of HTML color chart conversion sites out there if you do a google... I did a google with this search string: HTML color conversion chart and the first example was: Doug's Home Page I hope that helps. _____________________
rm -rf /bin/ladden #beware of geeks bearing grifts
|
Strife Onizuka
Moonchild
![]() Join date: 3 Mar 2004
Posts: 5,887
|
10-06-2004 08:08
CODE
_____________________
Truth is a river that is always splitting up into arms that reunite. Islanded between the arms, the inhabitants argue for a lifetime as to which is the main river. - Cyril Connolly Without the political will to find common ground, the continual friction of tactic and counter tactic, only creates suspicion and hatred and vengeance, and perpetuates the cycle of violence. - James Nachtwey |