Blender  V2.59
Functions
allocimbuf.c File Reference
#include <stddef.h>
#include "IMB_imbuf.h"
#include "IMB_imbuf_types.h"
#include "IMB_allocimbuf.h"
#include "IMB_filetype.h"
#include "IMB_metadata.h"
#include "imbuf.h"
#include "MEM_CacheLimiterC-Api.h"
#include "MEM_guardedalloc.h"

Go to the source code of this file.

Functions

void imb_freemipmapImBuf (ImBuf *ibuf)
void imb_freerectfloatImBuf (ImBuf *ibuf)
void imb_freerectImBuf (ImBuf *ibuf)
void imb_freetilesImBuf (ImBuf *ibuf)
static void freeencodedbufferImBuf (ImBuf *ibuf)
void IMB_freezbufImBuf (ImBuf *ibuf)
void IMB_freezbuffloatImBuf (ImBuf *ibuf)
void IMB_freeImBuf (ImBuf *ibuf)
void IMB_refImBuf (ImBuf *ibuf)
short addzbufImBuf (ImBuf *ibuf)
short addzbuffloatImBuf (ImBuf *ibuf)
short imb_addencodedbufferImBuf (ImBuf *ibuf)
short imb_enlargeencodedbufferImBuf (ImBuf *ibuf)
short imb_addrectfloatImBuf (ImBuf *ibuf)
short imb_addrectImBuf (ImBuf *ibuf)
short imb_addtilesImBuf (ImBuf *ibuf)
ImBufIMB_allocImBuf (unsigned int x, unsigned int y, uchar d, unsigned int flags)
ImBufIMB_dupImBuf (ImBuf *ibuf1)
static void imbuf_cache_destructor (void *data)
static MEM_CacheLimiterC ** get_imbuf_cache_limiter (void)
void IMB_free_cache_limiter (void)
void IMB_cache_limiter_insert (ImBuf *i)
void IMB_cache_limiter_unmanage (ImBuf *i)
void IMB_cache_limiter_touch (ImBuf *i)
void IMB_cache_limiter_ref (ImBuf *i)
void IMB_cache_limiter_unref (ImBuf *i)
int IMB_cache_limiter_get_refcount (ImBuf *i)

Detailed Description

Definition in file allocimbuf.c.


Function Documentation

short addzbuffloatImBuf ( ImBuf ibuf)
short addzbufImBuf ( struct ImBuf ibuf)
Attention:
Defined in allocimbuf.c

Definition at line 180 of file allocimbuf.c.

References FALSE, ImBuf::flags, IB_zbuf, IMB_freezbufImBuf(), ImBuf::mall, MEM_mapallocN(), NULL, size(), TRUE, ImBuf::x, ImBuf::y, and ImBuf::zbuf.

Referenced by imb_addrectImBuf(), and IMB_allocImBuf().

static void freeencodedbufferImBuf ( ImBuf ibuf) [static]
static MEM_CacheLimiterC** get_imbuf_cache_limiter ( void  ) [static]
short imb_addencodedbufferImBuf ( ImBuf ibuf)
short imb_addrectfloatImBuf ( ImBuf ibuf)
short imb_addrectImBuf ( ImBuf ibuf)
short imb_addtilesImBuf ( ImBuf ibuf)
ImBuf* IMB_allocImBuf ( unsigned int  x,
unsigned int  y,
unsigned char  d,
unsigned int  flags 
) [read]
Attention:
Defined in allocimbuf.c

Definition at line 333 of file allocimbuf.c.

References addzbuffloatImBuf(), addzbufImBuf(), ImBuf::channels, simple_enum_gen::d, ImBuf::depth, FALSE, ImBuf::ftype, IB_rect, IB_rectfloat, IB_zbuf, IB_zbuffloat, imb_addrectfloatImBuf(), imb_addrectImBuf(), IMB_freeImBuf(), MEM_callocN(), NULL, ImBuf::ppm, TGA, ImBuf::x, and ImBuf::y.

