neuray API Programmer's Manual

ibsdf_measurement.h File Reference

Description

Scene element Bsdf_measurement.

Code Example

ibsdf_measurement.h

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

#ifndef MI_NEURAYLIB_IBSDF_MEASUREMENT_H
#define MI_NEURAYLIB_IBSDF_MEASUREMENT_H

#include <mi/neuraylib/iscene_element.h>

namespace mi {

namespace neuraylib {

class IBsdf_isotropic_data;
class IReader;














class IBsdf_measurement :
    public base::Interface_declare<0xa05e5a42,0x3f74,0x4ad9,0x8e,0xa9,0x17,0x4f,0x97,0x52,0x39,0x8a,
                                   neuraylib::IScene_element>
{
public:
    virtual Sint32 
               reset_file( const char* filename) = 0;

    virtual Sint32 
               reset_reader( IReader* reader) = 0;

    virtual const char* get_filename() const = 0;

    virtual const char* get_original_filename() const = 0;

    virtual Sint32 
               set_reflection( const IBsdf_isotropic_data* bsdf_data) = 0;

    virtual const base::IInterface* get_reflection() const = 0;

    template<class T>
    const T* get_reflection() const
    {
        const base::IInterface* ptr_iinterface = get_reflection();
        if( !ptr_iinterface)
            return 0;
        const T* ptr_T = static_cast<const T*>( ptr_iinterface->get_interface( typename T::IID()));
        ptr_iinterface->release();
        return ptr_T;
    }

    virtual Sint32 
               set_transmission( const IBsdf_isotropic_data* bsdf_data) = 0;

    virtual const base::IInterface* get_transmission() const = 0;

    template<class T>
    const T* get_transmission() const
    {
        const base::IInterface* ptr_iinterface = get_transmission();
        if( !ptr_iinterface)
            return 0;
        const T* ptr_T = static_cast<const T*>( ptr_iinterface->get_interface( typename T::IID()));
        ptr_iinterface->release();
        return ptr_T;
    }
};
 // end group mi_neuray_misc

} // namespace neuraylib

} // namespace mi

#endif // MI_NEURAYLIB_IBSDF_MEASUREMENT_H

Namespaces

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

Classes

class 
A scene element that stores measured BSDF data. More...