You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/README.md
+24Lines changed: 24 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -69,6 +69,30 @@ For more instructions, you could tap `help(mpegCoder)`.
69
69
70
70
## Update Report
71
71
72
+
### V1.8 update report:
73
+
74
+
1. Provide options (widthDst, heightDst) to let MpegDecoder could control the output size manually. To ensure the option is valid, we must use the method `setParameter` before 'FFmpegSetup'. Now you could use this options to get a rescaled output directly:
75
+
76
+
```python
77
+
d = mpegCoder.MpegDecoder() # initialize
78
+
d.setParameter(widthDst=400, heightDst=300) # noted that these options must be set before 'FFmpegSetup'!
79
+
d.FFmpegSetup(b'i.avi') # the original video size would not influence the output
80
+
print(d) # examine the parameters. You could also get the original video size by 'getParameter'
81
+
d.ExtractFrame(0, 100) # get 100 frames with 400x300
82
+
```
83
+
84
+
In another example, the set optional parameters could be inherited by encoder, too:
85
+
86
+
```python
87
+
d.setParameter(widthDst=400, heightDst=300) # set optional parameters
88
+
...
89
+
e.setParameter(decoder=d) # the width/height would inherit from widthDst/heightDst rather than original width/height of the decoder.
90
+
```
91
+
92
+
Noted that we do not provide `widthDst`/`heightDst`in`getParameter`, because these 2 options are allset by users. There is no need to get them from the video metadata.
93
+
94
+
2. Optimize some realization of Decoder so that its efficiency could be improved.
0 commit comments