FDL Core Library
ASC Framing Decision List — C/C++ Reference Implementation
Loading...
Searching...
No Matches
Typedefs | Functions
fdl_accessors_api.cpp File Reference

C ABI field accessors with thread-local string buffering and per-document mutex locking. More...

#include "fdl/fdl_core.h"
#include "fdl_canonical.h"
#include "fdl_compat.h"
#include "fdl_constants.h"
#include "fdl_doc.h"
#include "fdl_enum_map.h"
#include <cstdlib>
#include <cstring>
#include <functional>
#include <string>
#include <unordered_map>
#include "fdl_tl_cache.h"

Typedefs

using ojson = jsoncons::ojson
 Alias for ordered JSON type.
 

Functions

const char * fdl_context_get_label (const fdl_context_t *ctx)
 Get the label of a context.
 
const char * fdl_context_get_context_creator (const fdl_context_t *ctx)
 Get the context_creator of a context.
 
const char * fdl_canvas_get_label (const fdl_canvas_t *canvas)
 Get the label of a canvas.
 
const char * fdl_canvas_get_id (const fdl_canvas_t *canvas)
 Get the ID of a canvas.
 
const char * fdl_canvas_get_source_canvas_id (const fdl_canvas_t *canvas)
 Get the source_canvas_id of a canvas (the canvas this was derived from).
 
fdl_dimensions_i64_t fdl_canvas_get_dimensions (const fdl_canvas_t *canvas)
 Get the canvas dimensions in pixels.
 
int fdl_canvas_has_effective_dimensions (const fdl_canvas_t *canvas)
 Check if the canvas has effective dimensions set.
 
fdl_dimensions_i64_t fdl_canvas_get_effective_dimensions (const fdl_canvas_t *canvas)
 Get effective (active image area) dimensions.
 
fdl_point_f64_t fdl_canvas_get_effective_anchor_point (const fdl_canvas_t *canvas)
 Get the effective anchor point (offset from canvas origin).
 
double fdl_canvas_get_anamorphic_squeeze (const fdl_canvas_t *canvas)
 Get the anamorphic squeeze factor.
 
int fdl_canvas_has_photosite_dimensions (const fdl_canvas_t *canvas)
 Check if the canvas has photosite dimensions set.
 
fdl_dimensions_i64_t fdl_canvas_get_photosite_dimensions (const fdl_canvas_t *canvas)
 Get photosite (sensor) dimensions.
 
int fdl_canvas_has_physical_dimensions (const fdl_canvas_t *canvas)
 Check if the canvas has physical dimensions set.
 
