Unit of measure for NV_ENC_PIC_PARAMS.inputDuration

83 Views Asked by At

What should I put into NV_ENC_PIC_PARAMS.inputDuration? According to the documentation inputTimeStamp can be any monotonically growing value, but I am struggling to find anything on inputDuration.

Should it just be frame.inputTimeStamp - prevFrame.inputTimeStamp?

1

There are 1 best solutions below

0
aergistal On BEST ANSWER

You can use whatever unit you choose, it doesn't impact the encoding process at all.

NV_ENC_PIC_PARAMS inputTimeStamp and inputDuration are copied to NV_ENC_LOCK_BITSTREAM outputTimeStamp and outputDuration respectively to keep track which picture produced which bitstream.

The inputTimeStamp can be additionally used to invalidate reference frames with NvEncInvalidateRefFrames.