From 33c638d538cef475cbcd61a941dc94294417e849 Mon Sep 17 00:00:00 2001 From: "m.Rcu" <> Date: Sun, 12 Feb 2012 20:30:50 +0100 Subject: Jpeg screengrab use VDR RgbToJpeg function. --- softhddevice.cpp | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'softhddevice.cpp') diff --git a/softhddevice.cpp b/softhddevice.cpp index ad9d0cb..a579bd3 100644 --- a/softhddevice.cpp +++ b/softhddevice.cpp @@ -886,17 +886,17 @@ bool cSoftHdDevice::Flush(int timeout_ms) ** Sets the video display format to the given one (only useful if this ** device has an MPEG decoder). ** -** @note FIXME: this function isn't called on the initial channel +** @note this function isn't called on the initial channel */ void cSoftHdDevice::SetVideoDisplayFormat( eVideoDisplayFormat video_display_format) { static int last = -1; - cDevice::SetVideoDisplayFormat(video_display_format); - dsyslog("[softhddev]%s: %d\n", __FUNCTION__, video_display_format); + cDevice::SetVideoDisplayFormat(video_display_format); + // called on every channel switch, no need to kill osd... if (last != video_display_format) { last = video_display_format; @@ -1033,6 +1033,16 @@ uchar *cSoftHdDevice::GrabImage(int &size, bool jpeg, int quality, int width, return::GrabImage(&size, jpeg, quality, width, height); } +/** +** Call rgb to jpeg for C Plugin. +*/ +extern "C" uint8_t * CreateJpeg(uint8_t * image, int *size, int quality, + int width, int height) +{ + return (uint8_t *) RgbToJpeg((uchar *) image, width, height, *size, + quality); +} + ////////////////////////////////////////////////////////////////////////////// // cPlugin ////////////////////////////////////////////////////////////////////////////// -- cgit v1.2.3