X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=futatabi%2Fframe_on_disk.h;h=dbe121113f185bb9011ce3c58c9d0a835a5daa0c;hb=33b86069c755119da2a35af63fbd580ca9abfa7c;hp=6d1d3977deb872ee3672f784d39d007c6c9549c9;hpb=8e88294902b4b6f43c8db83dbf04830b5b9d2bfd;p=nageru diff --git a/futatabi/frame_on_disk.h b/futatabi/frame_on_disk.h index 6d1d397..dbe1211 100644 --- a/futatabi/frame_on_disk.h +++ b/futatabi/frame_on_disk.h @@ -14,7 +14,9 @@ struct FrameOnDisk { int64_t pts = -1; // -1 means empty. off_t offset; unsigned filename_idx; - uint32_t size; // Not using size_t saves a few bytes; we can have so many frames. + uint32_t size; // Not using size_t saves a few bytes; we can have so many frames. TODO: Not anymore due to audio_size. + uint32_t audio_size; + // Unfortunately, 32 bits wasted in padding here. }; extern std::vector frames[MAX_STREAMS]; // Under frame_mu. extern std::vector frame_filenames; // Under frame_mu. @@ -24,7 +26,8 @@ static bool inline operator==(const FrameOnDisk &a, const FrameOnDisk &b) return a.pts == b.pts && a.offset == b.offset && a.filename_idx == b.filename_idx && - a.size == b.size; + a.size == b.size && + a.audio_size == b.audio_size; } // A helper class to read frames from disk. It caches the file descriptor