[mythtv] detiecting upcoming recordings in frontend/mythweb
ou401cru02 at sneakemail.com
Thu Jul 10 16:38:51 EDT 2003
On 10 Jul 2003 10:53:50 -0700, "Chris Petersen lists-at-forevermore.net
|mythtv/1.0-Allow|" <o8f8hesx3k0t at sneakemail.com> said:
> > Adding a special border/tag/whatever looks pretty easy (it is
> > essesntially just a modified query similar to
> > ScheduledRecording::findAllProgramsToRecord). I'll be happy to submit a
> > patch to Chris implementing this.
> I'm happy to take a look at it - anything to save me a bit of work. :)
> > Anyhow, this second method seems better to me overall (implement a
> > VerifyRecording method in the backend, which checks whether we really
> > plan to record a given program), and I'll volunteer to write it if this
> > seems sane to others. Otherwise, I'll just do a simpler query in mythweb
> > (which won't be as accurate, but will be better than what we have today),
> > and submit a patch to Chris.
> currently, the Program object in mythweb is designed (though not fully
> implemented) to get ALL info about a recording, both from the database
> and from mythbackend, so whichever ends up working is best. The program
> guide currently only grabs info from the database (thus, doesn't check
> for resolved conflicts, etc), but if I query the backend for info, it
> should return everything pertinent about the programs, including whether
> or not they've been suppressed, etc.
Okay, here is a patch to Chris's mythweb which implements a
'should_record' and 'will_record'
'should_record' indicates that the program matches a row in the record
table. 'will_record' indicates that 'should_record' is set AND that this
program does not appear in oldrecorded or in program where starttime <
the current starttime.
'should_record' programs are highlighted in white, will_record are in
red. (okay those colors are horrible, but they are easy to change)
The downside of this is that it is slow. Loading the listing is
noticably slower than it was ebfore (and it wasn't exactly speedy). the
only way I can think of to relieve this is to do a seperate query for
each 'should_record' program (i.e. the 'VerifyRecording' method I
mentioned before), but that requires many more db hits, and may not
actually be faster. I'm open to suggestions, and mySQL is certainly not
my strongest programing language.
Implementing this in mythfrontend would be just as easy, however, the
performance hit is likely similar.
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 5016 bytes
Desc: not available
Url : http://lists.snowman.net/pipermail/mythtv-dev/attachments/20030710/70ca0279/mw1.bin
More information about the mythtv-dev