Referenced by add_ibuf_size(), allocImBuf(), anim_getnew(), avi_fetchibuf(), BKE_image_acquire_ibuf(), BL_MakeScreenShot(), brush_imbuf_new(), brush_painter_fixed_tex_partial_update(), de_interlace_ng(), de_interlace_st(), do_displace(), do_mapuv(), do_paintface_box_select(), do_write_image_or_movie(), ED_view3d_draw_offscreen_imbuf(), envmap_split_ima(), filelist_from_library(), filelist_init_icons(), GHOST_SystemCocoa::handleDraggingEvent(), ibJpegImageFromCinfo(), icon_draw_rect(), image_get_ibuf_multilayer(), image_get_render_result(), image_load_sequence_multilayer(), image_undo_push_tile(), image_undo_restore(), imapaint_lift_clone(), imb_bmp_decode(), imb_cocoaLoadImage(), IMB_de_interlace(), IMB_double_fast_x(), IMB_double_fast_y(), IMB_dupImBuf(), IMB_half_x(), IMB_half_y(), IMB_interlace(), imb_load_dds(), imb_load_dpx_cineon(), imb_load_openexr(), imb_loadiris(), imb_loadpng(), imb_loadtarga(), IMB_makemipmap(), IMB_onehalf(), IMB_remakemipmap(), IMB_thumb_create(), input_preprocess(), loadblend_thumb(), make_histogram_view_from_ibuf_byte(), make_histogram_view_from_ibuf_float(), make_sep_waveform_view_from_ibuf_byte(), make_sep_waveform_view_from_ibuf_float(), make_vectorscope_view_from_ibuf_byte(), make_vectorscope_view_from_ibuf_float(), make_waveform_view_from_ibuf_byte(), make_waveform_view_from_ibuf_float(), make_zebra_view_from_ibuf(), my_envmap_split_ima(), node_composit_exec_output_file(), node_composit_exec_rotate(), node_composit_exec_scale(), ImageBuff::plot(), prepare_effect_imbufs(), RE_layer_load_from_file(), render_envmap(), save_envmap(), save_jstjpeg(), screen_opengl_render_anim_step(), screenshot_exec(), screenshot_startjob(), seq_render_effect_strip_impl(), seq_render_scene_strip_impl(), seq_render_strip(), seq_render_strip_stack(), and view3d_read_backbuf().

int IMB_cache_limiter_get_refcount ( ImBuf i)

Definition at line 507 of file allocimbuf.c.

References ImBuf::c_handle, and MEM_CacheLimiter_get_refcount().

void IMB_cache_limiter_insert ( struct ImBuf i)
void IMB_cache_limiter_ref ( ImBuf i)

Definition at line 495 of file allocimbuf.c.

References ImBuf::c_handle, and MEM_CacheLimiter_ref().

void IMB_cache_limiter_touch ( ImBuf i)

Definition at line 489 of file allocimbuf.c.

References ImBuf::c_handle, and MEM_CacheLimiter_touch().

void IMB_cache_limiter_unmanage ( ImBuf i)

Definition at line 481 of file allocimbuf.c.

References ImBuf::c_handle, MEM_CacheLimiter_unmanage(), and NULL.

Referenced by IMB_freeImBuf().

void IMB_cache_limiter_unref ( ImBuf i)

Definition at line 501 of file allocimbuf.c.

References ImBuf::c_handle, and MEM_CacheLimiter_unref().

ImBuf* IMB_dupImBuf ( struct ImBuf ibuf1) [read]
short imb_enlargeencodedbufferImBuf ( ImBuf ibuf)
void IMB_free_cache_limiter ( void  )

Definition at line 463 of file allocimbuf.c.

References delete_MEM_CacheLimiter(), get_imbuf_cache_limiter(), and NULL.

