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
I just noticed that both flag fields (flags, flags2) in the codec context are type long in C but they should be unsigned long. The current setup leads to some strange errors when naively setting, for example, the CLOSED_GOP flag ... could we change this?
...
stream=container.add_stream("h264", 60)
stream.flags|=0x80000000# set cgop flag
results in
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "av\\codec\\context.pyx", line 119, in av.codec.context.CodecContext.flags.__set__
OverflowError: Python int too large to convert to C long
The current way to set this flag (in v14.0.1) is to use the corresponding signed representation of the flag. This is slightly unintuitive and not very self-explanatory:
stream=container.add_stream("h264", 60)
stream.flags|=-2147483648# set cgop flag
Activity