Global

Methods

draw()

p5.js draw function, is run every frame to create the desired animation
Source:

getCharCodes() → {Array.<Number>}

Convert a string to ASCII char codes
Source:
Returns:
- The array of ASCII char codes
Type
Array.<Number>

getInputString() → {String}

Read the string in the input text area and return it
Source:
Returns:
- The raw input string
Type
String

getJumpEnd() → {Number}

Function to find the matching jump end for a particular left bracket. If not matching returns undefined.
Source:
Returns:
- Jump index location
Type
Number

getJumpStart() → {Number}

Function to find the matching jump start for a particular right bracket. If not matching returns undefined.
Source:
Returns:
- Jump index location
Type
Number

getRawProgramTxt() → {String}

Read the string in the source code text area and return it
Source:
Returns:
- The raw program string
Type
String

minify()

Minify the code in the source code input area
Source:

parse(programText) → {Array.<BFInstruction>}

A function to parse the optimised source code into BFInstruction objects
Parameters:
Name Type Description
programText Array.<char> The source code
Source:
Returns:
- The list of instructions
Type
Array.<BFInstruction>

preProcess(rawProgramtext) → {String}

A function to remove comments and excess white space from the source code.
Parameters:
Name Type Description
rawProgramtext String The raw source code
Source:
Returns:
- The preprocessed source code
Type
String

run()

Run the current BF program that is in the input text area
Source:

setup()

p5.js setup function, creates canvas.
Source:

syntaxHighlightSourceCode()

Function to apply the syntax highlighting
Source:

Documentation generated by JSDoc 4.0.2 on Fri Jun 12 2026 23:36:43 GMT-0700 (Pacific Daylight Time)