&hcamcorder->video_encoder_resource);
if (ret != MM_RESOURCE_MANAGER_ERROR_NONE) {
_mmcam_dbg_err("could not prepare for encoder resource");
- ret = MM_ERROR_CAMCORDER_INTERNAL;
+ ret = MM_ERROR_RESOURCE_INTERNAL;
_MMCAMCORDER_UNLOCK_RESOURCE(hcamcorder);
goto _ERR_CAMCORDER_VIDEO_COMMAND;
}
/* acquire resources */
ret = mm_resource_manager_commit(hcamcorder->resource_manager);
if (ret != MM_RESOURCE_MANAGER_ERROR_NONE) {
- _MMCAMCORDER_UNLOCK_RESOURCE(hcamcorder);
-
_mmcam_dbg_err("could not acquire resources");
-
+ ret = MM_ERROR_RESOURCE_INTERNAL;
+ _MMCAMCORDER_UNLOCK_RESOURCE(hcamcorder);
goto _ERR_CAMCORDER_VIDEO_COMMAND;
}
if (info->video_frame_count >= _MMCAMCORDER_MINIMUM_FRAME) {
break;
} else if (count == _MMCAMCORDER_RETRIAL_COUNT) {
- _mmcam_dbg_err("Pause fail, frame count %llu", info->video_frame_count);
+ _mmcam_dbg_err("Pause fail, frame count %"G_GUINT64_FORMAT, info->video_frame_count);
return MM_ERROR_CAMCORDER_INVALID_CONDITION;
} else {
- _mmcam_dbg_warn("Waiting for enough video frame, retrial[%d], frame %llu", count, info->video_frame_count);
+ _mmcam_dbg_warn("Waiting for enough video frame, retrial[%d], frame %"G_GUINT64_FORMAT, count, info->video_frame_count);
}
usleep(_MMCAMCORDER_FRAME_WAIT_TIME);
if (info->video_frame_count >= _MMCAMCORDER_MINIMUM_FRAME && info->audio_frame_count) {
break;
} else if (count == _MMCAMCORDER_RETRIAL_COUNT) {
- _mmcam_dbg_err("Pause fail, frame count VIDEO[%llu], AUDIO [%llu]",
+ _mmcam_dbg_err("Pause fail, frame count VIDEO[%"G_GUINT64_FORMAT"], AUDIO [%"G_GUINT64_FORMAT"]",
info->video_frame_count, info->audio_frame_count);
return MM_ERROR_CAMCORDER_INVALID_CONDITION;
} else {
- _mmcam_dbg_warn("Waiting for enough frames, retrial [%d], VIDEO[%llu], AUDIO [%llu]",
+ _mmcam_dbg_warn("Waiting for enough frames, retrial [%d], VIDEO[%"G_GUINT64_FORMAT"], AUDIO [%"G_GUINT64_FORMAT"]",
count, info->video_frame_count, info->audio_frame_count);
}
hcamcorder->capture_in_recording == FALSE) {
break;
} else if (count == _MMCAMCORDER_RETRIAL_COUNT) {
- _mmcam_dbg_err("Commit fail, frame count is %llu, capturing %d",
+ _mmcam_dbg_err("Commit fail, frame count is %"G_GUINT64_FORMAT", capturing %d",
info->video_frame_count, hcamcorder->capture_in_recording);
if (info->video_frame_count >= _MMCAMCORDER_MINIMUM_FRAME) {
return MM_ERROR_CAMCORDER_INVALID_CONDITION;
}
} else {
- _mmcam_dbg_warn("Waiting for enough video frame, retrial [%d], frame %llu, capturing %d",
+ _mmcam_dbg_warn("Waiting for enough video frame, retrial [%d], frame %"G_GUINT64_FORMAT", capturing %d",
count, info->video_frame_count, hcamcorder->capture_in_recording);
}
} else {
hcamcorder->capture_in_recording == FALSE) {
break;
} else if (count == _MMCAMCORDER_RETRIAL_COUNT) {
- _mmcam_dbg_err("Commit fail, VIDEO[%llu], AUDIO [%llu], capturing %d",
+ _mmcam_dbg_err("Commit fail, VIDEO[%"G_GUINT64_FORMAT"], AUDIO [%"G_GUINT64_FORMAT"], capturing %d",
info->video_frame_count, info->audio_frame_count, hcamcorder->capture_in_recording);
if (info->video_frame_count >= _MMCAMCORDER_MINIMUM_FRAME && info->audio_frame_count) {
return MM_ERROR_CAMCORDER_INVALID_CONDITION;
} else {
- _mmcam_dbg_warn("Waiting for enough frames, retrial [%d], VIDEO[%llu], AUDIO [%llu], capturing %d",
+ _mmcam_dbg_warn("Waiting for enough frames, retrial [%d], VIDEO[%"G_GUINT64_FORMAT"], AUDIO [%"G_GUINT64_FORMAT"], capturing %d",
count, info->video_frame_count, info->audio_frame_count, hcamcorder->capture_in_recording);
}
}
_mmcam_dbg_err("");
- if (hcamcorder->state_change_by_system != _MMCAMCORDER_STATE_CHANGE_BY_FOCUS) {
- /* Play record stop sound */
- _mmcamcorder_sound_solo_play(handle, _MMCAMCORDER_SAMPLE_SOUND_NAME_REC_STOP, FALSE);
- } else {
- _mmcam_dbg_warn("Play stop sound through pulseaudio");
-
- _mmcamcorder_sound_init(handle);
-
- _mmcamcorder_sound_play((MMHandleType)hcamcorder, _MMCAMCORDER_SAMPLE_SOUND_NAME_REC_STOP, TRUE);
-
- _mmcamcorder_sound_finalize(handle);
- }
+ /* Play record stop sound */
+ _mmcamcorder_sound_solo_play(handle, _MMCAMCORDER_SAMPLE_SOUND_NAME_REC_STOP, FALSE);
/* remove blocking part */
MMCAMCORDER_G_OBJECT_SET(sc->encode_element[_MMCAMCORDER_ENCSINK_ENCBIN].gst, "block", FALSE);
/* Check file size */
if (info->max_size > 0) {
_mmcamcorder_get_file_size(info->filename, &file_size);
- _mmcam_dbg_log("MAX size %lld byte - created filesize %lld byte",
+ _mmcam_dbg_log("MAX size %"G_GUINT64_FORMAT" byte - created filesize %"G_GUINT64_FORMAT" byte",
info->max_size, file_size);
if (file_size > info->max_size) {
info->filesize = 0;
info->b_commiting = FALSE;
- if (hcamcorder->state_change_by_system != _MMCAMCORDER_STATE_CHANGE_BY_FOCUS) {
- /* check recording stop sound */
- _mmcamcorder_sound_solo_play_wait(handle);
- }
+ /* check recording stop sound */
+ _mmcamcorder_sound_solo_play_wait(handle);
_mmcam_dbg_err("_MMCamcorder_CMD_COMMIT : end");
nread = fread(&buf, sizeof(char), sizeof(buf), f);
- _mmcam_dbg_log("recorded file fread %d", nread);
+ _mmcam_dbg_log("recorded file fread %zu", nread);
udta_size = _mmcamcorder_get_container_size(buf);