static OMX_ERRORTYPE scloud_prc_config_change (void * ap_prc, OMX_U32 TIZ_UNUSED (a_pid), OMX_INDEXTYPE a_config_idx) { scloud_prc_t * p_prc = ap_prc; OMX_ERRORTYPE rc = OMX_ErrorNone; assert (p_prc); if (OMX_TizoniaIndexConfigPlaylistSkip == a_config_idx && p_prc->p_trans_) { TIZ_INIT_OMX_STRUCT (p_prc->playlist_skip_); tiz_check_omx (tiz_api_GetConfig ( tiz_get_krn (handleOf (p_prc)), handleOf (p_prc), OMX_TizoniaIndexConfigPlaylistSkip, &p_prc->playlist_skip_)); p_prc->playlist_skip_.nValue > 0 ? obtain_next_url (p_prc, 1) : obtain_next_url (p_prc, -1); /* Changing the URL has the side effect of halting the current download */ tiz_urltrans_set_uri (p_prc->p_trans_, p_prc->p_uri_param_); if (p_prc->port_disabled_) { /* Record that the URI has changed, so that when the port is re-enabled, we restart the transfer */ p_prc->uri_changed_ = true; } else { /* re-start the transfer */ tiz_urltrans_start (p_prc->p_trans_); } } return rc; }
static OMX_ERRORTYPE dirble_prc_transfer_and_process (void * ap_prc, OMX_U32 a_pid) { dirble_prc_t * p_prc = ap_prc; OMX_ERRORTYPE rc = OMX_ErrorNone; assert (p_prc); if (p_prc->auto_detect_on_) { rc = tiz_urltrans_start (p_prc->p_trans_); } return rc; }
static OMX_ERRORTYPE scloud_prc_port_enable (const void * ap_prc, OMX_U32 a_pid) { scloud_prc_t * p_prc = (scloud_prc_t *) ap_prc; OMX_ERRORTYPE rc = OMX_ErrorNone; assert (p_prc); if (p_prc->port_disabled_) { p_prc->port_disabled_ = false; if (!p_prc->uri_changed_) { rc = tiz_urltrans_unpause (p_prc->p_trans_); } else { p_prc->uri_changed_ = false; rc = tiz_urltrans_start (p_prc->p_trans_); } } return rc; }