Check out our latest project ✨ OpenChapter.io: free ebooks the way its meant to be 📖

BlipKit

An asset by Detomon
The page banner background of a mountain and forest
BlipKit hero image

Quick Information

0 ratings
BlipKit icon image
Detomon
BlipKit

A GDExtension for creating the beautiful sound of old sound chips.• Generate waveforms: square, triangle, noise, sawtooth, sine, and BlipKitWaveform using BlipKitTrack• Create pitch, volume, panning, and duty cycle envelopes using BlipKitInstrument• Load and play audio samples from AudioStreamWAV using BlipKitSample• Provides a basic byte code interpreter to generate more complex melodies and reuse patterns

Supported Engine Version
4.3
Version String
1.0.0
License Version
MIT
Support Level
community
Modified Date
1 month ago
Git URL
Issue URL

BlipKit for Godot Engine 4.3

A GDExtension for creating the beautiful sound of old sound chips.

Contents

Installation

  1. Clone this repository or download the archive
  2. Copy the folder addons/detomon.blipkit to your project's addons folder (create it if needed)
  3. Enable the plugin in the project settings via the Plugins tab

Introduction

The BlipKitTrack class generates a single waveform. Multiple tracks can be attached to a AudioStreamBlipKit, which then mixes the audio. As with every audio stream, it can be used with AudioStreamPlayer, AudioStreamPlayer2D or AudioStreamPlayer3D nodes.

Time is measured in ticks. Every tick allows properties of the waveform to be updated. The tick rate is 240 ticks per second.

Usage

[!TIP] See the examples directory for some examples.

Class descriptions are available in the Editor via the reference documentation after the extension is loaded, or in the doc/classes directory.

Examples

extends Node

# Create a track.
var _track := BlipKitTrack.new()
# Create an instrument.
var _instr := BlipKitInstrument.new()

# An audio player with an `AudioStreamBlipKit` resource.
@onready var _player: AudioStreamPlayer = $AudioStreamPlayer


func _ready() -> void:
    # Set pitch sequence:
    # - Play lower octave for 18 ticks (defined with `_track.instrument_divider`)
    # - Then play current note as long as the note is playing
    _instr.set_envelope(BlipKitInstrument.ENVELOPE_PITCH, [-12, 0])

    # Set volume envelope:
    # - Set volume to 1.0 for 0 ticks (do not slide from previous value)
    # - Keep volume on 1.0 for 18 ticks
    # - Slide volume to 0.0 for 162 ticks
    _instr.set_envelope(BlipKitInstrument.ENVELOPE_VOLUME, [1.0, 1.0, 0.0], [0, 18, 162])

    # Set duty cycle of square wave to 50%.
    _track.duty_cycle = 8
    # Set instrument.
    _track.instrument = _instr
    # Set number of ticks per envelope sequence value.
    _track.instrument_divider = 18

    # Get the audio stream.
    var stream: AudioStreamBlipKit = _player.stream
    # Attach the track to the audio stream.
    _track.attach(stream)

    # Add a divider and call it every 360 ticks (1.5 seconds).
    _track.add_divider(360, func () -> int:
        # Release previous note to start instrument again.
        _track.release()
        # Play note C on octave 6.
        _track.note = BlipKitTrack.NOTE_C_6

        # Do not change tick rate of divider.
        return 0
    )

Byte code interpreter

The byte code assembler allows to create instructions to play patterns.

Examples

Classes

Overview

References

Uses the BlipKit library to generate audio.

A GDExtension for creating the beautiful sound of old sound chips.

• Generate waveforms: square, triangle, noise, sawtooth, sine, and BlipKitWaveform using BlipKitTrack
• Create pitch, volume, panning, and duty cycle envelopes using BlipKitInstrument
• Load and play audio samples from AudioStreamWAV using BlipKitSample
• Provides a basic byte code interpreter to generate more complex melodies and reuse patterns

Reviews

0 ratings

Your Rating

Headline must be at least 3 characters but not more than 50
Review must be at least 5 characters but not more than 500
Please sign in to add a review

Quick Information

0 ratings
BlipKit icon image
Detomon
BlipKit

A GDExtension for creating the beautiful sound of old sound chips.• Generate waveforms: square, triangle, noise, sawtooth, sine, and BlipKitWaveform using BlipKitTrack• Create pitch, volume, panning, and duty cycle envelopes using BlipKitInstrument• Load and play audio samples from AudioStreamWAV using BlipKitSample• Provides a basic byte code interpreter to generate more complex melodies and reuse patterns

Supported Engine Version
4.3
Version String
1.0.0
License Version
MIT
Support Level
community
Modified Date
1 month ago
Git URL
Issue URL

Open Source

Released under the AGPLv3 license

Plug and Play

Browse assets directly from Godot

Community Driven

Created by developers for developers