isce3 0.25.0
Loading...
Searching...
No Matches
SLC.icc
1// -*- C++ -*-
2// -*- coding: utf-8 -*-
3//
4// michael a.g. aïvázis <michael.aivazis@para-sim.com>
5// parasim
6// (c) 1998-2019 all rights reserved
7//
8
9// code guard
10#if !defined(ampcor_libampcor_dom_slc_icc)
11#error This header file contains implementation details of class ampcor::dom::SLC
12#endif
13
14
15// interface
16// the memory footprint of individual SLC pixels
17constexpr auto
18ampcor::dom::SLC::
19pixelSize() {
20 // easy enough
21 return sizeof(pixel_type);
22}
23
24
25// my layout
26auto
27ampcor::dom::SLC::
28layout() const {
29 // ask my grid
30 return _grid.layout();
31}
32
33
34// the number of pixels
35auto
36ampcor::dom::SLC::
37pixels() const {
38 // my grid layout knows the answer
39 return _grid.layout().size();
40}
41
42
43// the memory footprint of the raster data
44auto
45ampcor::dom::SLC::
46size() const {
47 // ask my grid for its number of cells a
48 return pixels() * pixelSize();
49}
50
51
52// the location of the data buffer
53auto
54ampcor::dom::SLC::
55data() const {
56 // ask my grid for its number of cells a
57 return _grid.data();
58}
59
60
61// pixel access
62// by index
63const auto &
64ampcor::dom::SLC::
65operator[] (const index_type & index) const {
66 // ask my grid for its number of cells a
67 return _grid[index];
68}
69
70
71// by offset
72const auto &
73ampcor::dom::SLC::
74operator[] (size_type offset) const {
75 // ask my grid for its number of cells a
76 return _grid[offset];
77}
78
79
80// iteration support
81auto
82ampcor::dom::SLC::
83view() {
84 // ask my grid
85 return _grid.view();
86}
87
88
89auto
90ampcor::dom::SLC::
91view(const slice_type & slice) {
92 // ask my grid
93 return _grid.view(slice);
94}
95
96
97auto
98ampcor::dom::SLC::
99view() const {
100 // ask my grid
101 return _grid.view();
102}
103
104
105auto
106ampcor::dom::SLC::
107view(const slice_type & slice) const {
108 // ask my grid
109 return _grid.view(slice);
110}
111
112
113auto
114ampcor::dom::SLC::
115constview(const slice_type & slice) const {
116 // ask my grid
117 return _grid.constview(slice);
118}
119
120
121// constructor
122ampcor::dom::SLC::
123SLC(uri_type filename, shape_type shape) :
124 // the caller provides the {shape}
125 // specify the {layout} explicitly, just in case the default changes...
126 _grid { filename, {shape, {1ul, 0ul}} }
127{}
128
129
130// end of file

Generated for ISCE3.0 by doxygen 1.13.2.