}
/**
- * Finds a decoder instance by its instance id, but only in the bottom
+ * Finds a decoder instance by its instance ID, but only in the bottom
* level of instances -- instances already stacked on top of another one
* will not be found.
*
- * @param inst_id The instance id to be found.
+ * @param inst_id The instance ID to be found.
*
* @return Pointer to struct srd_decoder_inst, or NULL if not found.
*/
* stack).
*
* @param output_type The output type this callback will receive. Only one
- * callback per output type can be registered.
+ * callback per output type can be registered.
* @param cb The function to call.
- * @param user_data Unused.
+ * @param cb_data Unused.
*/
SRD_API int srd_register_callback(int output_type,
- srd_pd_output_callback_t cb, void *user_data)
+ srd_pd_output_callback_t cb, void *cb_data)
{
struct srd_pd_callback *pd_cb;
}
pd_cb->output_type = output_type;
- pd_cb->callback = cb;
- pd_cb->user_data = user_data;
+ pd_cb->cb = cb;
+ pd_cb->cb_data = cb_data;
callbacks = g_slist_append(callbacks, pd_cb);
return SRD_OK;
for (l = callbacks; l; l = l->next) {
pd_cb = l->data;
if (pd_cb->output_type == output_type) {
- cb = pd_cb->callback;
+ cb = pd_cb->cb;
break;
}
}