# Create

To access the api to record, you need to first create an instance of [IScreenRecorder](https://voxelbusters.com/products/cross-platform-screen-recorder-kit/documentation/api/VoxelBusters.ScreenRecorderKit.IScreenRecorder.html). ScreenRecorderBuilder provides a way to create IScreenRecorder instances for both Gif and Video.

### Create Video Recorder

To create a video recorder IScreenRecorder instance, first you need to create an instance of VideoRecorderRuntimeSettings and pass it to [ScreenRecorderBuilder](https://voxelbusters.com/products/cross-platform-screen-recorder-kit/documentation/api/VoxelBusters.ScreenRecorderKit.ScreenRecorderBuilder.html).

#### Configuration

[VideoRecorderRuntimeSettings](https://voxelbusters.com/products/cross-platform-screen-recorder-kit/documentation/api/VoxelBusters.ScreenRecorderKit.ScreenRecorderBuilder.html#VoxelBusters_ScreenRecorderKit_ScreenRecorderBuilder_CreateVideoRecorder_VoxelBusters_ScreenRecorderKit_VideoRecorderRuntimeSettings_) provides a way to configure the video recorder. You can change the microphone status to enable or disable for the current recording.

{% code title="Create settings instance" %}

```csharp
VideoRecorderRuntimeSettings settings = new VideoRecorderRuntimeSettings(enableMicrophone: true);
```

{% endcode %}

#### IScreenRecorder instance for Video

Once you create a VideoRecorderRuntimeSettings instance, pass it to ScreenRecorderBuilder to create an IScreenRecorder instance.

```csharp
IScreenRecorder recorder;
//...
//...

// Create settings
VideoRecorderRuntimeSettings settings = new VideoRecorderRuntimeSettings(enableMicrophone: true);

// Pass settings to ScreenRecorderBuilder and build
ScreenRecorderBuilder builder = ScreenRecorderBuilder.CreateVideoRecorder(settings);
recorder = builder.Build();
```

### Create GIF Recorder

Create a GIF recorder IScreenRecorder instance vis ScreenRecorderBuilder.

#### Configuration

You can pass Camera instance to builder if you want to record only a specific camera.

#### IScreenRecorder instance for GIF

You can either record a specific camera or complete screen with GIF recorder.

{% code title="Camera Recording" %}

```csharp
IScreenRecorder recorder;
Camera cameraInstance;
//....
ScreenRecorderBuilder builder = ScreenRecorderBuilder.CreateGifRecorder(cameraInstance);
recorder = builder.Build();
```

{% endcode %}

{% code title="Full Screen Recording" %}

```csharp
IScreenRecorder recorder;
//....

ScreenRecorderBuilder builder = ScreenRecorderBuilder.CreateGifRecorder();
recorder = builder.Build();
```

{% endcode %}
