Web-based tool to build gradient data for retro platforms using a visual editor

Overview

Gradient Blaster

https://gradient-blaster.grahambates.com

Gradient Blaster is a web-based tool to build gradient data for retro platforms using a visual editor. It supports multiple algorithms for colour blending and dithering. The gradient data can be exported in several formats for use with different languages and use cases.

Interface

screenshot

  1. Options
  2. Selected point detail - Editor for the current point
  3. Points track - Draggable/selectable markers of the points defined on the gradient
  4. Preview
  5. Output - Export gradient data in desired format
  6. History - undo/redo changes or reset to default state

Options

Steps:

The number of values in the gradient output i.e. the number of pixels it spans.

Blend mode:

The colour model / algorithm used to interpolate between points in the gradient.

  1. OKLAB: Interpolates values using the OKLAB colour space. This is a perceptual colour space designed for image processing tasks, including creating smooth and uniform looking transitions between colors.
  2. LAB: Interpolates values using the standard LAB colour space.
  3. Gamma adjusted RGB: Converts to linear colour space using the SRGB model prior to interpolation. Applies adjustments for percieved brightness. Based on 'Mark's method'.
  4. Simple RGB: Naive linear interpolation of the raw RGB values.

Target:

The platform and colour mode that the gradient is intended for:

Platform Bit depth Data format
Amiga OCS/ECS 12 bit (4 per channel) Single word:
R3 R2 R1 R0 G3 G2 G1 G0 B3 B2 B1 B0
Amiga OCS/ECS
Interlaced
15 bit (effective) As above, but two alternating frames to give the appearence of blended colours and provide an extra 'fake' bit per channel
Amiga AGA 24 bit (8 per channel) Two words: high/low nibbles
A: R7 R6 R5 R4 G7 G6 G5 G4 B7 B6 B5 B4
B: R3 R2 R1 R0 G3 G2 G1 G0 B3 B2 B1 B0
Atari ST 9 bit (3 per channel) Single word:
__ R2 R1 R0 __ G2 G1 G0 __ B2 B1 B0
Atari STe/TT 12 bit (4 per channel) Single word: LSB first
R0 R3 R2 R1 G0 G3 G2 G1 B0 B3 B2 B1
Atari Falcon 18 bit (6 per channel) Single longword: 2 LSB per byte unused, 3rd byte blank
R5 R4 R3 R2 R1 R0 __ __ G5 G4 G3 G2 G1 G0 __ __
__ __ __ __ __ __ __ __ B5 B4 B3 B2 B1 B0 __ __
Atari Falcon
true colour
16 bit (5 red, 6 green, 5 blue) Single word:
R4 R3 R2 R1 R0 G5 G4 G3 G2 G1 G0 B4 B3 B2 B1 B0

Dither Modes:

  1. Off: no dithering, just hard quantise to the desired bit depth.
  2. Shuffle: Switches pairs of values at colour boundaries to lessen the appearance of banding.
  3. Error diffusion: Applies one-dimesionsal error diffusion to values.
  4. Blue noise: Adds blue noise to data to each channel before quantising.
  5. Blue noise mono: As above, but applies the same noise values across all RGB channels, whereas normally we use a different starting offset for each channel. Less subtle but avoids colour variation in the dithering artifacts.
  6. Golden ratio: Adds noise using an algorithm based on the Golden ratio sequence. Similar to blue noise, this givens an even distribution of noise. Depending on the data either one of these may give better results.
  7. Golden ratio mono: See Blue noise mono
  8. White noise: Applies completely random noise. Generally looks pretty bad, but useful for comparison with other noise algorithms or to create a deliberately noise appearance.
  9. White noise mono: See Blue noise mono
  10. Ordered: Applies +/- offset to odd and even rows. This gives a consistent alternating pattern.
  11. Ordered mono: Applies the same offset to all channels, whereas normally the green channel is flipped +/- for a smoother appearance.

Dither amount:

Multiplier for noise or adjustments applied by the current dithering algorithm.

Shuffle count:

Maximum numer of pairs to swap at each boundary when using the Shuffle dither mode.


Editing

The gradient is defined by a list of fixed points which have a colour value and position. These are then interpolated to provide the intermediate values.

The left hand panel (2) shows the currently selected point and allows you to edit the colour and position. The center panel shows a preview of the gradient (4) and has markers for the points in the track down the left hand side (3).

Adding a point:

Click in the track (3) to add a new point at that position

Selecting a point:

  • Click the marker in the track (3)
  • Navigate using the arrows at the top of the detail panel (2)

