Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(33)

Side by Side Diff: third_party/WebKit/Source/modules/shapedetection/ShapeDetector.h

Issue 2502763005: ShapeDetection: Add FaceDetectorOptions for fastMode and maxDetectedFaces (Closed)
Patch Set: 80 cols Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef ShapeDetector_h 5 #ifndef ShapeDetector_h
6 #define ShapeDetector_h 6 #define ShapeDetector_h
7 7
8 #include "bindings/core/v8/ScriptPromise.h" 8 #include "bindings/core/v8/ScriptPromise.h"
9 #include "bindings/core/v8/ScriptPromiseResolver.h" 9 #include "bindings/core/v8/ScriptPromiseResolver.h"
10 #include "modules/ModulesExport.h" 10 #include "modules/ModulesExport.h"
11 #include "modules/canvas2d/CanvasRenderingContext2D.h" 11 #include "modules/canvas2d/CanvasRenderingContext2D.h"
12 #include "modules/shapedetection/FaceDetectorOptions.h"
12 #include "public/platform/modules/shapedetection/shapedetection.mojom-blink.h" 13 #include "public/platform/modules/shapedetection/shapedetection.mojom-blink.h"
13 14
14 namespace blink { 15 namespace blink {
15 16
16 class LocalFrame; 17 class LocalFrame;
17 18
18 class MODULES_EXPORT ShapeDetector 19 class MODULES_EXPORT ShapeDetector
19 : public GarbageCollectedFinalized<ShapeDetector> { 20 : public GarbageCollectedFinalized<ShapeDetector> {
20 public: 21 public:
21 enum class DetectorType { 22 enum class DetectorType {
(...skipping 28 matching lines...) Expand all
50 int width, 51 int width,
51 int height); 52 int height);
52 void onDetectFaces(ScriptPromiseResolver*, 53 void onDetectFaces(ScriptPromiseResolver*,
53 mojom::blink::FaceDetectionResultPtr); 54 mojom::blink::FaceDetectionResultPtr);
54 void onDetectBarcodes(ScriptPromiseResolver*, 55 void onDetectBarcodes(ScriptPromiseResolver*,
55 Vector<mojom::blink::BarcodeDetectionResultPtr>); 56 Vector<mojom::blink::BarcodeDetectionResultPtr>);
56 57
57 mojom::blink::ShapeDetectionPtr m_service; 58 mojom::blink::ShapeDetectionPtr m_service;
58 59
59 HeapHashSet<Member<ScriptPromiseResolver>> m_serviceRequests; 60 HeapHashSet<Member<ScriptPromiseResolver>> m_serviceRequests;
61
62 protected:
63 mojom::blink::FaceDetectorOptionsPtr m_options;
60 }; 64 };
61 65
62 } // namespace blink 66 } // namespace blink
63 67
64 #endif // ShapeDetector_h 68 #endif // ShapeDetector_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698