]> git.sesse.net Git - vlc/blob - include/video_decoder.h
* Fixed the BeOS compile typo.
[vlc] / include / video_decoder.h
1 /*****************************************************************************
2  * video_decoder.h : video decoder thread
3  *****************************************************************************
4  * Copyright (C) 1999, 2000 VideoLAN
5  * $Id: video_decoder.h,v 1.24 2001/05/30 17:03:11 sam Exp $
6  *
7  * Authors: Christophe Massiot <massiot@via.ecp.fr>
8  *
9  * This program is free software; you can redistribute it and/or modify
10  * it under the terms of the GNU General Public License as published by
11  * the Free Software Foundation; either version 2 of the License, or
12  * (at your option) any later version.
13  * 
14  * This program is distributed in the hope that it will be useful,
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17  * GNU General Public License for more details.
18  *
19  * You should have received a copy of the GNU General Public License
20  * along with this program; if not, write to the Free Software
21  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111, USA.
22  *****************************************************************************/
23  
24 /*****************************************************************************
25  * Requires:
26  *  "config.h"
27  *  "common.h"
28  *  "mtime.h"
29  *  "threads.h"
30  *  "input.h"
31  *  "video.h"
32  *  "video_output.h"
33  *  "decoder_fifo.h"
34  *****************************************************************************/
35
36 /*****************************************************************************
37  * vdec_thread_t: video decoder thread descriptor
38  *****************************************************************************
39  * XXX??
40  *****************************************************************************/
41 typedef struct vdec_thread_s
42 {
43     /* Thread properties and locks */
44     boolean_t           b_die;                                 /* `die' flag */
45     boolean_t           b_run;                                 /* `run' flag */
46     boolean_t           b_error;                             /* `error' flag */
47     boolean_t           b_active;                           /* `active' flag */
48     vlc_thread_t        thread_id;                /* id for thread functions */
49
50     /* Thread configuration */
51     /* XXX?? */
52 //    int *pi_status;
53
54     /* idct iformations */
55     dctelem_t              p_pre_idct[64*64];
56
57     /* Macroblock copy functions */
58     void ( * pf_decode_init ) ( struct vdec_thread_s * );
59     void ( * pf_decode_mb_c ) ( struct vdec_thread_s *, struct macroblock_s * );
60     void ( * pf_decode_mb_bw )( struct vdec_thread_s *, struct macroblock_s * );
61
62     /* Input properties */
63     struct vpar_thread_s * p_vpar;                    /* video_parser thread */
64
65 } vdec_thread_t;
66
67 /*****************************************************************************
68  * Prototypes
69  *****************************************************************************/
70 struct vpar_thread_s;
71 struct macroblock_s;
72
73 /* Thread management functions */
74 #ifndef VDEC_SMP
75 int             vdec_InitThread         ( struct vdec_thread_s *p_vdec );
76 #endif
77 void            vdec_DecodeMacroblock   ( struct vdec_thread_s *p_vdec,
78                                           struct macroblock_s *p_mb );
79 void            vdec_DecodeMacroblockC  ( struct vdec_thread_s *p_vdec,
80                                           struct macroblock_s *p_mb );
81 void            vdec_DecodeMacroblockBW ( struct vdec_thread_s *p_vdec,
82                                           struct macroblock_s *p_mb );
83 vdec_thread_t * vdec_CreateThread       ( struct vpar_thread_s *p_vpar /*,
84                                           int *pi_status */ );
85 void            vdec_DestroyThread      ( vdec_thread_t *p_vdec /*,
86                                           int *pi_status */ );
87