Ansel 0.0
A darktable fork - bloat + design vision
Loading...
Searching...
No Matches
import_sequence.h File Reference
+ Include dependency graph for import_sequence.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  dt_import_sequence_t
 Job-local numbering and reservation state; table lifetime belongs to the worker. More...
 
struct  dt_import_destination_t
 Borrowed inputs for one destination expansion. More...
 

Typedefs

typedef struct dt_import_sequence_t dt_import_sequence_t
 Job-local numbering and reservation state; table lifetime belongs to the worker.
 
typedef struct dt_import_destination_t dt_import_destination_t
 Borrowed inputs for one destination expansion.
 

Functions

int dt_import_sequence_assign (dt_import_sequence_t *sequences, const char *filename)
 Assign a capture number, retaining it even when subsequent expansion fails.
 
char * dt_import_sequence_destination (dt_import_sequence_t *sequences, const dt_import_destination_t *request)
 Expand and reserve a destination, retrying a sibling collision exactly once.
 

Typedef Documentation

◆ dt_import_destination_t

Borrowed inputs for one destination expansion.

◆ dt_import_sequence_t

Job-local numbering and reservation state; table lifetime belongs to the worker.

Function Documentation

◆ dt_import_sequence_assign()

int dt_import_sequence_assign ( dt_import_sequence_t *  sequences,
const char *  filename 
)

Assign a capture number, retaining it even when subsequent expansion fails.

Returns
The positive sequence assigned to the full source path without its extension.

Definition at line 9 of file import_sequence.c.

References dt_free, dt_util_path_get_extension(), extension(), IS_NULL_PTR, and L.

Referenced by _control_import_job_run().

◆ dt_import_sequence_destination()

char * dt_import_sequence_destination ( dt_import_sequence_t *  sequences,
const dt_import_destination_t *  request 
)

Expand and reserve a destination, retrying a sibling collision exactly once.

Reservations retain their first owner for the whole job. An unchanged or already-reserved fallback reaches the filesystem conflict policy as-is. Replaces data->target_dir; the worker owns the returned path and frees it.

Returns
Newly allocated destination, or NULL when expansion fails.

Definition at line 25 of file import_sequence.c.

References dt_import_destination_t::capture_sequence, dt_import_destination_t::data, dt_build_filename_from_pattern(), dt_free, dt_import_destination_t::filename, dt_import_destination_t::image, IS_NULL_PTR, L, and dt_control_import_t::target_dir.

Referenced by _control_import_job_run().