Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc
Commits
2a852751
Commit
2a852751
authored
Nov 27, 2014
by
Francois Cartegnie
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
stream_filter: dash: remove vlc object ref from adaptationlogic
parent
3a60ec4b
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
19 additions
and
21 deletions
+19
-21
modules/stream_filter/dash/DASHManager.cpp
modules/stream_filter/dash/DASHManager.cpp
+1
-1
modules/stream_filter/dash/adaptationlogic/AbstractAdaptationLogic.cpp
...m_filter/dash/adaptationlogic/AbstractAdaptationLogic.cpp
+2
-3
modules/stream_filter/dash/adaptationlogic/AbstractAdaptationLogic.h
...eam_filter/dash/adaptationlogic/AbstractAdaptationLogic.h
+1
-2
modules/stream_filter/dash/adaptationlogic/AdaptationLogicFactory.cpp
...am_filter/dash/adaptationlogic/AdaptationLogicFactory.cpp
+3
-3
modules/stream_filter/dash/adaptationlogic/AdaptationLogicFactory.h
...ream_filter/dash/adaptationlogic/AdaptationLogicFactory.h
+1
-1
modules/stream_filter/dash/adaptationlogic/AlwaysBestAdaptationLogic.cpp
...filter/dash/adaptationlogic/AlwaysBestAdaptationLogic.cpp
+2
-2
modules/stream_filter/dash/adaptationlogic/AlwaysBestAdaptationLogic.h
...m_filter/dash/adaptationlogic/AlwaysBestAdaptationLogic.h
+1
-1
modules/stream_filter/dash/adaptationlogic/RateBasedAdaptationLogic.cpp
..._filter/dash/adaptationlogic/RateBasedAdaptationLogic.cpp
+7
-4
modules/stream_filter/dash/adaptationlogic/RateBasedAdaptationLogic.h
...am_filter/dash/adaptationlogic/RateBasedAdaptationLogic.h
+1
-4
No files found.
modules/stream_filter/dash/DASHManager.cpp
View file @
2a852751
...
...
@@ -62,7 +62,7 @@ bool DASHManager::start()
if
(
this
->
mpdManager
==
NULL
)
return
false
;
this
->
adaptationLogic
=
AdaptationLogicFactory
::
create
(
this
->
logicType
,
this
->
mpdManager
,
this
->
stream
);
adaptationLogic
=
AdaptationLogicFactory
::
create
(
logicType
,
mpdManager
);
if
(
this
->
adaptationLogic
==
NULL
)
return
false
;
...
...
modules/stream_filter/dash/adaptationlogic/AbstractAdaptationLogic.cpp
View file @
2a852751
...
...
@@ -31,16 +31,15 @@ using namespace dash::logic;
using
namespace
dash
::
xml
;
using
namespace
dash
::
mpd
;
AbstractAdaptationLogic
::
AbstractAdaptationLogic
(
MPDManager
*
mpdManager
,
stream_t
*
stream
)
:
AbstractAdaptationLogic
::
AbstractAdaptationLogic
(
MPDManager
*
mpdManager
)
:
mpdManager
(
mpdManager
),
bpsAvg
(
0
),
bpsLastChunk
(
0
),
stream
(
stream
),
bufferedMicroSec
(
0
),
bufferedPercent
(
0
)
{
}
AbstractAdaptationLogic
::~
AbstractAdaptationLogic
()
{
}
...
...
modules/stream_filter/dash/adaptationlogic/AbstractAdaptationLogic.h
View file @
2a852751
...
...
@@ -43,7 +43,7 @@ namespace dash
class
AbstractAdaptationLogic
:
public
IAdaptationLogic
{
public:
AbstractAdaptationLogic
(
dash
::
mpd
::
MPDManager
*
mpdManager
,
stream_t
*
stream
);
AbstractAdaptationLogic
(
dash
::
mpd
::
MPDManager
*
mpdManager
);
virtual
~
AbstractAdaptationLogic
();
virtual
void
downloadRateChanged
(
uint64_t
bpsAvg
,
uint64_t
bpsLastChunk
);
...
...
@@ -59,7 +59,6 @@ namespace dash
private:
int
bpsAvg
;
long
bpsLastChunk
;
stream_t
*
stream
;
mtime_t
bufferedMicroSec
;
int
bufferedPercent
;
};
...
...
modules/stream_filter/dash/adaptationlogic/AdaptationLogicFactory.cpp
View file @
2a852751
...
...
@@ -32,12 +32,12 @@ using namespace dash::xml;
using
namespace
dash
::
mpd
;
IAdaptationLogic
*
AdaptationLogicFactory
::
create
(
IAdaptationLogic
::
LogicType
logic
,
MPDManager
*
mpdManager
,
stream_t
*
stream
)
MPDManager
*
mpdManager
)
{
switch
(
logic
)
{
case
IAdaptationLogic
:
:
AlwaysBest
:
return
new
AlwaysBestAdaptationLogic
(
mpdManager
,
stream
);
case
IAdaptationLogic
:
:
RateBased
:
return
new
RateBasedAdaptationLogic
(
mpdManager
,
stream
);
case
IAdaptationLogic
:
:
AlwaysBest
:
return
new
AlwaysBestAdaptationLogic
(
mpdManager
);
case
IAdaptationLogic
:
:
RateBased
:
return
new
RateBasedAdaptationLogic
(
mpdManager
);
case
IAdaptationLogic
:
:
Default
:
case
IAdaptationLogic
:
:
AlwaysLowest
:
default:
...
...
modules/stream_filter/dash/adaptationlogic/AdaptationLogicFactory.h
View file @
2a852751
...
...
@@ -40,7 +40,7 @@ namespace dash
class
AdaptationLogicFactory
{
public:
static
IAdaptationLogic
*
create
(
IAdaptationLogic
::
LogicType
logic
,
dash
::
mpd
::
MPDManager
*
mpdManager
,
stream_t
*
stream
);
static
IAdaptationLogic
*
create
(
IAdaptationLogic
::
LogicType
logic
,
dash
::
mpd
::
MPDManager
*
mpdManager
);
};
}
}
...
...
modules/stream_filter/dash/adaptationlogic/AlwaysBestAdaptationLogic.cpp
View file @
2a852751
...
...
@@ -32,8 +32,8 @@ using namespace dash::xml;
using
namespace
dash
::
http
;
using
namespace
dash
::
mpd
;
AlwaysBestAdaptationLogic
::
AlwaysBestAdaptationLogic
(
MPDManager
*
mpdManager
,
stream_t
*
stream
)
:
AbstractAdaptationLogic
(
mpdManager
,
stream
)
AlwaysBestAdaptationLogic
::
AlwaysBestAdaptationLogic
(
MPDManager
*
mpdManager
)
:
AbstractAdaptationLogic
(
mpdManager
)
{
this
->
count
=
0
;
this
->
initSchedule
();
...
...
modules/stream_filter/dash/adaptationlogic/AlwaysBestAdaptationLogic.h
View file @
2a852751
...
...
@@ -41,7 +41,7 @@ namespace dash
class
AlwaysBestAdaptationLogic
:
public
AbstractAdaptationLogic
{
public:
AlwaysBestAdaptationLogic
(
dash
::
mpd
::
MPDManager
*
mpdManager
,
stream_t
*
stream
);
AlwaysBestAdaptationLogic
(
dash
::
mpd
::
MPDManager
*
mpdManager
);
virtual
~
AlwaysBestAdaptationLogic
();
dash
::
http
::
Chunk
*
getNextChunk
();
...
...
modules/stream_filter/dash/adaptationlogic/RateBasedAdaptationLogic.cpp
View file @
2a852751
...
...
@@ -28,18 +28,21 @@
#include "RateBasedAdaptationLogic.h"
#include "Representationselectors.hpp"
#include <vlc_common.h>
#include <vlc_variables.h>
using
namespace
dash
::
logic
;
using
namespace
dash
::
xml
;
using
namespace
dash
::
http
;
using
namespace
dash
::
mpd
;
RateBasedAdaptationLogic
::
RateBasedAdaptationLogic
(
MPDManager
*
mpdManager
,
stream_t
*
stream
)
:
AbstractAdaptationLogic
(
mpdManager
,
stream
),
RateBasedAdaptationLogic
::
RateBasedAdaptationLogic
(
MPDManager
*
mpdManager
)
:
AbstractAdaptationLogic
(
mpdManager
),
count
(
0
),
currentPeriod
(
mpdManager
->
getFirstPeriod
())
{
width
=
var_InheritInteger
(
stream
,
"dash-prefwidth"
);
height
=
var_InheritInteger
(
stream
,
"dash-prefheight"
);
width
=
var_InheritInteger
(
mpdManager
->
getMPD
()
->
getVLCObject
()
,
"dash-prefwidth"
);
height
=
var_InheritInteger
(
mpdManager
->
getMPD
()
->
getVLCObject
()
,
"dash-prefheight"
);
}
Chunk
*
RateBasedAdaptationLogic
::
getNextChunk
()
...
...
modules/stream_filter/dash/adaptationlogic/RateBasedAdaptationLogic.h
View file @
2a852751
...
...
@@ -30,9 +30,6 @@
#include "mpd/MPDManager.hpp"
#include "http/Chunk.h"
#include <vlc_common.h>
#include <vlc_stream.h>
#define MINBUFFER 30
namespace
dash
...
...
@@ -42,7 +39,7 @@ namespace dash
class
RateBasedAdaptationLogic
:
public
AbstractAdaptationLogic
{
public:
RateBasedAdaptationLogic
(
dash
::
mpd
::
MPDManager
*
mpdManager
,
stream_t
*
stream
);
RateBasedAdaptationLogic
(
dash
::
mpd
::
MPDManager
*
mpdManager
);
dash
::
http
::
Chunk
*
getNextChunk
();
const
dash
::
mpd
::
Representation
*
getCurrentRepresentation
()
const
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment