File tree Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Expand file tree Collapse file tree 1 file changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -95,3 +95,20 @@ def testGetUnexistedOutputStream():
95
95
outputFileName = "testGetUnexistedOutputStream.mov"
96
96
ouputFile = av .OutputFile (outputFileName )
97
97
ouputFile .getStream (0 )
98
+
99
+
100
+ def testAddingCustomStream ():
101
+ """
102
+ Create an OutputFile, and add a custom stream and try to access that stream.
103
+ """
104
+ outputFileName = "testAddingCustomStream.mov"
105
+ ouputFile = av .OutputFile (outputFileName )
106
+
107
+ codec = av .AudioCodec (av .eCodecTypeEncoder , "pcm_s24le" );
108
+ addedOutputStream = ouputFile .addCustomStream (codec )
109
+
110
+ retrievedOutputStream = ouputFile .getStream (0 )
111
+
112
+ assert_equals (addedOutputStream .getStreamIndex (), retrievedOutputStream .getStreamIndex ())
113
+ assert_equals (addedOutputStream .getStreamDuration (), retrievedOutputStream .getStreamDuration ())
114
+ assert_equals (addedOutputStream .getNbFrames (), retrievedOutputStream .getNbFrames ())
You can’t perform that action at this time.
0 commit comments