Skip to main content

Operating Modes

plugindata can run in two distinct modes, each optimized for different workflows:
  1. Plugin Mode - Runs inside a DAW as a VST3/AU/LV2/CLAP plugin
  2. Standalone Mode - Runs as an independent desktop application
Both modes share the same core Pure Data engine but differ in how they handle I/O, MIDI, and system integration.

Standalone Mode

Architecture

Standalone mode runs as a native application with full system access. From PluginProcessor.cpp:54-82, the audio bus configuration differs:

Features

Window Management
  • Multiple windows support
  • Native window decorations
  • Maximizable/fullscreen
  • Independent window positioning
File Operations
  • Direct file system access
  • Save/load patches anywhere
  • External file management
  • No DAW session dependency
Audio/MIDI Routing
  • Direct hardware access
  • Selectable audio interfaces
  • Virtual MIDI ports
  • System MIDI devices
  • Internal synthesizer support
From PluginProcessor.cpp:175-179:
Multi-Patch Workflow
  • Open multiple patches simultaneously
  • Tab-based interface
  • Split view support
  • Independent patch states
Preferences and Settings
  • Global audio/MIDI settings
  • Theme customization
  • Library management
  • Path configuration

Audio I/O Configuration

Standalone provides direct control over: Input Configuration
  • Device selection
  • Channel count (up to 32)
  • Sample rate selection
  • Buffer size adjustment
Output Configuration
  • Device selection
  • Channel routing
  • Sample rate matching
  • Latency compensation
Processing
  • Configurable block size (64 samples default)
  • Independent sample rate
  • Direct hardware communication

Use Cases

Development and Testing
  • Rapid prototyping
  • Algorithm development
  • Quick experimentation
  • Debugging and testing
Live Performance
  • No DAW required
  • Lower latency potential
  • Direct hardware access
  • Simpler signal flow
Sound Design
  • Standalone synthesizers
  • Audio processors
  • Effects chains
  • Experimental instruments
Education
  • Learning Pure Data
  • Teaching DSP concepts
  • No DAW knowledge required
  • Simpler environment

Plugin Mode

Architecture

plugindata integrates into DAWs using standard plugin formats:
  • VST3 - Steinberg’s cross-platform format
  • AU - Apple’s Audio Units (macOS)
  • LV2 - Open-source format (Linux)
  • CLAP - Modern open standard

Integration Features

DAW Synchronization From PluginProcessor.cpp:1055-1128, playhead information is synchronized:
Pd patches can receive:
  • Playing/recording/looping state
  • Tempo (BPM)
  • Time signature
  • Transport position (PPQ, samples, seconds)
  • Loop points
  • Frame rate
Access via:
Automation From PluginProcessor.cpp:120-131, parameters are exposed:
Automation parameters:
  • param1 through param64 (default)
  • Mapped to Pd receivers: [r param1], [r param2], etc.
  • Fully automatable in DAW
  • Saved with DAW project
From PluginProcessor.cpp:1149-1159, parameter updates:
State Management Plugin state is saved with DAW projects:
  • Patch content (embedded)
  • Parameter values
  • Editor size/position
  • Connection paths (segmented)
  • GUI states
From PluginProcessor.cpp:1224-1308:
MIDI Routing Plugin mode MIDI handling from PluginProcessor.cpp:1166-1201:

Channel Configuration

Plugin mode supports flexible I/O: Input Buses
  • Main input (stereo, enabled)
  • Aux inputs 1-N (stereo, optional)
  • Up to 32 total input channels
Output Buses
  • Main output (stereo, enabled)
  • Aux outputs 1-N (stereo, optional)
  • Up to 32 total output channels
Pd Access

Plugin-Specific Features

Presentation Mode From PluginMode.h:13-526, dedicated plugin UI:
Features:
  • Fixed-size UI mode
  • Zoom levels (50%, 75%, 100%, 125%, 150%, 175%, 200%)
  • Fullscreen mode (standalone only)
  • Titlebar with patch name
  • Edit mode toggle
  • Clipped rendering area
Scale settings are saved in meta.json:
Sample Rate Handling From PluginProcessor.cpp:699-759:
Pd always processes in 64-sample blocks internally. Plugins handle arbitrary block sizes via FIFO buffering. Latency Reporting From PluginProcessor.cpp:192:
Plugins report 64 samples of latency (one Pd block) to the DAW for automatic delay compensation.

Plugin Limitations

File Access
  • No direct file browser
  • Patches embedded in DAW session
  • External files must be in search path
  • No arbitrary file writing
Window Management
  • Single window per instance
  • Size constrained by plugin mode
  • No multiple patches per instance
  • DAW controls window state
Audio Routing
  • Bus configuration set by DAW
  • Cannot change I/O at runtime
  • No direct hardware access
  • Routing through DAW mixer
Processing
  • Fixed to DAW sample rate
  • DAW controls buffer size
  • Must handle variable block sizes
  • Subject to DAW thread priority

Oversampling

Both modes support oversampling from PluginProcessor.cpp:655-668:
Oversampling reduces aliasing in nonlinear processes:
  • None (1x): Standard quality
  • 2x: Good quality, moderate CPU
  • 4x: High quality, higher CPU
  • 8x: Maximum quality, significant CPU
Oversampling uses polyphase IIR filters for efficiency.

Choosing the Right Mode

Use Standalone When:

✅ Prototyping new ideas quickly
✅ Learning Pure Data/DSP
✅ Live performance without DAW
✅ Testing with different audio interfaces
✅ Working with multiple patches simultaneously
✅ Need direct file system access
✅ Developing standalone instruments/effects

Use Plugin When:

✅ Integrating with DAW workflow
✅ Recording automation
✅ Tempo sync required
✅ Multiple instances needed
✅ Mixing with other plugins
✅ Session recall important
✅ Distributing to users with DAWs

Migration Between Modes

Standalone to Plugin

  1. Save patch in standalone
  2. Load in DAW as plugin
  3. Configure I/O to match DAW routing
  4. Map automation parameters
  5. Test playhead sync if needed
  6. Set plugin mode for presentation

Plugin to Standalone

  1. Export patch from DAW session
  2. Open in standalone
  3. Configure audio/MIDI devices
  4. Test I/O channels
  5. Adjust workflow for multi-patch if needed

Best Practices

Cross-Compatible Patches

To work well in both modes: Use Relative Paths
Dynamic Channel Count
Conditional Automation
Portable File Handling
  • Keep external files in same directory as patch
  • Use relative paths with [declare]
  • Test in both modes before distribution

Performance Optimization

Plugin Mode
  • Minimize processing (shared CPU with DAW)
  • Use efficient algorithms
  • Consider oversampling cost
  • Report accurate latency
Standalone Mode
  • Can use more CPU if needed
  • Direct hardware = lower latency possible
  • Adjust buffer size for latency/stability

Next Steps

DAW Integration

Learn how plugdata integrates with your DAW

Patching Basics

Master the fundamentals of Pure Data patching