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
a1eb826d
Commit
a1eb826d
authored
Aug 09, 2007
by
Pierre d'Herbemont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
control/media_instance.c: Set a per-object drawable.
parent
8239a932
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
22 additions
and
4 deletions
+22
-4
src/control/libvlc_internal.h
src/control/libvlc_internal.h
+4
-3
src/control/media_instance.c
src/control/media_instance.c
+18
-1
No files found.
src/control/libvlc_internal.h
View file @
a1eb826d
...
...
@@ -95,9 +95,10 @@ struct libvlc_media_instance_t
vlc_mutex_t
object_lock
;
int
i_input_id
;
/* Input object id. We don't use a pointer to
avoid any crash */
struct
libvlc_instance_t
*
p_libvlc_instance
;
/* Parent instance */
libvlc_media_descriptor_t
*
p_md
;
/* current media descriptor */
libvlc_event_manager_t
*
p_event_manager
;
struct
libvlc_instance_t
*
p_libvlc_instance
;
/* Parent instance */
libvlc_media_descriptor_t
*
p_md
;
/* current media descriptor */
libvlc_event_manager_t
*
p_event_manager
;
libvlc_drawable_t
drawable
;
};
struct
libvlc_media_list_player_t
...
...
src/control/media_instance.c
View file @
a1eb826d
...
...
@@ -145,6 +145,7 @@ libvlc_media_instance_new( libvlc_instance_t * p_libvlc_instance,
p_mi
=
malloc
(
sizeof
(
libvlc_media_instance_t
)
);
p_mi
->
p_md
=
NULL
;
p_mi
->
drawable
=
0
;
p_mi
->
p_libvlc_instance
=
p_libvlc_instance
;
p_mi
->
i_input_id
=
-
1
;
/* refcount strategy:
...
...
@@ -403,6 +404,12 @@ void libvlc_media_instance_play( libvlc_media_instance_t *p_mi,
p_mi
->
p_md
->
p_input_item
);
p_mi
->
i_input_id
=
p_input_thread
->
i_object_id
;
if
(
p_mi
->
drawable
)
{
vlc_value_t
val
;
val
.
i_int
=
p_mi
->
drawable
;
var_Set
(
p_input_thread
,
"drawable"
,
val
);
}
var_AddCallback
(
p_input_thread
,
"state"
,
input_state_changed
,
p_mi
);
/* will be released in media_instance_release() */
...
...
@@ -436,7 +443,17 @@ void libvlc_media_instance_pause( libvlc_media_instance_t *p_mi,
void
libvlc_media_instance_stop
(
libvlc_media_instance_t
*
p_mi
,
libvlc_exception_t
*
p_e
)
{
libvlc_exception_raise
(
p_mi
,
"Not implemented"
);
libvlc_exception_raise
(
p_e
,
"Not implemented"
);
}
/**************************************************************************
* Set Drawable
**************************************************************************/
void
libvlc_media_instance_set_drawable
(
libvlc_media_instance_t
*
p_mi
,
libvlc_drawable_t
drawable
,
libvlc_exception_t
*
p_e
)
{
p_mi
->
drawable
=
drawable
;
}
/**************************************************************************
...
...
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