iOS API reference
Complete API reference for the Video Mobile SDK on iOS.
This reference documents all public classes and methods in the iOS Video Mobile SDK.
PFCDynamic
The main class for image and video processing.
public class PFCDynamicInitialize the SDK
The SDK is initialized by creating a PFCDynamic instance with your license credentials.
init(apiKey:certificate:)
Creates a new instance with license credentials.
public init(apiKey: String, certificate: String)| Parameter | Type | Description |
|---|---|---|
apiKey | String | Your API key from EyeQ |
certificate | String | Your certificate string |
Initialization does not guarantee that the instance will work correctly. Use checkStatus() to ensure initialization was successful before processing images.
Use raw string literals (#"..."#) for certificates to avoid escaping special characters.
License verification
Always verify the SDK initialized correctly before processing images.
checkStatus()
Verifies the initialization and license status.
public func checkStatus() -> Int32Returns: Status code indicating initialization result.
| Code | Description |
|---|---|
0 | Success |
-1 | Expired certificate |
-2 | Wrong API key/certificate combination |
-3 | Failed to initialize AI model |
-4 | Failed to load model file PFCDynamicModel.pnnc from framework resources |
-5 | Failed to create context |
Image processing
The core method for applying Dynamic correction to images.
processImage(_:strength:)
Applies Dynamic correction to an image.
public func processImage(_ image: CGImage, strength: Float) throws -> CGImage| Parameter | Type | Description |
|---|---|---|
image | CGImage | Source image |
strength | Float | Correction intensity (0.0–1.0) |
Returns: Processed CGImage with applied Dynamic effect.
Video parameters
Configure these settings before processing video or camera frames to ensure temporal consistency and reduce flickering.
setParams(deflickerCurve:deflickerImage:skip:)
Configures parameters for video processing. Setting parameters to any value other than 0 is recommended only when working with videos or camera feeds.
public func setParams(deflickerCurve: Float, deflickerImage: Float, skip: Int)| Parameter | Type | Description | Recommended |
|---|---|---|---|
deflickerCurve | Float | Tone curve temporal smoothing (0.0–1.0) | 0.08 |
deflickerImage | Float | Image correction temporal smoothing (0.0–1.0) | 0.9 |
skip | Int | Frames to skip between inference calculations | 0–2 |
Deflickering has a cumulative effect. Call resetDeflicker() when switching videos or cameras to reset the state.
Skip parameter behavior:
| Value | Behavior | Use case |
|---|---|---|
0 | Process every frame | Highest quality |
1 | Process every other frame | Balanced performance |
2 | Process every third frame | Lower-end devices |
resetDeflicker()
Resets the deflickering state. Call this to clear the cumulative deflicker effect.
public func resetDeflicker()When to call:
| Scenario | Action |
|---|---|
| Switching cameras (front/back) | Call resetDeflicker() |
| Starting new video recording | Call resetDeflicker() |
| Seeking in video player | Call resetDeflicker() |
| Loading new video file | Call resetDeflicker() |
| Resuming from background | Call resetDeflicker() |
API summary
Quick reference for all PFCDynamic methods:
| Method | Description |
|---|---|
init(apiKey:certificate:) | Initialize with license credentials |
checkStatus() -> Int32 | Verify initialization (0 = success) |
processImage(_:strength:) throws -> CGImage | Process an image |
setParams(deflickerCurve:deflickerImage:skip:) | Configure video parameters |
resetDeflicker() | Reset deflicker state |
VIDEO-SDK Version 1.0.0.23 built from aa5eef97017e23db1d3051b079500606825ef474 on 5-6-2023.
Copyright © 2026 EyeQ Imaging Inc. All rights reserved.