| 330 | } |
| 331 | |
| 332 | void 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 | |
| 340 | void WriteColor(EncodeStream* stream, const Color& color) { |
| 341 | stream->writeUint8(color.red); |
no test coverage detected