Documentation ¶
Index ¶
- type Generator
- func (g Generator) CombineSpriteImages(images []image.Image) image.Image
- func (g Generator) MarkerPreviewVideo(ctx context.Context, input string, hash string, seconds int, includeAudio bool) error
- func (g Generator) PreviewVideo(ctx context.Context, input string, videoDuration float64, hash string, ...) error
- func (g Generator) PreviewWebp(ctx context.Context, input string, hash string) error
- func (g Generator) SceneMarkerScreenshot(ctx context.Context, input string, hash string, seconds int, width int) error
- func (g Generator) SceneMarkerWebp(ctx context.Context, input string, hash string, seconds int) error
- func (g Generator) Screenshot(ctx context.Context, input string, hash string, videoWidth int, ...) error
- func (g Generator) SpriteScreenshot(ctx context.Context, input string, seconds float64) (image.Image, error)
- func (g Generator) SpriteScreenshotSlow(ctx context.Context, input string, frame int) (image.Image, error)
- func (g Generator) SpriteVTT(ctx context.Context, output string, spritePath string, stepSize float64) error
- func (g Generator) Thumbnail(ctx context.Context, input string, hash string, videoDuration float64, ...) error
- func (g Generator) Transcode(ctx context.Context, input string, hash string, options TranscodeOptions) error
- func (g Generator) TranscodeAudio(ctx context.Context, input string, hash string, options TranscodeOptions) error
- func (g Generator) TranscodeCopyVideo(ctx context.Context, input string, hash string, options TranscodeOptions) error
- func (g Generator) TranscodeVideo(ctx context.Context, input string, hash string, options TranscodeOptions) error
- type MarkerPaths
- type Paths
- type PreviewOptions
- type SceneMarkerScreenshotOptions
- type ScenePaths
- type ScreenshotOptions
- type TranscodeOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Generator ¶
type Generator struct { Encoder ffmpeg.FFMpeg LockManager *fsutil.ReadLockManager MarkerPaths MarkerPaths ScenePaths ScenePaths Overwrite bool }
func (Generator) CombineSpriteImages ¶
func (Generator) MarkerPreviewVideo ¶
func (Generator) PreviewVideo ¶
func (Generator) PreviewWebp ¶
PreviewWebp generates a webp file based on the preview video input. TODO - this should really generate a new webp using chunks.
func (Generator) SceneMarkerScreenshot ¶
func (Generator) SceneMarkerWebp ¶
func (Generator) Screenshot ¶
func (Generator) SpriteScreenshot ¶
func (Generator) SpriteScreenshotSlow ¶
func (Generator) TranscodeAudio ¶
func (g Generator) TranscodeAudio(ctx context.Context, input string, hash string, options TranscodeOptions) error
TranscodeAudio will copy the video stream as is, and transcode audio.
func (Generator) TranscodeCopyVideo ¶
func (g Generator) TranscodeCopyVideo(ctx context.Context, input string, hash string, options TranscodeOptions) error
TranscodeCopyVideo will copy the video stream as is, and drop the audio stream.
func (Generator) TranscodeVideo ¶
func (g Generator) TranscodeVideo(ctx context.Context, input string, hash string, options TranscodeOptions) error
TranscodeVideo transcodes the video, and removes the audio. In some videos where the audio codec is not supported by ffmpeg, ffmpeg fails if you try to transcode the audio
type MarkerPaths ¶
type PreviewOptions ¶
type ScenePaths ¶
type ScenePaths interface { Paths GetVideoPreviewPath(checksum string) string GetWebpPreviewPath(checksum string) string GetScreenshotPath(checksum string) string GetThumbnailScreenshotPath(checksum string) string GetSpriteImageFilePath(checksum string) string GetSpriteVttFilePath(checksum string) string GetTranscodePath(checksum string) string }
type ScreenshotOptions ¶
type ScreenshotOptions struct {
At *float64
}
type TranscodeOptions ¶
Click to show internal directories.
Click to hide internal directories.