openMSX
|
#include <Disk.hh>
Classes | |
struct | TSS |
Public Member Functions | |
virtual | ~Disk ()=default |
const DiskName & | getName () const |
void | writeTrack (uint8_t track, uint8_t side, const RawTrack &input) |
Replace a full track in this image with the given track. | |
virtual void | readTrack (uint8_t track, uint8_t side, RawTrack &output)=0 |
Read a full track from this disk image. | |
virtual bool | hasChanged () const |
Has the content of this disk changed, by some other means than the MSX writing to the disk. | |
bool | isDoubleSided () |
Public Member Functions inherited from openmsx::SectorAccessibleDisk | |
void | readSector (size_t sector, SectorBuffer &buf) const |
void | writeSector (size_t sector, const SectorBuffer &buf) |
void | readSectors (std::span< SectorBuffer > buffers, size_t startSector) const |
void | writeSectors (std::span< const SectorBuffer > buffers, size_t startSector) |
size_t | getNbSectors () const |
bool | isWriteProtected () const |
void | forceWriteProtect () |
virtual bool | isDummyDisk () const |
void | applyPatch (Filename patchFile) |
std::vector< Filename > | getPatches () const |
bool | hasPatches () const |
Sha1Sum | getSha1Sum (FilePool &filePool) |
Calculate SHA1 of the content of this disk. | |
virtual void | readSectorsImpl (std::span< SectorBuffer > buffers, size_t startSector) |
virtual void | readSectorImpl (size_t sector, SectorBuffer &buf) |
Protected Member Functions | |
Disk (DiskName name) | |
size_t | physToLog (uint8_t track, uint8_t side, uint8_t sector) |
TSS | logToPhys (size_t log) |
virtual void | detectGeometry () |
virtual void | detectGeometryFallback () |
void | setSectorsPerTrack (unsigned num) |
unsigned | getSectorsPerTrack () |
void | setNbSides (unsigned num) |
virtual void | writeTrackImpl (uint8_t track, uint8_t side, const RawTrack &input)=0 |
Protected Member Functions inherited from openmsx::SectorAccessibleDisk | |
SectorAccessibleDisk () | |
~SectorAccessibleDisk () | |
void | setPeekMode (bool peek) |
bool | isPeekMode () const |
virtual void | checkCaches () |
virtual void | flushCaches () |
virtual Sha1Sum | getSha1SumImpl (FilePool &filePool) |
Additional Inherited Members | |
Static Public Attributes inherited from openmsx::SectorAccessibleDisk | |
static constexpr size_t | SECTOR_SIZE = sizeof(SectorBuffer) |
|
virtualdefault |
|
protectedvirtual |
Reimplemented in openmsx::SectorBasedDisk.
Definition at line 79 of file Disk.cc.
References openmsx::SectorBuffer::bootSector, detectGeometryFallback(), openmsx::MSXBootSector::nrSides, openmsx::SectorBuffer::raw, openmsx::SectorAccessibleDisk::readSector(), and openmsx::MSXBootSector::sectorsTrack.
Referenced by openmsx::SectorBasedDisk::detectGeometry(), getSectorsPerTrack(), isDoubleSided(), logToPhys(), and physToLog().
|
protectedvirtual |
Definition at line 71 of file Disk.cc.
References openmsx::SectorAccessibleDisk::getNbSectors().
Referenced by detectGeometry().
|
protected |
Definition at line 63 of file Disk.cc.
References detectGeometry().
Referenced by openmsx::DMKDiskImage::getNbSectorsImpl().
|
inlinevirtual |
Has the content of this disk changed, by some other means than the MSX writing to the disk.
In other words: should caches on the MSX side be dropped? (E.g. via the 'disk-changed-signal' that's present in (some) MSX disk interfaces).
Reimplemented in openmsx::DirAsDSK.
bool openmsx::Disk::isDoubleSided | ( | ) |
Definition at line 22 of file Disk.cc.
References detectGeometry().
|
protected |
Definition at line 46 of file Disk.cc.
References detectGeometry().
Referenced by openmsx::DMKDiskImage::readSectorImpl(), and openmsx::DMKDiskImage::writeSectorImpl().
|
protected |
Definition at line 36 of file Disk.cc.
References detectGeometry().
|
pure virtual |
Read a full track from this disk image.
Implemented in openmsx::DMKDiskImage.
|
inlineprotected |
Definition at line 44 of file Disk.hh.
Referenced by openmsx::SectorBasedDisk::detectGeometry(), and openmsx::DirAsDSK::DirAsDSK().
|
inlineprotected |
Definition at line 42 of file Disk.hh.
Referenced by openmsx::SectorBasedDisk::detectGeometry(), and openmsx::DirAsDSK::DirAsDSK().
void openmsx::Disk::writeTrack | ( | uint8_t | track, |
uint8_t | side, | ||
const RawTrack & | input | ||
) |
Replace a full track in this image with the given track.
Definition at line 13 of file Disk.cc.
References openmsx::SectorAccessibleDisk::flushCaches(), openmsx::SectorAccessibleDisk::isWriteProtected(), and writeTrackImpl().
Referenced by openmsx::DMKDiskImage::writeSectorImpl().
|
protectedpure virtual |
Implemented in openmsx::DMKDiskImage.
Referenced by writeTrack().