diff options
author | dynaflash <[email protected]> | 2010-05-18 16:22:00 +0000 |
---|---|---|
committer | dynaflash <[email protected]> | 2010-05-18 16:22:00 +0000 |
commit | 8ce6a2514aa10e3ad28c34b8933238001b15c7d4 (patch) | |
tree | 4cd695a97cdb7e0c3dcdf79b8ec2d6d0c06d0fc6 /macosx/HBPreviewController.h | |
parent | 89d4a3ba2ecf35c4bde144ec6f35b348fca77fd0 (diff) |
MacGui: Live Preview HUD Overlay playback controller initial implementation
- Fixes current issue where a live preview with the display res larger than storage res would not show the built in QTKit control bar.
- Replaces the stock QTKit movie controller.
- Adds playback time code information to HUD display.
- Allows frame by frame scrubbing via keyboard arrow keys.
-- Methods exist for frame by frame step through but buttons are not on the HUD overlay yet.
Known Bugs:
- If movie is playing, first click on the scrubber bar can cause the movie to jump to beginning or end unless scrubber is held and dragged.
- Probably some others I haven't seen yet.
To Do (not that it ever will get done):
- Replace the current crappy stock buttons with some decent ones.
- Display accurate frame number hopefully though QTKit offers little documentation to get that exact info.
- Add a volume slider and remember the volume setting in the prefs.
- Add a subtitle control widget hopefully so that users can see what the subtitles would look like.
Other small changes include adding some tooltips to the hud overlay controller widgets to hopefully make it a bit more intuitive.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@3300 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'macosx/HBPreviewController.h')
-rw-r--r-- | macosx/HBPreviewController.h | 36 |
1 files changed, 35 insertions, 1 deletions
diff --git a/macosx/HBPreviewController.h b/macosx/HBPreviewController.h index cbfd04c9c..c8dc6d023 100644 --- a/macosx/HBPreviewController.h +++ b/macosx/HBPreviewController.h @@ -30,6 +30,7 @@ IBOutlet NSBox * fPictureViewArea; IBOutlet NSBox * fPictureControlBox; IBOutlet NSBox * fEncodingControlBox; + IBOutlet NSBox * fMoviePlaybackControlBox; IBOutlet NSSlider * fPictureSlider; IBOutlet NSTextField * fInfoField; @@ -52,7 +53,22 @@ IBOutlet NSButton * fScaleToScreenToggleButton; IBOutlet NSButton * fPictureSettingsToggleButton; BOOL scaleToScreen; + /* Movie Previews */ + QTMovie * aMovie; + IBOutlet QTMovieView * fMovieView; + /* Playback Panel Controls */ + IBOutlet NSButton * fPlayPauseButton; + IBOutlet NSButton * fGoToBeginningButton; + IBOutlet NSButton * fGoToEndButton; + IBOutlet NSButton * fGoForwardOneFrameButton; + IBOutlet NSButton * fGoBackwardOneFrameButton; + IBOutlet NSSlider * fMovieScrubberSlider; + IBOutlet NSButton * fGoToStillPreviewButton; + IBOutlet NSTextField * fMovieInfoField; + NSTimer * fMovieTimer; + + IBOutlet NSButton * fCreatePreviewMovieButton; IBOutlet NSButton * fCancelPreviewMovieButton; IBOutlet NSButton * fShowPreviewMovieButton; @@ -61,7 +77,6 @@ hb_handle_t * fPreviewLibhb; // private libhb for creating previews NSTimer * fLibhbTimer; // timer for retrieving state from libhb IBOutlet NSTextField * fPreviewMovieStatusField; - IBOutlet QTMovieView * fMovieView; IBOutlet NSPopUpButton * fPreviewMovieLengthPopUp; // popup of choices for length of preview in seconds } - (id)init; @@ -89,9 +104,28 @@ - (void) startReceivingLibhbNotifications; - (void) stopReceivingLibhbNotifications; +- (void) installMovieCallbacks; +- (void)removeMovieCallbacks; + - (IBAction) createMoviePreview: (id) sender; - (void) libhbStateChanged: (hb_state_t ) state; - (IBAction) showMoviePreview: (NSString *) path; +- (IBAction) toggleMoviePreviewPlayPause: (id) sender; +- (IBAction) moviePlaybackGoToBeginning: (id) sender; +- (IBAction) moviePlaybackGoToEnd: (id) sender; +- (IBAction) moviePlaybackGoBackwardOneFrame: (id) sender; +- (IBAction) moviePlaybackGoForwardOneFrame: (id) sender; + +-(void) initPreviewScrubberForMovie; +-(void) adjustPreviewScrubberForCurrentMovieTime; +- (IBAction) previewScrubberChanged: (id) sender; +-(void)setTime:(int)timeValue; +-(void)timeToQTTime:(long)timeValue resultTime:(QTTime *)aQTTime; +- (void) startMovieTimer; +- (void) stopMovieTimer; +- (NSString*) calculatePlaybackSMTPETimecodeForDisplay; + + - (IBAction) previewDurationPopUpChanged: (id) sender; |