Blender V4.3
openexr_stub.cpp File Reference
#include "openexr_api.h"
#include "IMB_openexr.hh"

Go to the source code of this file.

Functions

void * IMB_exr_get_handle ()
 
void * IMB_exr_get_handle_name (const char *)
 
void IMB_exr_add_channel (void *, const char *, const char *, const char *, int, int, float *, bool)
 
bool IMB_exr_begin_read (void *, const char *, int *, int *, const bool)
 
bool IMB_exr_begin_write (void *, const char *, int, int, int, const StampData *)
 
void IMB_exrtile_begin_write (void *, const char *, int, int, int, int, int)
 
bool IMB_exr_set_channel (void *, const char *, const char *, int, int, float *)
 
floatIMB_exr_channel_rect (void *, const char *, const char *, const char *)
 
void IMB_exr_read_channels (void *)
 
void IMB_exr_write_channels (void *)
 
void IMB_exrtile_write_channels (void *, int, int, int, const char *, bool)
 
void IMB_exr_clear_channels (void *)
 
void IMB_exr_multilayer_convert (void *, void *, void *(*)(void *base, const char *str), void *(*)(void *base, const char *str), void(*)(void *base, void *lay, const char *str, float *rect, int totchan, const char *chan_id, const char *view))
 
void IMB_exr_close (void *)
 
void IMB_exr_add_view (void *, const char *)
 
bool IMB_exr_has_multilayer (void *)
 

Function Documentation

◆ IMB_exr_add_channel()

void IMB_exr_add_channel ( void * handle,
const char * layname,
const char * passname,
const char * viewname,
int xstride,
int ystride,
float * rect,
bool use_half_float )

Adds flattened ExrChannel's xstride, ystride and rect can be done in set_channel too, for tile writing.

Parameters
passnameDoes not include view.

Definition at line 21 of file openexr_stub.cpp.

References BLI_addtail(), exr_printf(), imb_exr_get_multiView_id(), imb_exr_insert_view_name(), ExrChannel::m, ExrChannel::name, ExrChannel::rect, STRNCPY, ExrChannel::use_half_float, ExrChannel::view_id, ExrChannel::xstride, and ExrChannel::ystride.

Referenced by add_exr_compositing_result(), BKE_image_render_write_exr(), and render_layer_add_pass().

◆ IMB_exr_add_view()

void IMB_exr_add_view ( void * handle,
const char * name )

Definition at line 104 of file openexr_stub.cpp.

References ExrHandle::multiView.

Referenced by BKE_image_render_write_exr().

◆ IMB_exr_begin_read()

bool IMB_exr_begin_read ( void * handle,
const char * filepath,
int * width,
int * height,
bool parse_channels )

◆ IMB_exr_begin_write()

bool IMB_exr_begin_write ( void * handle,
const char * filepath,
int width,
int height,
int compress,
const StampData * stamp )

Used for output files (from RenderResult) (single and multi-layer, single and multi-view).

Definition at line 40 of file openexr_stub.cpp.

References BKE_stamp_info_callback(), imb_exr_type_by_channels(), LISTBASE_FOREACH, openexr_header_compression(), and openexr_header_metadata_callback().

Referenced by BKE_image_render_write_exr().

◆ IMB_exr_channel_rect()

float * IMB_exr_channel_rect ( void * handle,
const char * layname,
const char * passname,
const char * viewname )

◆ IMB_exr_clear_channels()

void IMB_exr_clear_channels ( void * handle)

Definition at line 86 of file openexr_stub.cpp.

References BLI_freelistN(), and LISTBASE_FOREACH.

◆ IMB_exr_close()

◆ IMB_exr_get_handle()

void * IMB_exr_get_handle ( )

◆ IMB_exr_get_handle_name()

void * IMB_exr_get_handle_name ( const char * name)

Definition at line 17 of file openexr_stub.cpp.

References BLI_rfindstring(), data, exrhandles, IMB_exr_get_handle(), offsetof, and STRNCPY.

◆ IMB_exr_has_multilayer()

bool IMB_exr_has_multilayer ( void * handle)

Definition at line 105 of file openexr_stub.cpp.

References imb_exr_is_multi().

Referenced by load_image_single().

◆ IMB_exr_multilayer_convert()

void IMB_exr_multilayer_convert ( void * ,
void * ,
void * *)(void *base, const char *str,
void * *)(void *base, const char *str,
void(*  )(void *base, void *lay, const char *str, float *rect, int totchan, const char *chan_id, const char *view) )

Definition at line 88 of file openexr_stub.cpp.

◆ IMB_exr_read_channels()

void IMB_exr_read_channels ( void * handle)

◆ IMB_exr_set_channel()

bool IMB_exr_set_channel ( void * handle,
const char * layname,
const char * passname,
int xstride,
int ystride,
float * rect )

Still clumsy name handling, layers/channels can be ordered as list in list later.

Parameters
passnameHere is the raw channel name without the layer.

Definition at line 59 of file openexr_stub.cpp.

References BLI_findstring(), BLI_strncpy(), EXR_LAY_MAXNAME, EXR_PASS_MAXNAME, EXR_TOT_MAXNAME, offsetof, ExrChannel::rect, SNPRINTF, ExrChannel::xstride, and ExrChannel::ystride.

Referenced by render_result_exr_file_read_path().

◆ IMB_exr_write_channels()

void IMB_exr_write_channels ( void * handle)

◆ IMB_exrtile_begin_write()

void IMB_exrtile_begin_write ( void * handle,
const char * filepath,
int mipmap,
int width,
int height,
int tilex,
int tiley )

Only used for writing temp. render results (not image files) (FSA and Save Buffers).

Definition at line 49 of file openexr_stub.cpp.

References BLI_assert, exr_printf(), and LISTBASE_FOREACH.

◆ IMB_exrtile_write_channels()

void IMB_exrtile_write_channels ( void * handle,
int partx,
int party,
int level,
const char * viewname,
bool empty )

Temporary function, used for FSA and Save Buffers. called once per tile * view.

Definition at line 78 of file openexr_stub.cpp.

References exr_printf(), imb_exr_get_multiView_id(), LISTBASE_FOREACH, STREQ, and view.