00001
00002 #ifndef vil1_resample_image_impl_h_
00003 #define vil1_resample_image_impl_h_
00004 #ifdef VCL_NEEDS_PRAGMA_INTERFACE
00005 #pragma interface
00006 #endif
00007
00008
00009
00010
00011
00012 #include <vil1/vil1_image_impl.h>
00013 #include <vil1/vil1_image.h>
00014 #include <vcl_string.h>
00015
00016
00017
00018
00019 class vil1_resample_image_impl : public vil1_image_impl
00020 {
00021 public:
00022 vil1_resample_image_impl(vil1_image const &underlying, unsigned nw, unsigned nh);
00023 ~vil1_resample_image_impl() {}
00024
00025
00026 int planes() const { return base.planes(); }
00027 int width() const { return new_width; }
00028 int height() const { return new_height; }
00029 int components() const { return base.components(); }
00030 int bits_per_component() const { return base.bits_per_component(); }
00031 vil1_component_format component_format() const { return base.component_format(); }
00032
00033 vil1_image get_plane(unsigned int p) const;
00034
00035 bool get_section(void *buf, int x0, int y0, int w, int h) const;
00036 bool put_section(void const *buf, int x0, int y0, int w, int h);
00037
00038 bool get_property(char const *tag, void *property_value_out = 0) const;
00039
00040
00041 virtual vcl_string is_a() const { return "vil1_resample_image_impl"; }
00042
00043
00044 virtual bool is_class(vcl_string const& s) const
00045 { return s==is_a() || vil1_image_impl::is_class(s); }
00046
00047 private:
00048 vil1_image base;
00049 unsigned new_width, new_height;
00050 };
00051
00052 #endif // vil1_resample_image_impl_h_