neuray API Programmer's Manual

iimage.h File Reference

Description

Scene element Image.

Code Example

iimage.h

‎/***************************************************************************************************
 * Copyright 2024 NVIDIA Corporation. All rights reserved.
 **************************************************************************************************/

#ifndef MI_NEURAYLIB_IIMAGE_H
#define MI_NEURAYLIB_IIMAGE_H

#include <mi/neuraylib/iscene_element.h>
#include <mi/neuraylib/version.h>

namespace mi {

class IArray;

namespace neuraylib {

class ICanvas;
class IReader;































class IImage :
    public base::Interface_declare<0xca59b977,0x30ee,0x4172,0x91,0x53,0xb7,0x70,0x2c,0x6b,0x3a,0x76,
                                   neuraylib::IScene_element>
{
public:


    virtual Sint32 
               reset_file( const char* filename, const char* selector = 0) = 0;

    virtual Sint32 
               reset_reader(
        IReader* reader, const char* image_format, const char* selector = 0) = 0;

    virtual Sint32 
               reset_reader(
        IArray* reader, const char* image_format, const char* selector = 0) = 0;

    virtual bool set_from_canvas(
        const ICanvas* canvas, const char* selector = 0) = 0;

    virtual bool set_from_canvas(
        ICanvas* canvas, const char* selector = 0, bool shared = false) = 0;

#ifdef MI_NEURAYLIB_DEPRECATED_14_0
    inline bool set_from_canvas( ICanvas* canvas, bool shared)
    { return set_from_canvas( canvas, 0, shared); }
#endif

    virtual bool set_from_canvas(
        const IArray* uvtiles, const char* selector = 0) = 0;

    virtual bool set_from_canvas(
        IArray* uvtiles, const char* selector = 0, bool shared = false) = 0;

#ifdef MI_NEURAYLIB_DEPRECATED_14_0
    inline bool set_from_canvas( IArray* uvtiles, bool shared)
    { return set_from_canvas( uvtiles, 0, shared); }
#endif




    virtual bool is_animated() const = 0;

    virtual Size 
               get_length() const = 0;

    virtual Size 
               get_frame_number( Size frame_id) const = 0;

    virtual Size 
               get_frame_id( Size frame_number) const = 0;




    virtual bool is_uvtile() const = 0;

    virtual Size 
               get_frame_length( Size frame_id) const = 0;

    virtual Sint32 
               get_uvtile_uv( Size frame_id, Size uvtile_id, Sint32& u, Sint32& v) const = 0;

    virtual Size 
               get_uvtile_id( Size frame_id, Sint32 u, Sint32 v) const = 0;

    virtual void get_uvtile_uv_ranges(
        Size frame_id, Sint32& min_u, Sint32& min_v, Sint32& max_u, Sint32& max_v) const = 0;




    virtual const char* get_filename( Size frame_id, Size uvtile_id) const = 0;

    virtual const char* get_original_filename() const = 0;

    virtual const char* get_selector() const = 0;

    virtual const ICanvas* get_canvas( Size frame_id, Size uvtile_id, Uint32 level) const = 0;




    virtual const char* get_type( Size frame_id, Size uvtile_id) const = 0 ;

    virtual Uint32 
               get_levels( Size frame_id, Size uvtile_id) const = 0;

    virtual Uint32 
               resolution_x( Size frame_id, Size uvtile_id, Uint32 level) const = 0;

    virtual Uint32 
               resolution_y( Size frame_id, Size uvtile_id, Uint32 level) const = 0;

    virtual Uint32 
               resolution_z( Size frame_id, Size uvtile_id, Uint32 level) const = 0;

};
 // end group mi_neuray_misc

} // namespace neuraylib

} // namespace mi

#endif // MI_NEURAYLIB_IIMAGE_H

Namespaces

namespace 
Common namespace for APIs of NVIDIA Advanced Rendering Center GmbH. More...
namespace 
Namespace for the neuray API. More...

Classes

class 
This interface represents a pixel image file. More...