Crate fluxfox

Source
Expand description

§fluxfox

fluxfox is a library crate for reading, writing, and manipulating floppy disk images of the kind used with vintage IBM Personal Computers and compatibles.

fluxfox is primarily designed for emulator authors who may be writing a PC emulator and would like to support disk images in a variety of formats, however it can be used for visualization, dumping, editing, and other disk image tasks.

fluxfox currently supports several different disk image formats, both modern and vintage, of flux, bitstream and sector-based resolution.

The main interface to fluxfox is via a DiskImage object, which can be created by loading a disk image file, or by creating a new disk image from scratch.

It is recommended to use the image_builder::ImageBuilder interface to load or create a disk image.

Re-exports§

pub use crate::diskimage::DiskImage;
pub use crate::diskimage::DiskImageFileFormat;
pub use crate::diskimage::SectorMapEntry;
pub use crate::image_builder::ImageBuilder;
pub use crate::standard_format::StandardFormat;

Modules§

bitstream
diskimage
The diskimage module defines the DiskImage struct which serves as the main interface to fluxfox. A DiskImage represents the single disk image as read from a disk image file, or created new as a specified format.
flux
image_builder
standard_format
The standard_format module defines the StandardFormat enum that defines parameters for several standard PC disk formats.
structure_parsers
The structure_parsers module defines a DiskStructureParser trait that can be implemented by different parser types.
util
The util module provides various utility functions.
visualization
The visualization module provides rendering functions for disk images. This module requires the viz feature to be enabled. Graphics support is provided by the tiny-skia crate, which will be re-exported.

Structs§

DiskCh
A structure representing two of the four components of Sector ID:
DiskChs
A structure representing three of the four components of Sector ID:
DiskChsn
A structure representing the four components of Sector ID:
ImageWriter

Enums§

DiskDataEncoding
The base bitcell encoding method of the data in a disk image. Note that some disk images may contain tracks with different encodings.
DiskDataRate
DiskDataRate defines the data rate of the disk image - for MFM and FM encoding, this is the bit rate / 2. DiskDataRate defines standard data rate categories, while storing a clock adjustment factor to make possible calculation of the exact data rate if required.
DiskDataResolution
The resolution of the data in the disk image. Currently only ByteStream and BitStream are implemented.
DiskDensity
The density of the disk image.
DiskImageError
DiskPhysicalDimensions
The physical dimensions of a disk corresponding to the format of the image. This is rarely stored by disk image formats, so it is determined automatically.
DiskRpm
A DiskRpm may represent the standard rotation speed of a standard disk image, or the actual rotation speed of a disk drive while reading a disk. Double density 5.25“ disk drives rotate at 300RPM, but a double-density disk read in a high-density 5.25“ drive may rotate at 360RPM.
DiskVisualizationError
LoadingStatus
The status of a disk image loading operation, for file parsers that support progress reporting.
ParserWriteCompatibility

Constants§

ASCII_EOF
DEFAULT_SECTOR_SIZE
MAXIMUM_SECTOR_SIZE

Traits§

ImageParser
Currently called via enum dispatch - implement on parsers directly?

Functions§

format_from_ext
Returns a DiskImageFormat enum variant based on the file extension provided. If the extension is not recognized, None is returned.
supported_extensions
Returns a list of advertised file extensions supported by available image format parsers. This is a convenience function for use in file dialogs - internal image detection is not based on file extension, but by image file content and size.

Type Aliases§

DiskSectorMap