Protocol

FxOnScreenControl

The FxOnScreenControl protocol defines the methods a plug-in must implement to create on-screen parameter controls.

Declaration

@protocol FxOnScreenControl

Overview

Plug-ins can use the FxOnScreenControlAPI to draw controls and other user interface elements directly on the canvas where the user has applied the plug-in. This allows direct manipulation of the object and is a natural and fun way for users to interact with a plug-in. Use this API to transform points from the drawing space of the canvas or document to the pixel space of the object the user wants to manipulate, and vice-versa.

Topics

Drawing Controls

- drawingCoordinates

Defines the coordinate space for an event.

Required.

- drawOSC:height:activePart:time:

Draws a control on an image. This is the main method the host application calls to draw a plug-in parameter control.

Required.

Handling Mouse Events

- mouseUp:positionY:activePart:modifiers:forceUpdate:time:

Provides information when the left mouse button is released.

Required.

- mouseDragged:positionY:activePart:modifiers:forceUpdate:time:

Provides information when the left mouse button is pressed and the the cursor is moved with the mouse button still down.

Required.

- mouseDown:positionY:activePart:modifiers:forceUpdate:time:

Provides information when the left mouse button is pressed and the cursor is on an image with an active plug-in control.

Required.

Handling Keyboard Events

- keyDown:positionY:keyPressed:modifiers:forceUpdate:didHandle:time:

Provides information when a key is pressed.

Required.

- keyUp:positionY:keyPressed:modifiers:forceUpdate:didHandle:time:

Provides information when a key is released.

Required.

Constants

FxDrawingCoordinates

Constants used to identify coordinate spaces. The Y coordinate component increases upwardly in all coordinate spaces.

FxModifierKeys

Specifies flags that identify modifier keys held down while an event is generated.

Relationships