MCPcopy Create free account
hub / github.com/Tencent/libpag / WriteTime

Function WriteTime

src/codec/DataTypes.cpp:332–338  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

330}
331
332void WriteTime(EncodeStream* stream, Frame time) {
333 // Since most of the time values are positive (time in keyframes),
334 // just write it as uint64_t to save space (no need to write the sign bit).
335 // If it is negative time, it is also can be written and read as normal, but
336 // requires more space.
337 stream->writeEncodedUint64(static_cast<uint64_t>(time));
338}
339
340void WriteColor(EncodeStream* stream, const Color& color) {
341 stream->writeUint8(color.red);

Callers 8

writeValueMethod · 0.85
WriteTimeAndValueFunction · 0.85
WriteMarkerListFunction · 0.85
WriteVideoSequenceFunction · 0.85
WriteAudioBytesFunction · 0.85
WriteTimeStretchModeFunction · 0.85

Calls 1

writeEncodedUint64Method · 0.80

Tested by

no test coverage detected