Commit 59b3006c authored by Mickaël Turnel's avatar Mickaël Turnel

Fix incorrect indentations

parent 2f5f30e6
......@@ -101,8 +101,8 @@ static int video_capture_set_fps(MSFilter *f, void *arg){
AndroidReaderContext* d = (AndroidReaderContext*) f->data;
d->fps=*((float*)arg);
snprintf(d->fps_context, sizeof(d->fps_context), "Captured mean fps=%%f, expected=%f", d->fps);
ms_video_init_framerate_controller(&d->fpsControl, d->fps);
ms_video_init_average_fps(&d->averageFps, d->fps_context);
ms_video_init_framerate_controller(&d->fpsControl, d->fps);
ms_video_init_average_fps(&d->averageFps, d->fps_context);
return 0;
}
......@@ -149,8 +149,8 @@ static int video_capture_set_vsize(MSFilter *f, void* data){
// handle result :
// - 0 : width
// - 1 : height
// - 2 : useDownscaling
// - 1 : height
// - 2 : useDownscaling
jint res[3];
env->GetIntArrayRegion((jintArray)resArray, 0, 3, res);
ms_message("Camera selected resolution is: %dx%d (requested: %dx%d) with downscaling?%d\n", res[0], res[1], d->requestedSize.width, d->requestedSize.height, res[2]);
......
......@@ -42,7 +42,7 @@ static const MSVideoConfiguration mediaCodecH264_conf_list[] = {
MS_MEDIACODECH264_CONF(1024000, 5000000, 720P, 30, 2),
MS_MEDIACODECH264_CONF(750000, 2048000, XGA, 25, 2),
MS_MEDIACODECH264_CONF(500000, 1024000, SVGA, 15, 2),
MS_MEDIACODECH264_CONF(600000, 3000000, VGA, 30, 2),
MS_MEDIACODECH264_CONF(600000, 3000000, VGA, 30, 2),
MS_MEDIACODECH264_CONF(400000, 800000, VGA, 15, 2),
MS_MEDIACODECH264_CONF(128000, 512000, CIF, 15, 1),
MS_MEDIACODECH264_CONF(100000, 380000, QVGA, 15, 1),
......
......@@ -70,7 +70,7 @@ static AVCaptureVideoOrientation Angle2AVCaptureVideoOrientation(int deviceOrien
MSYuvBufAllocator* bufAllocator;
MSFilter *filter;
MSFrameRateController framerate_controller;
bool_t filterIsRunning;
bool_t filterIsRunning;
};
- (void)initIOSCapture;
......@@ -169,14 +169,14 @@ static void capture_queue_cleanup(void* p) {
CVImageBufferRef frame = nil;
@synchronized(self) {
@try {
ms_mutex_lock(&mutex);
if (!filterIsRunning || !ms_video_capture_new_frame(&framerate_controller, filter->ticker->time)) {
ms_mutex_unlock(&mutex);
return;
}
ms_mutex_unlock(&mutex);
ms_mutex_lock(&mutex);
if (!filterIsRunning || !ms_video_capture_new_frame(&framerate_controller, filter->ticker->time)) {
ms_mutex_unlock(&mutex);
return;
}
ms_mutex_unlock(&mutex);
frame = CMSampleBufferGetImageBuffer(sampleBuffer);
CVReturn status = CVPixelBufferLockBaseAddress(frame, 0);
if (kCVReturnSuccess != status) {
......@@ -430,9 +430,9 @@ static AVCaptureVideoOrientation Angle2AVCaptureVideoOrientation(int deviceOrien
mDownScalingRequired = FALSE;
} else if ( (outputSize.width * outputSize.height) == (MS_VIDEO_SIZE_QCIF_W * MS_VIDEO_SIZE_QCIF_H) ){
[session setSessionPreset:AVCaptureSessionPreset352x288];
mCameraVideoSize = MS_VIDEO_SIZE_CIF;
mOutputVideoSize = MS_VIDEO_SIZE_QCIF;
mDownScalingRequired = TRUE;
mCameraVideoSize = MS_VIDEO_SIZE_CIF;
mOutputVideoSize = MS_VIDEO_SIZE_QCIF;
mDownScalingRequired = TRUE;
} else {
// Default case
[session setSessionPreset: AVCaptureSessionPresetMedium];
......@@ -615,20 +615,20 @@ static void ioscapture_preprocess(MSFilter *f) {
NSAutoreleasePool* myPool = [[NSAutoreleasePool alloc] init];
[thiz performSelectorInBackground:@selector(start) withObject:nil];
[myPool drain];
ms_mutex_lock(&thiz->mutex);
thiz->filterIsRunning = 1;
ms_mutex_unlock(&thiz->mutex);
ms_mutex_lock(&thiz->mutex);
thiz->filterIsRunning = 1;
ms_mutex_unlock(&thiz->mutex);
}
}
static void ioscapture_postprocess(MSFilter *f) {
IOSCapture *thiz = (IOSCapture*)f->data;
if (thiz != NULL) {
ms_mutex_lock(&thiz->mutex);
thiz->filterIsRunning = 0;
ms_mutex_unlock(&thiz->mutex);
}
IOSCapture *thiz = (IOSCapture*)f->data;
if (thiz != NULL) {
ms_mutex_lock(&thiz->mutex);
thiz->filterIsRunning = 0;
ms_mutex_unlock(&thiz->mutex);
}
}
static int ioscapture_get_fps(MSFilter *f, void *arg) {
......
......@@ -44,12 +44,12 @@ static const MSVideoConfiguration vp8_conf_list[] = {
MS_VP8_CONF(1024000, 1536000, SXGA_MINUS, 12, 2),
MS_VP8_CONF( 750000, 1024000, XGA, 12, 2),
MS_VP8_CONF( 500000, 750000, SVGA, 12, 2),
MS_VP8_CONF( 800000, 3000000, VGA, 30, 8),
MS_VP8_CONF( 800000, 3000000, VGA, 30, 8),
MS_VP8_CONF( 800000, 3000000, VGA, 25, 4),
MS_VP8_CONF( 400000, 800000, VGA, 12, 2),
MS_VP8_CONF( 100000, 300000, QVGA, 18, 2),
MS_VP8_CONF( 64000, 100000, QCIF, 12, 2),
MS_VP8_CONF( 400000, 600000, VGA, 12, 1),
MS_VP8_CONF( 400000, 800000, VGA, 12, 1),
MS_VP8_CONF( 100000, 300000, QVGA, 10, 1),
MS_VP8_CONF( 64000, 100000, QCIF, 10, 1),
MS_VP8_CONF( 0, 64000, QCIF, 5, 1)
......
......@@ -1045,9 +1045,9 @@ MSVideoConfiguration ms_video_find_best_configuration_for_size_and_bitrate(const
}
last_good_vconf = NULL;
best_vconf.vsize = vsize;
ms_message("Best video configuration for %dbits/s: rb=%d, bl=%d, fps=%f, vsize=%dx%d, mincpu=%d", bitrate, best_vconf.required_bitrate, best_vconf.bitrate_limit, best_vconf.fps, best_vconf.vsize.width, best_vconf.vsize.height, best_vconf.mincpu);
ms_message("Best video configuration for %dbits/s: rb=%d, bl=%d, fps=%f, vsize=%dx%d, mincpu=%d", bitrate, best_vconf.required_bitrate, best_vconf.bitrate_limit, best_vconf.fps, best_vconf.vsize.width, best_vconf.vsize.height, best_vconf.mincpu);
return best_vconf;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment