Project

General

Profile

Feature #2039 ยป 0001-Get-activeOsd3DMode..patch

chriszero, 12/23/2014 08:00 PM

View differences:

softhddevice.cpp
{
//dsyslog("[softhddev]%s: id %s\n", __FUNCTION__, id);
if (strcmp(id, OSD1_3DMODE_SERVICE) == 0) {
SoftHDDevice_Osd3DModeService_v1_1_t *r;
r = (SoftHDDevice_Osd3DModeService_v1_1_t *) data;
if (r->GetMode) {
r->Mode = VideoGetOsd3DMode();
}
else {
VideoSetOsd3DMode(r->Mode);
return true;
}
}
if (strcmp(id, OSD_3DMODE_SERVICE) == 0) {
SoftHDDevice_Osd3DModeService_v1_0_t *r;
softhddevice_service.h
#define ATMO_GRAB_SERVICE "SoftHDDevice-AtmoGrabService-v1.0"
#define ATMO1_GRAB_SERVICE "SoftHDDevice-AtmoGrabService-v1.1"
#define OSD_3DMODE_SERVICE "SoftHDDevice-Osd3DModeService-v1.0"
#define OSD1_3DMODE_SERVICE "SoftHDDevice-Osd3DModeService-v1.1"
enum
{ GRAB_IMG_RGBA_FORMAT_B8G8R8A8 };
......
typedef struct
{
int Mode;
bool GetMode;
} SoftHDDevice_Osd3DModeService_v1_1_t;
typedef struct
{
// request/reply data
int width;
video.c
}
///
/// Set active 3d OSD mode.
///
/// @return mode OSD mode (0=off, 1=SBS, 2=Top Bottom)
///
int VideoGetOsd3DMode(void)
{
return Osd3DMode;
}
///
/// Set the 3d OSD mode.
///
/// @param mode OSD mode (0=off, 1=SBS, 2=Top Bottom)
video.h
/// Set Osd 3D Mode
extern void VideoSetOsd3DMode(int);
/// Get Osd 3D Mode
extern int VideoGetOsd3DMode(void);
/// Set video clock.
extern void VideoSetClock(VideoHwDecoder *, int64_t);
    (1-1/1)