casa
5.7.0-16
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
casa
code
display
DisplayCanvas
WCLinearScaleHandler.h
Go to the documentation of this file.
1
//# WCLinearScaleHandler.h: linear data scaling for WorldCanvases
2
//# Copyright (C) 1993,1994,1995,1996,1999,2000,2001
3
//# Associated Universities, Inc. Washington DC, USA.
4
//#
5
//# This library is free software; you can redistribute it and/or modify it
6
//# under the terms of the GNU Library General Public License as published by
7
//# the Free Software Foundation; either version 2 of the License, or (at your
8
//# option) any later version.
9
//#
10
//# This library is distributed in the hope that it will be useful, but WITHOUT
11
//# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12
//# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
13
//# License for more details.
14
//#
15
//# You should have received a copy of the GNU Library General Public License
16
//# along with this library; if not, write to the Free Software Foundation,
17
//# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
18
//#
19
//# Correspondence concerning AIPS++ should be addressed as follows:
20
//# Internet email: aips2-request@nrao.edu.
21
//# Postal address: AIPS++ Project Office
22
//# National Radio Astronomy Observatory
23
//# 520 Edgemont Road
24
//# Charlottesville, VA 22903-2475 USA
25
//#
26
//# $Id$
27
28
#ifndef TRIALDISPLAY_WCLINEARSCALEHANDLER_H
29
#define TRIALDISPLAY_WCLINEARSCALEHANDLER_H
30
31
#include <
casa/aips.h
>
32
#include <
display/DisplayCanvas/WCDataScaleHandler.h
>
33
34
namespace
casa {
//# NAMESPACE CASA - BEGIN
35
36
// <summary>
37
// Linear scaling of data for WorldCanvases.
38
// </summary>
39
//
40
// <prerequisite>
41
// <li> <linkto class="WCDataScaleHandler">WCDataScaleHandler</linkto>
42
// </prerequisite>
43
//
44
// <etymology>
45
// WCLinearScaleHandler : WorldCanvas Linear Scale Handler
46
// </etymology>
47
//
48
// <synopsis>
49
// The WCLinearScaleHandler is an implementation of the
50
// <linkto class="WCDataScaleHandler">WCDataScaleHandler</linkto> that
51
// uses linear scaling to get from real values to discrete values in
52
// the range of 0 to rangeMax. Typically, rangeMax is equivalent to the
53
// available color resolution minus 1.
54
// </synopsis>
55
//
56
// <motivation>
57
// Need to provide some basic implementations of the WCDataScaleHandler
58
// so users can model other custom scale handlers after it. Linear scaling
59
// is a common need, so it was implemented.
60
// </motivation>
61
//
62
// <example>
63
// see the test program tWCLinearScaleHandler.cc in the Display/test directory.
64
// </example>
65
//
66
// <todo>
67
// <li> stream ops
68
// </todo>
69
//
70
71
class
WCLinearScaleHandler
:
public
WCDataScaleHandler
{
72
public
:
73
74
// Default Constructor Required
75
WCLinearScaleHandler
();
76
77
// Destructor
78
virtual
~WCLinearScaleHandler
();
79
80
// apply returns true if the array in was converted to the
81
// array out successfully
82
// the last parameter sets the output range
83
// <group>
84
virtual
casacore::Bool
operator()
(
casacore::Array<casacore::uInt>
& out,
const
casacore::Array<casacore::Bool>
& in);
85
virtual
casacore::Bool
operator()
(
casacore::Array<casacore::uInt>
& out,
const
casacore::Array<casacore::uChar>
& in);
86
virtual
casacore::Bool
operator()
(
casacore::Array<casacore::uInt>
& out,
const
casacore::Array<casacore::Char>
& in);
87
virtual
casacore::Bool
operator()
(
casacore::Array<casacore::uInt>
& out,
const
casacore::Array<casacore::uShort>
& in);
88
virtual
casacore::Bool
operator()
(
casacore::Array<casacore::uInt>
& out,
const
casacore::Array<casacore::Short>
& in);
89
virtual
casacore::Bool
operator()
(
casacore::Array<casacore::uInt>
& out,
const
casacore::Array<casacore::uInt>
& in);
90
virtual
casacore::Bool
operator()
(
casacore::Array<casacore::uInt>
& out,
const
casacore::Array<casacore::Int>
& in);
91
virtual
casacore::Bool
operator()
(
casacore::Array<casacore::uInt>
& out,
const
casacore::Array<casacore::uLong>
& in);
92
virtual
casacore::Bool
operator()
(
casacore::Array<casacore::uInt>
& out,
const
casacore::Array<casacore::Long>
& in);
93
virtual
casacore::Bool
operator()
(
casacore::Array<casacore::uInt>
& out,
const
casacore::Array<casacore::Float>
& in);
94
virtual
casacore::Bool
operator()
(
casacore::Array<casacore::uInt>
& out,
const
casacore::Array<casacore::Double>
& in);
95
virtual
casacore::Bool
operator()
(
casacore::Array<casacore::uInt>
& out,
const
casacore::Array<casacore::Complex>
& in);
96
virtual
casacore::Bool
operator()
(
casacore::Array<casacore::uInt>
& out,
const
casacore::Array<casacore::DComplex>
& in);
97
// </group>
98
99
};
100
101
102
}
//# NAMESPACE CASA - END
103
104
#endif
casa::WCLinearScaleHandler::operator()
virtual casacore::Bool operator()(casacore::Array< casacore::uInt > &out, const casacore::Array< casacore::Bool > &in)
apply returns true if the array in was converted to the array out successfully the last parameter set...
aips.h
casa::WCLinearScaleHandler::WCLinearScaleHandler
WCLinearScaleHandler()
Default Constructor Required.
WCDataScaleHandler.h
casacore::Bool
bool Bool
Define the standard types used by Casacore.
Definition:
aipstype.h:42
casa::WCLinearScaleHandler::~WCLinearScaleHandler
virtual ~WCLinearScaleHandler()
Destructor.
casacore::Array< casacore::uInt >
casa::WCLinearScaleHandler
Linear scaling of data for WorldCanvases.
Definition:
WCLinearScaleHandler.h:71
casa::WCDataScaleHandler
Class implementing simple data scaling for the WorldCanvas.
Definition:
WCDataScaleHandler.h:113
Generated on Sun Sep 1 2019 23:32:30 for casa by
1.8.5