This object gives access to Eulers in Blender. The item this is wrapping or None (read-only). True when this object wraps external data (read-only). True when the owner of this data is valid. True when this object has been frozen (read-only). ReturnsĬonvert from CIE XYZ (Illuminant D65) to scene linear color space. ReturnsĬonvert from sRGB to scene linear color space. ReturnsĬonvert from scene linear to CIE XYZ (Illuminant D65) color space. Return typeĬonvert from scene linear to sRGB color space. ReturnsĪ color in Rec.709 linear color space. Return typeĬolor from_scene_linear_to_rec709_linear ( ) Ĭonvert from scene linear to Rec.709 linear color space. ReturnsĪ color in ACES2065-1 linear color space. ReturnsĬonvert from scene linear to ACES2065-1 linear color space. Return typeĬolor from_rec709_linear_to_scene_linear ( ) Ĭonvert from Rec.709 linear color space to scene linear color space. ReturnsĪ color in scene linear color space. from_aces_to_scene_linear ( ) Ĭonvert from ACES2065-1 linear to scene linear color space. freeze ( ) Īfter this the object can be hashed, used in dictionaries & sets. Use this to get a copy of a wrapped color with Color (( 0.25, 0.0, 0.0 )) # Color can be multiplied, in this example color is scaled to 0-255 # can printed as integers print ( "Color: %d, %d, %d " % ( col * 255.0 )) # This example prints the color as hexadecimal print ( "Hexadecimal: %.2x%.2x%.2x " % ( int ( col. r ) print ( "Color G:", col ) print ( "Color B:", col ) print ( "Color HSV: %.2f, %.2f, %.2f ", col ) # components of an existing color can be set col = 0.0, 0.5, 1.0 # components of an existing color can use slice notation to get a tuple print ( "Values: %f, %f, %f " % col ) # colors can be added and subtracted col += mathutils. s *= 0.5 # you can access its components by attribute or index print ( "Color R:", col. Color (( 0.0, 0.0, 1.0 )) # as well as r/g/b attribute access you can adjust them by h/s/v col. Import mathutils # color values are represented as RGB values from 0 - 1, this is blue col = mathutils.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |