Commit d58fc248 authored by Mickaël Turnel's avatar Mickaël Turnel

Fix media player time type

parent c48ef3eb
......@@ -135,7 +135,7 @@ typedef enum _MSPlayerState MSPlayerState;
MS_FILTER_METHOD(MSFilterPlayerInterface,7,int)
#define MS_PLAYER_GET_CURRENT_POSITION \
MS_FILTER_METHOD(MSFilterPlayerInterface,8,int64_t)
MS_FILTER_METHOD(MSFilterPlayerInterface,8,int)
#define MS_PLAYER_EOF \
MS_FILTER_EVENT_NO_ARG(MSFilterPlayerInterface,0)
......
......@@ -2487,7 +2487,7 @@ static void mkv_track_player_flush(MKVTrackPlayer *obj) {
typedef struct {
MKVReader *reader;
MSPlayerState state;
timecode_t time;
int time;
MKVTrackPlayer *players[2];
ms_bool_t position_changed;
int loop_pause_interval, time_before_next_loop;
......@@ -2775,7 +2775,7 @@ static int player_get_current_position(MSFilter *f, void *arg) {
ms_error("MKVPlayer: cannot get current duration. No file is open");
goto fail;
}
*(int64_t *)arg = (int64_t)obj->time;
*(int *)arg = obj->time;
ms_filter_unlock(f);
return 0;
......
......@@ -249,7 +249,7 @@ int ms_media_player_get_duration(MSMediaPlayer *obj) {
}
int ms_media_player_get_current_position(MSMediaPlayer *obj) {
int64_t position;
int position;
if(!obj->is_open) {
ms_error("Could not get position. No file is open");
return -1;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment