GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Docs.rs
  • cdtoc-0.15.0
  • Permalink
  • Docs.rs crate page
  • WTFPL
  • Repository
  • crates.io
  • Source
  • joshstoik1
  • dactyl 0.14.* normal
  • serde_core 1.0.* normal optional
  • sha1 0.11.* normal optional
  • brunch 0.12.* dev
  • serde_json 1.0.* dev

This view

  • Original page
  • New address

GeezerVison is showing docs.rs — cdtoc - Rust

Crate cdtoc 

Source
Expand description

§CDTOC

docs.rs changelog
crates.io ci deps.rs
license contributions welcome

CDTOC is a simple Rust library for parsing and working with audio CD tables of contents, namely in the form of CDTOC-style metadata values.

By default it can also generate disc IDs for services like AccurateRip, CDDB, CUETools Database, and MusicBrainz, but you can disable the corresponding crate feature(s) — accuraterip, cddb, ctdb, and musicbrainz respectively — to shrink the dependency tree if you don’t need that functionality.

§Examples

use cdtoc::Toc;

// From a CDTOC string.
let toc1 = Toc::from_cdtoc("4+96+2D2B+6256+B327+D84A").unwrap();

// From the raw parts.
let toc2 = Toc::from_parts(
    vec![150, 11563, 25174, 45863],
    None,
    55370,
).unwrap();

// Either way gets you to the same place.
assert_eq!(toc1, toc2);

// You can also get a CDTOC-style string back at any time:
assert_eq!(toc1.to_string(), "4+96+2D2B+6256+B327+D84A");

§De/Serialization

The optional serde crate feature can be enabled to expose de/serialization implementations for this library’s types:

TypeFormatNotes
AccurateRipString
CddbString
Durationu64
ShaB64StringMusicBrainz and CTDB IDs.
TocString
TrackMap
TrackPositionString

Structs§

AccurateRipaccuraterip
AccurateRip ID.
Cddbcddb
CDDB ID.
CtdbLookupctdb
CUETools Database Lookup.
CtdbLookupEntryctdb
CUETools Database Lookup Entry.
CtdbParitySettingsSizedctdb
CUETools Parity Settings (Sized).
Duration
(CDDA Sector) Duration.
ShaB64sha1
Sha1/Base64.
Toc
CDTOC.
Track
Audio Track.
Tracks
Audio Tracks Iterator.

Enums§

CtdbParitySettingsctdb
CUETools Parity Settings.
TocError
Error Type.
TocKind
CD Format.
TrackPosition
Track Position.

Functions§

lba_to_msf
LBA to MSF.
msf_to_lba
MSF to LBA.

Type Aliases§

AccurateRipTrackChecksumsaccuraterip
AccurateRip Track Checksums.
CtdbTrackChecksumsctdb
CTDB Track Checksums.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.