1 /******************************************************************************
5 / Description: ATI Rage Theater Video Decoder interface.
7 / Copyright 2001, Carlos Hasan
9 *******************************************************************************/
14 #include "TheatreReg.h"
15 #include "lendian_bitfield.h"
17 CTheater::CTheater(CRadeon
& radeon
, int device
)
20 fClock(C_RADEON_NO_VIDEO_CLOCK
),
24 fStandard(C_THEATER_NTSC
),
25 fSource(C_THEATER_TUNER
),
34 CTheater::~CTheater(){};
36 uint32
CTheater::Capabilities() const
41 caps
|= C_VIDEO_IN_HAS_COMPOSITE
;
43 caps
|= C_VIDEO_IN_HAS_SVIDEO
;
48 int CTheater::Register(int index
)
50 return fPort
.Register(fDevice
, index
);
53 int CTheater::Register(int index
, int mask
)
55 return fPort
.Register(fDevice
, index
) & mask
;
58 void CTheater::SetRegister(int index
, int value
)
60 fPort
.SetRegister(fDevice
, index
, value
);
63 void CTheater::SetRegister(int index
, int mask
, int value
)
65 if ((value
& ~mask
) != 0)
66 PRINT(("WARNING: CTheater::SetRegister(0x%04x, 0x%08x, 0x%08x)\n", index
, mask
, value
));
68 fPort
.SetRegister(fDevice
, index
,
69 (fPort
.Register(fDevice
, index
) & ~mask
) | (value
& mask
));