summaryrefslogtreecommitdiff
path: root/softhddevice.cpp
diff options
context:
space:
mode:
authorm.Rcu <>2012-02-12 20:30:50 +0100
committerJohns <johns98@gmx.net>2012-02-12 20:30:50 +0100
commit33c638d538cef475cbcd61a941dc94294417e849 (patch)
tree71b4e3825615bfa8d28bbebbdf4f89cd9b469c59 /softhddevice.cpp
parent0a2a221fa93bd4177b2a21d2499cef68b47424bd (diff)
downloadvdr-plugin-softhddevice-33c638d538cef475cbcd61a941dc94294417e849.tar.gz
vdr-plugin-softhddevice-33c638d538cef475cbcd61a941dc94294417e849.tar.bz2
Jpeg screengrab use VDR RgbToJpeg function.
Diffstat (limited to 'softhddevice.cpp')
-rw-r--r--softhddevice.cpp16
1 files changed, 13 insertions, 3 deletions
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
//////////////////////////////////////////////////////////////////////////////