From e8ca9b7064daec43e5e14a7ea7b81cae6b8b940f Mon Sep 17 00:00:00 2001 From: WeebDataHoarder <57538841+WeebDataHoarder@users.noreply.github.com> Date: Thu, 10 Aug 2023 19:23:26 +0200 Subject: [PATCH] x264: add build --- encoder/libx264/libx264.go | 4 ++++ encoder/libx264/libx264_test.go | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/encoder/libx264/libx264.go b/encoder/libx264/libx264.go index d5ae136..994e590 100644 --- a/encoder/libx264/libx264.go +++ b/encoder/libx264/libx264.go @@ -38,6 +38,10 @@ func Version() string { return x264Version } +func Build() int { + return int(C.X264_BUILD) +} + const ( LogLevelNone int = -1 LogLevelError int = 0 diff --git a/encoder/libx264/libx264_test.go b/encoder/libx264/libx264_test.go index 65c3da1..8439ecb 100644 --- a/encoder/libx264/libx264_test.go +++ b/encoder/libx264/libx264_test.go @@ -15,6 +15,10 @@ func TestVersion(t *testing.T) { t.Logf("libx264 version: %s", Version()) } +func TestBuild(t *testing.T) { + t.Logf("libx264 version: %d", Build()) +} + func testEncode(sample testdata.TestSample, t *testing.T) { reader, err := sample.Open(t) if err != nil {