コード例 #1
0
ファイル: Utils.cs プロジェクト: miktemk/VidkaEditor
 public static void SetFrameMarker_RightOfAClipJustBefore(this IVidkaOpContext iEditor, VidkaClipAudio clip, VidkaProj proj)
 {
     long frameMarker = clip.FrameOffset; // start
     var rightThreshFrames = proj.SecToFrame(Settings.Default.RightTrimMarkerOffsetSeconds);
     // if clip is longer than RightTrimMarkerOffsetSeconds, we can skip to end-RightTrimMarkerOffsetSeconds
     if (clip.LengthFrameCalc > rightThreshFrames)
         frameMarker += clip.LengthFrameCalc - rightThreshFrames;
     iEditor.SetFrameMarker_ShowFrameInPlayer(frameMarker);
 }
コード例 #2
0
        public void SetParticulars(
			VidkaClipVideoAbstract vclip,
			VidkaFileMapping fileMapping)
        {
            this.imageMan = new ImageCacheManager();
            this.fileMapping = fileMapping;
            this.vclip = vclip;
            // set up the vclip that we will draw
            vclipFullToDraw = vclip.MakeCopy_VideoClip();
            vclipFullToDraw.FrameStart = 0;
            vclipFullToDraw.FrameEnd = vclipFullToDraw.LengthFrameCalc;
            // set up the audio clip that we will draw
            aclipToDraw = new VidkaClipAudio()
            {
                FileName = vclip.CustomAudioFilename,
                FileLengthSec = vclip.CustomAudioLengthSec,
                FileLengthFrames = dimdim.SecToFrame(vclip.CustomAudioLengthSec ?? 0),
                FrameStart = 0,
                FrameEnd = dimdim.SecToFrame(vclip.CustomAudioLengthSec ?? 0),
            };
            imageMan.ImagesReady += imageMan_ImagesReady;
        }
コード例 #3
0
 public void SetParticulars(VidkaClipAudio clip)
 {
     VClip = clip;
     // set all the UI
     txtPostOp.Text = VClip.PostOp;
 }
コード例 #4
0
ファイル: EditorLogic.cs プロジェクト: uche40/VidkaEditor
 private void dragAndDropMan_MetaReadyForOutstandingAudio(VidkaClipAudio aclip, VideoMetadataUseful meta)
 {
     editor.PleaseRepaint();
 }
コード例 #5
0
ファイル: Utils.cs プロジェクト: miktemk/VidkaEditor
 public static void SetFrameMarker_LeftOfAClip(this IVidkaOpContext iEditor, VidkaClipAudio clip)
 {
     iEditor.SetFrameMarker_ShowFrameInPlayer(clip.FrameOffset);
 }
コード例 #6
0
 /// <summary>
 /// There can only be one hover b/w video and audio line, so video will be set to null
 /// </summary>
 public void SetHoverAudio(VidkaClipAudio hover)
 {
     if (CurrentAudioClipHover != hover ||
         CurrentVideoClipHover != null)
         stateChanged = true;
     CurrentAudioClipHover = hover;
     CurrentVideoClipHover = null;
 }
コード例 #7
0
 public void SetDraggyAudio(VidkaClipAudio clip)
 {
     if (Draggy.AudioClip != clip)
         stateChanged = true;
     Draggy.AudioClip = clip;
 }
コード例 #8
0
 /// <summary>
 /// There can only be one selected (active) b/w video and audio line, so video will be set to null
 /// </summary>
 public void SetActiveAudio(VidkaClipAudio active)
 {
     if (CurrentAudioClip != active ||
         CurrentVideoClip != null)
     {
         stateChanged = true;
         originalTimelineSelectionChanged = true;
         SetOriginalTimelinePlaybackMode(false);
     }
     CurrentAudioClip = ArrayOfOne_ClipsAudio[0] = active;
     CurrentVideoClip = null;
     resetCurrentClipUsages();
     if (active != null)
         CurClipAllUsagesAudio = ArrayOfOne_ClipsAudio;
     UpdateCurrentClipFrameAbsPos(null);
 }
コード例 #9
0
ファイル: EditorLogic.cs プロジェクト: miktemk/VidkaEditor
 private void AddUndoableAction_insertAudioClipAtMarkerPosition(VidkaClipAudio newClip)
 {
     newClip.FrameOffset = UiObjects.CurrentMarkerFrame;
     AddUndableAction_andFireRedo(new UndoableAction
     {
         Redo = () =>
         {
             Proj.ClipsAudio.Add(newClip);
             UiObjects.SetActiveAudio(newClip);
         },
         Undo = () =>
         {
             Proj.ClipsAudio.Remove(newClip);
         },
     });
 }