Opened 18 years ago

Closed 17 years ago

Last modified 11 years ago

#2426 closed enhancement (fixed)

enhancement: embed playback box, move end of recording prompts to the OSD.

Reported by: skamithi Owned by: skamithi
Priority: minor Milestone: 0.21
Component: mythtv Version: head
Severity: medium Keywords:
Cc: Ticket locked: no

Description

I posted a huge diff couple weeks back on the dev alias and got some good feedback on it.

This is the first part I wish to submit. I hope it to be a replacement for the "Jump to Recorded Programs" OSD option.

Embedding the playback box involves 4 steps

1) Consolidate the tv object creation code. Created a startTV function that other parts of mythtv can call to start watching a live tv stream or a recording. I've made sure that playlists still works.

2) Add the code in playbackbox.h/cpp , and tv_play.cpp to allow embedding of the playbackbox widget, and cleanup/remove unused functions/variables.

3) Move the playbackbox.h and playbackbox.cpp to libmythtv directory.

4) Ask theme developers to create a new window called "playback-video". This container is essentially playback container with an object called "tv_video", where the recording will be shown. If a theme doesn't have a playback-video container, recording is paused, the "playback" container is used.

1st step is done. I've made 3 changes to mythtv functionality:

i) End of the recording prompt has been moved to the OSD space. Doing this also allows you to rewind, in case you've forwarded too far, and reached the end of the recording.

ii) (and i can change this back to the current mapping). Added a "STOPSHOW" action. On my remote, i have an "exit" and a "stop" button. When i hit stop, I want it to prompt me. When I hit "exit" i want it to quit the show, with no prompt. the "stopshow" action maps to the "stop" button. This way, when I hit the "off" key on my harmony remote, it exits, the show. Before, it would just show the prompt, and never quit.

If this change is accepted, then in the dialog displayed, a dev can add "delete recording" option at a later stage. Selecting "Delete recording" should bring up another dialog asking if you are sure , just like the end of recording prompt. This will allow a user to delete a show midstream if necessary. Right now the OSD dialog only accepts 4 buttons. Looks like a theme change needs to be made to accomodate 5 buttons in the dialog.

iii) When prompted to exit the video, the prompt will remain up for only 2 minutes, then stop displaying, and either exit the show, if at the end, or continuing to play the show.

I haven't changed the tv object creation code in manualbox.cpp. I don't really know what the manualbox is for, so decided not to touch it.

Thoughts, comments are always welcome. my IRC name is skamithi.

Attachments (9)

embed_playback_part2.diff (17.1 KB) - added by skamithi 18 years ago.
first version of the part 2 patch. Basically it just replaces the Jump to Program stuff. So to activate it, do as if you were going to "Jump To Program". Instead of a OSD screen, you should now see the Watch Recording screen. I have set the behaviour to be consistent with the other embedded widgets e.g schedule recording, program guide, etc. The video is paused and the watch recording window is displayed. The active show is unhighlighted. buttons such as "play and delete" are removed. Creating a playlist in this mode is not allowed, and those commands don't exist. Preview Video is disabled ( it caused too many lock/unlock problems).
embed_playback_part2.2.diff (17.0 KB) - added by skamithi 18 years ago.
remove pbinfolock around runplaybackbox call in tv_play.cpp .
embed_playback_part2.3.diff (17.3 KB) - added by skamithi 17 years ago.
use function pointer to pass runplaybackbox to tv_play.cpp functions. Jump to programs only works when running mythfrontend. using mythtv exec jump to programs is disabled.
embed_playback_part2.4.diff (17.8 KB) - added by skamithi 17 years ago.
temp workaround till pin support is added for the JUMPPREV/(jump to last watched show) option. if the recording groups of the current program and next program are not the same, clear the lastProgram variable.
endprompt_cutlists.diff (2.3 KB) - added by skamithi 17 years ago.
end of prompt not shown if a cutlist causes the end of the recording to occur before the "real" end of recording. fixed issue where jumping ahead doesn't respect cutlists. this patch should resolve both issues. 1st issue depends on the 2nd.
embed_playback_part3.tar.gz (5.1 KB) - added by skamithi 17 years ago.
step 3. added watch recording feature for live tv. gunzip file contains change to the Titivillus theme. created a "playback-video" window in the ui.xml. This theme change allows you to continue to watch live tv while looking through the list of recordings. If playback-video theme change is not available, it pauses live tv and shows the "watch recording" window using the "playback" window in ui.xml. other themes can be changed as well.
crash_on_calcsliderpos.diff (1.9 KB) - added by skamithi 17 years ago.
prevents state change from occurring while pause action is been executed. prevents a crash when changing to a different recording.
pbb_playbackvideo_enhancements.diff (7.3 KB) - added by skamithi 17 years ago.
allow the use of the playback-video container on a prerecorded or recording show.
isnearend.diff (3.8 KB) - added by skamithi 17 years ago.
change the IsNearEnd?? detection code in tv_play.cpp. makes it easier for the next enhancement, i'll introduce in a later ticket which is to keep the prerecorded running during the program guide.

