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
92a4a5b3
Commit
92a4a5b3
authored
Aug 26, 2008
by
Laurent Aimar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Do not access to internal p_input sout in input_DecoderNew.
parent
fa2757f7
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
12 deletions
+11
-12
include/vlc_input.h
include/vlc_input.h
+1
-1
modules/stream_out/display.c
modules/stream_out/display.c
+1
-1
src/input/decoder.c
src/input/decoder.c
+9
-10
No files found.
include/vlc_input.h
View file @
92a4a5b3
...
@@ -540,7 +540,7 @@ static inline input_state_e input_GetState( input_thread_t * p_input )
...
@@ -540,7 +540,7 @@ static inline input_state_e input_GetState( input_thread_t * p_input )
input_Control
(
p_input
,
INPUT_GET_STATE
,
&
state
);
input_Control
(
p_input
,
INPUT_GET_STATE
,
&
state
);
return
state
;
return
state
;
}
}
VLC_EXPORT
(
decoder_t
*
,
input_DecoderNew
,
(
input_thread_t
*
,
es_format_t
*
,
bool
b_force_decoder
)
);
VLC_EXPORT
(
decoder_t
*
,
input_DecoderNew
,
(
input_thread_t
*
,
es_format_t
*
,
sout_instance_t
*
)
);
VLC_EXPORT
(
void
,
input_DecoderDelete
,
(
decoder_t
*
)
);
VLC_EXPORT
(
void
,
input_DecoderDelete
,
(
decoder_t
*
)
);
VLC_EXPORT
(
void
,
input_DecoderDecode
,(
decoder_t
*
,
block_t
*
)
);
VLC_EXPORT
(
void
,
input_DecoderDecode
,(
decoder_t
*
,
block_t
*
)
);
...
...
modules/stream_out/display.c
View file @
92a4a5b3
...
@@ -168,7 +168,7 @@ static sout_stream_id_t * Add( sout_stream_t *p_stream, es_format_t *p_fmt )
...
@@ -168,7 +168,7 @@ static sout_stream_id_t * Add( sout_stream_t *p_stream, es_format_t *p_fmt )
}
}
}
}
id
->
p_dec
=
input_DecoderNew
(
p_sys
->
p_input
,
p_fmt
,
true
);
id
->
p_dec
=
input_DecoderNew
(
p_sys
->
p_input
,
p_fmt
,
NULL
);
if
(
id
->
p_dec
==
NULL
)
if
(
id
->
p_dec
==
NULL
)
{
{
msg_Err
(
p_stream
,
"cannot create decoder for fcc=`%4.4s'"
,
msg_Err
(
p_stream
,
"cannot create decoder for fcc=`%4.4s'"
,
...
...
src/input/decoder.c
View file @
92a4a5b3
...
@@ -45,7 +45,7 @@
...
@@ -45,7 +45,7 @@
#include "stream_output/stream_output.h"
#include "stream_output/stream_output.h"
#include "input_internal.h"
#include "input_internal.h"
static
decoder_t
*
CreateDecoder
(
input_thread_t
*
,
es_format_t
*
,
int
);
static
decoder_t
*
CreateDecoder
(
input_thread_t
*
,
es_format_t
*
,
int
,
sout_instance_t
*
p_sout
);
static
void
DeleteDecoder
(
decoder_t
*
);
static
void
DeleteDecoder
(
decoder_t
*
);
static
void
*
DecoderThread
(
vlc_object_t
*
);
static
void
*
DecoderThread
(
vlc_object_t
*
);
...
@@ -148,7 +148,7 @@ mtime_t decoder_GetDisplayDate( decoder_t *p_dec, mtime_t i_ts )
...
@@ -148,7 +148,7 @@ mtime_t decoder_GetDisplayDate( decoder_t *p_dec, mtime_t i_ts )
* \return the spawned decoder object
* \return the spawned decoder object
*/
*/
decoder_t
*
input_DecoderNew
(
input_thread_t
*
p_input
,
decoder_t
*
input_DecoderNew
(
input_thread_t
*
p_input
,
es_format_t
*
fmt
,
bool
b_force_decoder
)
es_format_t
*
fmt
,
sout_instance_t
*
p_sout
)
{
{
decoder_t
*
p_dec
=
NULL
;
decoder_t
*
p_dec
=
NULL
;
vlc_value_t
val
;
vlc_value_t
val
;
...
@@ -157,10 +157,10 @@ decoder_t *input_DecoderNew( input_thread_t *p_input,
...
@@ -157,10 +157,10 @@ decoder_t *input_DecoderNew( input_thread_t *p_input,
(
void
)
b_force_decoder
;
(
void
)
b_force_decoder
;
#else
#else
/* If we are in sout mode, search for packetizer module */
/* If we are in sout mode, search for packetizer module */
if
(
p_
input
->
p
->
p_sout
&&
!
b_force_decoder
)
if
(
p_
sout
)
{
{
/* Create the decoder configuration structure */
/* Create the decoder configuration structure */
p_dec
=
CreateDecoder
(
p_input
,
fmt
,
VLC_OBJECT_PACKETIZER
);
p_dec
=
CreateDecoder
(
p_input
,
fmt
,
VLC_OBJECT_PACKETIZER
,
p_sout
);
if
(
p_dec
==
NULL
)
if
(
p_dec
==
NULL
)
{
{
msg_Err
(
p_input
,
"could not create packetizer"
);
msg_Err
(
p_input
,
"could not create packetizer"
);
...
@@ -173,7 +173,7 @@ decoder_t *input_DecoderNew( input_thread_t *p_input,
...
@@ -173,7 +173,7 @@ decoder_t *input_DecoderNew( input_thread_t *p_input,
#endif
#endif
{
{
/* Create the decoder configuration structure */
/* Create the decoder configuration structure */
p_dec
=
CreateDecoder
(
p_input
,
fmt
,
VLC_OBJECT_DECODER
);
p_dec
=
CreateDecoder
(
p_input
,
fmt
,
VLC_OBJECT_DECODER
,
p_sout
);
if
(
p_dec
==
NULL
)
if
(
p_dec
==
NULL
)
{
{
msg_Err
(
p_input
,
"could not create decoder"
);
msg_Err
(
p_input
,
"could not create decoder"
);
...
@@ -192,8 +192,7 @@ decoder_t *input_DecoderNew( input_thread_t *p_input,
...
@@ -192,8 +192,7 @@ decoder_t *input_DecoderNew( input_thread_t *p_input,
return
NULL
;
return
NULL
;
}
}
if
(
p_input
->
p
->
p_sout
&&
p_input
->
p
->
input
.
b_can_pace_control
&&
if
(
p_sout
&&
p_sout
==
p_input
->
p
->
p_sout
&&
p_input
->
p
->
input
.
b_can_pace_control
)
!
b_force_decoder
)
{
{
msg_Dbg
(
p_input
,
"stream out mode -> no decoder thread"
);
msg_Dbg
(
p_input
,
"stream out mode -> no decoder thread"
);
p_dec
->
p_owner
->
b_own_thread
=
false
;
p_dec
->
p_owner
->
b_own_thread
=
false
;
...
@@ -375,7 +374,7 @@ int input_DecoderSetCcState( decoder_t *p_dec, bool b_decode, int i_channel )
...
@@ -375,7 +374,7 @@ int input_DecoderSetCcState( decoder_t *p_dec, bool b_decode, int i_channel )
es_format_t
fmt
;
es_format_t
fmt
;
es_format_Init
(
&
fmt
,
SPU_ES
,
fcc
[
i_channel
]
);
es_format_Init
(
&
fmt
,
SPU_ES
,
fcc
[
i_channel
]
);
p_cc
=
CreateDecoder
(
p_owner
->
p_input
,
&
fmt
,
VLC_OBJECT_DECODER
);
p_cc
=
CreateDecoder
(
p_owner
->
p_input
,
&
fmt
,
VLC_OBJECT_DECODER
,
p_dec
->
p_owner
->
p_sout
);
if
(
!
p_cc
)
if
(
!
p_cc
)
{
{
msg_Err
(
p_dec
,
"could not create decoder"
);
msg_Err
(
p_dec
,
"could not create decoder"
);
...
@@ -437,7 +436,7 @@ int input_DecoderGetCcState( decoder_t *p_dec, bool *pb_decode, int i_channel )
...
@@ -437,7 +436,7 @@ int input_DecoderGetCcState( decoder_t *p_dec, bool *pb_decode, int i_channel )
* \return the decoder object
* \return the decoder object
*/
*/
static
decoder_t
*
CreateDecoder
(
input_thread_t
*
p_input
,
static
decoder_t
*
CreateDecoder
(
input_thread_t
*
p_input
,
es_format_t
*
fmt
,
int
i_object_type
)
es_format_t
*
fmt
,
int
i_object_type
,
sout_instance_t
*
p_sout
)
{
{
decoder_t
*
p_dec
;
decoder_t
*
p_dec
;
decoder_owner_sys_t
*
p_owner
;
decoder_owner_sys_t
*
p_owner
;
...
@@ -475,7 +474,7 @@ static decoder_t * CreateDecoder( input_thread_t *p_input,
...
@@ -475,7 +474,7 @@ static decoder_t * CreateDecoder( input_thread_t *p_input,
p_dec
->
p_owner
->
p_vout
=
NULL
;
p_dec
->
p_owner
->
p_vout
=
NULL
;
p_dec
->
p_owner
->
p_spu_vout
=
NULL
;
p_dec
->
p_owner
->
p_spu_vout
=
NULL
;
p_dec
->
p_owner
->
i_spu_channel
=
0
;
p_dec
->
p_owner
->
i_spu_channel
=
0
;
p_dec
->
p_owner
->
p_sout
=
p_
input
->
p
->
p_
sout
;
p_dec
->
p_owner
->
p_sout
=
p_sout
;
p_dec
->
p_owner
->
p_sout_input
=
NULL
;
p_dec
->
p_owner
->
p_sout_input
=
NULL
;
p_dec
->
p_owner
->
p_packetizer
=
NULL
;
p_dec
->
p_owner
->
p_packetizer
=
NULL
;
...
...
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