Merge branch 'master' of ssh://git.haiku-os.org/haiku
Merge split commit between two repos. tcp stack comments
This commit is contained in:
@@ -116,9 +116,9 @@ public:
|
||||
BMediaConnection* OutputAt(int32 index) const;
|
||||
|
||||
BMediaConnection* FindInput(
|
||||
const media_destination& dest) const;
|
||||
const media_connection& input) const;
|
||||
BMediaConnection* FindOutput(
|
||||
const media_source& source) const;
|
||||
const media_connection& output) const;
|
||||
|
||||
bool IsRunning() const;
|
||||
|
||||
@@ -135,7 +135,9 @@ public:
|
||||
// It will be B_INCREASE_LATENCY by default
|
||||
BMediaNode::run_mode RunMode() const;
|
||||
status_t SetRunMode(BMediaNode::run_mode mode);
|
||||
status_t SetTimeSource(media_node timesource);
|
||||
// TODO: Really needed?
|
||||
status_t SetTimeSource(
|
||||
const media_client& timesource);
|
||||
|
||||
// Specify a latency range to allow the node behave correctly.
|
||||
// Ideally the minimum latency should be the algorithmic latency you expect
|
||||
@@ -183,6 +185,10 @@ protected:
|
||||
status_t ReleaseConnection(BMediaConnection* conn);
|
||||
|
||||
private:
|
||||
BMediaConnection* FindInput(
|
||||
const media_destination& dest) const;
|
||||
BMediaConnection* FindOutput(
|
||||
const media_source& source) const;
|
||||
|
||||
void _Init();
|
||||
void _Deinit();
|
||||
|
||||
@@ -15,6 +15,7 @@ namespace BPrivate { namespace media {
|
||||
|
||||
typedef int32 media_client_id;
|
||||
typedef int32 media_client_kind;
|
||||
typedef int32 media_connection_kind;
|
||||
typedef int32 media_connection_id;
|
||||
|
||||
|
||||
@@ -27,7 +28,7 @@ enum media_client_kinds {
|
||||
B_MEDIA_CONTROLLABLE = 0x000000004
|
||||
};
|
||||
|
||||
enum media_connection_kind {
|
||||
enum media_connection_kinds {
|
||||
B_MEDIA_INPUT = 0,
|
||||
B_MEDIA_OUTPUT = 1
|
||||
};
|
||||
@@ -55,7 +56,7 @@ typedef struct media_connection {
|
||||
media_connection_id Id() const;
|
||||
media_connection_kind Kind() const;
|
||||
|
||||
media_client Client() const;
|
||||
const media_client& Client() const;
|
||||
|
||||
const char* Name() const;
|
||||
|
||||
|
||||
@@ -249,6 +249,30 @@ BMediaClient::OutputAt(int32 index) const
|
||||
}
|
||||
|
||||
|
||||
BMediaConnection*
|
||||
BMediaClient::FindInput(const media_connection& input) const
|
||||
{
|
||||
CALLED();
|
||||
|
||||
if (!input.IsInput())
|
||||
return NULL;
|
||||
|
||||
return FindInput(input.Destination());
|
||||
}
|
||||
|
||||
|
||||
BMediaConnection*
|
||||
BMediaClient::FindOutput(const media_connection& output) const
|
||||
{
|
||||
CALLED();
|
||||
|
||||
if (!output.IsOutput())
|
||||
return NULL;
|
||||
|
||||
return FindOutput(output.Source());
|
||||
}
|
||||
|
||||
|
||||
BMediaConnection*
|
||||
BMediaClient::FindInput(const media_destination& dest) const
|
||||
{
|
||||
@@ -388,12 +412,12 @@ BMediaClient::SetRunMode(BMediaNode::run_mode mode)
|
||||
|
||||
|
||||
status_t
|
||||
BMediaClient::SetTimeSource(media_node timesource)
|
||||
BMediaClient::SetTimeSource(const media_client& timesource)
|
||||
{
|
||||
CALLED();
|
||||
|
||||
return BMediaRoster::CurrentRoster()->SetTimeSourceFor(fNode->Node().node,
|
||||
timesource.node);
|
||||
timesource.node.node);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -7,6 +7,8 @@
|
||||
#include <MediaConnection.h>
|
||||
#include <SupportDefs.h>
|
||||
|
||||
#include <debug.h>
|
||||
|
||||
#include <assert.h>
|
||||
#include <stdio.h>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user