Download all attachments as: .zip

Change History (47)

comment:1 Changed 18 years ago by skamithi

if step one is not rejected, i will continue with step 2 once step 1 is committed.

comment:2 Changed 18 years ago by skamithi

Status: newassigned

still doing further testing. going to test how jumppoint activation affects the code, and looking at other tests before commiting.

comment:3 Changed 18 years ago by skamithi

changed "stopshow" action to just "stop". gnome42 offered to help test before i commit.

comment:4 Changed 18 years ago by skamithi

changed "stop" action back to "stopshow" from feedback from gnome42.

comment:5 Changed 18 years ago by skamithi

(In [11519]) Refs #2426. Step 1 patch for the ability to access the "watch recording" screen while watching a show. major code change is the consolidation of most of the startTV calls in various places to one function TV::StartTV. feature change: end of recording prompt is moved to the OSD. this means that at the end of the recording a user can hit any of the rew buttons to jump back, if this was a mistake. ESCAPE action no longer brings up the prompt if prompting is enabled. this function is now done by the "STOPSHOW" action. So now the EXIT button just exits, and the STOP button can either prompt you or behave like the EXIT button depending on the exit prompt setting. thx to gnome42 for testing this patch. pls read the ticket for more details.

comment:6 Changed 18 years ago by skamithi

(In [11523]) Refs #2426. per isaac suggestion. changed keybinding. new keybinding is called EXITSHOWNOPROMPTS. this just quits, even if prompts are enabled. removed STOPSHOW action. ESCAPE action will now bring up exit prompts if prompts is enabled. if u chose delete recording from the exit prompt and chose "keep it", recording doesn't exit. resolved that.

comment:7 Changed 18 years ago by bjm

(In [11528]) Per comments by Chris Pinkham and Greg Estabrooks, the OSD delete options should not be destructive by default. The default choice is now "No, do not delete". Refs #2426.

comment:8 Changed 18 years ago by skamithi

(In [11530]) Refs #2426. if user executes the DELETE action it will show the delete prompt regardless of what the exit prompt setting is. also, just exit the video exit prompt if in a dvd menu.

comment:9 Changed 18 years ago by skamithi

(In [11531]) Refs #2426. typo in [11530]

Changed 18 years ago by skamithi

Attachment: embed_playback_part2.diff added

first version of the part 2 patch. Basically it just replaces the Jump to Program stuff. So to activate it, do as if you were going to "Jump To Program". Instead of a OSD screen, you should now see the Watch Recording screen. I have set the behaviour to be consistent with the other embedded widgets e.g schedule recording, program guide, etc. The video is paused and the watch recording window is displayed. The active show is unhighlighted. buttons such as "play and delete" are removed. Creating a playlist in this mode is not allowed, and those commands don't exist. Preview Video is disabled ( it caused too many lock/unlock problems).

comment:10 Changed 18 years ago by skamithi

to test part 2, you have to create symlinks to playbackbox.h and playbackbox.cpp in libmythtv directory. when all is done, these files will be moved to the libmythtv directory.

mythtv>cd libs/libmythtv
mythtv>ln -s ../../programs/mythfrontend/playbackbox.cpp
mythtv>ln -s ../../programs/mythfrontend/playbackbox.h

comment:11 Changed 18 years ago by skamithi

