int pipeline_container_realize (LVAVSPipelineContainer *container) { VisListEntry *le = NULL; LVAVSPipelineElement *element; while ((element = visual_list_next (container->members, &le)) != NULL) { switch (element->type) { case LVAVS_PIPELINE_ELEMENT_TYPE_NULL: break; case LVAVS_PIPELINE_ELEMENT_TYPE_ACTOR: visual_actor_realize (element->data.actor); visual_param_container_copy_match (visual_plugin_get_params ( visual_actor_get_plugin (element->data.actor)), element->params); break; case LVAVS_PIPELINE_ELEMENT_TYPE_TRANSFORM: visual_transform_realize (element->data.transform); visual_param_container_copy_match (visual_plugin_get_params ( visual_transform_get_plugin (element->data.transform)), element->params); break; case LVAVS_PIPELINE_ELEMENT_TYPE_MORPH: visual_morph_realize (element->data.morph); break; case LVAVS_PIPELINE_ELEMENT_TYPE_RENDERSTATE: break; case LVAVS_PIPELINE_ELEMENT_TYPE_CONTAINER: pipeline_container_realize (LVAVS_PIPELINE_CONTAINER (element)); break; default: visual_log (VISUAL_LOG_CRITICAL, "Invalid LVAVSPipelineElementType"); break; } } return 0; }
/** * This is called to run the palette part of a VisTransform. * * @see visual_transform_run * * @param transform Pointer to a VisTransform that needs to be runned. * @param audio Pointer to a VisAudio that contains all the audio data. * * @return VISUAL_OK on succes, -VISUAL_ERROR_TRANSFORM_NULL, -VISUAL_ERROR_TRANSFORM_PALETTE_NULL * or -VISUAL_ERROR_TRANSFORM_PLUGIN_NULL on failure. */ int visual_transform_run_palette (VisTransform *transform, VisAudio *audio) { VisTransformPlugin *transplugin; VisPluginData *plugin; visual_log_return_val_if_fail (transform != NULL, -VISUAL_ERROR_TRANSFORM_NULL); visual_log_return_val_if_fail (transform->pal != NULL, -VISUAL_ERROR_TRANSFORM_PALETTE_NULL); transplugin = get_transform_plugin (transform); plugin = visual_transform_get_plugin (transform); if (transplugin == NULL) { visual_log (VISUAL_LOG_CRITICAL, _("The given transform does not reference any transform plugin")); return -VISUAL_ERROR_TRANSFORM_PLUGIN_NULL; } visual_plugin_events_pump (plugin); transplugin->palette (plugin, transform->pal, audio); return VISUAL_OK; }