Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
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-gpu
Commits
5363e037
Commit
5363e037
authored
Jul 10, 2004
by
Laurent Aimar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* all: lot of cosmetics, and added a MUX_GET_MIME (not yet used).
parent
7fdad1d9
Changes
2
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
129 additions
and
116 deletions
+129
-116
include/stream_output.h
include/stream_output.h
+110
-93
src/stream_output/stream_output.c
src/stream_output/stream_output.c
+19
-23
No files found.
include/stream_output.h
View file @
5363e037
This diff is collapsed.
Click to expand it.
src/stream_output/stream_output.c
View file @
5363e037
...
...
@@ -39,7 +39,7 @@
/*****************************************************************************
* Local prototypes
*****************************************************************************/
static
void
sout_
cfg_free
(
sout_cfg_t
*
);
static
void
sout_
CfgDestroy
(
sout_cfg_t
*
);
#define sout_stream_url_to_chain( p, s ) _sout_stream_url_to_chain( VLC_OBJECT(p), s )
static
char
*
_sout_stream_url_to_chain
(
vlc_object_t
*
,
char
*
);
...
...
@@ -138,7 +138,7 @@ sout_instance_t *__sout_NewInstance( vlc_object_t *p_parent, char * psz_dest )
/* attach it for inherit */
vlc_object_attach
(
p_sout
,
p_parent
);
p_sout
->
p_stream
=
sout_
stream_n
ew
(
p_sout
,
p_sout
->
psz_chain
);
p_sout
->
p_stream
=
sout_
StreamN
ew
(
p_sout
,
p_sout
->
psz_chain
);
if
(
p_sout
->
p_stream
==
NULL
)
{
...
...
@@ -163,7 +163,7 @@ void sout_DeleteInstance( sout_instance_t * p_sout )
vlc_object_detach
(
p_sout
);
/* remove the stream out chain */
sout_
stream_d
elete
(
p_sout
->
p_stream
);
sout_
StreamD
elete
(
p_sout
->
p_stream
);
/* *** free all string *** */
FREE
(
p_sout
->
psz_sout
);
...
...
@@ -282,7 +282,7 @@ sout_access_out_t *sout_AccessOutNew( sout_instance_t *p_sout,
return
NULL
;
}
psz_next
=
sout_
cfg_parser
(
&
p_access
->
psz_access
,
&
p_access
->
p_cfg
,
psz_next
=
sout_
CfgCreate
(
&
p_access
->
psz_access
,
&
p_access
->
p_cfg
,
psz_access
);
if
(
psz_next
)
{
...
...
@@ -323,7 +323,7 @@ void sout_AccessOutDelete( sout_access_out_t *p_access )
}
free
(
p_access
->
psz_access
);
sout_
cfg_free
(
p_access
->
p_cfg
);
sout_
CfgDestroy
(
p_access
->
p_cfg
);
free
(
p_access
->
psz_name
);
...
...
@@ -373,13 +373,13 @@ sout_mux_t * sout_MuxNew( sout_instance_t *p_sout, char *psz_mux,
}
p_mux
->
p_sout
=
p_sout
;
psz_next
=
sout_
cfg_parser
(
&
p_mux
->
psz_mux
,
&
p_mux
->
p_cfg
,
psz_mux
);
psz_next
=
sout_
CfgCreate
(
&
p_mux
->
psz_mux
,
&
p_mux
->
p_cfg
,
psz_mux
);
if
(
psz_next
)
{
free
(
psz_next
);
}
p_mux
->
p_access
=
p_access
;
p_mux
->
pf_c
apacity
=
NULL
;
p_mux
->
pf_c
ontrol
=
NULL
;
p_mux
->
pf_addstream
=
NULL
;
p_mux
->
pf_delstream
=
NULL
;
p_mux
->
pf_mux
=
NULL
;
...
...
@@ -404,12 +404,10 @@ sout_mux_t * sout_MuxNew( sout_instance_t *p_sout, char *psz_mux,
}
/* *** probe mux capacity *** */
if
(
p_mux
->
pf_c
apacity
)
if
(
p_mux
->
pf_c
ontrol
)
{
int
b_answer
;
if
(
p_mux
->
pf_capacity
(
p_mux
,
SOUT_MUX_CAP_GET_ADD_STREAM_ANY_TIME
,
NULL
,
(
void
*
)
&
b_answer
)
!=
SOUT_MUX_CAP_ERR_OK
)
if
(
sout_MuxControl
(
p_mux
,
MUX_CAN_ADD_STREAM_WHILE_MUXING
,
&
b_answer
)
)
{
b_answer
=
VLC_FALSE
;
}
...
...
@@ -419,9 +417,7 @@ sout_mux_t * sout_MuxNew( sout_instance_t *p_sout, char *psz_mux,
p_mux
->
b_add_stream_any_time
=
VLC_TRUE
;
p_mux
->
b_waiting_stream
=
VLC_FALSE
;
if
(
p_mux
->
pf_capacity
(
p_mux
,
SOUT_MUX_CAP_GET_ADD_STREAM_WAIT
,
NULL
,
(
void
*
)
&
b_answer
)
!=
SOUT_MUX_CAP_ERR_OK
)
if
(
sout_MuxControl
(
p_mux
,
MUX_GET_ADD_STREAM_WAIT
,
&
b_answer
)
)
{
b_answer
=
VLC_FALSE
;
}
...
...
@@ -460,7 +456,7 @@ void sout_MuxDelete( sout_mux_t *p_mux )
}
free
(
p_mux
->
psz_mux
);
sout_
cfg_free
(
p_mux
->
p_cfg
);
sout_
CfgDestroy
(
p_mux
->
p_cfg
);
vlc_object_destroy
(
p_mux
);
}
...
...
@@ -748,7 +744,7 @@ static char *_get_chain_end( char *str )
}
}
char
*
sout_
cfg_parser
(
char
**
ppsz_name
,
sout_cfg_t
**
pp_cfg
,
char
*
psz_chain
)
char
*
sout_
CfgCreate
(
char
**
ppsz_name
,
sout_cfg_t
**
pp_cfg
,
char
*
psz_chain
)
{
sout_cfg_t
*
p_cfg
=
NULL
;
char
*
p
=
psz_chain
;
...
...
@@ -880,7 +876,7 @@ char *sout_cfg_parser( char **ppsz_name, sout_cfg_t **pp_cfg, char *psz_chain )
return
NULL
;
}
static
void
sout_
cfg_free
(
sout_cfg_t
*
p_cfg
)
static
void
sout_
CfgDestroy
(
sout_cfg_t
*
p_cfg
)
{
while
(
p_cfg
!=
NULL
)
{
...
...
@@ -896,7 +892,7 @@ static void sout_cfg_free( sout_cfg_t *p_cfg )
}
}
void
__sout_
ParseCfg
(
vlc_object_t
*
p_this
,
char
*
psz_prefix
,
void
__sout_
CfgParse
(
vlc_object_t
*
p_this
,
char
*
psz_prefix
,
const
char
**
ppsz_options
,
sout_cfg_t
*
cfg
)
{
char
*
psz_name
;
...
...
@@ -999,7 +995,7 @@ void __sout_ParseCfg( vlc_object_t *p_this, char *psz_prefix,
/*
* XXX name and p_cfg are used (-> do NOT free them)
*/
sout_stream_t
*
sout_
stream_n
ew
(
sout_instance_t
*
p_sout
,
char
*
psz_chain
)
sout_stream_t
*
sout_
StreamN
ew
(
sout_instance_t
*
p_sout
,
char
*
psz_chain
)
{
sout_stream_t
*
p_stream
;
...
...
@@ -1021,7 +1017,7 @@ sout_stream_t *sout_stream_new( sout_instance_t *p_sout, char *psz_chain )
p_stream
->
p_sys
=
NULL
;
p_stream
->
psz_next
=
sout_
cfg_parser
(
&
p_stream
->
psz_name
,
&
p_stream
->
p_cfg
,
psz_chain
);
sout_
CfgCreate
(
&
p_stream
->
psz_name
,
&
p_stream
->
p_cfg
,
psz_chain
);
msg_Dbg
(
p_sout
,
"stream=`%s'"
,
p_stream
->
psz_name
);
...
...
@@ -1032,14 +1028,14 @@ sout_stream_t *sout_stream_new( sout_instance_t *p_sout, char *psz_chain )
if
(
!
p_stream
->
p_module
)
{
sout_
stream_d
elete
(
p_stream
);
sout_
StreamD
elete
(
p_stream
);
return
NULL
;
}
return
p_stream
;
}
void
sout_
stream_d
elete
(
sout_stream_t
*
p_stream
)
void
sout_
StreamD
elete
(
sout_stream_t
*
p_stream
)
{
msg_Dbg
(
p_stream
,
"destroying chain... (name=%s)"
,
p_stream
->
psz_name
);
...
...
@@ -1049,7 +1045,7 @@ void sout_stream_delete( sout_stream_t *p_stream )
FREE
(
p_stream
->
psz_name
);
FREE
(
p_stream
->
psz_next
);
sout_
cfg_free
(
p_stream
->
p_cfg
);
sout_
CfgDestroy
(
p_stream
->
p_cfg
);
msg_Dbg
(
p_stream
,
"destroying chain done"
);
vlc_object_destroy
(
p_stream
);
...
...
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