0023912: TDataStd_ExtStringArray::Value() returns a copy of TCollection_ExtendedStrin...
[occt.git] / src / Image / Image_PseudoColorImage.cdl
CommitLineData
b311480e 1-- Created on: 1993-07-27
2-- Created by: Jean Louis FRENKEL
3-- Copyright (c) 1993-1999 Matra Datavision
4-- Copyright (c) 1999-2012 OPEN CASCADE SAS
5--
6-- The content of this file is subject to the Open CASCADE Technology Public
7-- License Version 6.5 (the "License"). You may not use the content of this file
8-- except in compliance with the License. Please obtain a copy of the License
9-- at http://www.opencascade.org and read it completely before using this file.
10--
11-- The Initial Developer of the Original Code is Open CASCADE S.A.S., having its
12-- main offices at: 1, place des Freres Montgolfier, 78280 Guyancourt, France.
13--
14-- The Original Code and all software distributed under the License is
15-- distributed on an "AS IS" basis, without warranty of any kind, and the
16-- Initial Developer hereby disclaims all such warranties, including without
17-- limitation, any warranties of merchantability, fitness for a particular
18-- purpose or non-infringement. Please see the License for the specific terms
19-- and conditions governing the rights and limitations under the License.
20
7fd59977 21
22
23class PseudoColorImage from Image inherits DIndexedImage from Image
24
25 ---Purpose : A PseudoColorImage is a DIndexedImage associated with a
26 -- ColorMap . The ColoMap is set at Creation time and then
27 -- never be changed. Each Pixel in the Image ,as a IndexPixel
28 -- from Aspect, match a ColoMap Entry with the same value.
29
30uses
31 ColorMap from Aspect,
32 Color from Quantity,
33 IndexPixel from Aspect ,
34 Array1OfColor from Quantity,
35 HArray1OfColor from Quantity,
36 LookupTable from Image,
37 Image from Image,
38 TypeOfImage from Image
39
40is
41
42 Create( x,y,dx,dy : in Integer from Standard ;
43 aColorMap : ColorMap from Aspect )
44 returns mutable PseudoColorImage from Image;
45 ---Level: Public
46 ---Purpose : Creates a PseudoColorImage object.
47 -- The default Background Pixel is set to 0 .
48 -- All the Image is initialised with Background Pixel
49
50 Create( x,y,dx,dy : in Integer from Standard ;
51 aColorMap : ColorMap from Aspect ;
52 BackPixel : IndexPixel from Aspect )
53 returns mutable PseudoColorImage from Image;
54 ---Level: Public
55 ---Purpose : Creates a PseudoColorImage object and set the
56 -- Background Pixel.
57 -- All the Image is initialised with Background Pixel
58
59 Type ( me : immutable ) returns TypeOfImage from Image ;
60 ---Level: Public
61 ---Purpose : Returns the Image Type.
62
63 ColorMap( me ) returns immutable ColorMap from Aspect;
64 ---Level: Public
65 ---Purpose : returns the Image ColorMap .
66
67 PixelColor( me : immutable ; X,Y : in Integer from Standard )
68 returns Color from Quantity ;
69 ---C++: return const &
70 ---Level: Public
71 ---Purpose : Returns the Pixel Color .
72
73 RowColor ( me : immutable ; Y : in Integer from Standard )
74 returns HArray1OfColor from Quantity is redefined ;
75 ---Level: Public
76 ---Purpose : Return the PixelRow Color in a HArray1 of Color.
77
78 RowColor ( me : immutable ;
79 Y : in Integer from Standard ;
80 aArray1 : in out Array1OfColor from Quantity ) is redefined ;
81 ---Level: Public
82 ---Purpose : Stores the PixelRow Color in a Array1 .
83
84 Squeeze( me : immutable ;
85 BasePixel : IndexPixel from Aspect )
86 returns PseudoColorImage from Image ;
87 ---Level: Public
88 ---Purpose : Creates a new Image with continuous Pixel and a continuous
89 -- ColorMap whith only used Image color starting from
90 -- BasePixel .
91
92 SqueezedLookupTable(
93 me : immutable ;
94 BasePixel : IndexPixel from Aspect ;
95 aLookup : in out LookupTable from Image ) ;
96 ---Level: Public
97 ---Purpose: Creates a LookupTable that can be used to create a
98 -- new Image with continuous Pixel and a continuous
99 -- ColorMap with only used Image color starting
100 -- from BasePixel .
101
102 Lookup( me : mutable ;
103 aLookup : in LookupTable from Image ) ;
104 ---Level: Public
105 ---Purpose : Pass a PseudoColorImage through a lookupTable
106
107 Extrema( me : immutable ; Min, Max : in out IndexPixel from Aspect );
108 ---Level: Public
109 ---Purpose: Find the maximum and minimum Pixel Value of an Image.
110
111 Threshold( me : mutable ; Min, Max : IndexPixel from Aspect ;
112 Map : IndexPixel from Aspect );
113 ---Level: Public
114 ---Purpose: This method changes the value of any Pixel beetwen the
115 -- range (Min->Max) to the Pixel Map value. All Pixel values
116 -- outside the range are passed through without changed .
117
118 Rescale( me : mutable ; Scale, Offset : Real from Standard ) ;
119 ---Level: Public
120 ---Purpose : Map the Image Pixel Value from one range to another range.
121 -- This method perform the mapping by multiplying each
122 -- Pixel Value by Scale and then adding Offset to the result.
123
124 Dup ( me : immutable ) returns mutable Image from Image;
125 ---Level: Public
126 ---Purpose : Duplicate a Image.
127
128 -- ******************* Redefined method ***************************
129
130-- ShallowCopy (me) returns mutable like me ;
131 ---Level: Public
132-- ---Purpose: Returns a copy at the first level of <me>. The objects
133-- -- referenced are not copied. Entities copied by
134-- -- ShallowCopy are equal.
135-- ---C++: function call
136
137-- DeepCopy (me) returns mutable like me ;
138 ---Level: Public
139-- ---Purpose: Returns a deep copy of <me>. The objects
140-- -- referenced are copied. Entities copied by
141-- -- DeepCopy are similar (c.f the Method IsSimilar).
142-- ---C++: function call
143
144fields
145 myColorMap: ColorMap from Aspect;
146
147end PseudoColorImage from Image;