void TopologyController::process_pad(const GstDebugger::TopologyPad &pad, GstDebugger::Action action) { ElementPathProcessor path_processor(pad.path()); auto parent = path_processor.get_parent_element(); if (!parent) return; switch (action) { case GstDebugger::ADD: parent->add_pad(std::make_shared<PadModel>(path_processor.get_last_obj_str(), protocol_template_to_gst_template(pad.template_()), pad.is_ghostpad(), static_cast<Gst::PadDirection>(pad.direction()), static_cast<Gst::PadPresence>(pad.presence()))); break; case GstDebugger::REMOVE: parent->remove_pad(path_processor.get_last_obj_str()); break; } }
static int decrypt_state (scs_t *ctx, scs_keyset_t *ks) { /* Decrypt and remove padding, if any. */ return (D.dec(ctx, ks) || remove_pad(ctx)); }