(In [11570]) Refs #2426. remove double delete confirmation. put delete OSD in the same order as the watch recording delete prompt. Set default for delete osd to "do not delete"

comment:12 Changed 18 years ago by Mark.Buechler@…

Found two faults, one where the frontend segfaults, the other where it locks. Both are triggered by entering recordings from "Jump to Program" from an already running recording. I managed to successfully jump from recording to recording a few times, however.

Changed 18 years ago by skamithi

Attachment: embed_playback_part2.2.diff added

remove pbinfolock around runplaybackbox call in tv_play.cpp .

comment:13 Changed 18 years ago by skamithi

(In [11581]) Refs #2426. prevent end of recording prompt from appearing during recording editing. save the bookmark when EXITSHOWNOPROMPTS is executed.

comment:14 Changed 17 years ago by skamithi

going to use a jumppoint or something similiar to activate embedded pbb. isaac does not want playbackbox.h/cpp moved.

comment:15 Changed 17 years ago by jochen

In Ticket #1772 there is a patch for a old version wich allows writing to more than one file from the dvb recorder. This is a part of the multiple channels from one transponder fix.

When someone try's to fix this, this may be a start...

Changed 17 years ago by skamithi

Attachment: embed_playback_part2.3.diff added

use function pointer to pass runplaybackbox to tv_play.cpp functions. Jump to programs only works when running mythfrontend. using mythtv exec jump to programs is disabled.

Changed 17 years ago by skamithi

Attachment: embed_playback_part2.4.diff added

temp workaround till pin support is added for the JUMPPREV/(jump to last watched show) option. if the recording groups of the current program and next program are not the same, clear the lastProgram variable.

comment:16 Changed 17 years ago by John Poet <jppoet@…>

When watching a show where the "end" of the show is never reached due to a cutlist, the "end of recording" prompt is never displayed. Minor issue, since you can delete the show once back in the "Watch Recordings" list.

John

Changed 17 years ago by skamithi

Attachment: endprompt_cutlists.diff added

end of prompt not shown if a cutlist causes the end of the recording to occur before the "real" end of recording. fixed issue where jumping ahead doesn't respect cutlists. this patch should resolve both issues. 1st issue depends on the 2nd.

comment:17 Changed 17 years ago by skamithi

(In [11637]) Refs #2426. step 2. when jump to program is executed , this will now bring up the watch recording window instead. currently playing show, comes up as an inactive program. if theme developers would like, this can be changed and a color can be assigned to it. perhaps in the playback window theme, create a "currentlyplaying_fnt" font name and the code can check for this? step 3 is to enable this feature while watching live tv. see ticket for more details.

comment:18 Changed 17 years ago by skamithi

(In [11638]) Refs #2426. hittin "left" when arrowaccel is enabled may not work as intended on an exit prompt, if its mapped to any rewind function. this ensures that the left action is honored.

comment:19 Changed 17 years ago by skamithi

2 things i'll do for step 3. add pin support for the program accessed using JUMPPREV action. So if the program that was last watched is in a recording group that is password protected, mythtv should pause the video, and bring up a password prompt . Then I will also allow the watch recording screen to be accessed while watching live tv.

comment:20 Changed 17 years ago by skamithi

(In [11667]) Closes #2645. Refs #2426. resolves vague responses on new end of recording dialog box.

comment:21 Changed 17 years ago by skamithi

(In [11678]) Refs #2426. end of prompt not shown if a cutlist causes the end of the recording to occur before the "real" end of recording. fixed issue where jumping ahead doesn't respect cutlists. this patch should resolve both issues. 1st issue depends on the 2nd.

Changed 17 years ago by skamithi

Attachment: embed_playback_part3.tar.gz added

step 3. added watch recording feature for live tv. gunzip file contains change to the Titivillus theme. created a "playback-video" window in the ui.xml. This theme change allows you to continue to watch live tv while looking through the list of recordings. If playback-video theme change is not available, it pauses live tv and shows the "watch recording" window using the "playback" window in ui.xml. other themes can be changed as well.

comment:22 Changed 17 years ago by skamithi

