47 return _(
"base buffer");
94 .backtransform = NULL,
120 const void *
const ivoid,
void *
const ovoid)
133 const size_t x =
MAX(roi_out->
x, 0);
134 const size_t y =
MAX(roi_out->
y, 0);
141 const size_t row_bytes = in_width * piece->
dsc_in.
bpp;
144 const size_t y_offset = y * in_stride;
145 const size_t x_offset =
x * piece->
dsc_in.
bpp;
150 const void *
const restrict input = buf.
buf;
153 for(
size_t j = 0; j < in_height; j++)
154 memcpy(
ovoid + j * out_stride, input + x_offset + y_offset + j * in_stride,
MIN(row_bytes, out_stride));
175 const size_t x =
MAX(roi_out->
x, 0);
176 const size_t y =
MAX(roi_out->
y, 0);
182 const size_t y_offset = y * in_stride;
183 const size_t x_offset =
x * piece->
dsc_in.
bpp;
188 const void *
const restrict input = buf.
buf;
192 size_t origin[] = { 0, 0, 0 };
196 region, in_stride, CL_TRUE);
201 return err == CL_SUCCESS;
void modify_roi_out(dt_iop_module_t *self, const dt_dev_pixelpipe_t *pipe, dt_dev_pixelpipe_iop_t *piece, dt_iop_roi_t *roi_out, const dt_iop_roi_t *const roi_in)
static void _basebuffer_geometry_map_size(const void *data, const dt_iop_roi_t *const in, dt_iop_roi_t *out)
__DT_CLONE_TARGETS__ int process(dt_iop_module_t *self, const dt_dev_pixelpipe_t *pipe, const dt_dev_pixelpipe_iop_t *piece, const void *const ivoid, void *const ovoid)
void modify_roi_in(dt_iop_module_t *self, const dt_dev_pixelpipe_t *pipe, dt_dev_pixelpipe_iop_t *piece, const dt_iop_roi_t *const roi_out, dt_iop_roi_t *roi_in)
static const dt_geometry_vtable_t _basebuffer_geometry_vtable
void output_format(dt_iop_module_t *self, dt_dev_pixelpipe_t *pipe, dt_dev_pixelpipe_iop_t *piece, dt_iop_buffer_dsc_t *dsc)
gboolean geometry_record(dt_iop_module_t *self, const void *params, dt_geometry_record_t *record)
void cleanup_pipe(dt_iop_module_t *self, dt_dev_pixelpipe_t *pipe, dt_dev_pixelpipe_iop_t *piece)
int default_colorspace(dt_iop_module_t *self, dt_dev_pixelpipe_t *pipe, const dt_dev_pixelpipe_iop_t *piece)
void input_format(dt_iop_module_t *self, dt_dev_pixelpipe_t *pipe, dt_dev_pixelpipe_iop_t *piece, dt_iop_buffer_dsc_t *dsc)
void init(dt_iop_module_t *self)
void init_pipe(dt_iop_module_t *self, dt_dev_pixelpipe_t *pipe, dt_dev_pixelpipe_iop_t *piece)
dt_iop_basebuffer_params_t dt_iop_basebuffer_data_t
int process_cl(struct dt_iop_module_t *self, const dt_dev_pixelpipe_t *pipe, const dt_dev_pixelpipe_iop_t *piece, cl_mem dev_in, cl_mem dev_out)
void cleanup(dt_iop_module_t *self)
const dt_colormatrix_t dt_aligned_pixel_t out
Where things are on the image, answered without a pipeline.
@ IOP_FLAGS_TAKE_NO_INPUT
@ IOP_FLAGS_CPU_WRITES_OPENCL
@ IOP_FLAGS_NO_HISTORY_STACK
#define dt_free_align(ptr)
Release memory from dt_alloc_align() and set ptr to NULL.
static void * dt_calloc_align(size_t size)
dt_alloc_align() followed by a zero fill.
#define dt_free(ptr)
g_free() ptr and set it to NULL, skipping both if it is already NULL.
#define dt_mipmap_cache_get(B, C, D, E, F)
#define dt_mipmap_cache_release(B)
#define DT_MODULE_INTROSPECTION(MODVER, PARAMSTYPE)
DT_MODULE() for a module whose params struct is introspected.
int dt_opencl_write_host_to_device_raw(const int devid, const void *host, void *device, const size_t *origin, const size_t *region, const int rowpitch, const int blocking)
#define __OMP_PARALLEL_FOR__(...)
dt_iop_buffer_dsc_t dsc_out
dt_iop_buffer_dsc_t dsc_in
struct dt_iop_module_t *void * data
struct dt_develop_t * dev
One module instance's contribution, as data.
const dt_geometry_vtable_t * vtable
A module's geometry, evaluated. Pure functions of the record's own data.
void(* map_size)(const void *data, const dt_iop_roi_t *const in, dt_iop_roi_t *out)
Full-resolution input rect -> output rect. Mirrors modify_roi_out() at scale 1.
int32_t hide_enable_button
dt_iop_params_t * default_params
Region of interest passed through the pixelpipe.
#define __DT_CLONE_TARGETS__