CameraEngine icon indicating copy to clipboard operation
CameraEngine copied to clipboard

how to capture square video

Open zinwalin opened this issue 9 years ago • 1 comments

I tried to hardcode height and width for VideoEncoder's process,

_encoder = [VideoEncoder encoderForPath:path Height:_cy width:_cx channels:_channels samples:_samplerate];

as follows:

    // hard-code resolution
    NSDictionary* actual = _videoDataOutput.videoSettings;

// _cy = [[actual objectForKey:@"Height"] floatValue]; // _cx = [[actual objectForKey:@"Width"] floatValue]; _cy = VIDEO_RESOLUTION_HEIGHT; _cx = VIDEO_RESOLUTION_WIDTH;

unfortunately, the video was distorted, though, it's square, indeed.

zinwalin avatar Nov 13 '15 08:11 zinwalin

Good ! That's a good feature to implement. Let's do it. :+1:

remirobert avatar Dec 24 '15 05:12 remirobert