/* Swfdec
 * Copyright (C) 2007-2008 Benjamin Otte <otte@gnome.org>
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 * 
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Lesser General Public License for more details.
 * 
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, 
 * Boston, MA  02110-1301  USA
 */

#ifndef _SWFDEC_NMP_H_
#define _SWFDEC_NMP_H_

typedef enum
{
	MP_CLOSED = 0,
	MP_OPENNING,
	MP_OPENED,
	MP_STARTING,
	MP_STARTED,
	MP_PB_PLAYING = MP_STARTED,
	MP_PB_BUFFERING,	
	MP_PB_FINISHED,
} MPSTATUS;

#ifdef __cplusplus
extern "C"
{
#endif

int 		swfdec_nmp_constructor(void **mp);
int 		swfdec_nmp_destructor(void **mp);
MPSTATUS 	swfdec_nmp_set_status(void *mp, MPSTATUS status);
MPSTATUS 	swfdec_nmp_get_status(void *mp);
int 		swfdec_nmp_open(void *mp, int *p_exit);
int 		swfdec_nmp_play(void *mp, int x, int y, int w, int h, int buffer_time, int *p_exit);
int 		swfdec_nmp_close(void *mp);
int 		swfdec_nmp_pause(void *mp, int on_off);
int 		swfdec_nmp_resize(void *mp, int x, int y, int w, int h);
long 		swfdec_nmp_get_pts(void *mp);
double 		swfdec_nmp_get_bitrate(void *mp);
int			swfdec_nmp_get_metadata(void *mp, char **buf, int *size);
int			swfdec_nmp_is_fail(void *mp);
int			swfdec_nmp_get_starttime(void *mp, char *buf, int size, unsigned int *start_time);
int			swfdec_nmp_set_starttime(void *mp, char **buf, int *size, unsigned int start_time);

#ifdef __cplusplus
}
#endif

#endif
