- Introduction
- Installation and Setup
- Getting Started
- User Interface Overview
- Creating Shaders
- Editing Shaders
- Converting Shaders
- Testing Shaders
- Debugging Shaders
- Node-Based Editor
- 3D Scene Editor
- Audio Integration
- MIDI Control
- OSC Integration
- Timeline Animation
- Exporting and Sharing
- Performance Profiling
- Troubleshooting
WGSL Shader Studio is a comprehensive development environment for creating, editing, testing, and converting shaders across multiple graphics APIs and shading languages. This guide provides detailed instructions on how to use all features of the application effectively.
The application supports:
- WebGPU Shading Language (WGSL)
- OpenGL Shading Language (GLSL)
- High-Level Shading Language (HLSL)
- Interactive Shader Format (ISF)
- Real-time preview and testing
- Node-based shader composition
- 3D scene editing
- Audio/MIDI/OSC integration
- Timeline animation
- Cross-platform shader conversion
- Operating System: Windows 10/11, macOS 10.15+, Ubuntu 20.04+
- Graphics: DirectX 12, Vulkan 1.2, or Metal support
- RAM: 8GB minimum, 16GB recommended
- Storage: 2GB available space
- WebGPU Support: Compatible browser or native WebGPU implementation
-
Download the Application
- Visit the official repository or download page
- Download the appropriate version for your operating system
-
Install Dependencies
# Install Rust toolchain curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh # Install system dependencies (Ubuntu/Debian) sudo apt-get update sudo apt-get install cmake pkg-config libfreetype6-dev libfontconfig1-dev libxcb1-dev libxrandr-dev libxinerama-dev libxcursor-dev libxi-dev libxss-dev
-
Build from Source
git clone https://github.com/your-repo/wgsl-shader-studio.git cd wgsl-shader-studio cargo build --release -
Run the Application
cargo run --release
Upon first launch, the application will:
- Detect available graphics adapters
- Configure WebGPU backend
- Set up default workspace
- Initialize documentation server
When you first launch WGSL Shader Studio:
- Welcome Screen: Review the welcome message and quick start guide
- Workspace Selection: Choose or create a workspace directory
- Template Selection: Select a starter template:
- Empty Project
- Basic 2D Shader
- 3D Scene Template
- ISF Effect Template
- Compute Shader Example
-
Create New Project
- File → New Project
- Select "Basic 2D Shader"
- Name your project and choose location
-
Explore Interface
- Main editor window
- Preview panel
- Properties panel
- Node graph (if applicable)
-
Modify Shader
- Open the default shader file
- Make a simple change (e.g., change color value)
- Observe real-time preview update
-
Test Export
- File → Export → WGSL
- Save to desired location
┌─────────────────────────────────────────────────────────────┐
│ Menu Bar │
├─────────────────────────────────────────────────────────────┤
│ Toolbar │
├────────┬────────────────────────────────────┬───────────────┤
│ │ │ │
│Project │ Editor Area │ Properties │
│Explorer│ │ Panel │
│ │ │ │
├────────┼────────────────────────────────────┼───────────────┤
│ │ │ │
│ │ Preview Panel │ Inspector │
│ │ │ │
└────────┴────────────────────────────────────┴───────────────┘
Status Bar
The menu bar provides access to all major application features:
- File: New, Open, Save, Export, Import
- Edit: Undo, Redo, Cut, Copy, Paste
- View: Toggle panels, Zoom, Fullscreen
- Shader: Create, Convert, Validate, Optimize
- Tools: Node Editor, 3D Editor, Timeline
- Window: Manage layouts, Panels
- Help: Documentation, About, Report Issue
The toolbar provides quick access to frequently used commands:
- New Shader
- Open Project
- Save
- Undo/Redo
- Compile Shader
- Run Preview
- Debug Shader
- Export
- Project Explorer: Shows project files and folders
- Editor Area: Main code editing area with syntax highlighting
- Properties Panel: Displays and edits shader properties
- Preview Panel: Real-time shader preview
- Inspector: Detailed inspection of shader elements
- Console: Compilation output and error messages
-
Access Wizard
- Click "New Shader" button in toolbar
- Or use File → New → Shader
-
Select Shader Type
- Vertex Shader
- Fragment/Pixel Shader
- Compute Shader
- Geometry Shader
- Hull/Domain Shader
- ISF Effect
-
Configure Settings
- Language (WGSL/GLSL/HLSL/ISF)
- Target API (WebGPU/DirectX/Vulkan/OpenGL)
- Entry Point Name
- Template Selection
-
Generate Boilerplate
- The wizard creates appropriate boilerplate code
- Sets up required imports/includes
- Configures basic structure
-
Create New File
- Right-click in Project Explorer
- Select New → File
- Enter filename with appropriate extension (.wgsl, .glsl, .hlsl, .fs)
-
Add Basic Structure
// Example WGSL shader @group(0) @binding(0) var<uniform> time: f32; @vertex fn vertexMain(@builtin(vertex_index) vertexIndex: u32) -> @builtin(position) vec4<f32> { let pos = array( vec2(-0.5, -0.5), vec2( 0.5, -0.5), vec2( 0.0, 0.5) ); return vec4(pos[vertexIndex], 0.0, 1.0); } @fragment fn fragmentMain() -> @location(0) vec4<f32> { return vec4(1.0, 0.0, 0.0, 1.0); }
-
Syntax Highlighting
- Language-specific coloring
- Bracket matching
- Line numbering
-
IntelliSense
- Auto-completion
- Parameter hints
- Error detection
-
Refactoring Tools
- Rename symbols
- Extract functions
- Format code
-
Navigation
- Go to definition
- Find references
- Symbol search
-
Real-time Compilation
- Automatic compilation on save
- Error highlighting in editor
- Performance indicators
-
Preview Controls
- Play/Pause animation
- Adjust time parameters
- Change resolution
- Toggle fullscreen
-
Debug Visualization
- Intermediate render targets
- Value inspection
- Performance profiling
-
Uniform Inspector
- Edit uniform values in real-time
- Visual sliders for numeric values
- Color pickers for vector values
- File selectors for textures
-
Hot Reload
- Changes applied immediately
- State preservation during reload
- Error rollback on invalid changes
-
Access Converter
- Tools → Convert Shader
- Right-click shader file → Convert
-
Select Conversion Type
- WGSL ↔ GLSL
- WGSL ↔ HLSL
- GLSL ↔ HLSL
- ISF ↔ Other formats
-
Configure Options
- Target language version
- Optimization level
- Resource binding mapping
- Extension handling
-
Review and Apply
- Preview converted code
- Compare with original
- Apply conversion
-
Select Multiple Files
- Ctrl+Click or Shift+Click in Project Explorer
- Select all with Ctrl+A
-
Batch Convert
- Right-click selection
- Choose Convert Selected
- Configure batch options
-
Monitor Progress
- Conversion progress dialog
- Error reporting
- Summary report
-
Automatic Validation
- Syntax checking
- Semantic analysis
- Resource binding verification
-
Manual Verification
- Side-by-side comparison
- Functionality testing
- Performance benchmarking
-
Unit Tests
- Create test cases for shader functions
- Define input/output pairs
- Automated execution
-
Integration Tests
- Test shader in complete pipeline
- Verify rendering output
- Performance benchmarks
-
Regression Tests
- Compare output with baseline
- Detect unintended changes
- Version tracking
-
Execute Tests
- Run individual tests
- Run test suites
- Continuous testing mode
-
View Results
- Pass/fail indicators
- Performance metrics
- Error details
-
Generate Reports
- Export test results
- Create HTML reports
- Integrate with CI/CD
-
Shader Debugger
- Step through shader execution
- Inspect variable values
- Set breakpoints
-
Frame Capture
- Capture render pipeline state
- Analyze draw calls
- Inspect resources
-
Performance Profiler
- GPU time measurement
- Resource usage tracking
- Bottleneck identification
-
Intermediate Targets
- View render targets at each stage
- Inspect MIP levels
- Analyze format conversion
-
Value Inspection
- Hover over variables for values
- Pin variables for continuous monitoring
- Export inspection data
-
Error Highlighting
- Syntax errors with line markers
- Runtime errors with stack traces
- Performance warnings
-
Canvas Navigation
- Pan with middle mouse button
- Zoom with scroll wheel
- Fit to view with double-click
-
Node Operations
- Drag nodes to reposition
- Connect outputs to inputs
- Group related nodes
-
Node Library
- Math operations
- Texture sampling
- Lighting models
- Custom functions
-
Add Nodes
- Drag from library panel
- Right-click canvas → Add Node
- Search for specific nodes
-
Connect Nodes
- Drag from output to input
- Automatic type matching
- Visual connection lines
-
Configure Nodes
- Double-click to edit properties
- Inline parameter editing
- Preset selection
-
Graph to Code
- Automatic shader generation
- Optimization of node networks
- Comment generation
-
Code Integration
- Generated code editable
- Mixed node/code workflows
- Version control friendly
-
Object Management
- Add/remove objects
- Parent/child relationships
- Transform hierarchy
-
Component System
- Mesh renderer
- Material properties
- Light sources
- Cameras
-
Scene Navigation
- Orbit, pan, zoom controls
- Object selection
- Gizmo manipulation
-
Property Editing
- Albedo color
- Metallic/roughness
- Normal mapping
- Emission
-
Texture Assignment
- Drag/drop texture files
- UV coordinate editing
- Tiling/offset controls
-
Shader Assignment
- Assign custom shaders
- Override material properties
- Multi-pass materials
-
Light Types
- Directional lights
- Point lights
- Spot lights
- Area lights
-
Light Properties
- Color and intensity
- Shadows
- Attenuation
- Cookies
-
Environment Lighting
- Skyboxes
- Image-based lighting
- Ambient lighting
-
File Input
- Load audio files (WAV, MP3, OGG)
- Real-time playback control
- Looping options
-
Device Input
- Microphone/capture device
- System audio capture
- Latency settings
-
Generated Audio
- Procedural sound generation
- Synthesizer integration
- MIDI input
-
FFT Analysis
- Real-time frequency analysis
- Band separation
- Beat detection
-
Audio Parameters
- Volume/RMS
- Frequency spectrum
- Beat timing
-
Visualization
- Waveform display
- Spectrum analyzer
- Beat indicator
-
Parameter Mapping
- Map audio to shader uniforms
- Frequency band mapping
- Trigger events
-
Synchronization
- BPM synchronization
- Beat-matched transitions
- Audio timeline
-
Device Detection
- Automatic device discovery
- Hot-plug support
- Device configuration
-
Input Mapping
- Note on/off events
- Control change messages
- Pitch bend
- Program change
-
Output Feedback
- Send MIDI messages
- Control external devices
- Synchronize with DAWs
-
Parameter Binding
- Map MIDI controls to shader parameters
- Learn mode for easy mapping
- Save/load mappings
-
Mapping Editor
- Visual mapping interface
- Range scaling
- Curve editing
-
Preset Management
- Save MIDI mappings as presets
- Organize mapping collections
- Share with others
-
Network Configuration
- Set IP addresses and ports
- Configure sending/receiving
- Network security
-
Message Routing
- Define OSC address patterns
- Map to shader parameters
- Filter incoming messages
-
Protocol Support
- OSC 1.0 compliance
- Bundle support
- Timestamp handling
-
Remote Control
- Control from external applications
- TouchOSC integration
- Tablet/mobile support
-
Bidirectional Communication
- Send status updates
- Feedback to controllers
- Parameter synchronization
-
Scripting Interface
- Custom OSC handlers
- Message processing scripts
- Automation sequences
-
Track Management
- Add/remove animation tracks
- Organize track hierarchy
- Track grouping
-
Keyframe Editing
- Insert keyframes
- Adjust timing
- Interpolation modes
-
Curve Editing
- Bezier curve manipulation
- Ease in/out controls
- Custom curve shapes
-
Parameter Animation
- Animate any shader parameter
- Multiple parameter tracks
- Expression-based animation
-
Sequencing
- Arrange clips on timeline
- Crossfades and transitions
- Loop regions
-
Synchronization
- Audio sync
- MIDI sync
- External timecode
-
Transport Controls
- Play, pause, stop
- Scrubbing
- Loop playback
-
Time Display
- Current time indicator
- Time format selection
- Marker navigation
-
Rendering
- Export animations
- Frame-by-frame rendering
- Video encoding
-
Shader Code
- WGSL, GLSL, HLSL source
- Minified versions
- Header files
-
Compiled Shaders
- SPIR-V bytecode
- DXBC/DXIL
- Metal IR
-
Documentation
- HTML documentation
- PDF manuals
- API references
-
Project Bundles
- Export entire projects
- Dependency tracking
- Version information
-
Asset Collections
- Texture packs
- Shader libraries
- Preset collections
-
Sharing Options
- Direct file export
- Cloud storage integration
- Version control export
-
Engine Integration
- Unity package
- Unreal plugin
- Custom engine support
-
Framework Support
- Three.js modules
- Babylon.js plugins
- Custom framework templates
-
Build Systems
- CMake integration
- Makefile generation
- Package managers
-
Timing Analysis
- Shader execution time
- Draw call overhead
- State change costs
-
Resource Usage
- Memory consumption
- Bandwidth utilization
- Cache efficiency
-
Bottleneck Identification
- CPU vs GPU bound
- Pipeline stalls
- Resource contention
-
Performance Hints
- Automatic suggestions
- Best practice recommendations
- Platform-specific advice
-
Code Analysis
- Static analysis
- Complexity metrics
- Optimization opportunities
-
Benchmarking
- Frame rate measurement
- Comparative testing
- Regression detection
-
System Information
- GPU specifications
- Driver versions
- Feature support
-
Capability Queries
- Extension support
- Limit queries
- Format support
-
Compatibility Reports
- Cross-platform compatibility
- Feature level mapping
- Fallback recommendations
-
Compilation Errors
- Syntax errors
- Type mismatches
- Undefined identifiers
-
Runtime Problems
- Black screens
- Incorrect rendering
- Performance issues
-
Integration Failures
- Linking errors
- Resource loading
- Platform compatibility
-
Error Logs
- Detailed error messages
- Stack traces
- Context information
-
Validation Layers
- API validation
- Resource tracking
- State monitoring
-
Debug Rendering
- Wireframe mode
- Depth visualization
- Normal viewing
-
Documentation
- Online manuals
- API references
- Tutorial videos
-
Community Support
- Forums
- Discord channels
- GitHub issues
-
Professional Support
- Commercial licensing
- Priority bug fixes
- Custom development
End of Application Usage Guide