fdl_dimensions_f64_t fdl_canvas_get_physical_dimensions (const fdl_canvas_t *canvas)
 Get physical dimensions (e.g.
 
int fdl_context_has_clip_id (const fdl_context_t *ctx)
 Check if a context has a clip_id.
 
const char * fdl_context_get_clip_id (const fdl_context_t *ctx)
 Get clip_id as a JSON string.
 
fdl_clip_id_tfdl_context_clip_id (fdl_context_t *ctx)
 Get the clip_id handle from a context.
 
const char * fdl_clip_id_get_clip_name (const fdl_clip_id_t *cid)
 Get the clip_name from a clip_id.
 
int fdl_clip_id_has_file (const fdl_clip_id_t *cid)
 Check if a clip_id has a file path.
 
const char * fdl_clip_id_get_file (const fdl_clip_id_t *cid)
 Get the file path from a clip_id.
 
int fdl_clip_id_has_sequence (const fdl_clip_id_t *cid)
 Check if a clip_id has a file sequence.
 
fdl_file_sequence_tfdl_clip_id_sequence (fdl_clip_id_t *cid)
 Get the file sequence handle from a clip_id.
 
char * fdl_clip_id_to_json (const fdl_clip_id_t *cid, int indent)
 Serialize a clip_id to canonical JSON.
 
const char * fdl_file_sequence_get_value (const fdl_file_sequence_t *seq)
 Get the sequence pattern value string.
 
const char * fdl_file_sequence_get_idx (const fdl_file_sequence_t *seq)
 Get the index variable name.
 
int64_t fdl_file_sequence_get_min (const fdl_file_sequence_t *seq)
 Get the minimum (first) frame number.
 
int64_t fdl_file_sequence_get_max (const fdl_file_sequence_t *seq)
 Get the maximum (last) frame number.
 
const char * fdl_framing_decision_get_label (const fdl_framing_decision_t *fd)
 Get the label of a framing decision.
 
const char * fdl_framing_decision_get_id (const fdl_framing_decision_t *fd)
 Get the ID of a framing decision.
 
const char * fdl_framing_decision_get_framing_intent_id (const fdl_framing_decision_t *fd)
 Get the framing_intent_id that this framing decision references.
 
fdl_dimensions_f64_t fdl_framing_decision_get_dimensions (const fdl_framing_decision_t *fd)
 Get the framing decision dimensions (floating-point sub-pixel).
 
fdl_point_f64_t fdl_framing_decision_get_anchor_point (const fdl_framing_decision_t *fd)
 Get the anchor point of a framing decision.
 
int fdl_framing_decision_has_protection (const fdl_framing_decision_t *fd)
 Check if a framing decision has protection area set.
 
fdl_dimensions_f64_t fdl_framing_decision_get_protection_dimensions (const fdl_framing_decision_t *fd)
 Get the protection area dimensions.
 
fdl_point_f64_t fdl_framing_decision_get_protection_anchor_point (const fdl_framing_decision_t *fd)
 Get the protection anchor point.
 
const char * fdl_framing_intent_get_label (const fdl_framing_intent_t *fi)
 Get the label of a framing intent.
 
const char * fdl_framing_intent_get_id (const fdl_framing_intent_t *fi)
 Get the ID of a framing intent.
 
fdl_dimensions_i64_t fdl_framing_intent_get_aspect_ratio (const fdl_framing_intent_t *fi)
 Get the target aspect ratio of a framing intent.
 
double fdl_framing_intent_get_protection (const fdl_framing_intent_t *fi)
 Get the protection factor of a framing intent.
 
const char * fdl_canvas_template_get_label (const fdl_canvas_template_t *ct)
 Get the label of a canvas template.
 
const char * fdl_canvas_template_get_id (const fdl_canvas_template_t *ct)
 Get the ID of a canvas template.
 
fdl_dimensions_i64_t fdl_canvas_template_get_target_dimensions (const fdl_canvas_template_t *ct)
 Get the target dimensions of a canvas template.
 
double fdl_canvas_template_get_target_anamorphic_squeeze (const fdl_canvas_template_t *ct)
 Get the target anamorphic squeeze factor.
 
fdl_geometry_path_t fdl_canvas_template_get_fit_source (const fdl_canvas_template_t *ct)
 Get the fit source — which dimension layer to scale from.
 
fdl_fit_method_t fdl_canvas_template_get_fit_method (const fdl_canvas_template_t *ct)
 Get the fit method — how source is scaled into target.
 
fdl_halign_t fdl_canvas_template_get_alignment_method_horizontal (const fdl_canvas_template_t *ct)
 Get the horizontal alignment method.
 
fdl_valign_t fdl_canvas_template_get_alignment_method_vertical (const fdl_canvas_template_t *ct)
 Get the vertical alignment method.
 
int fdl_canvas_template_has_preserve_from_source_canvas (const fdl_canvas_template_t *ct)
 Check if preserve_from_source_canvas is set.
 
fdl_geometry_path_t fdl_canvas_template_get_preserve_from_source_canvas (const fdl_canvas_template_t *ct)
 Get the preserve_from_source_canvas geometry path.
 
int fdl_canvas_template_has_maximum_dimensions (const fdl_canvas_template_t *ct)
 Check if maximum_dimensions constraint is set.
 
fdl_dimensions_i64_t fdl_canvas_template_get_maximum_dimensions (const fdl_canvas_template_t *ct)
 Get the maximum_dimensions constraint.
 
int fdl_canvas_template_get_pad_to_maximum (const fdl_canvas_template_t *ct)
 Get the pad_to_maximum flag.
 
fdl_round_strategy_t fdl_canvas_template_get_round (const fdl_canvas_template_t *ct)
 Get the rounding strategy.
 
int fdl_doc_get_version_major (const fdl_doc_t *doc)
 Get the FDL version major number.
 
int fdl_doc_get_version_minor (const fdl_doc_t *doc)
 Get the FDL version minor number.
 
char * fdl_context_to_json (const fdl_context_t *ctx, int indent)
 Serialize a context sub-object to canonical JSON.
 
char * fdl_canvas_to_json (const fdl_canvas_t *canvas, int indent)
 Serialize a canvas sub-object to canonical JSON.
 
char * fdl_framing_decision_to_json (const fdl_framing_decision_t *fd, int indent)
 Serialize a framing decision to canonical JSON.
 
char * fdl_framing_intent_to_json (const fdl_framing_intent_t *fi, int indent)
 Serialize a framing intent to canonical JSON.
 
char * fdl_canvas_template_to_json (const fdl_canvas_template_t *ct, int indent)
 Serialize a canvas template to canonical JSON.
 

Detailed Description

C ABI field accessors with thread-local string buffering and per-document mutex locking.

Function Documentation

◆ fdl_context_get_label()

const char * fdl_context_get_label ( const fdl_context_t ctx)

Get the label of a context.

Parameters
ctxContext handle.
Returns
Label string. Thread-local pointer, valid until next call for same field on same thread.

◆ fdl_context_get_context_creator()

const char * fdl_context_get_context_creator ( const fdl_context_t ctx)

Get the context_creator of a context.

Parameters
ctxContext handle.
Returns
Creator string. Thread-local pointer, valid until next call for same field on same thread.

◆ fdl_canvas_get_label()

const char * fdl_canvas_get_label ( const fdl_canvas_t canvas)

Get the label of a canvas.

Parameters
canvasCanvas handle.
Returns
Label string. Thread-local pointer.

◆ fdl_canvas_get_id()

const char * fdl_canvas_get_id ( const fdl_canvas_t canvas)

Get the ID of a canvas.

Parameters
canvasCanvas handle.
Returns
ID string. Thread-local pointer.

◆ fdl_canvas_get_source_canvas_id()

const char * fdl_canvas_get_source_canvas_id ( const fdl_canvas_t canvas)

Get the source_canvas_id of a canvas (the canvas this was derived from).

Parameters
canvasCanvas handle.
Returns
Source canvas ID string. Thread-local pointer.

◆ fdl_canvas_get_dimensions()

fdl_dimensions_i64_t fdl_canvas_get_dimensions ( const fdl_canvas_t canvas)

Get the canvas dimensions in pixels.

Parameters
canvasCanvas handle.
Returns
Canvas dimensions.

◆ fdl_canvas_has_effective_dimensions()

int fdl_canvas_has_effective_dimensions ( const fdl_canvas_t canvas)

Check if the canvas has effective dimensions set.

Parameters
canvasCanvas handle.
Returns
FDL_TRUE if effective dimensions are present, FDL_FALSE otherwise.

◆ fdl_canvas_get_effective_dimensions()

fdl_dimensions_i64_t fdl_canvas_get_effective_dimensions ( const fdl_canvas_t canvas)

Get effective (active image area) dimensions.

Parameters
canvasCanvas handle.
Returns
Effective dimensions. Only valid if fdl_canvas_has_effective_dimensions() returns FDL_TRUE.

◆ fdl_canvas_get_effective_anchor_point()

fdl_point_f64_t fdl_canvas_get_effective_anchor_point ( const fdl_canvas_t canvas)

Get the effective anchor point (offset from canvas origin).

Parameters
canvasCanvas handle.
Returns
Effective anchor point. Returns {0,0} if no effective dimensions.

◆ fdl_canvas_get_anamorphic_squeeze()

double fdl_canvas_get_anamorphic_squeeze ( const fdl_canvas_t canvas)

Get the anamorphic squeeze factor.

Parameters
canvasCanvas handle.
Returns
Squeeze factor (1.0 for non-anamorphic).

◆ fdl_canvas_has_photosite_dimensions()

int fdl_canvas_has_photosite_dimensions ( const fdl_canvas_t canvas)

Check if the canvas has photosite dimensions set.

Parameters
canvasCanvas handle.
Returns
FDL_TRUE if photosite dimensions are present, FDL_FALSE otherwise.

◆ fdl_canvas_get_photosite_dimensions()

fdl_dimensions_i64_t fdl_canvas_get_photosite_dimensions ( const fdl_canvas_t canvas)

Get photosite (sensor) dimensions.

Parameters
canvasCanvas handle.
Returns
Photosite dimensions. Only valid if fdl_canvas_has_photosite_dimensions() returns FDL_TRUE.

◆ fdl_canvas_has_physical_dimensions()

int fdl_canvas_has_physical_dimensions ( const fdl_canvas_t canvas)

Check if the canvas has physical dimensions set.

Parameters
canvasCanvas handle.
Returns
FDL_TRUE if physical dimensions are present, FDL_FALSE otherwise.

◆ fdl_canvas_get_physical_dimensions()

fdl_dimensions_f64_t fdl_canvas_get_physical_dimensions ( const fdl_canvas_t canvas)

Get physical dimensions (e.g.

millimeters on sensor).

Parameters
canvasCanvas handle.
Returns
Physical dimensions. Only valid if fdl_canvas_has_physical_dimensions() returns FDL_TRUE.

◆ fdl_context_has_clip_id()

int fdl_context_has_clip_id ( const fdl_context_t ctx)

Check if a context has a clip_id.

Parameters
ctxContext handle.
Returns
FDL_TRUE if clip_id is present, FDL_FALSE otherwise.

◆ fdl_context_get_clip_id()

const char * fdl_context_get_clip_id ( const fdl_context_t ctx)

Get clip_id as a JSON string.

Parameters
ctxContext handle.
Returns
Heap-allocated JSON string, or NULL if not present. Caller owns — free with fdl_free().

< POSIX strdup.

◆ fdl_context_clip_id()

fdl_clip_id_t * fdl_context_clip_id ( fdl_context_t ctx)

Get the clip_id handle from a context.

Parameters
ctxContext handle.
Returns
Clip ID handle (owned by doc), or NULL if clip_id is not present.

◆ fdl_clip_id_get_clip_name()

const char * fdl_clip_id_get_clip_name ( const fdl_clip_id_t cid)

Get the clip_name from a clip_id.

Parameters
cidClip ID handle.
Returns
Clip name string. Thread-local pointer, valid until next call for same field on same thread.

◆ fdl_clip_id_has_file()

int fdl_clip_id_has_file ( const fdl_clip_id_t cid)

Check if a clip_id has a file path.

Parameters
cidClip ID handle.
Returns
FDL_TRUE if file is present, FDL_FALSE otherwise.

◆ fdl_clip_id_get_file()

const char * fdl_clip_id_get_file ( const fdl_clip_id_t cid)

Get the file path from a clip_id.

Parameters
cidClip ID handle.
Returns
File path string, or NULL if not present. Thread-local pointer.

◆ fdl_clip_id_has_sequence()

int fdl_clip_id_has_sequence ( const fdl_clip_id_t cid)

Check if a clip_id has a file sequence.

Parameters
cidClip ID handle.
Returns
FDL_TRUE if sequence is present, FDL_FALSE otherwise.

◆ fdl_clip_id_sequence()

fdl_file_sequence_t * fdl_clip_id_sequence ( fdl_clip_id_t cid)

Get the file sequence handle from a clip_id.

Parameters
cidClip ID handle.
Returns
File sequence handle (owned by doc), or NULL if sequence is not present.

◆ fdl_clip_id_to_json()

char * fdl_clip_id_to_json ( const fdl_clip_id_t cid,
int  indent 
)

Serialize a clip_id to canonical JSON.

Parameters
cidClip ID handle.
indentNumber of spaces per indent level (0 for compact).
Returns
Heap-allocated JSON string. Caller owns — free with fdl_free().

◆ fdl_file_sequence_get_value()

const char * fdl_file_sequence_get_value ( const fdl_file_sequence_t seq)

Get the sequence pattern value string.

Parameters
seqFile sequence handle.
Returns
Sequence pattern string. Thread-local pointer.

◆ fdl_file_sequence_get_idx()

const char * fdl_file_sequence_get_idx ( const fdl_file_sequence_t seq)

Get the index variable name.

Parameters
seqFile sequence handle.
Returns
Index variable string. Thread-local pointer.

◆ fdl_file_sequence_get_min()

int64_t fdl_file_sequence_get_min ( const fdl_file_sequence_t seq)

Get the minimum (first) frame number.

Parameters
seqFile sequence handle.
Returns
First frame number.

◆ fdl_file_sequence_get_max()

int64_t fdl_file_sequence_get_max ( const fdl_file_sequence_t seq)

Get the maximum (last) frame number.

Parameters
seqFile sequence handle.
Returns
Last frame number.

◆ fdl_framing_decision_get_label()

const char * fdl_framing_decision_get_label ( const fdl_framing_decision_t fd)

Get the label of a framing decision.

Parameters
fdFraming decision handle.
Returns
Label string. Thread-local pointer.

◆ fdl_framing_decision_get_id()

const char * fdl_framing_decision_get_id ( const fdl_framing_decision_t fd)

Get the ID of a framing decision.

Parameters
fdFraming decision handle.
Returns
ID string. Thread-local pointer.

◆ fdl_framing_decision_get_framing_intent_id()

const char * fdl_framing_decision_get_framing_intent_id ( const fdl_framing_decision_t fd)

Get the framing_intent_id that this framing decision references.

Parameters
fdFraming decision handle.
Returns
Framing intent ID string. Thread-local pointer.

◆ fdl_framing_decision_get_dimensions()

fdl_dimensions_f64_t fdl_framing_decision_get_dimensions ( const fdl_framing_decision_t fd)

Get the framing decision dimensions (floating-point sub-pixel).

Parameters
fdFraming decision handle.
Returns
Framing dimensions.

◆ fdl_framing_decision_get_anchor_point()

fdl_point_f64_t fdl_framing_decision_get_anchor_point ( const fdl_framing_decision_t fd)

Get the anchor point of a framing decision.

Parameters
fdFraming decision handle.
Returns
Anchor point (offset from canvas origin).

◆ fdl_framing_decision_has_protection()

int fdl_framing_decision_has_protection ( const fdl_framing_decision_t fd)

Check if a framing decision has protection area set.

Parameters
fdFraming decision handle.
Returns
FDL_TRUE if protection is present, FDL_FALSE otherwise.

◆ fdl_framing_decision_get_protection_dimensions()

fdl_dimensions_f64_t fdl_framing_decision_get_protection_dimensions ( const fdl_framing_decision_t fd)

Get the protection area dimensions.

Parameters
fdFraming decision handle.
Returns
Protection dimensions. Only valid if fdl_framing_decision_has_protection() returns FDL_TRUE.

◆ fdl_framing_decision_get_protection_anchor_point()

fdl_point_f64_t fdl_framing_decision_get_protection_anchor_point ( const fdl_framing_decision_t fd)

Get the protection anchor point.

Parameters
fdFraming decision handle.
Returns
Protection anchor point. Only valid if fdl_framing_decision_has_protection() returns FDL_TRUE.

◆ fdl_framing_intent_get_label()

const char * fdl_framing_intent_get_label ( const fdl_framing_intent_t fi)

Get the label of a framing intent.

Parameters
fiFraming intent handle.
Returns
Label string. Thread-local pointer.

◆ fdl_framing_intent_get_id()

const char * fdl_framing_intent_get_id ( const fdl_framing_intent_t fi)

Get the ID of a framing intent.

Parameters
fiFraming intent handle.
Returns
ID string. Thread-local pointer.

◆ fdl_framing_intent_get_aspect_ratio()

fdl_dimensions_i64_t fdl_framing_intent_get_aspect_ratio ( const fdl_framing_intent_t fi)

Get the target aspect ratio of a framing intent.

Parameters
fiFraming intent handle.
Returns
Aspect ratio as integer width:height (e.g. {16, 9}).

◆ fdl_framing_intent_get_protection()

double fdl_framing_intent_get_protection ( const fdl_framing_intent_t fi)

Get the protection factor of a framing intent.

Parameters
fiFraming intent handle.
Returns
Protection factor (0.0 = no protection).

◆ fdl_canvas_template_get_label()

const char * fdl_canvas_template_get_label ( const fdl_canvas_template_t ct)

Get the label of a canvas template.

Parameters
ctCanvas template handle.
Returns
Label string. Thread-local pointer.

◆ fdl_canvas_template_get_id()

const char * fdl_canvas_template_get_id ( const fdl_canvas_template_t ct)

Get the ID of a canvas template.

Parameters
ctCanvas template handle.
Returns
ID string. Thread-local pointer.

◆ fdl_canvas_template_get_target_dimensions()

fdl_dimensions_i64_t fdl_canvas_template_get_target_dimensions ( const fdl_canvas_template_t ct)

Get the target dimensions of a canvas template.

Parameters
ctCanvas template handle.
Returns
Target output dimensions in pixels.

◆ fdl_canvas_template_get_target_anamorphic_squeeze()

double fdl_canvas_template_get_target_anamorphic_squeeze ( const fdl_canvas_template_t ct)

Get the target anamorphic squeeze factor.

Parameters
ctCanvas template handle.
Returns
Target squeeze factor (1.0 for non-anamorphic).

◆ fdl_canvas_template_get_fit_source()

fdl_geometry_path_t fdl_canvas_template_get_fit_source ( const fdl_canvas_template_t ct)

Get the fit source — which dimension layer to scale from.

Parameters
ctCanvas template handle.
Returns
Geometry path (canvas, effective, protection, or framing).

◆ fdl_canvas_template_get_fit_method()

fdl_fit_method_t fdl_canvas_template_get_fit_method ( const fdl_canvas_template_t ct)

Get the fit method — how source is scaled into target.

Parameters
ctCanvas template handle.
Returns
Fit method (WIDTH, HEIGHT, FIT_ALL, or FILL).

◆ fdl_canvas_template_get_alignment_method_horizontal()

fdl_halign_t fdl_canvas_template_get_alignment_method_horizontal ( const fdl_canvas_template_t ct)

Get the horizontal alignment method.

Parameters
ctCanvas template handle.
Returns
Horizontal alignment (LEFT, CENTER, or RIGHT).

◆ fdl_canvas_template_get_alignment_method_vertical()

fdl_valign_t fdl_canvas_template_get_alignment_method_vertical ( const fdl_canvas_template_t ct)

Get the vertical alignment method.

Parameters
ctCanvas template handle.
Returns
Vertical alignment (TOP, CENTER, or BOTTOM).

◆ fdl_canvas_template_has_preserve_from_source_canvas()

int fdl_canvas_template_has_preserve_from_source_canvas ( const fdl_canvas_template_t ct)

Check if preserve_from_source_canvas is set.

Parameters
ctCanvas template handle.
Returns
FDL_TRUE if present, FDL_FALSE otherwise.

◆ fdl_canvas_template_get_preserve_from_source_canvas()

fdl_geometry_path_t fdl_canvas_template_get_preserve_from_source_canvas ( const fdl_canvas_template_t ct)

Get the preserve_from_source_canvas geometry path.

Parameters
ctCanvas template handle.
Returns
Geometry path to preserve. Only valid if has_preserve returns FDL_TRUE.

◆ fdl_canvas_template_has_maximum_dimensions()

int fdl_canvas_template_has_maximum_dimensions ( const fdl_canvas_template_t ct)

Check if maximum_dimensions constraint is set.

Parameters
ctCanvas template handle.
Returns
FDL_TRUE if maximum dimensions are set, FDL_FALSE otherwise.

◆ fdl_canvas_template_get_maximum_dimensions()

fdl_dimensions_i64_t fdl_canvas_template_get_maximum_dimensions ( const fdl_canvas_template_t ct)

Get the maximum_dimensions constraint.

Parameters
ctCanvas template handle.
Returns
Maximum dimensions. Only valid if has_maximum_dimensions returns FDL_TRUE.

◆ fdl_canvas_template_get_pad_to_maximum()

int fdl_canvas_template_get_pad_to_maximum ( const fdl_canvas_template_t ct)

Get the pad_to_maximum flag.

Parameters
ctCanvas template handle.
Returns
FDL_TRUE if output should be padded to maximum dimensions, FDL_FALSE otherwise.

◆ fdl_canvas_template_get_round()

fdl_round_strategy_t fdl_canvas_template_get_round ( const fdl_canvas_template_t ct)

Get the rounding strategy.

Parameters
ctCanvas template handle.
Returns
Rounding strategy (even + mode).

◆ fdl_doc_get_version_major()

int fdl_doc_get_version_major ( const fdl_doc_t doc)

Get the FDL version major number.

Parameters
docDocument to query.
Returns
Major version number, or 0 if not present.

◆ fdl_doc_get_version_minor()

int fdl_doc_get_version_minor ( const fdl_doc_t doc)

Get the FDL version minor number.

Parameters
docDocument to query.
Returns
Minor version number, or 0 if not present.

◆ fdl_context_to_json()

char * fdl_context_to_json ( const fdl_context_t ctx,
int  indent 
)

Serialize a context sub-object to canonical JSON.

Parameters
ctxContext handle.
indentNumber of spaces per indent level (0 for compact).
Returns
Heap-allocated JSON string. Caller owns — free with fdl_free(). Returns NULL if ctx is NULL.

◆ fdl_canvas_to_json()

char * fdl_canvas_to_json ( const fdl_canvas_t canvas,
int  indent 
)

Serialize a canvas sub-object to canonical JSON.

Parameters
canvasCanvas handle.
indentNumber of spaces per indent level (0 for compact).
Returns
Heap-allocated JSON string. Caller owns — free with fdl_free().

◆ fdl_framing_decision_to_json()

char * fdl_framing_decision_to_json ( const fdl_framing_decision_t fd,
int  indent 
)

Serialize a framing decision to canonical JSON.

Parameters
fdFraming decision handle.
indentNumber of spaces per indent level (0 for compact).
Returns
Heap-allocated JSON string. Caller owns — free with fdl_free().

◆ fdl_framing_intent_to_json()

char * fdl_framing_intent_to_json ( const fdl_framing_intent_t fi,
int  indent 
)

Serialize a framing intent to canonical JSON.

Parameters
fiFraming intent handle.
indentNumber of spaces per indent level (0 for compact).
Returns
Heap-allocated JSON string. Caller owns — free with fdl_free().

◆ fdl_canvas_template_to_json()

char * fdl_canvas_template_to_json ( const fdl_canvas_template_t ct,
int  indent 
)

Serialize a canvas template to canonical JSON.

Parameters
ctCanvas template handle.
indentNumber of spaces per indent level (0 for compact).
Returns
Heap-allocated JSON string. Caller owns — free with fdl_free().