summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Expand)Author
2020-03-24qcam: viewfinder: Reorder methods to match header fileLaurent Pinchart
2020-03-24qcam: viewfinder: Use PixelFormat default constructorLaurent Pinchart
2020-03-24qcam: viewfinder: Embed QImage in ViewFinderLaurent Pinchart
2020-03-24qcam: viewfinder: Make the viewfinder hold a reference to a bufferLaurent Pinchart
2020-03-24qcam: viewfinder: Move multi-planar check into viewfinderLaurent Pinchart
2020-03-24qcam: viewfinder: Add MappedBuffer to store memory mapping informationLaurent Pinchart
2020-03-24qcam: Use Qt qInfo() and qWarning() logging facilitiesLaurent Pinchart
2020-03-24qcam: main_window: Remove unneeded debug messageLaurent Pinchart
2020-03-24qcam: main_window: Document functions and reorganize member dataLaurent Pinchart
2020-03-24qcam: main_window: Don't print message when saving a pictureLaurent Pinchart
2020-03-24qcam: main_window: Add shortcuts for toolbar actionsLaurent Pinchart
2020-03-24qcam: main_window: Use icons from system icon themeLaurent Pinchart
2020-03-24qcam: main_window: Replace start and stop actions with a toggle actionLaurent Pinchart
2020-03-24qcam: main_window: Move capture event processing to main threadLaurent Pinchart
2020-03-24qcam: main_window: Move request queuing to a separate functionLaurent Pinchart
2020-03-24qcam: Use QSize through the code baseLaurent Pinchart
2020-03-24qcam: Ensure headers are self-containedLaurent Pinchart
2020-03-24qcam: Remove custom event dispatcherLaurent Pinchart
2020-03-24libcamera: v4l2_videodevice: Add support for all 32-bit ARGB formatsLaurent Pinchart
2020-03-24cam: main: Cache lookup of role propertyLaurent Pinchart
2020-03-23libcamera: v4l2_device: Enable enumeration of U8 controlsJacopo Mondi
2020-03-23libcamera: v4l2_controls: Support U8 array controlsJacopo Mondi
2020-03-23libcamera: v4l2_device: Support reading U8 array controlsJacopo Mondi
2020-03-23libcamera: v4l2_device: Support writing array U8 controlsJacopo Mondi
2020-03-23libcamera: v4l2_controls: Cache query control informationJacopo Mondi
2020-03-23libcamera: controls: Add zero-copy set API for ControlValueLaurent Pinchart
2020-03-23libcamera: device_enumerator: Convey device ownership through unique_ptrLaurent Pinchart
2020-03-23libcamera: device_enumerator_udev: Update pending list in addUdevDeviceLaurent Pinchart
2020-03-23libcamera: thread: Order headers alphabeticallyLaurent Pinchart
2020-03-23libcamera: device_enumerator_udev: Don't add media device twiceLaurent Pinchart
2020-03-23Revert "libcamera: controls: Don't over-optimize ControlValue layout"Laurent Pinchart
2020-03-21libcamera: device_enumerator: Remove '\todo' as it is completedKaaira Gupta
2020-03-20libcamera: controls: Don't over-optimize ControlValue layoutLaurent Pinchart
2020-03-20libcamera: controls: Move ControlValue size check to controls.cppLaurent Pinchart
2020-03-20libcamera: controls: Add support for string controlsLaurent Pinchart
2020-03-20libcamera: controls: Rename ControlRange to ControlInfoLaurent Pinchart
2020-03-20libcamera: controls: Name all ControlInfoMap instance variables infoMapLaurent Pinchart
2020-03-20cam: Print one property per lineJacopo Mondi
2020-03-20libcamera: v4l2_controls: Fix usage of strerror()Jacopo Mondi
2020-03-20libcamera: pipeline: rkisp1: Don't enable immutable linkHelen Koike
2020-03-20libcamera: pipeline: rkisp1: Use correct buffer count when importing buffersNiklas Söderlund
2020-03-19libcamera: utils: Adapt libcameraPath to match use casesKaaira Gupta
2020-03-19libcamera: v4l2_videodevice: Make V4L2PixelFormat constructor explicitLaurent Pinchart
2020-03-19libcamera: v4l2_videodevice: Rename toV4L2Fourcc to toV4L2PixelFormatLaurent Pinchart
2020-03-19libcamera: v4l2_videodevice: Add V4L2PixelFormat classLaurent Pinchart
2020-03-19qcam: saveImageAs: Set image quality explicitlyKieran Bingham
2020-03-19libcamera: geometry: Construct SizeRange from SizeLaurent Pinchart
2020-03-18libcamera: framebuffer_allocator: Lift camera restrictions on allocatorLaurent Pinchart
2020-03-18libcamera: pipeline_handler: Fold buffer management with start/stopLaurent Pinchart
2020-03-18libcamera: pipeline_handler: Decouple buffer import and exportLaurent Pinchart
/span> cerr << "Expected: '" << v4l2FmtExpect.toString() << "' got: '" << v4l2Fmt.toString() << "'" << endl; return TestFail; } /* * Use an empty Bayer format and verify that no matching * V4L2PixelFormat is found. */ v4l2FmtExpect = V4L2PixelFormat(); bayerFmt = BayerFormat(); v4l2Fmt = bayerFmt.toV4L2PixelFormat(); if (v4l2Fmt != v4l2FmtExpect) { cerr << "Expected: empty V4L2PixelFormat got: '" << v4l2Fmt.toString() << "'" << endl; return TestFail; } /* * Check if we get the expected Bayer format BGGR8 * when we convert the V4L2PixelFormat (V4L2_PIX_FMT_SBGGR8) * to a Bayer format. */ bayerFmtExpect = BayerFormat(BayerFormat::BGGR, 8, BayerFormat::None); v4l2Fmt = V4L2PixelFormat(V4L2_PIX_FMT_SBGGR8); bayerFmt = BayerFormat::fromV4L2PixelFormat(v4l2Fmt); if (bayerFmt != bayerFmtExpect) { cerr << "Expected BayerFormat '" << bayerFmtExpect.toString() << "', got: '" << bayerFmt.toString() << "'" << endl; return TestFail; } /* * Confirm that a V4L2PixelFormat that is not found in * the conversion table, doesn't yield a Bayer format. */ V4L2PixelFormat v4l2FmtUnknown = V4L2PixelFormat( V4L2_PIX_FMT_BGRA444); bayerFmt = BayerFormat::fromV4L2PixelFormat(v4l2FmtUnknown); if (bayerFmt.isValid()) { cerr << "Expected empty BayerFormat got: '" << bayerFmt.toString() << "'" << endl; return TestFail; } /* * Test if a valid Bayer format can be converted to a * string representation. */ bayerFmt = BayerFormat(BayerFormat::BGGR, 8, BayerFormat::None); if (bayerFmt.toString() != "BGGR-8") { cerr << "String representation != 'BGGR-8' (got: '" << bayerFmt.toString() << "' ) " << endl; return TestFail; } /* * Determine if an empty Bayer format results in no * string representation. */ bayerFmt = BayerFormat(); if (bayerFmt.toString() != "INVALID") { cerr << "String representation != 'INVALID' (got: '" << bayerFmt.toString() << "' ) " << endl; return TestFail; } /* * Perform a horizontal Flip and make sure that the * order is adjusted accordingly. */ bayerFmt = BayerFormat(BayerFormat::BGGR, 8, BayerFormat::None); bayerFmtExpect = BayerFormat(BayerFormat::GBRG, 8, BayerFormat::None); BayerFormat hFlipFmt = bayerFmt.transform(Transform::HFlip); if (hFlipFmt != bayerFmtExpect) { cerr << "Horizontal flip of 'BGGR-8' should result in '" << bayerFmtExpect.toString() << "', got: '" << hFlipFmt.toString() << "'" << endl; return TestFail; } /* * Perform a vertical Flip and make sure that * the order is adjusted accordingly. */ bayerFmt = BayerFormat(BayerFormat::BGGR, 8, BayerFormat::None); bayerFmtExpect = BayerFormat(BayerFormat::GRBG, 8, BayerFormat::None); BayerFormat vFlipFmt = bayerFmt.transform(Transform::VFlip); if (vFlipFmt != bayerFmtExpect) { cerr << "Vertical flip of 'BGGR-8' should result in '" << bayerFmtExpect.toString() << "', got: '" << vFlipFmt.toString() << "'" << endl; return TestFail; } /* * Perform a transposition on a pixel order with both green * pixels on the bottom left to top right diagonal and make * sure, that it doesn't change. */ bayerFmt = BayerFormat(BayerFormat::BGGR, 8, BayerFormat::None); BayerFormat transposeFmt = bayerFmt.transform( Transform::Transpose); if (transposeFmt != bayerFmt) { cerr << "Transpose with both green pixels on the " << "antidiagonal should not change the order " << "(got '" << transposeFmt.toString() << "')" << endl; return TestFail; } /* * Perform a transposition on an pixel order with red and blue * on the bottom left to top right diagonal and make sure * that their positions are switched. */ bayerFmt = BayerFormat(BayerFormat::GBRG, 8, BayerFormat::None); bayerFmtExpect = BayerFormat(BayerFormat::GRBG, 8, BayerFormat::None); transposeFmt = bayerFmt.transform(Transform::Transpose); if (transposeFmt != bayerFmtExpect) { cerr << "Transpose with the red & blue pixels on the " << "antidiagonal should switch their position " << "(got '" << transposeFmt.toString() << "')" << endl; return TestFail; } return TestPass; } }; TEST_REGISTER(BayerFormatTest)