tree: ce686c29c0c13bf1604f74ae8099d7005f0e1d36 [path history] [tgz]
  1. resources/
  2. detected-boundingBox-read-only.https.html
  3. detection-getSupportedFormats.https.html
  4. detection-HTMLCanvasElement.https.html
  5. detection-HTMLImageElement.https.html
  6. detection-HTMLVideoElement.https.html
  7. detection-ImageBitmap.https.html
  8. detection-ImageData-detached.https.html
  9. detection-ImageData.https.html
  10. detection-on-worker.https.worker.js
  11. detection-options.https.html
  12. detection-security-test.https.html
  13. detector-same-object.https.html
  14. idlharness.https.any-expected.txt
  15. idlharness.https.any.js
  16. idlharness.https.any.serviceworker-expected.txt
  17. idlharness.https.any.sharedworker-expected.txt
  18. idlharness.https.any.worker-expected.txt
  19. META.yml
  20. README.md
  21. shapedetection-cross-origin.sub.https.html
  22. shapedetection-empty-input.https.html
third_party/blink/web_tests/external/wpt/shape-detection/README.md

The shapedetection-helpers.js tests require implementations of the FaceDetectionTest and BarcodeDetectionTest interfaces, which should emulate platform shape detection backends.

The FaceDetectionTest interface is defined as:

  class FaceDetectionTest {
    async initialize();  // Sets up the testing environment.
    async reset(); // Frees the resources.
    MockFaceDetectionProvider(); //Returns `MockFaceDetectionProvider` interface.
  };

  class MockFaceDetectionProvider {
    getFrameData(); //Gets frame data of detection result.
    getMaxDetectedFaces(); //Gets value of `maxDetectedFaces` in `FaceDetector` constructor
    getFastMode(); //Gets value of `fastMode` in `FaceDetector` constructor
  };

The Chromium implementation of the FaceDetectionTest interface is located in mock-facedetection.js.

The BarcodeDetectionTest interface is defined as:

  class BarcodeDetectionTest {
    async initialize();  // Sets up the testing environment.
    async reset(); // Frees the resources.
    MockBarcodeDetectionProvider(); //Returns `MockBarcodeDetectionProvider` interface.
  };

  class MockBarcodeDetectionProvider {
    async enumerateSupportedFormats(); //Enumerates supported formats
    getFrameData(); //Gets frame data of detection result.
    getFormats(); //Gets value of `formats` in `BarcodeDetector` constructor
  };

The Chromium implementation of the BarcodeDetectionTest interface is located in mock-barcodedetection.js.

Other browser vendors should provide their own implementations of the FaceDetectionTest and BarcodeDetectionTest interfaces.