summaryrefslogtreecommitdiff
path: root/include/rvl/vifuncs.h
blob: fab95b4db214fa26eae4f466bac9ff8d284c1b58 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#ifndef __VIFUNCS_H
#define __VIFUNCS_H

#ifdef __cplusplus
extern "C" {
#endif

#include "rvl/vitypes.h"
#include "rvl/GXStruct.h"     // for GXRenderModeObj structure


#define VIPadFrameBufferWidth(width)     ((u16)(((u16)(width) + 15) & ~15))

void VIInit                  ( void );
void VIFlush                 ( void );
void VIWaitForRetrace        ( void );

void VIConfigure             ( const GXRenderModeObj* rm );
void VIConfigurePan          ( u16 PanPosX, u16 PanPosY,
                               u16 PanSizeX, u16 PanSizeY );
void VISetNextFrameBuffer    ( void *fb );

void *VIGetNextFrameBuffer   ( void );
void *VIGetCurrentFrameBuffer( void );

VIRetraceCallback VISetPreRetraceCallback  (VIRetraceCallback callback);
VIRetraceCallback VISetPostRetraceCallback (VIRetraceCallback callback);

void VISetBlack              ( bool black );
u32  VIGetRetraceCount       ( void );
u32  VIGetNextField          ( void );
u32  VIGetCurrentLine        ( void );
u32  VIGetTvFormat           ( void );
u32  VIGetScanMode           ( void );

u32  VIGetDTVStatus          ( void );

// For test of switch to Progressive from Interlace
void  VISetVSyncTimingTest ( void );
u32   VIGetVSyncTimingTest ( void );


/********************************/
#ifdef __cplusplus
}
#endif

#endif