#include <string.h>
#include <mm_error.h>
-#include <mm_attrs_private.h>
#include "mm_camcorder.h"
#include "mm_camcorder_internal.h"
mmf_return_val_if_fail((void *)camcorder, MM_ERROR_CAMCORDER_INVALID_ARGUMENT);
mmf_return_val_if_fail((void *)info, MM_ERROR_CAMCORDER_INVALID_ARGUMENT);
- _mmcam_dbg_err("");
+ MMCAM_LOG_ERROR("");
traceBegin(TTRACE_TAG_CAMERA, "MMCAMCORDER:CREATE");
traceEnd(TTRACE_TAG_CAMERA);
- _mmcam_dbg_err("END");
+ MMCAM_LOG_ERROR("END");
return error;
}
mmf_return_val_if_fail((void *)camcorder, MM_ERROR_CAMCORDER_INVALID_ARGUMENT);
- _mmcam_dbg_err("");
+ MMCAM_LOG_ERROR("");
traceBegin(TTRACE_TAG_CAMERA, "MMCAMCORDER:DESTROY");
traceEnd(TTRACE_TAG_CAMERA);
- _mmcam_dbg_err("END!!!");
+ MMCAM_LOG_ERROR("END!!!");
return error;
}
mmf_return_val_if_fail((void *)camcorder, MM_ERROR_CAMCORDER_INVALID_ARGUMENT);
- _mmcam_dbg_err("");
+ MMCAM_LOG_ERROR("");
- _MMCAMCORDER_LOCK_ASM(camcorder);
+ _MMCAMCORDER_LOCK_INTERRUPT(camcorder);
traceBegin(TTRACE_TAG_CAMERA, "MMCAMCORDER:REALIZE");
traceEnd(TTRACE_TAG_CAMERA);
- _MMCAMCORDER_UNLOCK_ASM(camcorder);
+ _MMCAMCORDER_UNLOCK_INTERRUPT(camcorder);
- _mmcam_dbg_err("END");
+ MMCAM_LOG_ERROR("END");
return error;
}
mmf_return_val_if_fail((void *)camcorder, MM_ERROR_CAMCORDER_INVALID_ARGUMENT);
- _mmcam_dbg_err("");
+ MMCAM_LOG_ERROR("");
- _MMCAMCORDER_LOCK_ASM(camcorder);
+ _MMCAMCORDER_LOCK_INTERRUPT(camcorder);
traceBegin(TTRACE_TAG_CAMERA, "MMCAMCORDER:UNREALIZE");
traceEnd(TTRACE_TAG_CAMERA);
- _MMCAMCORDER_UNLOCK_ASM(camcorder);
+ _MMCAMCORDER_UNLOCK_INTERRUPT(camcorder);
- _mmcam_dbg_err("END");
+ MMCAM_LOG_ERROR("END");
return error;
}
mmf_return_val_if_fail((void *)camcorder, MM_ERROR_CAMCORDER_INVALID_ARGUMENT);
- _mmcam_dbg_err("");
+ MMCAM_LOG_ERROR("");
- _MMCAMCORDER_LOCK_ASM(camcorder);
+ _MMCAMCORDER_LOCK_INTERRUPT(camcorder);
traceBegin(TTRACE_TAG_CAMERA, "MMCAMCORDER:START");
traceEnd(TTRACE_TAG_CAMERA);
- _MMCAMCORDER_UNLOCK_ASM(camcorder);
+ _MMCAMCORDER_UNLOCK_INTERRUPT(camcorder);
- _mmcam_dbg_err("END");
+ MMCAM_LOG_ERROR("END");
return error;
}
mmf_return_val_if_fail((void *)camcorder, MM_ERROR_CAMCORDER_INVALID_ARGUMENT);
- _mmcam_dbg_err("");
+ MMCAM_LOG_ERROR("");
- _MMCAMCORDER_LOCK_ASM(camcorder);
+ _MMCAMCORDER_LOCK_INTERRUPT(camcorder);
traceBegin(TTRACE_TAG_CAMERA, "MMCAMCORDER:STOP");
traceEnd(TTRACE_TAG_CAMERA);
- _MMCAMCORDER_UNLOCK_ASM(camcorder);
+ _MMCAMCORDER_UNLOCK_INTERRUPT(camcorder);
- _mmcam_dbg_err("END");
+ MMCAM_LOG_ERROR("END");
return error;
}
mmf_return_val_if_fail((void *)camcorder, MM_ERROR_CAMCORDER_INVALID_ARGUMENT);
- _mmcam_dbg_err("");
+ MMCAM_LOG_ERROR("");
- _MMCAMCORDER_LOCK_ASM(camcorder);
+ _MMCAMCORDER_LOCK_INTERRUPT(camcorder);
error = _mmcamcorder_capture_start(camcorder);
- _MMCAMCORDER_UNLOCK_ASM(camcorder);
+ _MMCAMCORDER_UNLOCK_INTERRUPT(camcorder);
- _mmcam_dbg_err("END");
+ MMCAM_LOG_ERROR("END");
return error;
}
mmf_return_val_if_fail((void *)camcorder, MM_ERROR_CAMCORDER_INVALID_ARGUMENT);
- _mmcam_dbg_err("");
+ MMCAM_LOG_ERROR("");
- _MMCAMCORDER_LOCK_ASM(camcorder);
+ _MMCAMCORDER_LOCK_INTERRUPT(camcorder);
error = _mmcamcorder_capture_stop(camcorder);
- _MMCAMCORDER_UNLOCK_ASM(camcorder);
+ _MMCAMCORDER_UNLOCK_INTERRUPT(camcorder);
- _mmcam_dbg_err("END");
+ MMCAM_LOG_ERROR("END");
return error;
}
mmf_return_val_if_fail((void*)camcorder, MM_ERROR_CAMCORDER_INVALID_ARGUMENT);
- _mmcam_dbg_err("");
+ MMCAM_LOG_ERROR("");
- _MMCAMCORDER_LOCK_ASM(camcorder);
+ _MMCAMCORDER_LOCK_INTERRUPT(camcorder);
error = _mmcamcorder_record(camcorder);
- _MMCAMCORDER_UNLOCK_ASM(camcorder);
+ _MMCAMCORDER_UNLOCK_INTERRUPT(camcorder);
- _mmcam_dbg_err("END");
+ MMCAM_LOG_ERROR("END");
return error;
}
mmf_return_val_if_fail((void *)camcorder, MM_ERROR_CAMCORDER_INVALID_ARGUMENT);
- _mmcam_dbg_err("");
+ MMCAM_LOG_ERROR("");
- _MMCAMCORDER_LOCK_ASM(camcorder);
+ _MMCAMCORDER_LOCK_INTERRUPT(camcorder);
error = _mmcamcorder_pause(camcorder);
- _MMCAMCORDER_UNLOCK_ASM(camcorder);
+ _MMCAMCORDER_UNLOCK_INTERRUPT(camcorder);
- _mmcam_dbg_err("END");
+ MMCAM_LOG_ERROR("END");
return error;
}
mmf_return_val_if_fail((void *)camcorder, MM_ERROR_CAMCORDER_INVALID_ARGUMENT);
- _mmcam_dbg_err("");
+ MMCAM_LOG_ERROR("");
- _MMCAMCORDER_LOCK_ASM(camcorder);
+ _MMCAMCORDER_LOCK_INTERRUPT(camcorder);
error = _mmcamcorder_commit(camcorder);
- _MMCAMCORDER_UNLOCK_ASM(camcorder);
+ _MMCAMCORDER_UNLOCK_INTERRUPT(camcorder);
- _mmcam_dbg_err("END");
+ MMCAM_LOG_ERROR("END");
return error;
}
mmf_return_val_if_fail((void *)camcorder, MM_ERROR_CAMCORDER_INVALID_ARGUMENT);
- _mmcam_dbg_err("");
+ MMCAM_LOG_ERROR("");
- _MMCAMCORDER_LOCK_ASM(camcorder);
+ _MMCAMCORDER_LOCK_INTERRUPT(camcorder);
error = _mmcamcorder_cancel(camcorder);
- _MMCAMCORDER_UNLOCK_ASM(camcorder);
+ _MMCAMCORDER_UNLOCK_INTERRUPT(camcorder);
- _mmcam_dbg_err("END");
+ MMCAM_LOG_ERROR("END");
return error;
}
}
+int mm_camcorder_set_video_encode_decision_callback(MMHandleType camcorder, mm_camcorder_video_encode_decision_callback callback, void* user_data)
+{
+ mmf_return_val_if_fail((void *)camcorder, MM_ERROR_CAMCORDER_INVALID_ARGUMENT);
+
+ return _mmcamcorder_set_video_encode_decision_callback(camcorder, callback, user_data);
+}
+
+
int mm_camcorder_get_state(MMHandleType camcorder, MMCamcorderStateType *state)
{
int ret = MM_ERROR_NONE;
if (!camcorder) {
- _mmcam_dbg_warn("Empty handle.");
+ MMCAM_LOG_WARNING("Empty handle.");
return MM_ERROR_CAMCORDER_INVALID_ARGUMENT;
}
int mm_camcorder_get_state2(MMHandleType camcorder, MMCamcorderStateType *state, MMCamcorderStateType *old_state)
{
if (!camcorder) {
- _mmcam_dbg_warn("Empty handle.");
+ MMCAM_LOG_WARNING("Empty handle.");
return MM_ERROR_CAMCORDER_INVALID_ARGUMENT;
}
return _mmcamcorder_manage_external_storage_state(camcorder, storage_state);
}
+
+int mm_camcorder_get_focus_level(MMHandleType camcorder, int *level)
+{
+ mmf_return_val_if_fail((void *)camcorder, MM_ERROR_CAMCORDER_INVALID_ARGUMENT);
+
+ return _mmcamcorder_get_focus_level(camcorder, level);
+}
+
+int mm_camcorder_get_log_level(void)
+{
+ return _mmcamcorder_get_log_level();
+}