(In [11705]) Refs #2426. step 3 patch. add jump to program feature when watching live tv. also added recorded group pin support when accessing the last watched program (JUMPPREV). the pin prompt window is not aligned properly. couldn't figure out how to do it. if could fix the window alignment, that would be very nice. To access the watch recording window without pausing live tv you need a "playback-video" container in your theme. provided one for the one i use (titivillus).

comment:23 Changed 17 years ago by skamithi

step4: cleanup..remove end of recording code from playbackbox.cpp and fix any bugs reported in the next 2-3 weeks.

Changed 17 years ago by skamithi

Attachment: crash_on_calcsliderpos.diff added

prevents state change from occurring while pause action is been executed. prevents a crash when changing to a different recording.

comment:24 Changed 17 years ago by skamithi

(In [11714]) Refs #2426. crash while switching between recordings. prevent state change from occurring while pause is executed. also prevent the pause osd from showing in this case.

comment:25 Changed 17 years ago by skamithi

(In [11746]) Refs #2426. clears small amount of video/audio of the previous show when switching recordings.

comment:26 Changed 17 years ago by skamithi

(In [11797]) Refs #2426. some cleanup.

Changed 17 years ago by skamithi

allow the use of the playback-video container on a prerecorded or recording show.

comment:27 Changed 17 years ago by skamithi

(In [11813]) Refs #2426. allow the use of the playback-video container for pre-recorded shows.

comment:28 Changed 17 years ago by skamithi

(In [11828]) Refs #2426. re-introduce previous OSD method of showing recordings. now you can choice which way you prefer. option to choice which way to access recordings during a show, is placed in Playback Settings (page 2). also fix a typo with the EndOfRecordingPrompt? check in tv_play.cpp and NuppelVideoPlayer?.cpp

comment:29 Changed 17 years ago by skamithi

(In [12140]) Refs #2426. prevent a possibility of a show been deleted if the end of recording prompt is not displayed. it may resolve also #2743

comment:30 Changed 17 years ago by skamithi

(In [12168]) Refs #2426. set starting recgroup, when activated, to be the current rec group of the active recorded show.

comment:31 Changed 17 years ago by skamithi

(In [12196]) Refs #2426. addition to changeset [12168]. when accessed in live tv mode use the default recgroup.

comment:32 Changed 17 years ago by skamithi

(In [12217]) Refs #2426. if a recorded show ringbuffer cannot be started , while loop in TV::StartTV() never quits. this should force it quit. easily reproduced by hitting "play dvd" when there is no dvd.

Changed 17 years ago by skamithi

Attachment: isnearend.diff added

change the IsNearEnd?? detection code in tv_play.cpp. makes it easier for the next enhancement, i'll introduce in a later ticket which is to keep the prerecorded running during the program guide.

comment:33 Changed 17 years ago by skamithi

(In [12594]) Refs #2426. if embedding the playbackbox, change the behaviour to pause the video when you've reached the end of the recording and maintain the embedded window. previous behaviour was to quit embedding when you reach the end of the recording. this way I'm able to finish doing what I was selecting/changing in the playbackbox without it quitting on me.

comment:34 Changed 17 years ago by skamithi

Resolution: fixed
Status: assignedclosed

comment:35 Changed 17 years ago by skamithi

(In [13849]) Refs #2426. fix for tv window doesn't show in embedded playbackbox after changeset [13617]

comment:36 Changed 17 years ago by skamithi

(In [13864]) Refs #2426. embedded playbackbox. resolve problem where tv window is not drawn completely after a popup is canceled.

comment:37 Changed 17 years ago by skamithi

(In [14290]) Refs #2426. embedded playbackbox. resolve problem where tv window is not drawn after accessing "edit schedule" window.

comment:38 Changed 11 years ago by Paul B Mahol <onemda@…>

In ec9f8b5a408935208de14504cfb80c00c166912f/mythtv:

smacker: fix off by one error

Regression since a93b572ae4f517ce0c35cf085167c318e9215908.

Fixes #2426.

Signed-off-by: Paul B Mahol <onemda@…>
(cherry picked from commit e3cc92a623a6ece42816c7a692c8815688a99ab0)
Signed-off-by: Jean-Yves Avenard <jyavenard@…>

Note: See TracTickets for help on using tickets.