Exemplo n.º 1
0
 public void Clear()
 {
     _ClipData = null;
     _ClipButtonImage.texture = null;
     _ClipButton.GetComponent <Image>().color = Color.white;
     _ClipButtonText.enabled = true;
     _State = ClipPadState.Empty;
 }
Exemplo n.º 2
0
    public void OnClipPreviewComplete(Texture2D previewTexture)
    {
        _ClipData._PreviewImg = previewTexture;

        //NFI why this is needed, but otherwise randomly half of the preview images won't render on the pad UI
        _ClipData._PreviewImg.LoadImage(previewTexture.EncodeToPNG());

        //If we're previewing, not loading from serialised, initialise the clipdata for first run
        _ClipData._VideoLengthMs = _Manager._PreviewPlayer.Info.GetDurationMs();
        _ClipData.InitSettings();

        _State = ClipPadState.Loaded;
        RefreshUI();
    }
Exemplo n.º 3
0
 public void LoadFromClipData(ProjectClip clipData)
 {
     _ClipData = clipData;
     _State    = ClipPadState.Loaded;
     RefreshUI();
 }