|
VLC 4.0.0-dev
|
Data Structures | |
| struct | diffutil_snakepoint_t |
| struct | diffutil_snake_t |
| struct | diffutil_box_t |
| struct | diffutil_context_t |
| struct | vlc_build_result_context |
Macros | |
| #define | POS_MOD(x, n) ((x) % n + n) % n |
Typedefs | |
| typedef struct diffutil_snake_t | diffutil_snake_t |
Functions | |
| static bool | Forwards (diffutil_context_t *ctx, const diffutil_box_t *box, int32_t d, diffutil_snakepoint_t *snakeOut) |
| static bool | Backward (diffutil_context_t *ctx, const diffutil_box_t *box, int32_t d, diffutil_snakepoint_t *snakeOut) |
| static bool | FindMidPoint (diffutil_context_t *ctx, const diffutil_box_t *box, diffutil_snakepoint_t snakeOut[2]) |
| static diffutil_snake_t * | MergeSnake (const diffutil_snakepoint_t *start, const diffutil_snakepoint_t *stop, diffutil_snake_t *head, diffutil_snake_t *tail) |
| static diffutil_snake_t * | DiffUtilFindPath (diffutil_context_t *ctx, int32_t left, int32_t top, int32_t right, int32_t bottom) |
| diffutil_snake_t * | vlc_diffutil_build_snake (const vlc_diffutil_callback_t *diffOp, const void *dataOld, const void *dataNew) |
| vlc_diffutil_build_snake compute a diff model between the dataOld model and the dataNew model. | |
| void | vlc_diffutil_free_snake (diffutil_snake_t *snake) |
| free the snake created by vlc_diffutil_build_snake | |
| bool | vlc_diffutil_walk_snake (const diffutil_snake_t *snake, const vlc_diffutil_snake_callback_t *snakeOp, void *cbData, const vlc_diffutil_callback_t *diffOp, const void *dataOld, const void *dataNew) |
| iterate over the changelist and callback user on each operation (keep/insert/remove) | |
| static void | buildResultInsert (void *cbData, const void *listOld, uint32_t oldPos, const void *listNew, uint32_t newPos) |
| static void | buildResultRemove (void *cbData, const void *listOld, unsigned posOld, const void *listNew, uint32_t posNew) |
| static void | buildResultEqual (void *cbData, const void *listOld, uint32_t posOld, const void *listNew, uint32_t posNew) |
| static void | vlc_diffutil_gather_move_changes (vlc_build_result_context *ctx, const vlc_diffutil_callback_t *diffOp, const void *dataOld, const void *dataNew, enum vlc_diffutil_result_flag flags) |
| vlc_diffutil_changelist_t * | vlc_diffutil_build_change_list (const diffutil_snake_t *snake, const vlc_diffutil_callback_t *diffOp, const void *dataOld, const void *dataNew, int flags) |
| void | vlc_diffutil_free_change_list (vlc_diffutil_changelist_t *changelist) |
| free the changelist created by vlc_diffutil_build_change_list | |
| #define POS_MOD | ( | x, | |
| n | |||
| ) | ((x) % n + n) % n |
| typedef struct diffutil_snake_t diffutil_snake_t |
|
static |
References diffutil_context_t::backward, diffutil_context_t::dataNew, diffutil_context_t::dataOld, diffutil_box_t::delta, diffutil_context_t::forward, vlc_diffutil_callback_t::isSame, diffutil_box_t::left, diffutil_context_t::op, POS_MOD, diffutil_box_t::top, diffutil_snakepoint_t::x, diffutil_snakepoint_t::y, and diffutil_context_t::z.
Referenced by FindMidPoint().
|
static |
References vlc_build_result_context::head, and VLC_UNUSED.
Referenced by vlc_diffutil_build_change_list().
|
static |
References vlc_diffutil_change_t::count, vlc_build_result_context::countInsert, vlc_diffutil_changelist_t::data, vlc_build_result_context::flags, vlc_build_result_context::head, vlc_diffutil_change_t::insert, vlc_diffutil_change_t::op, vlc_build_result_context::result, vlc_diffutil_changelist_t::size, vlc_diffutil_change_t::type, VLC_DIFFUTIL_OP_INSERT, VLC_DIFFUTIL_RESULT_AGGREGATE, VLC_DIFFUTIL_RESULT_MOVE, VLC_UNUSED, vlc_vector_push, and vlc_diffutil_insert::y.
Referenced by vlc_diffutil_build_change_list().
|
static |
References vlc_diffutil_change_t::count, vlc_build_result_context::countRemove, vlc_diffutil_changelist_t::data, vlc_build_result_context::flags, vlc_build_result_context::head, vlc_diffutil_change_t::op, vlc_diffutil_change_t::remove, vlc_build_result_context::result, vlc_diffutil_changelist_t::size, vlc_diffutil_change_t::type, VLC_DIFFUTIL_OP_REMOVE, VLC_DIFFUTIL_RESULT_AGGREGATE, VLC_DIFFUTIL_RESULT_MOVE, VLC_UNUSED, vlc_vector_push, and vlc_diffutil_remove::x.
Referenced by vlc_diffutil_build_change_list().
|
static |
References diffutil_box_t::bottom, diffutil_box_t::delta, DiffUtilFindPath(), FindMidPoint(), diffutil_box_t::left, MergeSnake(), diffutil_box_t::right, diffutil_box_t::size, diffutil_box_t::top, diffutil_snakepoint_t::x, and diffutil_snakepoint_t::y.
Referenced by DiffUtilFindPath(), and vlc_diffutil_build_snake().
|
static |
References diffutil_context_t::backward, Backward(), diffutil_box_t::bottom, diffutil_context_t::forward, Forwards(), diffutil_box_t::left, and diffutil_box_t::size.
Referenced by DiffUtilFindPath().
|
static |
References diffutil_context_t::backward, diffutil_context_t::dataNew, diffutil_context_t::dataOld, diffutil_box_t::delta, diffutil_context_t::forward, vlc_diffutil_callback_t::isSame, diffutil_box_t::left, diffutil_context_t::op, POS_MOD, diffutil_box_t::top, diffutil_snakepoint_t::x, diffutil_snakepoint_t::y, and diffutil_context_t::z.
Referenced by FindMidPoint().
|
static |
References diffutil_snake_t::data, diffutil_snake_t::size, vlc_vector_destroy, vlc_vector_init, vlc_vector_push, and vlc_vector_push_all.
Referenced by DiffUtilFindPath().
| vlc_diffutil_changelist_t * vlc_diffutil_build_change_list | ( | const diffutil_snake_t * | snake, |
| const vlc_diffutil_callback_t * | diffOp, | ||
| const void * | dataOld, | ||
| const void * | dataNew, | ||
| int | flags | ||
| ) |
References buildResultEqual(), buildResultInsert(), buildResultRemove(), vlc_build_result_context::countInsert, vlc_build_result_context::countRemove, vlc_build_result_context::flags, vlc_build_result_context::head, vlc_diffutil_snake_callback_t::remove, vlc_build_result_context::result, vlc_diffutil_gather_move_changes(), VLC_DIFFUTIL_RESULT_MOVE, vlc_diffutil_walk_snake(), and vlc_vector_init.
| diffutil_snake_t * vlc_diffutil_build_snake | ( | const vlc_diffutil_callback_t * | diffOp, |
| const void * | dataOld, | ||
| const void * | dataNew | ||
| ) |
vlc_diffutil_build_snake compute a diff model between the dataOld model and the dataNew model.
This model can be processed manually using vlc_diffutil_walk_snake or translated into a change list using vlc_diffutil_build_change_list
| diffOp | callback to compare the elements from the old and new model |
| dataOld | old model |
| dataNew | new model |
References diffutil_context_t::backward, diffutil_context_t::dataNew, diffutil_context_t::dataOld, DiffUtilFindPath(), diffutil_context_t::forward, vlc_diffutil_callback_t::getNewSize, vlc_diffutil_callback_t::getOldSize, vlc_diffutil_callback_t::isSame, diffutil_context_t::op, vlc_vector_init, and diffutil_context_t::z.
| void vlc_diffutil_free_change_list | ( | vlc_diffutil_changelist_t * | changelist | ) |
free the changelist created by vlc_diffutil_build_change_list
References vlc_vector_destroy.
| void vlc_diffutil_free_snake | ( | diffutil_snake_t * | snake | ) |
free the snake created by vlc_diffutil_build_snake
References vlc_vector_destroy.
|
static |
References vlc_diffutil_change_t::count, vlc_build_result_context::countInsert, vlc_build_result_context::countRemove, vlc_diffutil_changelist_t::data, vlc_diffutil_move::from, vlc_diffutil_insert::index, vlc_diffutil_remove::index, vlc_diffutil_change_t::insert, vlc_diffutil_callback_t::isSame, vlc_diffutil_change_t::move, vlc_diffutil_change_t::op, vlc_diffutil_change_t::remove, vlc_build_result_context::result, vlc_diffutil_changelist_t::size, vlc_diffutil_move::to, vlc_diffutil_change_t::type, VLC_DIFFUTIL_OP_IGNORE, VLC_DIFFUTIL_OP_INSERT, VLC_DIFFUTIL_OP_MOVE, VLC_DIFFUTIL_OP_REMOVE, VLC_DIFFUTIL_RESULT_AGGREGATE, vlc_diffutil_remove::x, vlc_diffutil_move::x, vlc_diffutil_insert::y, and vlc_diffutil_move::y.
Referenced by vlc_diffutil_build_change_list().
| bool vlc_diffutil_walk_snake | ( | const diffutil_snake_t * | snake, |
| const vlc_diffutil_snake_callback_t * | snakeOp, | ||
| void * | cbData, | ||
| const vlc_diffutil_callback_t * | diffOp, | ||
| const void * | dataOld, | ||
| const void * | dataNew | ||
| ) |
iterate over the changelist and callback user on each operation (keep/insert/remove)
| snake | the snake created with vlc_diffutil_build_snake |
| snakeOp | snake callback |
| cbData | user data for snake callbacks |
| diffOp | callbacks used in vlc_diffutil_build_snake |
| dataOld | old model |
| dataNew | new model |
References diffutil_snake_t::data, vlc_diffutil_snake_callback_t::equal, vlc_diffutil_snake_callback_t::insert, vlc_diffutil_snake_callback_t::remove, diffutil_snake_t::size, diffutil_snakepoint_t::x, and diffutil_snakepoint_t::y.
Referenced by vlc_diffutil_build_change_list().