Q: How to acquire frame / vPacket information like frame type etc. after encoding to bitstream i.e. NvEncoder::GetEncodedPacket(…).
There should be some structure I can cast to.
Cannot find anything in docs.
Please advise.
Thanks in advance.
Q: How to acquire frame / vPacket information like frame type etc. after encoding to bitstream i.e. NvEncoder::GetEncodedPacket(…).
There should be some structure I can cast to.
Cannot find anything in docs.
Please advise.
Thanks in advance.
Hi dima.borovikov,
information like frame type etc.
Please refer to NvEncLockBitstream() and its usage along with NV_ENC_LOCK_BITSTREAM. Will this have an information you looking for?
There should be some structure I can cast to
NvEncoder::GetEncodedPacket() returns a vector of per-frame bitstreams today, and there’s no way to get the associated metadata without modifying the signature and implementation of this function.
vPacket is a C++ vector, where it’s each element in turn is a vector that points to an encoded bistream of a frame. GetEncoderPackets() retrieves bitstream for all the encoded frames and populates vPacket for an application to consume/use. You could tweak this sample as per your needs.
Hope this helps.
Thanks.