return ret;
}
-int mmfile_format_get_frame(const char *path, double timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height)
+int mmfile_format_get_frame(const char *path, int64_t timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height)
{
int ret = MMFILE_FORMAT_SUCCESS;
AVFormatContext *pFormatCtx = NULL;
return ret;
}
-int mmfile_format_get_frame_from_memory(const void *data, unsigned int datasize, double timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height)
+int mmfile_format_get_frame_from_memory(const void *data, unsigned int datasize, int64_t timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height)
{
int ret = MMFILE_FORMAT_SUCCESS;
int format = -1;
* @see metadata_extractor_create(), metadata_extractor_destroy()
*/
-int mm_file_get_video_frame(const char *path, double timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height);
+int mm_file_get_video_frame(const char *path, int64_t timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height);
-int mm_file_get_video_frame_from_memory(const void *data, unsigned int datasize, double timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height);
+int mm_file_get_video_frame_from_memory(const void *data, unsigned int datasize, int64_t timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height);
int mm_file_check_uhqa(const char *filename, bool *is_uhqa);
*/
#ifndef __MMFILE_DYN_LOADING__
-int mmfile_format_get_frame(const char *path, double timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height);
+int mmfile_format_get_frame(const char *path, int64_t timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height);
-int mmfile_format_get_frame_from_memory(const void *data, unsigned int datasize, double timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height);
+int mmfile_format_get_frame_from_memory(const void *data, unsigned int datasize, int64_t timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height);
#endif
static int (*mmfile_format_read_frame)(MMFileFormatContext *formatContext, unsigned int timestamp, MMFileFormatFrame *frame);
static int (*mmfile_format_read_tag)(MMFileFormatContext *formatContext);
static int (*mmfile_format_close)(MMFileFormatContext *formatContext);
-static int (*mmfile_format_get_frame)(const char *path, double timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height);
-static int (*mmfile_format_get_frame_from_memory)(const void *data, unsigned int datasize, double timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height);
+static int (*mmfile_format_get_frame)(const char *path, int64_t timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height);
+static int (*mmfile_format_get_frame_from_memory)(const void *data, unsigned int datasize, int64_t timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height);
#endif
#ifdef __MMFILE_DYN_LOADING__
}
-int mm_file_get_video_frame(const char *path, double timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height)
+int mm_file_get_video_frame(const char *path, int64_t timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height)
{
int ret = 0;
void *formatFuncHandle = NULL;
}
-int mm_file_get_video_frame_from_memory(const void *data, unsigned int datasize, double timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height)
+int mm_file_get_video_frame_from_memory(const void *data, unsigned int datasize, int64_t timestamp, bool is_accurate, unsigned char **frame, int *size, int *width, int *height)
{
int ret = 0;
void *formatFuncHandle = NULL;
Name: libmm-fileinfo
Summary: Media Fileinfo
-Version: 1.0.16
+Version: 1.0.17
Release: 0
Group: System/Libraries
License: Apache-2.0
int width = 0;
int height = 0;
bool is_accurate = false;
- double time_stamp = 5. * 1000 * 1000; //5sec
+ int64_t time_stamp = 5 * 1000 * 1000; //5sec
if (accurate && accurate[0] == '1')
is_accurate = true;
- printf("Extracting video frame for [%s] [%f] accurate [%d]\n", path, time_stamp, is_accurate);
+ printf("Extracting video frame for [%s] [%"PRId64"] accurate [%d]\n", path, time_stamp, is_accurate);
if (file_test)
ret = mm_file_get_video_frame(path, time_stamp, is_accurate, &_frame, &_frame_size, &width, &height);