Referenced by IMB_exit().

void IMB_freeImBuf ( struct ImBuf ibuf)
Attention:
Defined in allocimbuf.c

Definition at line 155 of file allocimbuf.c.

References freeencodedbufferImBuf(), IMB_cache_limiter_unmanage(), imb_freerectfloatImBuf(), imb_freerectImBuf(), imb_freetilesImBuf(), IMB_freezbuffloatImBuf(), IMB_freezbufImBuf(), IMB_metadata_free(), MEM_freeN(), and ImBuf::refcounter.

Referenced by avi_fetchibuf(), BKE_free_envmapdata(), BKE_image_free_anim_ibufs(), BL_MakeScreenShot(), brush_painter_fixed_tex_partial_update(), brush_painter_free(), brush_painter_refresh_cache(), brush_painter_require_imbuf(), ImageBuff::clear(), copy_from_ibuf_still(), copy_to_ibuf_still(), curvemapping_do_ibuf(), de_interlace_ng(), de_interlace_st(), do_adjustment(), do_displace(), do_mapuv(), do_multicam(), do_paintface_box_select(), do_plugin_effect(), do_render_seq(), do_write_image_or_movie(), draw_image_seq(), EM_init_backbuf_border(), EM_init_backbuf_circle(), EM_mask_init_backbuf_border(), filelist_free(), filelist_free_icons(), filelist_init_icons(), free_brush(), freeImBuf(), HashValFree(), icon_copy_rect(), icon_draw_rect(), image_free_buffers(), image_load_image_file(), image_load_sequence_file(), image_remove_ibuf(), image_undo_restore(), imapaint_dirty_region(), imapaint_paint_op(), IMB_allocImBuf(), IMB_anim_absolute(), IMB_anim_previewframe(), IMB_de_interlace(), IMB_dupImBuf(), IMB_free_anim_ibuf(), imb_freemipmapImBuf(), IMB_interlace(), imb_load_openexr(), imb_loadpng(), IMB_makemipmap(), IMB_remakemipmap(), IMB_seq_cache_destructor(), IMB_thumb_create(), IMB_thumb_manage(), init_iconfile_list(), init_internal_icons(), input_preprocess(), ImageBuff::load(), loadblend_thumb(), my_free_envmapdata(), node_composit_exec_output_file(), node_composit_exec_rotate(), node_composit_exec_scale(), openanim(), ImageBuff::plot(), project_paint_end(), RE_layer_load_from_file(), sample_backbuf_area(), save_envmap(), save_jstjpeg(), screen_opengl_render_anim_step(), screen_opengl_render_apply(), screenshot_exec(), screenshot_startjob(), seq_render_effect_strip_impl(), seq_render_strip(), seq_render_strip_stack(), thumbnail_joblist_free(), ui_draw_but_IMAGE(), view3d_read_backbuf(), view3d_sample_backbuf_rect(), WM_write_file(), GHOST_EventDragnDrop::~GHOST_EventDragnDrop(), and ImageBuff::~ImageBuff().

void imb_freemipmapImBuf ( ImBuf ibuf)
void imb_freerectfloatImBuf ( ImBuf ibuf)
void imb_freerectImBuf ( ImBuf ibuf)
void imb_freetilesImBuf ( ImBuf ibuf)
void IMB_freezbuffloatImBuf ( ImBuf ibuf)
void IMB_freezbufImBuf ( struct ImBuf ibuf)
void IMB_refImBuf ( struct ImBuf ibuf)

Increase reference count to imbuf (to delete an imbuf you have to call freeImBuf as many times as it is referenced)

Attention:
Defined in allocimbuf.c

Definition at line 175 of file allocimbuf.c.

References ImBuf::refcounter.

Referenced by seq_render_effect_strip_impl(), seq_stripelem_cache_get(), and seq_stripelem_cache_put().

static void imbuf_cache_destructor ( void *  data) [static]