From patchwork Sun Oct 9 12:36:28 2005 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joachim Wilke X-Patchwork-Id: 12060 Received: from nproxy.gmail.com ([64.233.182.207]) by www.linuxtv.org with esmtp (Exim 4.50) id 1EOaQH-0004Np-VG for vdr@linuxtv.org; Sun, 09 Oct 2005 14:37:01 +0200 Received: by nproxy.gmail.com with SMTP id n15so363872nfc for ; Sun, 09 Oct 2005 05:36:28 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:mime-version:content-type; b=LouoePaD6+GuyPLSF3e4HasSuXDjJDV3tSAqCC+4C0O8QW6+LqiSqVf644cwF76mAvU7Ksbkw+yaDQZ8g+9dt92jGIw25LeHteVqEiRtgaO9kwUxYocLum3rjDsbJT3+Pdc0Ox6axYMqwJNsr4761hj1dskAdIOJUxEMRWiBPuU= Received: by 10.48.226.10 with SMTP id y10mr241455nfg; Sun, 09 Oct 2005 05:36:28 -0700 (PDT) Received: by 10.48.108.10 with HTTP; Sun, 9 Oct 2005 05:36:28 -0700 (PDT) Message-ID: <2a954dbc0510090536g5364c795m@mail.gmail.com> Date: Sun, 9 Oct 2005 14:36:28 +0200 From: Joachim Wilke To: Klaus Schmidinger's VDR MIME-Version: 1.0 Subject: [vdr] [Patch] radio-plugin: schow current running song in lcdproc X-BeenThere: vdr@linuxtv.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Klaus Schmidinger's VDR List-Id: Klaus Schmidinger's VDR List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 09 Oct 2005 12:37:02 -0000 Status: O X-Status: X-Keywords: X-UID: 5408 Hi everyone, attached is a patch, that enables the radio plugin to show the current running songtitle and artist on an attached lcd or any other facility that listens to cStatus::OsdProgramme events. Patch works at least for radio-0.0.8c. Joachim. diff -up radio-0.0.8c.o/radiotransfer.c radio-0.0.8c/radiotransfer.c --- radio-0.0.8c.o/radiotransfer.c Mon Sep 12 15:50:22 2005 +++ radio-0.0.8c/radiotransfer.c Sun Oct 9 14:26:56 2005 @@ -8,6 +8,7 @@ #include "radiotransfer.h" #include +#include #include "i18n.h" #define TRANSFERBUFSIZE MEGABYTE(2) @@ -830,6 +833,10 @@ void cRadioTextOsd::ShowText(void) } // + RT-Plus = 2 rows if ((S_RtOsdTags == 1 && RT_PlusShow) || S_RtOsdTags >= 2) { + + // announce current title and artist as current running for lcdproc and others + cStatus::MsgOsdProgramme (time(NULL), RTP_Title, RTP_Artist, 0, NULL, NULL); + sprintf(stext[1], "> %s %s", tr("Title :"), RTP_Title); osd->DrawText(3, 6+yoffset+fheight*(ii++), stext[1], rt_color[S_RtFgCol], clrTransparent, ftext, Setup.OSDWidth-4, ftext->Height()); //osd->DrawText(120, 6+yoffset+fheight*(ii++), RTP_Title, rt_color[S_RtFgCol], clrTransparent, ftext, Setup.OSDWidth-4, ftext->Height());