CDImage: Fix incorrect index returned for track-relative 00:02:00

Fixes some voice lines being very briefly cut off in Tomb Raider.
This commit is contained in:
Connor McLaughlin
2021-05-27 03:46:33 +10:00
parent e8e8b910a5
commit 56c08254c9
5 changed files with 35 additions and 33 deletions

View File

@ -280,7 +280,7 @@ void CDROM::InsertMedia(std::unique_ptr<CDImage> media)
// reading TOC? interestingly this doesn't work for GetlocL though...
CDImage::SubChannelQ subq;
if (media->Seek(0) && media->ReadSubChannelQ(&subq) && subq.IsCRCValid())
if (media->Seek(0) && media->ReadRawSector(nullptr, &subq) && subq.IsCRCValid())
m_last_subq = subq;
m_reader.SetMedia(std::move(media));