Moving a point:

To change to the position of a point you can either:

  • Drag the marker in the track (3)
  • Select the point and edit the 'Position' field (2)

Removing a point:

To remove a point for the gradient can either:

  • Select the point and click the 'Remove' button in the detail panel (2)
  • Drag the point outside of the track (3)

Output

The gradient can be exported in the following formats:

Copper list:

For Amiga targets, outputs data for the Copper to output the vertical gradient based on line wait commands.

Table:

Outputs the raw colour values for each step in the gradient. Supports code generation for several languages, as well as binary download in Big Endian suitable for INCBIN into your code.

PNG Image:

Download a PNG of the gradient preview. This contains the vertical gradient as shown in the preview, but at native resolution and allows you to specify the width. This can then be shared with designers/graphicians.


Links

References

Thanks to…

  • Soundy/Deadliners: for creating the original Gradient Master that provided inspiration for this tool
  • Evil/DHS: For suggestion and technical support implementing for Atari target modes
  • Pink/Abyss: for suggesting the interlace mode
You might also like...

Powerful rich text editor using Vue.js and Quill. About @quilljs editor component for @vuejs

Powerful rich text editor using Vue.js and Quill.  About @quilljs editor component for @vuejs

quill-vuejs Quill editor component for Vue. 基于 Quill、适用于 Vue 的富文本编辑器,支持服务端渲染和单页应用。 Preview Example CDN example page Component example page Install NPM

Aug 10, 2022

It shows an effective way to correct bus arrival information using data analytics based on Amazon Serverless such as Kiness Data Stream, Kinesis Data Firehose, S3, and Lambda.

It shows an effective way to correct bus arrival information using data analytics based on Amazon Serverless such as Kiness Data Stream, Kinesis Data Firehose, S3, and Lambda.

Amazon Serverless를 이용한 실시간 버스 정보 수집 및 저장 본 github repository는 버스 정보를 주기적으로 수집하여 분석할 수 있도록, Amazon Serverless인 Amazon Kinesis Data Stream, Kinesis Data

Nov 13, 2022

Simple shopping cart prototype which shows how React components and Redux can be used to build a friendly user experience with instant visual updates and scalable code in e-commerce applications.

Simple shopping cart prototype which shows how React components and Redux can be used to build a friendly user experience with instant visual updates and scalable code in e-commerce applications.

This simple shopping cart prototype shows how React components and Redux can be used to build a friendly user experience with instant visual updates a

Feb 8, 2022

Chrome extension to save and keep track of problems from different platforms(codeforces, codechef, atcoder, leetcode etc.)

Chrome extension to save and keep track of problems from different platforms(codeforces, codechef, atcoder, leetcode etc.)

