iOS SDK How to change resolution video

[Help]
I have tried to change the resolution of the iOS application to 320x120 11fps, but I think the way I did was not good because I changed the resolution in a hardcode on the ‘react-native-webrtc’ framework.

file WebRTCModule+RTCMediaStream.m
- (RTCVideoTrack *)createVideoTrack:(NSDictionary *)constraints {
RTCVideoSource *videoSource = [self.peerConnectionFactory videoSource];
[videoSource adaptOutputFormatToWidth:320 height:180 fps:11];
NSString *trackUUID = [[NSUUID UUID] UUIDString];
RTCVideoTrack *videoTrack = [self.peerConnectionFactory videoTrackWithSource:videoSource trackId:trackUUID];
#if !TARGET_IPHONE_SIMULATOR
RTCCameraVideoCapturer *videoCapturer = [[RTCCameraVideoCapturer alloc] initWithDelegate:videoSource];
VideoCaptureController *videoCaptureController
= [[VideoCaptureController alloc] initWithCapturer:videoCapturer
andConstraints:constraints[@“video”]];
videoTrack.videoCaptureController = videoCaptureController;
[videoCaptureController startCapture];
#endif
return videoTrack;
}

I have added a line [videoSource adaptOutputFormatToWidth:320 height:180 fps:11];
result:

what I want to ask is whether there is another better way to change the resolution without changing the default frameworks?