60Hz display mode configurable with setup.conf.

This commit is contained in:
Johns 2012-02-22 15:06:05 +01:00
parent 2f869884ba
commit 6ce760ccd8
6 changed files with 43 additions and 20 deletions

View File

@ -1,6 +1,7 @@
User johns User johns
Date: Date:
Makes 60Hz display mode configurable with setup.conf.
Support downmix of AC-3 to stero. Support downmix of AC-3 to stero.
New audio PES packet parser. New audio PES packet parser.
Fix bug: Grabbing a JPG image fails while suspended. Fix bug: Grabbing a JPG image fails while suspended.

View File

@ -176,6 +176,10 @@ Setup: /etc/vdr/setup.conf
softhddevice.Suspend.X11 = 0 softhddevice.Suspend.X11 = 0
1 suspend stops X11 server (not working yet) 1 suspend stops X11 server (not working yet)
softhddevice.60HzMode = 0
0 disable 60Hz display mode
1 enable 60Hz display mode
VideoDisplayFormat = ? VideoDisplayFormat = ?
0 pan and scan 0 pan and scan
1 letter box 1 letter box

1
Todo
View File

@ -25,7 +25,6 @@ missing:
suspend plugin didn't restore full-screen (is this wanted?) suspend plugin didn't restore full-screen (is this wanted?)
Option deinterlace off / deinterlace force! Option deinterlace off / deinterlace force!
ColorSpace aren't configurable with the gui. ColorSpace aren't configurable with the gui.
Inverse telecine isn't configurable with the gui.
Replay of old vdr 1.6 recordings. Replay of old vdr 1.6 recordings.
svdrp support for hot-keys. svdrp support for hot-keys.

View File

