5.8.0+agentic.12 - backtransform_point and retouch_update_shape Lua bindings
Fork of darktable 5.8.0 adding the darktable.develop Lua namespace used by darktable-mcp.
New in this build
-
dt.develop.backtransform_point(x, y[, len1][, len2])- converts a processed/display-frame normalized point into the pipe-input frame darktable's masks are actually stored in, using the samedt_masks_get_image_sizeplusdt_dev_distort_backtransformpath the GUI drag handlers use. Optional lengths (radius, feather) convert through a second offset point and normalize againstmindim(iwidth, iheight), matchingcircle.c's own convention.Without this, a programmatically placed mask point lands wrong whenever orientation, crop, rotate or lens correction is active. An EXIF-portrait raw swaps width and height on its own, which was enough to move a target from a neck to a chest.
-
dt.develop.retouch_update_shape(...)- move or resize an existing retouch circle in place, keeping its formid, rather than delete plus recreate. Geometry commits throughdt_dev_add_masks_history_item, the same mechanism ascircle.c's own drag-commit.
Both are registered alongside the existing retouch_add_shape / delete_shape / list_shapes bindings and run on the GUI thread via dt_lua_gtk_wrap.