ChucK Class Library Reference

Input / Output

IO

FileIO

StdOut

StdErr

OscIn

OscOut

OscMsg

Hid

HidMsg

SerialIO

MidiIn

MidiOut

MidiMsg

MidiFileIn

IO

: Event : Object

No description available

static member variables

int INT16

No description available

int INT32

No description available

int INT8

No description available

int MODE_ASYNC

No description available

int MODE_SYNC

No description available

int READ_INT16

No description available

int READ_INT32

No description available

int READ_INT8

No description available

static member functions

string newline()

No description available

string newlineEx2VistaHWNDVisualFoxProA()

No description available

string nl()

No description available

member functions

void close()

No description available

int eof()

No description available

void flush()

No description available

int good()

_

int mode(int flag)

No description available

int mode()

No description available

int more()

No description available

int readInt(int flags)

No description available

string readLine()

No description available

void write(string val)

No description available

void write(int val)

No description available

void write(float val)

No description available


FileIO

: IO : Event : Object

No description available

static member variables

int APPEND

No description available

int ASCII

No description available

int BINARY

No description available

int READ

No description available

int READ_WRITE

No description available

int WRITE

No description available

member functions

void close()

No description available

string[] dirList()

No description available

int eof()

No description available

void flush()

No description available

int good()

No description available

int isDir()

No description available

int mode(int flag)

No description available

int mode()

No description available

int more()

No description available

int open(string path)

No description available

int open(string path, int flags)

No description available

int readInt(int flags)

No description available

string readLine()

No description available

void seek(int pos)

No description available

int size()

No description available

int tell()

No description available

void write(string val)

No description available

void write(int val)

No description available

void write(int val, int flags)

No description available

void write(float val)

No description available


StdOut

: IO : Event : Object

No description available

member functions

void close()

No description available

int eof()

No description available

void flush()

No description available

int good()

No description available

int mode(int flag)

No description available

int mode()

No description available

int more()

No description available

int readInt(int flags)

No description available

string readLine()

No description available

void write(string val)

No description available

void write(int val)

No description available

void write(float val)

No description available


StdErr

: IO : Event : Object

No description available

member functions

void close()

No description available

int eof()

No description available

void flush()

No description available

int good()

No description available

int mode(int flag)

No description available

int mode()

No description available

int more()

No description available

int readInt(int flags)

No description available

string readLine()

No description available

void write(string val)

No description available

void write(int val)

No description available

void write(float val)

No description available


OscIn

: Event : Object

No description available

member functions

void addAddress(string address)

No description available

void listenAll()

No description available

int port()

No description available

int port(int p)

No description available

int recv(OscMsg msg)

No description available

void removeAddress(string address)

No description available

void removeAllAddresses()

No description available


OscOut

: Object

Class for sending OSC messages.

member functions

OscOut add(int i)

No description available

OscOut add(float f)

No description available

OscOut add(string s)

No description available

OscOut dest(string host, int port)

No description available

OscOut send()

No description available

OscOut start(string method)

No description available

OscOut start(string method, string host, int port)

No description available


OscMsg

: Object

No description available

member variables

string address

No description available

OscArg[] args

No description available

string typetag

No description available

member functions

float getFloat(int i)

No description available

int getInt(int i)

No description available

string getString(int i)

No description available

int numArgs()

No description available


Hid

: Event : Object

No description available

static member variables

int ACCELEROMETER

No description available

int AXIS_MOTION

No description available

int BUTTON_DOWN

No description available

int BUTTON_UP

No description available

int DEVICE_CONNECTED

No description available

int DEVICE_DISCONNECTED

No description available

int FORCE_FEEDBACK

No description available

int JOYSTICK

No description available

int JOYSTICK_BALL

No description available

int JOYSTICK_HAT

No description available

int KEYBOARD

No description available

int LED

No description available

int MOUSE

No description available

int MOUSE_MOTION

No description available

int MOUSE_WHEEL

No description available

int TABLET

No description available

int TILT_SENSOR

No description available

int WII_REMOTE

No description available

static member functions

dur globalTiltPollRate(dur d)

No description available

dur globalTiltPollRate()

No description available

int[] readTiltSensor()

No description available

int startCursorTrack()

No description available

int stopCursorTrack()

No description available

member functions

int can_wait()

No description available

int good()

No description available

