Pulp 1.88.0
Cross-platform audio plugin framework
Loading...
Searching...
No Matches
tape_machine_components.hpp File Reference

Public tape standards, physical models, EQ, and compander building blocks. More...

#include <pulp/signal/character_delay/tape_physical.hpp>
#include <pulp/signal/ballistics_filter.hpp>
#include <pulp/signal/character_delay/primitives.hpp>
#include <pulp/signal/character_delay/tables.hpp>
#include <pulp/signal/character_delay/tape.hpp>
#include <pulp/signal/character_delay/tape_loss.hpp>
#include <pulp/signal/denormal.hpp>
#include <pulp/signal/units.hpp>
#include <algorithm>
#include <array>
#include <cmath>
#include <complex>
#include <cstddef>
#include <cstdint>
#include <vector>

Go to the source code of this file.

Classes

struct  pulp::signal::tape::EqTimeConstants
 One standard's pair of time constants, in SECONDS. More...
struct  pulp::signal::tape::HeadGapGeometry
 Reproduce and record gap widths for one speed class, in METRES. More...
struct  pulp::signal::tape::ArchetypePreset
 The complete baked preset for one machine. More...
class  pulp::signal::TapeEqSection
 One first-order EQ section — a (curve, speed) record network, or its exact inverse. More...
class  pulp::signal::TapeCompanderT< SampleType >
 The 2:1 / 1:2 linear-dB compander pair. More...

Namespaces

namespace  pulp
namespace  pulp::signal
namespace  pulp::signal::tape
 Published tables and closed forms, free of any instance so a test can assert the SHIPPED constant rather than a copy of it.

Enumerations

enum class  pulp::signal::TapeCurve : std::uint8_t { pulp::signal::nab , pulp::signal::iec_ccir , pulp::signal::cassette_type1 , pulp::signal::cassette_type2 }
 Which recording standard's record/playback network pair is in force. More...
enum class  pulp::signal::TapeArchetype : std::uint8_t { pulp::signal::ampex_350_440 , pulp::signal::studer_a800 , pulp::signal::cassette_deck }
 Which machine's full preset a fresh instance starts from. More...

Functions

EqTimeConstants pulp::signal::tape::eq_time_constants (TapeCurve curve, double speed_ips) noexcept
 The published time-constant table, selected by (curve, speed).
double pulp::signal::tape::eq_corner_hz (double tau_s) noexcept
 Corner frequency of a time constant, in Hz. f = 1 / (2π·t).
double pulp::signal::tape::eq_record_response_db (const EqTimeConstants &tc, double hz) noexcept
 The analog record (pre-emphasis) prototype H(s) = (1 + s·t₁)/(1 + s·t₂), in dB, normalized to 0 dB at kEqReferenceHz.
double pulp::signal::tape::eq_playback_response_db (const EqTimeConstants &tc, double hz) noexcept
 The playback (de-emphasis) network is the exact reciprocal of the record network, so its response is the negation.
HeadGapGeometry pulp::signal::tape::head_gap_geometry (double speed_ips) noexcept
 Gap widths by speed class.
double pulp::signal::tape::speed_m_per_s (double speed_ips) noexcept
 Tape speed in metres per second.
double pulp::signal::tape::gap_loss_magnitude (double hz, double gap_m, double speed_ips) noexcept
 Westmijze's reproduce gap loss: |sin(π·g/λ) / (π·g/λ)|, λ = v/f.
double pulp::signal::tape::gap_loss_db (double hz, double gap_m, double speed_ips) noexcept
double pulp::signal::tape::gap_null_hz (double gap_m, double speed_ips) noexcept
 First extinction null, where λ = g: f = v / g.
double pulp::signal::tape::age_print_through_db (double age01) noexcept
double pulp::signal::tape::age_bias_drift (double age01) noexcept
double pulp::signal::tape::first_order_shelf_db (double corner_hz, double gain_linear, double hz, double sample_rate) noexcept
 Magnitude, in dB, of the REALIZED chardelay::FirstOrderShelf — the TPT one-pole shelf this module uses for both the bias shelf and the crosstalk tilt.
ArchetypePreset pulp::signal::tape::archetype_preset (TapeArchetype archetype) noexcept
 Baked defaults per §5 of the source spec.
double pulp::signal::tape::snap_speed_ips (TapeArchetype archetype, double requested_ips) noexcept
 Nearest legal speed for an archetype.

Variables

constexpr std::array< double, 5 > pulp::signal::tape::kSpeedsIps = {1.875, 3.75, 7.5, 15.0, 30.0}
 The halving speed ladder, in inches per second.
constexpr double pulp::signal::tape::kMetresPerInch = 0.0254
 Inches to metres. Exact by definition of the international inch.
constexpr double pulp::signal::tape::kEqReferenceHz = 1000.0
 The frequency every EQ curve in this module is normalized to be unity at.
constexpr std::array< double, 3 > pulp::signal::tape::kAgeAxis = {0.0, 0.5, 1.0}
 The reused kAgeAxis table drives spacing, hiss, chew and degrade, and kTapeAxis drives wow/flutter depth — all reused verbatim.
constexpr std::array< double, 3 > pulp::signal::tape::kAgePrintThroughDb = {-80.0, -55.0, -38.0}
 Storage print grows with age.
constexpr std::array< double, 3 > pulp::signal::tape::kAgeBiasDriftUnits = {0.0, 0.15, 0.4}
 An aging bias supply drifts toward OVER-bias — the documented failure direction, since oscillator components drift high more often than low.

Detailed Description

Public tape standards, physical models, EQ, and compander building blocks.