Keep Problems A Browser extension which helps to save and keep track of problems from different platforms(codeforces, codechef, atcoder, leetcode etc.

Aug 13, 2022

A social media platform aimed to capture the essence of all popular, existing social media platforms

A social media platform aimed to capture the essence of all popular, existing social media platforms

Social Fuel Reimagining Social Media, step by step 📌 About A social media platform aimed to capture the essence of all popular, existing social media

Feb 12, 2022

CodeTogether is a platform that aims to bring all the developers and coders together to appreciate collaborative coding by resolving issues faced by programmers on normal IDEs/platforms

CodeTogether is a platform that aims to bring all the developers and coders together to appreciate collaborative coding by resolving issues faced by programmers on normal IDEs/platforms

CodeTogether is a platform that aims to bring all the developers and coders together to appreciate collaborative coding by resolving issues faced by programmers on normal IDEs/platforms. It allows developers to communicate with their fellow developers or collaborators through online voice call and realtime chat. Besides, the whiteboard makes the framing of an algorithm easier by helping programmers working collaboratively to discuss and plan their approach together

Jan 20, 2022

An authorization library that supports access control models like ACL, RBAC, ABAC in modern JavaScript platforms

An authorization library that supports access control models like ACL, RBAC, ABAC in modern JavaScript platforms

Casbin-Core 💖 Looking for an open-source identity and access management solution like Okta, Auth0, Keycloak ? Learn more about: Casdoor News: still w

Oct 20, 2022

An app for spinning up social media micro-platforms.

Note: This project is super early. It's not in a usable state at this point. Though I'm working on this full-time, and it's moving ahead at a fast pac

Oct 21, 2022

Airtable for TypeScript and JavaScript (ES7, ES6, ES5). Supports Airtable database. Works in NodeJS, Browser, Ionic, Cordova and Electron platforms.

Airtable for TypeScript and JavaScript (ES7, ES6, ES5). Supports Airtable database. Works in NodeJS, Browser, Ionic, Cordova and Electron platforms.

TypeAirtable is an ORM that can run in NodeJS, Browser, Cordova, PhoneGap, Ionic, React Native, NativeScript, Expo, and Electron platforms and can be

Sep 11, 2022
Comments
  • Support for Falcon/24-bit mode

    Support for Falcon/24-bit mode

    Just found your tool, I like it very much.

    A small feature request: could you add also the full 24-bit scale for the Falcon format? As there is already a hardware which supports it (SuperVidel), the situation is similar as with ST vs STE palette: it's always a good idea to work natively with the better format.

    opened by mikrosk 4
  • Atari ST palette data is incorrect

    Atari ST palette data is incorrect

    There are 4-bit nibbles produced also in Atari ST palette mode (should be 3-bit).

    How to see the bug:

    1. Launch the tool
    2. Switch to Atari ST

    See datas such as : dc.w $ff0,$ff0,$ff0,$ff0,$ff4,$ff3,$ff3,$ff4 dc.w $ff3,$ff3,$ef5,$ff5,$ef4,$ef5,$ef5,$ff5 ... ST should be 0-7 only.

    If the first control colour is black, it will fade with ST colours until it reaches the next control colour and then start to output 4-bit nibbles. If the end control colour is black, the last part of the fade will be correct. So it seems fades going from or to black works fine, otherwise not.

    opened by evldhs 1
  • Feature request: left to right gradient

    Feature request: left to right gradient

    Not sure whether this is something you'd be interested in but for vertical gradients I'm using this: https://gecdesigns.com/color-gradient-generator ... and while it works, it can't be compared with the features offered by your tool! :)

    opened by mikrosk 9
A collection of retro emulators running in the web browser.

RETROCADE is (going to be) a collection of browser-based emulators capable of playing games from retro consoles and arcade machines, optimized for use both on desktop computers as well as mobile devices. The right tool for all your retro gaming needs!

null 3 Feb 18, 2022
Grupprojekt för kurserna 'Javascript med Ramverk' och 'Agil Utveckling'

JavaScript-med-Ramverk-Laboration-3 Grupprojektet för kurserna Javascript med Ramverk och Agil Utveckling. Utvecklingsguide För information om hur utv

Svante Jonsson IT-Högskolan 3 May 18, 2022
Hemsida för personer i Sverige som kan och vill erbjuda boende till människor på flykt

Getting Started with Create React App This project was bootstrapped with Create React App. Available Scripts In the project directory, you can run: np

null 4 May 3, 2022
Kurs-repo för kursen Webbserver och Databaser

Webbserver och databaser This repository is meant for CME students to access exercises and codealongs that happen throughout the course. I hope you wi

null 14 Jan 3, 2023
A tiny utility library to generate mesh gradient based on 4 RGB colors, built with vanilla js.

MeshGradient.js mesh-gradient.js is tiny utility library to generate mesh gradient based on 4 RGB colors, built with vanilla js. Installation! npm ins

Anup Aglawe 7 Jan 4, 2023
The awesomebooks project is a simple list, but separated into 3 parts and given a retro feel. The main page is where we can add books, and on another page we can see the list, and remove items. There is also a "contact-us" page.

Awesome Books This is the restructured version of the famous awesome-books project! Here you can find JavaScript broken into modules, using import-exp

Matt Gombos 12 Nov 15, 2022
🤍 Custom gradient image generator

Gradient Gradient is a custom gradiant making web app. Use it here Features Custom Gradient Making Using Sliders And Color Picker Use Ready Made Gradi

Dopevog 15 Sep 10, 2021
Replaces the default Strapi WYSIWYG editor with a customized build of CKEditor 5 html editor packed with useful plugins.

CKEditor 5 for Strapi Replaces the default Strapi WYSIWYG editor with a customized build of CKEditor 5 packed with useful plugins. ?? Get Started Feat

null 39 Jan 2, 2023
Harassment Manager is a web application that aims to empower users to document and take action on abuse targeted at them on online platforms.

Harassment Manager Online abuse and harassment silence important voices in conversation, forcing already marginalized people offline. Harassment Manag

Conversation AI 71 Dec 6, 2022
A unified and lightweight web application framework for multiple platforms.

Handlers.js Handlers.js is a unified and lightweight web application framework for multiple platforms. import handlerJS from "handlers.js"; const App

186526 7 Jul 26, 2022