• Home
  • Raw
  • Download

Lines Matching refs:xcamsrc

418 static gboolean gst_xcam_src_plugin_init (GstPlugin * xcamsrc);
580 gst_xcam_src_init (GstXCamSrc *xcamsrc) in gst_xcam_src_init() argument
582 gst_base_src_set_format (GST_BASE_SRC (xcamsrc), GST_FORMAT_TIME); in gst_xcam_src_init()
583 gst_base_src_set_live (GST_BASE_SRC (xcamsrc), TRUE); in gst_xcam_src_init()
584 gst_base_src_set_do_timestamp (GST_BASE_SRC (xcamsrc), TRUE); in gst_xcam_src_init()
586 xcamsrc->buf_count = DEFAULT_PROP_BUFFERCOUNT; in gst_xcam_src_init()
587 xcamsrc->sensor_id = 0; in gst_xcam_src_init()
588 xcamsrc->capture_mode = V4L2_CAPTURE_MODE_VIDEO; in gst_xcam_src_init()
589 xcamsrc->device = NULL; in gst_xcam_src_init()
590 xcamsrc->enable_usb = DEFAULT_PROP_ENABLE_USB; in gst_xcam_src_init()
593 xcamsrc->enable_3a = DEFAULT_PROP_ENABLE_3A; in gst_xcam_src_init()
594 xcamsrc->path_to_cpf = strndup(DEFAULT_CPF_FILE_NAME, XCAM_MAX_STR_SIZE); in gst_xcam_src_init()
595 xcamsrc->path_to_3alib = strndup(DEFAULT_DYNAMIC_3A_LIB, XCAM_MAX_STR_SIZE); in gst_xcam_src_init()
599 xcamsrc->cl_pipe_profile = DEFAULT_PROP_CL_PIPE_PROFILE; in gst_xcam_src_init()
600 xcamsrc->wdr_mode_type = DEFAULT_PROP_WDR_MODE; in gst_xcam_src_init()
601 xcamsrc->wavelet_mode = NONE_WAVELET; in gst_xcam_src_init()
602 xcamsrc->defog_mode = DEFAULT_PROP_DEFOG_MODE; in gst_xcam_src_init()
603 xcamsrc->denoise_3d_mode = DEFAULT_PROP_3D_DENOISE_MODE; in gst_xcam_src_init()
604 xcamsrc->denoise_3d_ref_count = 2; in gst_xcam_src_init()
605 xcamsrc->enable_wireframe = DEFAULT_PROP_ENABLE_WIREFRAME; in gst_xcam_src_init()
608 xcamsrc->path_to_fake = NULL; in gst_xcam_src_init()
609 xcamsrc->time_offset_ready = FALSE; in gst_xcam_src_init()
610 xcamsrc->time_offset = -1; in gst_xcam_src_init()
611 xcamsrc->buf_mark = 0; in gst_xcam_src_init()
612 xcamsrc->duration = 0; in gst_xcam_src_init()
613 xcamsrc->mem_type = DEFAULT_PROP_MEM_MODE; in gst_xcam_src_init()
614 xcamsrc->field = DEFAULT_PROP_FIELD; in gst_xcam_src_init()
616 xcamsrc->in_format = 0; in gst_xcam_src_init()
617 if (xcamsrc->enable_usb) { in gst_xcam_src_init()
618 xcamsrc->out_format = GST_VIDEO_FORMAT_YUY2; in gst_xcam_src_init()
621 xcamsrc->out_format = DEFAULT_PROP_PIXELFORMAT; in gst_xcam_src_init()
624 gst_video_info_init (&xcamsrc->gst_video_info); in gst_xcam_src_init()
625 if (xcamsrc->enable_usb) { in gst_xcam_src_init()
626 …gst_video_info_set_format (&xcamsrc->gst_video_info, GST_VIDEO_FORMAT_YUY2, DEFAULT_VIDEO_WIDTH, D… in gst_xcam_src_init()
629 …gst_video_info_set_format (&xcamsrc->gst_video_info, GST_VIDEO_FORMAT_NV12, DEFAULT_VIDEO_WIDTH, D… in gst_xcam_src_init()
632 XCAM_CONSTRUCTOR (xcamsrc->xcam_video_info, VideoBufferInfo); in gst_xcam_src_init()
633xcamsrc->xcam_video_info.init (DEFAULT_PROP_PIXELFORMAT, DEFAULT_VIDEO_WIDTH, DEFAULT_VIDEO_HEIGHT… in gst_xcam_src_init()
634 xcamsrc->image_processor_type = DEFAULT_PROP_IMAGE_PROCESSOR; in gst_xcam_src_init()
635 xcamsrc->analyzer_type = DEFAULT_PROP_ANALYZER; in gst_xcam_src_init()
636 XCAM_CONSTRUCTOR (xcamsrc->device_manager, SmartPtr<MainDeviceManager>); in gst_xcam_src_init()
637 xcamsrc->device_manager = new MainDeviceManager; in gst_xcam_src_init()
643 GstXCamSrc *xcamsrc = GST_XCAM_SRC (object); in gst_xcam_src_finalize() local
645 xcamsrc->device_manager.release (); in gst_xcam_src_finalize()
646 XCAM_DESTRUCTOR (xcamsrc->device_manager, SmartPtr<MainDeviceManager>); in gst_xcam_src_finalize()
909 GstXCamSrc *xcamsrc = GST_XCAM_SRC (src); in gst_xcam_src_start() local
910 SmartPtr<MainDeviceManager> device_manager = xcamsrc->device_manager; in gst_xcam_src_start()
926 if (xcamsrc->device == NULL) { in gst_xcam_src_start()
927 if (xcamsrc->capture_mode == V4L2_CAPTURE_MODE_STILL) in gst_xcam_src_start()
928 xcamsrc->device = strndup (CAPTURE_DEVICE_STILL, XCAM_MAX_STR_SIZE); in gst_xcam_src_start()
930 xcamsrc->device = strndup (CAPTURE_DEVICE_VIDEO, XCAM_MAX_STR_SIZE); in gst_xcam_src_start()
932 XCAM_ASSERT (xcamsrc->device); in gst_xcam_src_start()
935 if (xcamsrc->in_format == 0) { in gst_xcam_src_start()
936 if (xcamsrc->image_processor_type == CL_IMAGE_PROCESSOR) in gst_xcam_src_start()
937 xcamsrc->in_format = V4L2_PIX_FMT_SGRBG10; in gst_xcam_src_start()
938 else if (xcamsrc->enable_usb) in gst_xcam_src_start()
939 xcamsrc->in_format = V4L2_PIX_FMT_YUYV; in gst_xcam_src_start()
941 xcamsrc->in_format = V4L2_PIX_FMT_NV12; in gst_xcam_src_start()
944 if (xcamsrc->path_to_fake) { in gst_xcam_src_start()
946 } else if (xcamsrc->enable_usb) { in gst_xcam_src_start()
947 capture_device = new UVCDevice (xcamsrc->device); in gst_xcam_src_start()
951 capture_device = new AtomispDevice (xcamsrc->device); in gst_xcam_src_start()
955 capture_device->set_sensor_id (xcamsrc->sensor_id); in gst_xcam_src_start()
956 capture_device->set_capture_mode (xcamsrc->capture_mode); in gst_xcam_src_start()
957 capture_device->set_mem_type (xcamsrc->mem_type); in gst_xcam_src_start()
958 capture_device->set_buffer_count (xcamsrc->buf_count); in gst_xcam_src_start()
963 if (!xcamsrc->enable_usb && !xcamsrc->path_to_fake) { in gst_xcam_src_start()
975 switch (xcamsrc->image_processor_type) { in gst_xcam_src_start()
985 if(xcamsrc->wdr_mode_type != NONE_WDR) in gst_xcam_src_start()
988 xcamsrc->in_format = V4L2_PIX_FMT_SGRBG12; in gst_xcam_src_start()
992 if(xcamsrc->wdr_mode_type == GAUSSIAN_WDR) in gst_xcam_src_start()
996 else if(xcamsrc->wdr_mode_type == HALEQ_WDR) in gst_xcam_src_start()
1002 cl_processor->set_profile ((CL3aImageProcessor::PipelineProfile)xcamsrc->cl_pipe_profile); in gst_xcam_src_start()
1024 cl_post_processor->set_defog_mode ((CLPostImageProcessor::CLDefogMode) xcamsrc->defog_mode); in gst_xcam_src_start()
1026 … (CLPostImageProcessor::CL3DDenoiseMode) xcamsrc->denoise_3d_mode, xcamsrc->denoise_3d_ref_count); in gst_xcam_src_start()
1028 if (NONE_WAVELET != xcamsrc->wavelet_mode) { in gst_xcam_src_start()
1029 if (HAT_WAVELET_Y == xcamsrc->wavelet_mode) { in gst_xcam_src_start()
1031 } else if (HAT_WAVELET_UV == xcamsrc->wavelet_mode) { in gst_xcam_src_start()
1033 } else if (HARR_WAVELET_Y == xcamsrc->wavelet_mode) { in gst_xcam_src_start()
1035 } else if (HARR_WAVELET_UV == xcamsrc->wavelet_mode) { in gst_xcam_src_start()
1037 } else if (HARR_WAVELET_YUV == xcamsrc->wavelet_mode) { in gst_xcam_src_start()
1039 } else if (HARR_WAVELET_BAYES == xcamsrc->wavelet_mode) { in gst_xcam_src_start()
1046 cl_post_processor->set_wireframe (xcamsrc->enable_wireframe); in gst_xcam_src_start()
1052 switch (xcamsrc->analyzer_type) { in gst_xcam_src_start()
1059 XCAM_LOG_INFO ("cpf: %s", xcamsrc->path_to_cpf); in gst_xcam_src_start()
1060 … SmartPtr<X3aAnalyzer> aiq_analyzer = new X3aAnalyzerAiq (isp_controller, xcamsrc->path_to_cpf); in gst_xcam_src_start()
1069 XCAM_LOG_INFO ("dynamic 3a library: %s", xcamsrc->path_to_3alib); in gst_xcam_src_start()
1070 …SmartPtr<DynamicAnalyzerLoader> dynamic_loader = new DynamicAnalyzerLoader (xcamsrc->path_to_3alib… in gst_xcam_src_start()
1074 … XCAM_LOG_ERROR ("load dynamic analyzer(%s) failed, please check.", xcamsrc->path_to_3alib); in gst_xcam_src_start()
1080 XCAM_LOG_INFO ("hybrid 3a library: %s", xcamsrc->path_to_3alib); in gst_xcam_src_start()
1081 … SmartPtr<HybridAnalyzerLoader> hybrid_loader = new HybridAnalyzerLoader (xcamsrc->path_to_3alib); in gst_xcam_src_start()
1087 … XCAM_LOG_ERROR ("load hybrid analyzer(%s) failed, please check.", xcamsrc->path_to_3alib); in gst_xcam_src_start()
1105 if(xcamsrc->wdr_mode_type != NONE_WDR) in gst_xcam_src_start()
1129 if (cl_post_processor.ptr () && xcamsrc->enable_wireframe) { in gst_xcam_src_start()
1141 if (xcamsrc->enable_usb) { in gst_xcam_src_start()
1143 } else if (xcamsrc->path_to_fake) { in gst_xcam_src_start()
1144 poll_thread = new FakePollThread (xcamsrc->path_to_fake); in gst_xcam_src_start()
1162 GstXCamSrc *xcamsrc = GST_XCAM_SRC_CAST (src); in gst_xcam_src_stop() local
1163 SmartPtr<MainDeviceManager> device_manager = xcamsrc->device_manager; in gst_xcam_src_stop()
1181 GstXCamSrc *xcamsrc = GST_XCAM_SRC_CAST (src); in gst_xcam_src_unlock() local
1182 SmartPtr<MainDeviceManager> device_manager = xcamsrc->device_manager; in gst_xcam_src_unlock()
1192 GstXCamSrc *xcamsrc = GST_XCAM_SRC_CAST (src); in gst_xcam_src_unlock_stop() local
1193 SmartPtr<MainDeviceManager> device_manager = xcamsrc->device_manager; in gst_xcam_src_unlock_stop()
1203 GstXCamSrc *xcamsrc = GST_XCAM_SRC (src); in gst_xcam_src_get_caps() local
1206 return gst_pad_get_pad_template_caps (GST_BASE_SRC_PAD (xcamsrc)); in gst_xcam_src_get_caps()
1236 GstXCamSrc *xcamsrc = GST_XCAM_SRC (src); in gst_xcam_src_set_caps() local
1251 …SmartPtr<CLPostImageProcessor> processor = xcamsrc->device_manager->get_cl_post_image_processor (); in gst_xcam_src_set_caps()
1260 xcamsrc->out_format = out_format; in gst_xcam_src_set_caps()
1262 SmartPtr<MainDeviceManager> device_manager = xcamsrc->device_manager; in gst_xcam_src_set_caps()
1268 xcamsrc->in_format, in gst_xcam_src_set_caps()
1269 xcamsrc->field, in gst_xcam_src_set_caps()
1276 xcamsrc->gst_video_info = info; in gst_xcam_src_set_caps()
1278 for (uint32_t n = 0; n < GST_VIDEO_INFO_N_PLANES (&xcamsrc->gst_video_info); n++) { in gst_xcam_src_set_caps()
1279 GST_VIDEO_INFO_PLANE_OFFSET (&xcamsrc->gst_video_info, n) = offset; in gst_xcam_src_set_caps()
1281 … GST_VIDEO_INFO_PLANE_STRIDE (&xcamsrc->gst_video_info, n) = format.fmt.pix.bytesperline * 2 / 3; in gst_xcam_src_set_caps()
1285 GST_VIDEO_INFO_PLANE_STRIDE (&xcamsrc->gst_video_info, n) = format.fmt.pix.bytesperline; in gst_xcam_src_set_caps()
1288 … GST_VIDEO_INFO_PLANE_STRIDE (&xcamsrc->gst_video_info, n) = format.fmt.pix.bytesperline / 2; in gst_xcam_src_set_caps()
1290 offset += GST_VIDEO_INFO_PLANE_STRIDE (&xcamsrc->gst_video_info, n) * format.fmt.pix.height; in gst_xcam_src_set_caps()
1295xcamsrc->xcam_video_info.init (out_format, GST_VIDEO_INFO_WIDTH (&info), GST_VIDEO_INFO_HEIGHT (&… in gst_xcam_src_set_caps()
1297 xcamsrc->duration = gst_util_uint64_scale_int ( in gst_xcam_src_set_caps()
1299 GST_VIDEO_INFO_FPS_D(&xcamsrc->gst_video_info), in gst_xcam_src_set_caps()
1300 GST_VIDEO_INFO_FPS_N(&xcamsrc->gst_video_info)); in gst_xcam_src_set_caps()
1301 xcamsrc->pool = gst_xcam_buffer_pool_new (xcamsrc, caps, xcamsrc->device_manager); in gst_xcam_src_set_caps()
1309 GstXCamSrc *xcamsrc = GST_XCAM_SRC (src); in gst_xcam_src_decide_allocation() local
1313 XCAM_ASSERT (xcamsrc); in gst_xcam_src_decide_allocation()
1314 XCAM_ASSERT (xcamsrc->pool); in gst_xcam_src_decide_allocation()
1322 if (pool == xcamsrc->pool) in gst_xcam_src_decide_allocation()
1329 query, xcamsrc->pool, in gst_xcam_src_decide_allocation()
1330 GST_VIDEO_INFO_WIDTH (&xcamsrc->gst_video_info), in gst_xcam_src_decide_allocation()
1331 GST_XCAM_SRC_BUF_COUNT (xcamsrc), in gst_xcam_src_decide_allocation()
1332 GST_XCAM_SRC_BUF_COUNT (xcamsrc)); in gst_xcam_src_decide_allocation()
1341 GstXCamSrc *xcamsrc = GST_XCAM_SRC (src); in gst_xcam_src_alloc() local
1346 ret = gst_buffer_pool_acquire_buffer (xcamsrc->pool, buffer, NULL); in gst_xcam_src_alloc()
1717 gst_xcam_src_plugin_init (GstPlugin * xcamsrc) in gst_xcam_src_plugin_init() argument
1719 return gst_element_register (xcamsrc, "xcamsrc", GST_RANK_NONE, in gst_xcam_src_plugin_init()
1730 xcamsrc,