Sk2DPathEffect: it was encoding a partially-unintialized matrix type mask.
The others are simply uninitialized vars in the sample code.
Review URL: http://codereview.appspot.com/4539072/
git-svn-id: http://skia.googlecode.com/svn/trunk@1414
2bbb7eff-a529-9590-31e7-
b0007b416f81
bool fDoAA;
public:
HairlineView() {
+ fCounter = 0;
fProcIndex = 0;
fDoAA = true;
fNow = 0;
LineClipperView() {
fProcIndex = 0;
fCounter = 0;
+ fNow = 0;
int x = (640 - W)/2;
int y = (480 - H)/2;
}
SkFlatMatrix* SkFlatMatrix::Flatten(SkChunkAlloc* heap, const SkMatrix& matrix, int index) {
- int32_t size = sizeof(SkMatrix);
+ size_t size = matrix.flatten(NULL);
SkFlatMatrix* result = (SkFlatMatrix*) INHERITED::Alloc(heap, size, index);
- memcpy(&result->fMatrixData, &matrix, sizeof(SkMatrix));
+ matrix.flatten(&result->fMatrixData);
return result;
}