MCPcopy Create free account
hub / github.com/KAlO2/PerfectShow / Hat

Class Hat

jni/stasm/hat.h:10–45  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

8namespace stasm
9{
10class Hat
11{
12public:
13 void Init_( // init the HAT internal grad mat and indices
14 const Image& img, // in: image ROI scaled to the current pyr lev
15 const int patchwidth); // in: patch will be patchwidth x patchwidth pixs
16
17 VEC Desc_( // return HAT descriptor, Init_ must be called first
18 const double x, // in: x coord of center of patch (may be off image)
19 const double y) // in: y coord of center of patch (may be off image)
20 const;
21
22 Hat() {} // constructor
23
24private:
25 // All these private variables are initialized by Hat::Init_. They must
26 // be initialized if the image changes or if the patch width changes.
27 // (In a Stasm context, that means they must be initialized once per
28 // pyramid level. Also, for safe use of OpenMP in SuggestShape_,
29 // they must not change unless the pyramid level changes.)
30
31 int patchwidth_; // image patch is patchwidth x patchwidth pixels
32
33 MAT magmat_; // grad mag of the current image (face ROI)
34 MAT orientmat_; // grad orient of the current image (face ROI)
35
36 vec_int row_indices_; // histogram indices: these map a patch row,col
37 vec_double row_fracs_; // to the corresponding histogram grid row,col
38 vec_int col_indices_;
39 vec_double col_fracs_;
40
41 vec_double pixelweights_; // weight pixel by closeness to center of patch
42
43 DISALLOW_COPY_AND_ASSIGN(Hat);
44
45}; // end class Hat
46
47} // namespace stasm
48#endif // STASM_HAT_H

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected