d0e45a94e5ae6b5eabbd5a489098efdfdb91f9fd
[melted] / mlt / src / valerie / valerie_status.h
1 /*
2 * valerie_status.h -- Unit Status Handling
3 * Copyright (C) 2002-2003 Ushodaya Enterprises Limited
4 * Author: Charles Yates <charles.yates@pandora.be>
5 *
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2.1 of the License, or (at your option) any later version.
10 *
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
15 *
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the Free Software
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 */
20
21 #ifndef _VALERIE_STATUS_H_
22 #define _VALERIE_STATUS_H_
23
24 #ifdef __cplusplus
25 extern "C"
26 {
27 #endif
28
29 /** Status codes
30 */
31
32 typedef enum
33 {
34 unit_unknown = 0,
35 unit_undefined,
36 unit_offline,
37 unit_not_loaded,
38 unit_stopped,
39 unit_playing,
40 unit_paused,
41 unit_disconnected
42 }
43 unit_status;
44
45 /** Status structure.
46 */
47
48 typedef struct
49 {
50 int unit;
51 unit_status status;
52 char clip[ 2048 ];
53 double position;
54 double speed;
55 double fps;
56 double in;
57 double out;
58 double length;
59 char tail_clip[ 2048 ];
60 double tail_position;
61 double tail_in;
62 double tail_out;
63 double tail_length;
64 int seek_flag;
65 int generation;
66 int clip_index;
67 int dummy;
68 }
69 *valerie_status, valerie_status_t;
70
71 /** DV1394 Status API
72 */
73
74 extern void valerie_status_parse( valerie_status, char * );
75 extern char *valerie_status_serialise( valerie_status, char *, int );
76 extern int valerie_status_compare( valerie_status, valerie_status );
77 extern valerie_status valerie_status_copy( valerie_status, valerie_status );
78
79 #ifdef __cplusplus
80 }
81 #endif
82
83 #endif