| 60 | } |
| 61 | |
| 62 | CCamera* CCameraEnum::getCamera(int driverId, int camId, unsigned int width, unsigned int height, float frameRate) |
| 63 | { |
| 64 | if (camId>= getNumDevices(driverId)) return NULL; |
| 65 | |
| 66 | try{ |
| 67 | if (driverId == CAMERA_CV_ID) { |
| 68 | return new CCameraCV(camId, width, height, frameRate); |
| 69 | } |
| 70 | else { |
| 71 | return new NATIVE_CAM_CLASS(camId, width, height, frameRate); |
| 72 | } |
| 73 | } |
| 74 | catch (camera_exception &e) { |
| 75 | slog_write (SLOG_PRIO_ERR, "error initializing camera: %s\n", e.what()); |
| 76 | } |
| 77 | |
| 78 | return NULL; |
| 79 | } |
| 80 |
nothing calls this directly
no outgoing calls
no test coverage detected