Removed pixfmt from Video

This commit is contained in:
Alex Eidt 2022-07-23 15:23:26 -07:00
parent 0e18bf49d1
commit 226b3efe8f
4 changed files with 0 additions and 10 deletions

View file

@ -29,7 +29,6 @@ Duration() float64
FPS() float64
Codec() string
AudioCodec() string
PixFmt() string
FrameBuffer() []byte
SetFrameBuffer(buffer []byte)

View file

@ -119,9 +119,6 @@ func addVideoData(data map[string]string, video *Video) {
if codec, ok := data["codec_name"]; ok {
video.codec = codec
}
if pixfmt, ok := data["pix_fmt"]; ok {
video.pixfmt = pixfmt
}
}
// Parses the given data into a float64.

View file

@ -20,7 +20,6 @@ type Video struct {
fps float64 // Frames per second.
codec string // Codec used for video encoding.
audioCodec string // Codec used for audio encoding.
pixfmt string // Pixel format video is stored in.
framebuffer []byte // Raw frame data.
pipe *io.ReadCloser // Stdout pipe for ffmpeg process.
cmd *exec.Cmd // ffmpeg command.
@ -69,10 +68,6 @@ func (video *Video) AudioCodec() string {
return video.audioCodec
}
func (video *Video) PixFmt() string {
return video.pixfmt
}
func (video *Video) FrameBuffer() []byte {
return video.framebuffer
}

View file

@ -29,7 +29,6 @@ func TestVideoMetaData(t *testing.T) {
assertEquals(video.fps, float64(30))
assertEquals(video.codec, "h264")
assertEquals(video.audioCodec, "aac")
assertEquals(video.pixfmt, "yuv420p")
assertEquals(len(video.framebuffer), 0)
if video.pipe != nil {