VR-Forces 4.1.1 Class Documentation
Home
Modules
Namespaces
Classes
Files
Examples
Behavior Models
File List
File Members
include
vrvDrawControl
DtVdcColor.h
Go to the documentation of this file.
1
/******************************************************************************
2
** Copyright (c) 2006 MaK Technologies, Inc.
3
** All rights reserved.
4
******************************************************************************/
5
/******************************************************************************
6
** $RCSfile: DtVdcColor.h,v $ $Revision: 1.1 $ $State: Exp $
7
******************************************************************************/
8
#pragma once
9
13
14
#include <
vrvDrawControl/vrvDrawControl.h
>
15
16
namespace
vrvControlToolkit
17
{
24
class
DT_DLL_VRVDRAWCONTROL
DtVdcColor
25
{
26
public
:
27
29
DtVdcColor
();
30
43
DtVdcColor
(
unsigned
r,
unsigned
g,
unsigned
b,
unsigned
a = 255 );
44
46
DtVdcColor
(
const
DtVdcColor
& orig );
47
49
DtVdcColor
operator=(
const
DtVdcColor
& orig );
50
58
const
unsigned
& operator[](
int
index )
const
;
59
67
unsigned
& operator[](
int
index );
68
69
71
bool
operator==
(
const
DtVdcColor
& rhs)
const
;
72
74
bool
operator!=
(
const
DtVdcColor
& rhs)
const
;
75
87
void
setHSV(
unsigned
hue,
double
saturation,
double
value,
88
unsigned
alpha = 255 );
89
95
unsigned
red()
const
;
96
102
void
setRed(
unsigned
red );
103
109
unsigned
green()
const
;
110
116
void
setGreen(
unsigned
green );
117
123
unsigned
blue()
const
;
124
130
void
setBlue(
unsigned
blue );
131
137
unsigned
hue()
const
;
138
144
void
setHue(
unsigned
hue );
145
151
double
saturation()
const
;
152
158
void
setSaturation(
double
saturation );
159
165
double
value()
const
;
166
172
void
setValue(
double
value );
173
179
unsigned
alpha()
const
;
180
186
void
setAlpha(
unsigned
alpha );
187
189
static
const
DtVdcColor
DtVdcWhite
;
191
static
const
DtVdcColor
DtVdcBlack
;
193
static
const
DtVdcColor
DtVdcRed
;
195
static
const
DtVdcColor
DtVdcGreen
;
197
static
const
DtVdcColor
DtVdcBlue
;
199
static
const
DtVdcColor
DtVdcYellow
;
201
static
const
DtVdcColor
DtVdcPurple
;
203
static
const
DtVdcColor
DtVdcOrange
;
204
205
protected
:
206
void
toHSV();
207
void
fromHSV();
208
209
protected
:
210
unsigned
myRed
;
211
unsigned
myGreen
;
212
unsigned
myBlue
;
213
unsigned
myAlpha
;
214
215
unsigned
myHue
;
216
double
mySaturation
;
217
double
myValue
;
218
};
219
220
}
Document ID: Generated on Mon Apr 8 19:24:01 EDT 2013 from SVN revision 125877
Copyright © 2005-2013 VT MÄK. All Rights Reserved (
www.mak.com
)