Interface LensSource

Provides Lens metadata for one or more Lens groups.

When a Lens or Lens group is requested via the LensRepository, CameraKit will find the LensSource which claims ownership of that group. The appropriate LensSource method will be called and must return an ArrayBuffer containing the encoded Lens metadata -- this can be obtained from a CameraKit backend API.

interface LensSource {
    isGroupOwner(groupId: string): boolean;
    loadLens(lensId: string, groupId: string): Promise<ArrayBuffer>;
    loadLensGroup(groupId: string): Promise<ArrayBuffer>;
}

Methods

  • Parameters

    • groupId: string

    Returns boolean

MMNEPVFCICPMFPCPTTAAATR