mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-06-05 11:24:17 +03:00
The table of named colors has been compressed and moved out from Quantity_Color.cxx into Quantity_ColorTable.pxx. Quantity_NameOfColor - grayscale enumeration values have been re-ordered to fix discontinuity. Duplicating colors has been merged within enumeration: CHARTREUSE=CHARTREUSE1, GOLD=GOLD1, GREEN=GREEN1, ORANGE=ORANGE1, ORANGERED=ORANGERED1, RED=RED1, TOMATO=TOMATO1, YELLOW=YELLOW1. Added aliases to several other common colors: BLUE=BLUE1, CYAN=CYAN1, LIGHTCYAN=LIGHTCYAN1, MAGENTA=MAGENTA1. Quantity_Color class definition has been cleaned to follow OCCT coding style. Quantity_Color now stores NCollection_Vec3<float> as class field instead of separate components. Removed unused class Quantity_ColorDefinitionError. New methods Quantity_Color::Convert_LinearRGB_To_sRGB() and Quantity_Color::Convert_sRGB_To_LinearRGB() converting RGB components from linear to non-linear sRGB colorspace and vice versa. Image_PixMap::PixelColor() and Image_PixMap::SetPixelColor() methods have been extended with an optional argument for performing linearization/delinearization of 8-bit sRGB pixel formats. Draw Harness command AISColor has been corrected to take color name instead of enumeration index.
19 lines
784 B
Plaintext
19 lines
784 B
Plaintext
puts "============="
|
|
puts "0030076: Visualization, TKV3d - API to update certain vertex attribute(s) without recomputing a presentation"
|
|
puts "============="
|
|
|
|
set c1 {c 1 0 0}
|
|
set c2 {c 0 0 1}
|
|
|
|
pload VISUALIZATION
|
|
|
|
vclear
|
|
vinit View1
|
|
vdrawparray a triangles -deinterleaved -mutable v 10 0 0 {*}$c1 v 11 0 0 {*}$c1 v 11 1 0 {*}$c1 v 11 1 0 {*}$c2 v 10 1 0 {*}$c2 v 10 0 0 {*}$c2
|
|
vfit
|
|
vdump $imagedir/${casename}_1.png
|
|
vdrawparray a -patch triangles -deinterleaved -mutable v 10 0 0 {*}$c2 v 11 0 0 {*}$c2 v 11 1 0 {*}$c2 v 11 1 0 {*}$c1 v 10 1 0 {*}$c1 v 10 0 0 {*}$c1
|
|
if { [vreadpixel 200 150 rgb name] != "RED" } { puts "Error: array was not updated" }
|
|
if { [vreadpixel 200 250 rgb name] != "BLUE" } { puts "Error: array was not updated" }
|
|
vdump $imagedir/${casename}_2.png
|