Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
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-2-2
Commits
4855a761
Commit
4855a761
authored
Aug 16, 2007
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Made mosaic shared struct per-instance rather than per-process
parent
8b7d91f2
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
13 deletions
+13
-13
modules/stream_out/mosaic_bridge.c
modules/stream_out/mosaic_bridge.c
+8
-8
modules/video_filter/mosaic.c
modules/video_filter/mosaic.c
+3
-3
modules/video_filter/mosaic.h
modules/video_filter/mosaic.h
+2
-2
No files found.
modules/stream_out/mosaic_bridge.c
View file @
4855a761
...
...
@@ -175,7 +175,7 @@ static int Open( vlc_object_t *p_this )
{
sout_stream_t
*
p_stream
=
(
sout_stream_t
*
)
p_this
;
sout_stream_sys_t
*
p_sys
;
vlc_object_t
*
p_libvlc
_global
=
p_this
->
p_libvlc_global
;
vlc_object_t
*
p_libvlc
=
p_this
->
p_libvlc
;
vlc_value_t
val
;
config_ChainParse
(
p_stream
,
CFG_PREFIX
,
ppsz_sout_options
,
...
...
@@ -190,8 +190,8 @@ static int Open( vlc_object_t *p_this )
p_stream
->
p_sys
=
p_sys
;
p_sys
->
b_inited
=
VLC_FALSE
;
var_Create
(
p_libvlc
_global
,
"mosaic-lock"
,
VLC_VAR_MUTEX
);
var_Get
(
p_libvlc
_global
,
"mosaic-lock"
,
&
val
);
var_Create
(
p_libvlc
,
"mosaic-lock"
,
VLC_VAR_MUTEX
);
var_Get
(
p_libvlc
,
"mosaic-lock"
,
&
val
);
p_sys
->
p_lock
=
val
.
p_address
;
var_Get
(
p_stream
,
CFG_PREFIX
"id"
,
&
val
);
...
...
@@ -316,14 +316,14 @@ static sout_stream_id_t * Add( sout_stream_t *p_stream, es_format_t *p_fmt )
p_bridge
=
GetBridge
(
p_stream
);
if
(
p_bridge
==
NULL
)
{
vlc_object_t
*
p_libvlc
_global
=
p_stream
->
p_libvlc_global
;
vlc_object_t
*
p_libvlc
=
p_stream
->
p_libvlc
;
vlc_value_t
val
;
p_bridge
=
malloc
(
sizeof
(
bridge_t
)
);
var_Create
(
p_libvlc
_global
,
"mosaic-struct"
,
VLC_VAR_ADDRESS
);
var_Create
(
p_libvlc
,
"mosaic-struct"
,
VLC_VAR_ADDRESS
);
val
.
p_address
=
p_bridge
;
var_Set
(
p_libvlc
_global
,
"mosaic-struct"
,
val
);
var_Set
(
p_libvlc
,
"mosaic-struct"
,
val
);
p_bridge
->
i_es_num
=
0
;
p_bridge
->
pp_es
=
NULL
;
...
...
@@ -495,12 +495,12 @@ static int Del( sout_stream_t *p_stream, sout_stream_id_t *id )
if
(
b_last_es
)
{
vlc_object_t
*
p_libvlc
_global
=
p_stream
->
p_libvlc_global
;
vlc_object_t
*
p_libvlc
=
p_stream
->
p_libvlc
;
for
(
i
=
0
;
i
<
p_bridge
->
i_es_num
;
i
++
)
free
(
p_bridge
->
pp_es
[
i
]
);
free
(
p_bridge
->
pp_es
);
free
(
p_bridge
);
var_Destroy
(
p_libvlc
_global
,
"mosaic-struct"
);
var_Destroy
(
p_libvlc
,
"mosaic-struct"
);
}
vlc_mutex_unlock
(
p_sys
->
p_lock
);
...
...
modules/video_filter/mosaic.c
View file @
4855a761
...
...
@@ -284,7 +284,7 @@ static int CreateFilter( vlc_object_t *p_this )
{
filter_t
*
p_filter
=
(
filter_t
*
)
p_this
;
filter_sys_t
*
p_sys
;
vlc_object_t
*
p_libvlc
_global
=
p_filter
->
p_libvlc_global
;
vlc_object_t
*
p_libvlc
=
p_filter
->
p_libvlc
;
char
*
psz_order
;
char
*
psz_offsets
;
int
i_index
;
...
...
@@ -306,8 +306,8 @@ static int CreateFilter( vlc_object_t *p_this )
vlc_mutex_init
(
p_filter
,
&
p_sys
->
lock
);
vlc_mutex_lock
(
&
p_sys
->
lock
);
var_Create
(
p_libvlc
_global
,
"mosaic-lock"
,
VLC_VAR_MUTEX
);
var_Get
(
p_libvlc
_global
,
"mosaic-lock"
,
&
val
);
var_Create
(
p_libvlc
,
"mosaic-lock"
,
VLC_VAR_MUTEX
);
var_Get
(
p_libvlc
,
"mosaic-lock"
,
&
val
);
p_sys
->
p_lock
=
val
.
p_address
;
config_ChainParse
(
p_filter
,
CFG_PREFIX
,
ppsz_filter_options
,
...
...
modules/video_filter/mosaic.h
View file @
4855a761
...
...
@@ -40,11 +40,11 @@ typedef struct bridge_t
#define GetBridge(a) __GetBridge( VLC_OBJECT(a) )
static
bridge_t
*
__GetBridge
(
vlc_object_t
*
p_object
)
{
vlc_object_t
*
p_libvlc
_global
=
p_object
->
p_libvlc_global
;
vlc_object_t
*
p_libvlc
=
p_object
->
p_libvlc
;
bridge_t
*
p_bridge
;
vlc_value_t
val
;
if
(
var_Get
(
p_libvlc
_global
,
"mosaic-struct"
,
&
val
)
!=
VLC_SUCCESS
)
if
(
var_Get
(
p_libvlc
,
"mosaic-struct"
,
&
val
)
!=
VLC_SUCCESS
)
{
p_bridge
=
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