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
79179c9e
Commit
79179c9e
authored
Jan 07, 2008
by
Pierre d'Herbemont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
vlc/libvlc.h: Use libvlc_time_t.
parent
42720931
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
29 additions
and
17 deletions
+29
-17
include/vlc/libvlc.h
include/vlc/libvlc.h
+12
-12
include/vlc/libvlc_structures.h
include/vlc/libvlc_structures.h
+14
-1
src/control/media_instance.c
src/control/media_instance.c
+3
-4
No files found.
include/vlc/libvlc.h
View file @
79179c9e
...
@@ -230,7 +230,7 @@ VLC_PUBLIC_API libvlc_event_manager_t *
...
@@ -230,7 +230,7 @@ VLC_PUBLIC_API libvlc_event_manager_t *
libvlc_media_descriptor_event_manager
(
libvlc_media_descriptor_t
*
p_md
,
libvlc_media_descriptor_event_manager
(
libvlc_media_descriptor_t
*
p_md
,
libvlc_exception_t
*
p_e
);
libvlc_exception_t
*
p_e
);
VLC_PUBLIC_API
vlc_int64
_t
VLC_PUBLIC_API
libvlc_time
_t
libvlc_media_descriptor_get_duration
(
libvlc_media_descriptor_t
*
p_md
,
libvlc_media_descriptor_get_duration
(
libvlc_media_descriptor_t
*
p_md
,
libvlc_exception_t
*
p_e
);
libvlc_exception_t
*
p_e
);
...
@@ -445,17 +445,17 @@ VLC_PUBLIC_API void libvlc_media_instance_stop ( libvlc_media_instance_t *, libv
...
@@ -445,17 +445,17 @@ VLC_PUBLIC_API void libvlc_media_instance_stop ( libvlc_media_instance_t *, libv
VLC_PUBLIC_API
void
libvlc_media_instance_set_drawable
(
libvlc_media_instance_t
*
,
libvlc_drawable_t
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
void
libvlc_media_instance_set_drawable
(
libvlc_media_instance_t
*
,
libvlc_drawable_t
,
libvlc_exception_t
*
);
/** \bug This might go away ... to be replaced by a broader system */
/** \bug This might go away ... to be replaced by a broader system */
VLC_PUBLIC_API
vlc_int64
_t
libvlc_media_instance_get_length
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
libvlc_time
_t
libvlc_media_instance_get_length
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
vlc_int64
_t
libvlc_media_instance_get_time
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
libvlc_time
_t
libvlc_media_instance_get_time
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
void
libvlc_media_instance_set_time
(
libvlc_media_instance_t
*
,
vlc_int64
_t
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
void
libvlc_media_instance_set_time
(
libvlc_media_instance_t
*
,
libvlc_time
_t
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
float
libvlc_media_instance_get_position
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
float
libvlc_media_instance_get_position
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
void
libvlc_media_instance_set_position
(
libvlc_media_instance_t
*
,
float
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
void
libvlc_media_instance_set_position
(
libvlc_media_instance_t
*
,
float
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
void
libvlc_media_instance_set_chapter
(
libvlc_media_instance_t
*
,
int
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
void
libvlc_media_instance_set_chapter
(
libvlc_media_instance_t
*
,
int
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
int
libvlc_media_instance_get_chapter
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
int
libvlc_media_instance_get_chapter
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
int
libvlc_media_instance_get_chapter_count
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
int
libvlc_media_instance_get_chapter_count
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
vlc_bool_t
libvlc_media_instance_will_play
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
vlc_bool_t
libvlc_media_instance_will_play
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
float
libvlc_media_instance_get_rate
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
float
libvlc_media_instance_get_rate
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
void
libvlc_media_instance_set_rate
(
libvlc_media_instance_t
*
,
float
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
void
libvlc_media_instance_set_rate
(
libvlc_media_instance_t
*
,
float
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
libvlc_state_t
libvlc_media_instance_get_state
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
VLC_PUBLIC_API
libvlc_state_t
libvlc_media_instance_get_state
(
libvlc_media_instance_t
*
,
libvlc_exception_t
*
);
/**
/**
...
...
include/vlc/libvlc_structures.h
View file @
79179c9e
...
@@ -66,6 +66,19 @@ typedef char * libvlc_tag_t;
...
@@ -66,6 +66,19 @@ typedef char * libvlc_tag_t;
/**@} */
/**@} */
/*****************************************************************************
* Time
*****************************************************************************/
/** defgroup libvlc_time Time
* \ingroup libvlc
* LibVLC Time support in libvlc
* @{
*/
typedef
vlc_int64_t
libvlc_time_t
;
/**@} */
/*****************************************************************************
/*****************************************************************************
* Media Descriptor
* Media Descriptor
*****************************************************************************/
*****************************************************************************/
...
@@ -373,7 +386,7 @@ typedef struct libvlc_event_t
...
@@ -373,7 +386,7 @@ typedef struct libvlc_event_t
}
media_instance_position_changed
;
}
media_instance_position_changed
;
struct
struct
{
{
l
ong
in
t
new_time
;
l
ibvlc_time_
t
new_time
;
}
media_instance_time_changed
;
}
media_instance_time_changed
;
/* media list */
/* media list */
...
...
src/control/media_instance.c
View file @
79179c9e
...
@@ -221,7 +221,6 @@ input_time_changed( vlc_object_t * p_this, char const * psz_cmd,
...
@@ -221,7 +221,6 @@ input_time_changed( vlc_object_t * p_this, char const * psz_cmd,
libvlc_event_t
event
;
libvlc_event_t
event
;
event
.
type
=
libvlc_MediaInstanceTimeChanged
;
event
.
type
=
libvlc_MediaInstanceTimeChanged
;
event
.
u
.
media_instance_time_changed
.
new_time
=
val
.
i_time
;
event
.
u
.
media_instance_time_changed
.
new_time
=
val
.
i_time
;
libvlc_event_send
(
p_mi
->
p_event_manager
,
&
event
);
libvlc_event_send
(
p_mi
->
p_event_manager
,
&
event
);
return
VLC_SUCCESS
;
return
VLC_SUCCESS
;
}
}
...
@@ -594,7 +593,7 @@ void libvlc_media_instance_set_drawable( libvlc_media_instance_t *p_mi,
...
@@ -594,7 +593,7 @@ void libvlc_media_instance_set_drawable( libvlc_media_instance_t *p_mi,
/**************************************************************************
/**************************************************************************
* Getters for stream information
* Getters for stream information
**************************************************************************/
**************************************************************************/
vlc_int64
_t
libvlc_media_instance_get_length
(
libvlc_time
_t
libvlc_media_instance_get_length
(
libvlc_media_instance_t
*
p_mi
,
libvlc_media_instance_t
*
p_mi
,
libvlc_exception_t
*
p_e
)
libvlc_exception_t
*
p_e
)
{
{
...
@@ -611,7 +610,7 @@ vlc_int64_t libvlc_media_instance_get_length(
...
@@ -611,7 +610,7 @@ vlc_int64_t libvlc_media_instance_get_length(
return
(
val
.
i_time
+
500LL
)
/
1000LL
;
return
(
val
.
i_time
+
500LL
)
/
1000LL
;
}
}
vlc_int64
_t
libvlc_media_instance_get_time
(
libvlc_time
_t
libvlc_media_instance_get_time
(
libvlc_media_instance_t
*
p_mi
,
libvlc_media_instance_t
*
p_mi
,
libvlc_exception_t
*
p_e
)
libvlc_exception_t
*
p_e
)
{
{
...
@@ -629,7 +628,7 @@ vlc_int64_t libvlc_media_instance_get_time(
...
@@ -629,7 +628,7 @@ vlc_int64_t libvlc_media_instance_get_time(
void
libvlc_media_instance_set_time
(
void
libvlc_media_instance_set_time
(
libvlc_media_instance_t
*
p_mi
,
libvlc_media_instance_t
*
p_mi
,
vlc_int64
_t
time
,
libvlc_time
_t
time
,
libvlc_exception_t
*
p_e
)
libvlc_exception_t
*
p_e
)
{
{
input_thread_t
*
p_input_thread
;
input_thread_t
*
p_input_thread
;
...
...
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