<!--
{
  "availability" : [
    "FxPlug: 4.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "professional_video_applications",
  "identifier" : "/documentation/professional_video_applications/FxOnScreenControl_v4",
  "metadataVersion" : "0.1.0",
  "role" : "Protocol",
  "symbol" : {
    "kind" : "Protocol",
    "modules" : [
      "Professional Video Applications"
    ],
    "preciseIdentifier" : "c:objc(pl)FxOnScreenControl_v4"
  },
  "title" : "FxOnScreenControl_v4"
}
-->

# FxOnScreenControl_v4

Defines the methods a plug-in must implement to create parameter controls.

```
protocol FxOnScreenControl_v4
```

## Topics

### Instance Methods

[`func drawOSC(withWidth: Int, height: Int, activePart: Int, destinationImage: FxImageTile!, at: CMTime)`](/documentation/professional_video_applications/FxOnScreenControl_v4/drawOSC(withWidth:height:activePart:destinationImage:at:))

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

[`func drawingCoordinates() -> FxDrawingCoordinates`](/documentation/professional_video_applications/FxOnScreenControl_v4/drawingCoordinates())

Defines the coordinate space for an event.

[`func hitTestOSC(atMousePositionX: Double, mousePositionY: Double, activePart: UnsafeMutablePointer<Int>!, at: CMTime)`](/documentation/professional_video_applications/FxOnScreenControl_v4/hitTestOSC(atMousePositionX:mousePositionY:activePart:at:))

Figures out which part of the onscreen control was hit.

[`func keyDown(atPositionX: Double, positionY: Double, keyPressed: UInt16, modifiers: FxModifierKeys, forceUpdate: UnsafeMutablePointer<ObjCBool>!, didHandle: UnsafeMutablePointer<ObjCBool>!, at: CMTime)`](/documentation/professional_video_applications/FxOnScreenControl_v4/keyDown(atPositionX:positionY:keyPressed:modifiers:forceUpdate:didHandle:at:))

Provides information when a key is pressed.

[`func keyUp(atPositionX: Double, positionY: Double, keyPressed: UInt16, modifiers: FxModifierKeys, forceUpdate: UnsafeMutablePointer<ObjCBool>!, didHandle: UnsafeMutablePointer<ObjCBool>!, at: CMTime)`](/documentation/professional_video_applications/FxOnScreenControl_v4/keyUp(atPositionX:positionY:keyPressed:modifiers:forceUpdate:didHandle:at:))

Provides information when a key is released.

[`func mouseDown(atPositionX: Double, positionY: Double, activePart: Int, modifiers: FxModifierKeys, forceUpdate: UnsafeMutablePointer<ObjCBool>!, at: CMTime)`](/documentation/professional_video_applications/FxOnScreenControl_v4/mouseDown(atPositionX:positionY:activePart:modifiers:forceUpdate:at:))

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

[`func mouseDragged(atPositionX: Double, positionY: Double, activePart: Int, modifiers: FxModifierKeys, forceUpdate: UnsafeMutablePointer<ObjCBool>!, at: CMTime)`](/documentation/professional_video_applications/FxOnScreenControl_v4/mouseDragged(atPositionX:positionY:activePart:modifiers:forceUpdate:at:))

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

[`func mouseEntered(atPositionX: Double, positionY: Double, modifiers: FxModifierKeys, forceUpdate: UnsafeMutablePointer<ObjCBool>!, at: CMTime)`](/documentation/professional_video_applications/FxOnScreenControl_v4/mouseEntered(atPositionX:positionY:modifiers:forceUpdate:at:))

Provides information when the mouse pointer enters the view.

[`func mouseExited(atPositionX: Double, positionY: Double, modifiers: FxModifierKeys, forceUpdate: UnsafeMutablePointer<ObjCBool>!, at: CMTime)`](/documentation/professional_video_applications/FxOnScreenControl_v4/mouseExited(atPositionX:positionY:modifiers:forceUpdate:at:))

Provides information when the mouse pointer leaves the view.

[`func mouseMoved(atPositionX: Double, positionY: Double, activePart: Int, modifiers: FxModifierKeys, forceUpdate: UnsafeMutablePointer<ObjCBool>!, at: CMTime)`](/documentation/professional_video_applications/FxOnScreenControl_v4/mouseMoved(atPositionX:positionY:activePart:modifiers:forceUpdate:at:))

Provides information when the mouse pointer changes location.

[`func mouseUp(atPositionX: Double, positionY: Double, activePart: Int, modifiers: FxModifierKeys, forceUpdate: UnsafeMutablePointer<ObjCBool>!, at: CMTime)`](/documentation/professional_video_applications/FxOnScreenControl_v4/mouseUp(atPositionX:positionY:activePart:modifiers:forceUpdate:at:))

Provides information when the left mouse button is released.



---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)