@ -64,6 +64,7 @@ static char ConfigHideMainMenuEntry; ///< config hide main menu entry
static int ConfigVideoSkipLines; ///< config skip lines top/bottom static int ConfigVideoSkipLines; ///< config skip lines top/bottom
static int ConfigVideoStudioLevels; ///< config use studio levels static int ConfigVideoStudioLevels; ///< config use studio levels
static int ConfigVideo60HzMode; ///< config use 60Hz display mode
/// config deinterlace /// config deinterlace
static int ConfigVideoDeinterlace[RESOLUTIONS]; static int ConfigVideoDeinterlace[RESOLUTIONS];
@ -950,7 +951,7 @@ bool cSoftHdDevice::SetPlayMode(ePlayMode play_mode)
Suspend(1, 1, 0); Suspend(1, 1, 0);
return true; return true;
default: default:
dsyslog("[softhddev]playmode not implemented... %d\n", play_mode); dsyslog("[softhddev] playmode not implemented... %d\n", play_mode);
break; break;
} }
::SetPlayMode(); ::SetPlayMode();
@ -1469,98 +1470,102 @@ bool cPluginSoftHdDevice::SetupParse(const char *name, const char *value)
//dsyslog("[softhddev]%s: '%s' = '%s'\n", __FUNCTION__, name, value); //dsyslog("[softhddev]%s: '%s' = '%s'\n", __FUNCTION__, name, value);
if (!strcmp(name, "MakePrimary")) { if (!strcasecmp(name, "MakePrimary")) {
ConfigMakePrimary = atoi(value); ConfigMakePrimary = atoi(value);
return true; return true;
} }
if (!strcmp(name, "HideMainMenuEntry")) { if (!strcasecmp(name, "HideMainMenuEntry")) {
ConfigHideMainMenuEntry = atoi(value); ConfigHideMainMenuEntry = atoi(value);
return true; return true;
} }
if (!strcmp(name, "SkipLines")) { if (!strcasecmp(name, "SkipLines")) {
VideoSetSkipLines(ConfigVideoSkipLines = atoi(value)); VideoSetSkipLines(ConfigVideoSkipLines = atoi(value));
return true; return true;
} }
if (!strcmp(name, "StudioLevels")) { if (!strcasecmp(name, "StudioLevels")) {
VideoSetStudioLevels(ConfigVideoStudioLevels = atoi(value)); VideoSetStudioLevels(ConfigVideoStudioLevels = atoi(value));
return true; return true;
} }
if (!strcasecmp(name, "60HzMode")) {
VideoSet60HzMode(ConfigVideo60HzMode = atoi(value));
return true;
}
for (i = 0; i < RESOLUTIONS; ++i) { for (i = 0; i < RESOLUTIONS; ++i) {
char buf[128]; char buf[128];
snprintf(buf, sizeof(buf), "%s.%s", Resolution[i], "Scaling"); snprintf(buf, sizeof(buf), "%s.%s", Resolution[i], "Scaling");
if (!strcmp(name, buf)) { if (!strcasecmp(name, buf)) {
ConfigVideoScaling[i] = atoi(value); ConfigVideoScaling[i] = atoi(value);
VideoSetScaling(ConfigVideoScaling); VideoSetScaling(ConfigVideoScaling);
return true; return true;
} }
snprintf(buf, sizeof(buf), "%s.%s", Resolution[i], "Deinterlace"); snprintf(buf, sizeof(buf), "%s.%s", Resolution[i], "Deinterlace");
if (!strcmp(name, buf)) { if (!strcasecmp(name, buf)) {
ConfigVideoDeinterlace[i] = atoi(value); ConfigVideoDeinterlace[i] = atoi(value);
VideoSetDeinterlace(ConfigVideoDeinterlace); VideoSetDeinterlace(ConfigVideoDeinterlace);
return true; return true;
} }
snprintf(buf, sizeof(buf), "%s.%s", Resolution[i], snprintf(buf, sizeof(buf), "%s.%s", Resolution[i],
"SkipChromaDeinterlace"); "SkipChromaDeinterlace");
if (!strcmp(name, buf)) { if (!strcasecmp(name, buf)) {
ConfigVideoSkipChromaDeinterlace[i] = atoi(value); ConfigVideoSkipChromaDeinterlace[i] = atoi(value);
VideoSetSkipChromaDeinterlace(ConfigVideoSkipChromaDeinterlace); VideoSetSkipChromaDeinterlace(ConfigVideoSkipChromaDeinterlace);
return true; return true;
} }
snprintf(buf, sizeof(buf), "%s.%s", Resolution[i], "InverseTelecine"); snprintf(buf, sizeof(buf), "%s.%s", Resolution[i], "InverseTelecine");
if (!strcmp(name, buf)) { if (!strcasecmp(name, buf)) {
ConfigVideoInverseTelecine[i] = atoi(value); ConfigVideoInverseTelecine[i] = atoi(value);
VideoSetInverseTelecine(ConfigVideoInverseTelecine); VideoSetInverseTelecine(ConfigVideoInverseTelecine);
return true; return true;
} }
snprintf(buf, sizeof(buf), "%s.%s", Resolution[i], "Denoise"); snprintf(buf, sizeof(buf), "%s.%s", Resolution[i], "Denoise");
if (!strcmp(name, buf)) { if (!strcasecmp(name, buf)) {
ConfigVideoDenoise[i] = atoi(value); ConfigVideoDenoise[i] = atoi(value);
VideoSetDenoise(ConfigVideoDenoise); VideoSetDenoise(ConfigVideoDenoise);
return true; return true;
} }
snprintf(buf, sizeof(buf), "%s.%s", Resolution[i], "Sharpen"); snprintf(buf, sizeof(buf), "%s.%s", Resolution[i], "Sharpen");
if (!strcmp(name, buf)) { if (!strcasecmp(name, buf)) {
ConfigVideoSharpen[i] = atoi(value); ConfigVideoSharpen[i] = atoi(value);
VideoSetSharpen(ConfigVideoSharpen); VideoSetSharpen(ConfigVideoSharpen);
return true; return true;
} }
} }
if (!strcmp(name, "AudioDelay")) { if (!strcasecmp(name, "AudioDelay")) {
VideoSetAudioDelay(ConfigVideoAudioDelay = atoi(value)); VideoSetAudioDelay(ConfigVideoAudioDelay = atoi(value));
return true; return true;
} }
if (!strcmp(name, "AudioPassthrough")) { if (!strcasecmp(name, "AudioPassthrough")) {
CodecSetAudioPassthrough(ConfigAudioPassthrough = atoi(value)); CodecSetAudioPassthrough(ConfigAudioPassthrough = atoi(value));
return true; return true;
} }
if (!strcmp(name, "AudioDownmix")) { if (!strcasecmp(name, "AudioDownmix")) {
CodecSetAudioDownmix(ConfigAudioDownmix = atoi(value)); CodecSetAudioDownmix(ConfigAudioDownmix = atoi(value));
return true; return true;
} }
if (!strcmp(name, "AutoCrop.Interval")) { if (!strcasecmp(name, "AutoCrop.Interval")) {
VideoSetAutoCrop(ConfigAutoCropInterval = VideoSetAutoCrop(ConfigAutoCropInterval =
atoi(value), ConfigAutoCropDelay, ConfigAutoCropTolerance); atoi(value), ConfigAutoCropDelay, ConfigAutoCropTolerance);
return true; return true;
} }
if (!strcmp(name, "AutoCrop.Delay")) { if (!strcasecmp(name, "AutoCrop.Delay")) {
VideoSetAutoCrop(ConfigAutoCropInterval, ConfigAutoCropDelay = VideoSetAutoCrop(ConfigAutoCropInterval, ConfigAutoCropDelay =
atoi(value), ConfigAutoCropTolerance); atoi(value), ConfigAutoCropTolerance);
return true; return true;
} }
if (!strcmp(name, "AutoCrop.Tolerance")) { if (!strcasecmp(name, "AutoCrop.Tolerance")) {
VideoSetAutoCrop(ConfigAutoCropInterval, ConfigAutoCropDelay, VideoSetAutoCrop(ConfigAutoCropInterval, ConfigAutoCropDelay,
ConfigAutoCropTolerance = atoi(value)); ConfigAutoCropTolerance = atoi(value));
return true; return true;
} }
if (!strcmp(name, "Suspend.Close")) { if (!strcasecmp(name, "Suspend.Close")) {
ConfigSuspendClose = atoi(value); ConfigSuspendClose = atoi(value);
return true; return true;
} }
if (!strcmp(name, "Suspend.X11")) { if (!strcasecmp(name, "Suspend.X11")) {
ConfigSuspendX11 = atoi(value); ConfigSuspendX11 = atoi(value);
return true; return true;
} }

11
video.c
View File

@ -8914,6 +8914,17 @@ int VideoSetGeometry(const char *geometry)
return 0; return 0;
} }
/// Set 60hz display mode.
///
/// Pull up 50 Hz video for 60 Hz display.
///
/// @param onoff enable / disable the 60 Hz mode.
///
void VideoSet60HzMode(int onoff)
{
Video60HzMode = onoff;
}
/// ///
/// Set video output position. /// Set video output position.
/// ///

View File

@ -80,6 +80,9 @@ extern void VideoDisplayWakeup(void);
/// Set video geometry. /// Set video geometry.
extern int VideoSetGeometry(const char *); extern int VideoSetGeometry(const char *);
/// Set 60Hz display mode.
extern void VideoSet60HzMode(int);
/// Set video output position. /// Set video output position.
extern void VideoSetOutputPosition(int, int, int, int); extern void VideoSetOutputPosition(int, int, int, int);