makeup|SDK makeup|SDK is a library based on visage|SDK face tracking used to configure and render virtual makeup.

Loading...
Searching...
No Matches
Instance Methods | Class Methods | Properties | List of all members
FilterTemplate Class Reference

`#import <FeatureTemplate.h>`

Inherits NSObject.

## Instance Methods
(id) | - init
(NSMutableDictionary *) | - ToJSON

## Class Methods
(FilterTemplate *) | + FromJSON:

## Properties
NSString * | name
NSMutableArray< FilterParameterTemplate * > * | parameters

## Detailed Description

Defines a name and a paramaters list specifiying a filter. Each filter must take an image as input and returns and image processed by an filtering algorithm. Optionally, a filter can take additional parameters which are stored in parameters member. The engine supports the following filters:

- Smoothing: performs face smoothing filter on the input image
- Greyscale: performs greyscale conversion on the input image
- Threshold: performs binary thresholding operation on the input image
- Multply: performs multiplication of the given image with a custom mask texture specified as input parameter
- HighPass: performs gaussian high pass filter on the input image
- Blur - performs gaussian blur on the input image

The filter applied is defined by name member. Input parameters of each filter can be set using FilterParameterTemplate class Provides methods for serialization and deserialization of FilterTemplate instances from JSON format.

## Method Documentation

## ◆ FromJSON:

+ (FilterTemplate *) FromJSON: |  | (NSDictionary *) | jsonDictionary |

Returns FilterTemplate object out of JSON dictionary.

Parameters

  jsonDictionary | JSON dictionary

Returns
  deserialized FeatureTemplate object

## ◆ init

- (id) init |  |  |

Initializes new FilterTemplate object.

## ◆ ToJSON

- (NSMutableDictionary *) ToJSON |  |  |

Returns JSON dictionary out of this FilterTemplate object.

Returns
  JSON representation of this FilterTemplate returned as NSMutableDictionary

## Property Documentation

## ◆ name

- (NSString*) name
| read write nonatomic strong

Name of the filter to apply.

## ◆ parameters

- (NSMutableArray<FilterParameterTemplate*>*) parameters
| read write nonatomic strong

List of optional filter parameters.