string name()

No description available

int num()

No description available

int open(int type, int num)

No description available

int open(string name)

No description available

int openJoystick(int num)

No description available

int openKeyboard(int num)

No description available

int openMouse(int num)

No description available

int openTiltSensor()

No description available

void printerr(int print_or_not)

No description available

int read(int type, int which, HidMsg msg)

No description available

int recv(HidMsg msg)

No description available

int send(HidMsg msg)

No description available


HidMsg

: Object

No description available

member variables

int ascii

No description available

float axisPosition

No description available

int axis_position

No description available

int cursorX

No description available

int cursorY

No description available

int deltaX

No description available

int deltaY

No description available

int deviceNum

No description available

int deviceType

No description available

float fdata

No description available

int hatPosition

No description available

int idata

No description available

int key

No description available

float scaledCursorX

No description available

float scaledCursorY

No description available

float scaled_axis_position

No description available

float touchSize

No description available

float touchX

No description available

float touchY

No description available

int type

No description available

time when

No description available

int which

No description available

int x

No description available

int y

No description available

int z

No description available

member functions

int isAxisMotion()

No description available

int isButtonDown()

No description available

int isButtonUp()

No description available

int isHatMotion()

No description available

int isMouseMotion()

No description available

int isWheelMotion()

No description available

int is_axis_motion()

No description available

int is_button_down()

No description available

int is_button_up()

No description available

int is_hat_motion()

No description available

int is_mouse_motion()

No description available


SerialIO

: IO : Event : Object

Handles reading and writing for serial input/output devices, such as Arduino.

examples

static member variables

int ASCII

ASCII mode

int B115200

115200 baud

int B14400

14400 baud

int B19200

19200 baud

int B230400

230400 baud

int B2400

2400 baud

int B28800

28800 baud

int B38400

38400 baud

int B4800

4800 baud

int B57600

57600 baud

int B7200

7200 baud

int B76800

76800 baud

int B9600

9600 baud

int BINARY

Binary mode

static member functions

string[] list()

Return list of available serial devices.

member functions

int baudRate(int r)

Set baud rate.

int baudRate()

Get current baud rate.

void close()

No description available

int dataAvailable()

No description available

void flush()

Flush the IO buffer.

int getByte()

Get next requested byte.

int[] getBytes()

Get next requested number of bytes.

int[] getInts()

Get next requested number of integers.

string getLine()

Get next requested line.

SerialIO onByte()

Wait for one byte (binary mode only).

SerialIO onBytes(int num)

Wait for requested number of bytes (binary mode only).

SerialIO onFloats(int num)

Wait for requested number of floats (ASCII or binary mode).

SerialIO onInts(int num)

Wait for requested number of ints (ASCII or binary mode).

SerialIO onLine()

Wait for one line (ASCII mode only).

int open(int i, int baud, int mode)

Open serial device i with specified baud rate and mode (binary or ASCII).

string readLine()

No description available

void writeByte(int b)

Write a single byte.

void writeBytes(int[] b)

Write array of bytes.


MidiIn

: Event : Object

No description available

member functions

int can_wait()

No description available

int good()

No description available

string name()

Return the Midi device's name as string.

int num()

No description available

int open(int port)

Open Midi device using a port number.

int open(string name)

Open Midi device using the device's name.

void printerr(int print_or_not)

Set error printing (1 for on, 0 for off). On by default.

int recv(MidiMsg msg)

No description available


MidiOut

: Object

No description available

member functions

int good()

No description available

string name()

Return the Midi device's name as string.

int num()

No description available

int open(int port)

Open Midi device using a port number.

int open(string name)

Open Midi device using the device's name.

void printerr(int print_or_not)

Set error printing (1 for on, 0 for off). On by default.

int send(MidiMsg msg)

Send out a MidiMsg message.


MidiMsg

: Object

Creates a message for sending and receiving Midi information.

member variables

int data1

First byte of a Midi message, usually a status byte or command byte.

int data2

Second byte of a Midi message, usually a note value.

int data3

Third byte of a Midi message, usually a velocity value.

dur when

No description available


MidiFileIn

: Object

No description available

member functions

void close()

No description available

int numTracks()

No description available

int open(string path)

No description available

int read(MidiMsg msg)

No description available

int read(MidiMsg msg, int track)

No description available

void rewind()

No description available