BMediaRosterEx: cleanup and fix style in the header
This commit is contained in:
@@ -7,6 +7,7 @@
|
|||||||
#ifndef _MEDIA_ROSTER_EX_H_
|
#ifndef _MEDIA_ROSTER_EX_H_
|
||||||
#define _MEDIA_ROSTER_EX_H_
|
#define _MEDIA_ROSTER_EX_H_
|
||||||
|
|
||||||
|
|
||||||
#ifndef _MEDIA_T_LIST_H
|
#ifndef _MEDIA_T_LIST_H
|
||||||
#include "TList.h"
|
#include "TList.h"
|
||||||
#endif
|
#endif
|
||||||
@@ -20,8 +21,10 @@
|
|||||||
#include <MediaAddOn.h>
|
#include <MediaAddOn.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
namespace BPrivate { namespace media {
|
namespace BPrivate { namespace media {
|
||||||
|
|
||||||
|
|
||||||
/* The BMediaRosterEx class is an extension to the BMediaRoster.
|
/* The BMediaRosterEx class is an extension to the BMediaRoster.
|
||||||
* It provides functionality that can be used by the implementation
|
* It provides functionality that can be used by the implementation
|
||||||
* of media_server, media_addon_server and libmedia.so.
|
* of media_server, media_addon_server and libmedia.so.
|
||||||
@@ -31,29 +34,58 @@ namespace BPrivate { namespace media {
|
|||||||
class BMediaRosterEx : public BMediaRoster
|
class BMediaRosterEx : public BMediaRoster
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
BMediaRosterEx(status_t * out_error);
|
BMediaRosterEx(status_t* out_error);
|
||||||
status_t SaveNodeConfiguration(BMediaNode *node);
|
|
||||||
status_t LoadNodeConfiguration(media_addon_id addonid, int32 flavorid, BMessage *out_msg);
|
|
||||||
|
|
||||||
status_t IncrementAddonFlavorInstancesCount(media_addon_id addonid, int32 flavorid);
|
status_t SaveNodeConfiguration(BMediaNode* node);
|
||||||
status_t DecrementAddonFlavorInstancesCount(media_addon_id addonid, int32 flavorid);
|
status_t LoadNodeConfiguration(media_addon_id addonid,
|
||||||
status_t ReleaseNodeAll(const media_node& node);
|
int32 flavorid, BMessage* out_msg);
|
||||||
|
|
||||||
status_t SetNodeCreator(media_node_id node, team_id creator);
|
status_t IncrementAddonFlavorInstancesCount(
|
||||||
|
media_addon_id addonid, int32 flavorid);
|
||||||
|
|
||||||
status_t RegisterNode(BMediaNode * node, media_addon_id addonid, int32 flavorid);
|
status_t DecrementAddonFlavorInstancesCount(
|
||||||
status_t InstantiateDormantNode(media_addon_id addonid, int32 flavorid, team_id creator, media_node *out_node);
|
media_addon_id addonid, int32 flavorid);
|
||||||
status_t GetDormantFlavorInfo(media_addon_id addonid, int32 flavorid, dormant_flavor_info *out_flavor);
|
|
||||||
status_t GetNode(node_type type, media_node * out_node, int32 * out_input_id = NULL, BString * out_input_name = NULL);
|
|
||||||
status_t SetNode(node_type type, const media_node *node, const dormant_node_info *info = NULL, const media_input *input = NULL);
|
|
||||||
status_t GetAllOutputs(const media_node & node, List<media_output> *list);
|
|
||||||
status_t GetAllOutputs(BBufferProducer *node, List<media_output> *list);
|
|
||||||
status_t GetAllInputs(const media_node & node, List<media_input> *list);
|
|
||||||
status_t GetAllInputs(BBufferConsumer *node, List<media_input> *list);
|
|
||||||
status_t PublishOutputs(const media_node & node, List<media_output> *list);
|
|
||||||
status_t PublishInputs(const media_node & node, List<media_input> *list);
|
|
||||||
|
|
||||||
BTimeSource *MakeTimeSourceObject(media_node_id timesource_id);
|
status_t ReleaseNodeAll(const media_node& node);
|
||||||
|
|
||||||
|
status_t SetNodeCreator(media_node_id node, team_id creator);
|
||||||
|
|
||||||
|
status_t RegisterNode(BMediaNode* node, media_addon_id addonid,
|
||||||
|
int32 flavorid);
|
||||||
|
|
||||||
|
status_t InstantiateDormantNode(media_addon_id addonid,
|
||||||
|
int32 flavorid, team_id creator, media_node* out_node);
|
||||||
|
|
||||||
|
status_t GetDormantFlavorInfo(media_addon_id addonid,
|
||||||
|
int32 flavorid, dormant_flavor_info* out_flavor);
|
||||||
|
|
||||||
|
status_t GetNode(node_type type, media_node* out_node,
|
||||||
|
int32* out_input_id = NULL,
|
||||||
|
BString* out_input_name = NULL);
|
||||||
|
|
||||||
|
status_t SetNode(node_type type, const media_node* node,
|
||||||
|
const dormant_node_info* info = NULL,
|
||||||
|
const media_input *input = NULL);
|
||||||
|
|
||||||
|
status_t GetAllOutputs(const media_node& node,
|
||||||
|
List<media_output>* list);
|
||||||
|
|
||||||
|
status_t GetAllOutputs(BBufferProducer* node,
|
||||||
|
List<media_output>* list);
|
||||||
|
|
||||||
|
status_t GetAllInputs(const media_node& node,
|
||||||
|
List<media_input>* list);
|
||||||
|
|
||||||
|
status_t GetAllInputs(BBufferConsumer* node,
|
||||||
|
List<media_input>* list);
|
||||||
|
|
||||||
|
status_t PublishOutputs(const media_node& node,
|
||||||
|
List<media_output>* list);
|
||||||
|
|
||||||
|
status_t PublishInputs(const media_node& node,
|
||||||
|
List<media_input>* list);
|
||||||
|
|
||||||
|
BTimeSource* MakeTimeSourceObject(media_node_id timesource_id);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
friend class BMediaRoster;
|
friend class BMediaRoster;
|
||||||
@@ -62,9 +94,9 @@ private:
|
|||||||
/* The pointer returned by BMediaRoster::Roster() is always a
|
/* The pointer returned by BMediaRoster::Roster() is always a
|
||||||
* BMediaRosterEx object pointer. Use this to convert it.
|
* BMediaRosterEx object pointer. Use this to convert it.
|
||||||
*/
|
*/
|
||||||
inline BMediaRosterEx * MediaRosterEx(BMediaRoster *mediaroster)
|
inline BMediaRosterEx* MediaRosterEx(BMediaRoster* mediaroster)
|
||||||
{
|
{
|
||||||
return static_cast<BMediaRosterEx *>(mediaroster);
|
return static_cast<BMediaRosterEx*>(mediaroster);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user