Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@pixi/sound

Package Overview
Dependencies
Maintainers
0
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@pixi/sound

WebAudio API playback library with filters

  • 6.0.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
0
Created
Source

PixiJS Sound

WebAudio API playback library, with filters. Modern audio playback for modern browsers.

Node.js CI npm version

Features

  • Pausing and resuming
  • Independent volume control
  • Support blocking or layered sounds (multiple instances)
  • Support for PIXI.Assets system
  • Dynamic filters:
    • ReverbFilter
    • DistortionFilter
    • EqualizerFilter
    • StereoFilter
    • TelephoneFilter

Known Compatibility

  • Chrome 58+
  • Firefox 52+
  • Safari 11+
  • iOS 11+

Usage

Installation is available by NPM:

npm i @pixi/sound --save

To import into your project, for instance, when using Webpack, Parcel, Rollup, or another bundler:

import { sound } from '@pixi/sound';

sound.add('my-sound', 'path/to/file.mp3');
sound.play('my-sound');

Browser Usage

If you're using a <script> element to import @pixi/sound into your project, then the SoundLibrary object is PIXI.sound global.

<!-- PixiJS must be imported before @pixi/sound -->
<script src="https://unpkg.com/pixi.js/dist/browser/pixi.min.js"></script>

<!-- found here, if not using CDN "./node_modules/@pixi/sound/dist/pixi-sound.js" -->
<script src="https://unpkg.com/@pixi/sound/dist/pixi-sound.js"></script>

<script>
    PIXI.sound.add('my-sound', 'path/to/file.mp3');
    PIXI.sound.play('my-sound');
</script>

Versions Compatibility

PixiJSPixiJS Sound
v5.x - v6.xv4.x
v7.xv5.x
v8.xv6.x

Resources

License

MIT License.

Keywords

FAQs

Package last updated on 27 Jul 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc