Material Definition Language API nvidia_logo_transpbg.gif Up
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
iimage.h
Go to the documentation of this file.
1 /***************************************************************************************************
2  * Copyright 2020 NVIDIA Corporation. All rights reserved.
3  **************************************************************************************************/
6 
7 #ifndef MI_NEURAYLIB_IIMAGE_H
8 #define MI_NEURAYLIB_IIMAGE_H
9 
11 
12 namespace mi {
13 
14 class IArray;
15 
16 namespace neuraylib {
17 
18 class ICanvas;
19 class IReader;
20 
32 class IImage :
63  public base::Interface_declare<0xca59b977,0x30ee,0x4172,0x91,0x53,0xb7,0x70,0x2c,0x6b,0x3a,0x76,
64  neuraylib::IScene_element>
65 {
66 public:
113  virtual Sint32 reset_file( const char* filename) = 0;
114 
128  virtual Sint32 reset_reader( IReader* reader, const char* image_format) = 0;
129 
150  virtual Sint32 reset_reader( IArray* reader, const char* image_format) = 0;
151 
159  virtual const char* get_filename( Uint32 uvtile_id = 0) const = 0;
160 
166  virtual const char* get_original_filename() const = 0;
167 
176  virtual bool set_from_canvas( const ICanvas* canvas) = 0;
177 
189  virtual bool set_from_canvas( ICanvas* canvas, bool shared = false) = 0;
190 
206  virtual bool set_from_canvas( const IArray* uvtiles) = 0;
207 
229  virtual bool set_from_canvas( IArray* uvtiles, bool shared = false) = 0;
230 
239  virtual const ICanvas* get_canvas( Uint32 level = 0, Uint32 uvtile_id = 0) const = 0;
240 
246  virtual const char* get_type( Uint32 uvtile_id = 0) const = 0 ;
247 
252  virtual Uint32 get_levels( Uint32 uvtile_id = 0) const = 0;
253 
259  virtual Uint32 resolution_x( Uint32 level = 0, Uint32 uvtile_id = 0) const = 0;
260 
266  virtual Uint32 resolution_y( Uint32 level = 0, Uint32 uvtile_id = 0) const = 0;
267 
273  virtual Uint32 resolution_z( Uint32 level = 0, Uint32 uvtile_id = 0) const = 0;
274 
277  virtual Size get_uvtile_length() const = 0;
278 
285  virtual Sint32 get_uvtile_uv( Uint32 uvtile_id, Sint32& u, Sint32& v) const = 0;
286 
287  // Returns the uvtile-id corresponding to the tile at u,v.
292  virtual Uint32 get_uvtile_id( Sint32 u, Sint32 v) const = 0;
293 
295  virtual bool is_uvtile() const = 0;
296 
299  virtual void get_uvtile_uv_ranges(
300  Sint32& min_u, Sint32& min_v, Sint32& max_u, Sint32& max_v) const = 0;
301 };
302  // end group mi_neuray_misc
304 
305 } // namespace neuraylib
306 
307 } // namespace mi
308 
309 #endif // MI_NEURAYLIB_IIMAGE_H