12 # include <vcl_msvc_warnings.h> 36 unsigned first,
int skip,
40 assert(
int(first) +
int(n)*skip >= 0);
41 assert((
unsigned)(first + n*skip) <= im.
nplanes());
62 unsigned nplanes()
const override {
return 1; }
63 unsigned ni()
const override {
return src_->ni(); }
64 unsigned nj()
const override {
return src_->nj(); }
69 unsigned j0,
unsigned nj)
const override;
72 unsigned j0,
unsigned nj)
const override;
77 unsigned j0)
override;
80 bool get_property(
char const* tag,
void* property_value =
nullptr)
const override {
81 return src_->get_property(tag, property_value); }
90 #endif // vil_plane_h_ An abstract base class of smart pointers to actual image data in memory.
unsigned ni() const override
Dimensions: Planes x ni x nj.
unsigned plane_
which plane.
unsigned nplanes() const override
Dimensions: Planes x ni x nj.
Concrete view of image data of type T held in memory.
enum vil_pixel_format pixel_format() const override
Pixel Format.
vil_image_resource_sptr src_
Reference to underlying image source.
unsigned nj() const override
Dimensions: Planes x ni x nj.
std::ptrdiff_t jstep() const
Add this to your pixel pointer to get next j pixel.
unsigned ni() const
Width.
unsigned nj() const
Height.
std::ptrdiff_t planestep() const
Add this to your pixel pointer to get pixel on next plane.
bool get_property(char const *tag, void *property_value=nullptr) const override
Extra property information.
bool put_view(const vil_image_view_base &im, unsigned i0, unsigned j0) override
Put the data in this view back into the image source.
Abstract representation of an image source or image destination.
friend vil_image_resource_sptr vil_plane(const vil_image_resource_sptr &src, unsigned p)
Return a specific plane of an image.
A generic_image adaptor that behaves like a single plane version of its input.
vil_image_view_base_sptr get_copy_view() const
Create a read/write view of a copy of all the data.
A base class reference-counting view of some image data.
vil_plane_image_resource(vil_image_resource_sptr const &, unsigned p)
T * top_left_ptr()
Pointer to the first (top left in plane 0) pixel.
vil_image_view< T > vil_plane(const vil_image_view< T > &im, unsigned p)
Return a view of im's plane p.
unsigned nplanes() const
Number of planes.
const vil_memory_chunk_sptr & memory_chunk() const
Smart pointer to the object holding the data for this view.
Representation of a generic image source or destination.
vil_image_view< T > vil_planes(const vil_image_view< T > &im, unsigned first, int skip, unsigned n)
Return a view of a selection of im's planes.
std::ptrdiff_t istep() const
Add this to your pixel pointer to get next i pixel.
vil_image_view_base_sptr get_view() const
Create a read/write view of all the data.