60#ifndef DT_COMMON_IMAGE_H
61#define DT_COMMON_IMAGE_H
72#include "lensserious_vendor.h"
74#include <glib/gi18n.h>
78#define UNKNOWN_IMAGE -1
81#define DT_IMAGE_DBLOCKS 64
314 { N_(
"unknown"),
'.'},
322 { N_(
"rawspeed"),
'r'},
323 { N_(
"netpnm"),
'n'},
326 { N_(
"libraw"),
'l'},
554void dt_image_full_path(
const int32_t imgid,
char *pathname,
size_t pathname_len, gboolean *from_cache,
const char *calling_func);
557 size_t local_copy_len,
char *local_copy_legacy_path,
558 size_t local_copy_legacy_len);
561 size_t pathname_len, gboolean force_cache);
591int32_t
dt_image_import(int32_t film_id,
const char *filename, gboolean raise_signals);
632 const gboolean undo_on,
const gboolean group_on);
635 const gboolean undo_on);
638 const gboolean undo_on);
730int32_t
dt_image_move(
const int32_t imgid,
const int32_t filmid);
734int32_t
dt_image_rename(
const int32_t imgid,
const int32_t filmid,
const gchar *newname);
737int32_t
dt_image_copy(
const int32_t imgid,
const int32_t filmid);
const char * extension(dt_imageio_module_data_t *data)
static void transform(float *x, float *o, const float *m, const float t_h, const float t_v)
const dt_colormatrix_t dt_aligned_pixel_t out
GHashTable * selected
set of checked row labels, mirrored to conf on every change
gboolean dt_image_is_matrix_correction_supported(const dt_image_t *img)
int32_t dt_image_copy_rename(const int32_t imgid, const int32_t filmid, const gchar *newname)
@ DT_IMAGE_COLORSPACE_NONE
@ DT_IMAGE_COLORSPACE_ADOBE_RGB
@ DT_IMAGE_COLORSPACE_SRGB
int32_t dt_image_move(const int32_t imgid, const int32_t filmid)
void dt_image_synch_xmps(const GList *img)
char * dt_image_get_audio_path(const int32_t imgid)
gboolean dt_image_is_raw(const dt_image_t *img)
dt_image_pipe_class_t dt_image_pipe_class(const dt_image_t *img)
@ DT_IMAGE_PATH_LOCAL_COPY_LEGACY
@ DT_IMAGE_PATH_LOCAL_COPY
static dt_image_orientation_t dt_image_orientation_to_flip_bits(const int orient)
int dt_image_get_xmp_rating(const dt_image_t *img)
static const struct @4 loaders_info[LOADER_COUNT]
void dt_image_set_flip(const int32_t imgid, const dt_image_orientation_t user_flip)
void dt_image_check_camera_missing_sample(const struct dt_image_t *img)
dt_image_orientation_t dt_image_get_orientation(const int32_t imgid)
dt_image_flags_t dt_image_flags_from_extension(const char *extension)
void dt_image_path_append_version(const int32_t imgid, char *pathname, size_t pathname_len)
int32_t dt_image_get_id(int32_t film_id, const gchar *filename)
int32_t dt_image_copy(const int32_t imgid, const int32_t filmid)
void dt_image_refresh_makermodel(dt_image_t *img)
int32_t dt_image_duplicate_no_reload(const int32_t imgid)
int dt_image_monochrome_flags(const dt_image_t *img)
uint32_t dt_image_altered(const int32_t imgid)
void dt_image_get_datetime(const int32_t imgid, char *datetime)
const char * dt_image_pipe_class_name(const dt_image_pipe_class_t klass)
float dt_boundingbox_t[4]
char * dt_image_get_text_path_from_path(const char *image_path)
void dt_image_set_location(const int32_t imgid, const dt_image_geoloc_t *geoloc, const gboolean undo_on, const gboolean group_on)
void dt_image_film_roll(const dt_image_t *img, char *pathname, size_t pathname_len)
@ ORIENTATION_ROTATE_CCW_90_DEG
@ ORIENTATION_ROTATE_CW_90_DEG
@ ORIENTATION_ROTATE_180_DEG
@ ORIENTATION_FLIP_VERTICALLY
@ ORIENTATION_FLIP_HORIZONTALLY
void dt_image_print_exif(const dt_image_t *img, char *line, size_t line_len)
void dt_image_synch_all_xmp(const gchar *pathname)
void dt_image_get_location(const int32_t imgid, dt_image_geoloc_t *geoloc)
gboolean dt_image_is_hdr(const dt_image_t *img)
int32_t dt_image_duplicate_with_version(const int32_t imgid, const int32_t newversion)
gboolean dt_image_is_monochrome(const dt_image_t *img)
@ DT_IMAGEIO_UNSUPPORTED_FEATURE
@ DT_IMAGEIO_FILE_CORRUPTED
@ DT_IMAGEIO_UNSUPPORTED_FORMAT
@ DT_IMAGEIO_FILE_NOT_FOUND
@ DT_IMAGEIO_UNSUPPORTED_CAMERA
void dt_image_print_debug_info(const dt_image_t *img, const char *context)
void dt_image_init(dt_image_t *img)
void dt_image_buffer_resolve_flags(dt_image_t *img)
int32_t dt_image_import(int32_t film_id, const char *filename, gboolean raise_signals)
void dt_image_set_datetimes(const GList *imgs, const GArray *dtime, const gboolean undo_on)
const char * dt_image_film_roll_name(const char *path)
float dt_image_get_exposure_bias(const struct dt_image_t *image_storage)
GList * dt_image_find_xmps(const char *filename)
void dt_image_flip(const int32_t imgid, const dt_image_transform_t transform)
Apply an orientation change to one image, on top of the orientation it already has.
void dt_image_set_datetime(const GList *imgs, const char *datetime, const gboolean undo_on)
gboolean dt_image_is_ldr(const dt_image_t *img)
dt_exif_image_orientation_t
@ EXIF_ORIENTATION_TRANSPOSE
@ EXIF_ORIENTATION_ROTATE_180_DEG
@ EXIF_ORIENTATION_FLIP_VERTICALLY
@ EXIF_ORIENTATION_ROTATE_CW_90_DEG
@ EXIF_ORIENTATION_TRANSVERSE
@ EXIF_ORIENTATION_ROTATE_CCW_90_DEG
@ EXIF_ORIENTATION_FLIP_HORIZONTALLY
@ DT_IMAGE_NO_LEGACY_PRESETS
@ DT_IMAGE_HAS_ADDITIONAL_DNG_TAGS
@ DT_IMAGE_AUTO_PRESETS_APPLIED
@ DT_IMAGE_MONOCHROME_BAYER
@ DT_IMAGE_BUFFER_RESOLVED
@ DT_IMAGE_MONOCHROME_WORKFLOW
@ DT_IMAGE_THUMBNAIL_DEPRECATED
@ DT_IMAGE_MONOCHROME_PREVIEW
gboolean dt_image_pipe_class_is_provisional(const dt_image_t *img)
void dt_image_path_append_version_no_db(int version, char *pathname, size_t pathname_len)
gboolean dt_image_needs_rawprepare(const dt_image_t *img)
void dt_image_set_monochrome_flag(const int32_t imgid, gboolean monochrome)
void dt_image_set_images_locations(const GList *imgs, const GArray *gloc, const gboolean undo_on)
char * dt_image_get_audio_path_from_path(const char *image_path)
void dt_image_remove_undoable(const int32_t imgid)
Same as dt_image_remove(), and records the removal on the undo stack.
gboolean dt_image_use_monochrome_workflow(const dt_image_t *img)
int dt_image_local_copy_set(const int32_t imgid)
void dt_image_film_roll_directory(const dt_image_t *img, char *pathname, size_t pathname_len)
dt_image_write_sidecar_result_t
@ DT_IMAGE_WRITE_SIDECAR_OK
@ DT_IMAGE_WRITE_SIDECAR_IO_ERROR
@ DT_IMAGE_WRITE_SIDECAR_CACHE_BUSY
@ DT_IMAGE_WRITE_SIDECAR_NO_SOURCE_PATH
@ DT_IMAGE_WRITE_SIDECAR_DISABLED
gboolean dt_image_get_usercrop_oriented(const dt_image_t *img, const dt_image_orientation_t orientation, dt_boundingbox_t box)
dt_image_path_source_t dt_image_choose_input_path(const dt_image_t *img, char *pathname, size_t pathname_len, gboolean force_cache)
dt_image_transform_t
An orientation change the user asks for, in the coordinates they are looking at.
@ DT_IMAGE_TRANSFORM_FLIP_VERTICALLY
mirror top <-> bottom, as displayed
@ DT_IMAGE_TRANSFORM_ROTATE_CW
quarter turn clockwise
@ DT_IMAGE_TRANSFORM_RESET
back to ORIENTATION_NULL, i.e. what EXIF says
@ DT_IMAGE_TRANSFORM_FLIP_HORIZONTALLY
mirror left <-> right, as displayed
@ DT_IMAGE_TRANSFORM_ROTATE_CCW
quarter turn counter-clockwise
dt_image_write_sidecar_result_t dt_image_write_sidecar_file(const int32_t imgid)
void dt_image_xmp_mode_refresh_from_conf(void)
dt_image_orientation_t dt_image_get_effective_orientation(const dt_image_t *img)
void dt_image_remove(const int32_t imgid)
gboolean dt_image_is_sraw(const dt_image_t *img)
dt_image_pipe_class_t
Mutually-exclusive classification of an image by the early-pipeline processing it requires....
@ DT_IMAGE_PIPE_MOSAIC_RAW
@ DT_IMAGE_PIPE_LINEAR_RAW
gboolean dt_image_is_mosaiced(const dt_image_t *img)
char * dt_image_camera_missing_sample_message(const struct dt_image_t *img, gboolean logmsg)
int dt_image_get_xmp_rating_from_flags(const int flags)
int32_t dt_image_import_lua(int32_t film_id, const char *filename)
int dt_image_read_duplicates(const uint32_t id, const char *filename, const gboolean clear_selection)
void dt_image_orient_boundingbox(const dt_boundingbox_t in, const dt_image_orientation_t orientation, dt_boundingbox_t out)
static dt_image_orientation_t dt_image_orientation(const dt_image_t *img)
dt_view_image_over_t
What a thumbnail shows over an image: its rating, or one of the badge states.
gboolean dt_image_resolve_usercrop(const int32_t imgid, dt_boundingbox_t box)
void dt_image_set_locations(const GList *img, const dt_image_geoloc_t *geoloc, const gboolean undo_on)
dt_image_usercrop_status_t
@ DT_IMAGE_USERCROP_UNKNOWN
@ DT_IMAGE_USERCROP_IDENTITY
@ DT_IMAGE_USERCROP_MALFORMED
@ DT_IMAGE_USERCROP_CONFLICT
@ DT_IMAGE_USERCROP_ABSENT
@ DT_IMAGE_USERCROP_VALID
int dt_image_local_copy_reset(const int32_t imgid)
gboolean dt_image_get_xmp_mode()
char * dt_image_get_text_path(const int32_t imgid)
int32_t dt_image_get_id_full_path(const gchar *filename)
gboolean dt_image_safe_remove(const int32_t imgid)
void dt_image_set_xmp_rating(dt_image_t *img, const int rating)
char * dt_image_build_text_path_from_path(const char *image_path)
dt_image_write_sidecar_result_t dt_image_write_sidecar_file_forced(const int32_t imgid)
int32_t dt_image_duplicate(const int32_t imgid)
gboolean dt_image_get_usercrop(const dt_image_t *img, dt_boundingbox_t box)
void dt_image_local_copy_synch()
int32_t dt_image_rename(const int32_t imgid, const int32_t filmid, const gchar *newname)
void dt_image_synch_xmp(const int selected)
void dt_get_dirname_from_imgid(gchar *dir, const int32_t imgid)
void dt_image_full_path(const int32_t imgid, char *pathname, size_t pathname_len, gboolean *from_cache, const char *calling_func)
Get the full path of an image out of the database.
void dt_image_history_changed(const int32_t imgid, const gboolean refresh_filmstrip)
gboolean dt_image_needs_demosaic(const dt_image_t *img)
void dt_image_set_provisional_dsc(dt_image_t *img)
void dt_image_local_copy_paths_from_fullpath(const char *fullpath, int32_t imgid, char *local_copy_path, size_t local_copy_len, char *local_copy_legacy_path, size_t local_copy_legacy_len)
dt_mipmap_buffer_dsc_flags flags
#define DT_PATH_MAX
Buffer size for a filesystem path anywhere in Ansel.
#define DT_MAX_FILENAME_LEN
DT_ALIGNED_PIXEL float dt_aligned_pixel_t[4]
unsigned __int64 uint64_t
One registered profile: its identity, its LCMS handle, and where it sits in each combo box.
gboolean camera_missing_sample
GTimeSpan export_timestamp
float exif_focus_distance
dt_boundingbox_t usercrop
GTimeSpan import_timestamp
char camera_makermodel[128]
ls_vendor_data_t exif_correction
char local_copy_path[DT_PATH_MAX]
char camera_legacy_makermodel[128]
dt_image_usercrop_status_t usercrop_status
dt_image_orientation_t orientation
GTimeSpan change_timestamp
GTimeSpan print_timestamp
GTimeSpan exif_datetime_taken
float d65_color_matrix[9]
char filmroll[DT_PATH_MAX]
dt_image_colorspace_t colorspace
float adobe_XYZ_to_CAM[4][3]
struct dt_colorspaces_color_profile_t * embedded_profile
struct dt_cache_entry_t * cache_entry
char local_copy_legacy_path[DT_PATH_MAX]
dt_image_raw_parameters_t legacy_flip
char filename[DT_MAX_FILENAME_LEN]
uint16_t raw_black_level_separate[4]
dt_aligned_pixel_t wb_coeffs
char fullpath[DT_PATH_MAX]
uint32_t fuji_rotation_pos