Pipe factory names independently from the flattenables using them.
authorscroggo@google.com <scroggo@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>
Wed, 1 Aug 2012 19:34:20 +0000 (19:34 +0000)
committerscroggo@google.com <scroggo@google.com@2bbb7eff-a529-9590-31e7-b0007b416f81>
Wed, 1 Aug 2012 19:34:20 +0000 (19:34 +0000)
commit0c3e5fe728ce4b8606819ee919a4b82f4d9efc85
tree137ba2eb2fa061cfc29e737f1d98de8605675c3f
parent4605a3f3ff8fa2072f98e6bcb71bc43d4c6196d6
Pipe factory names independently from the flattenables using them.

Avoids an issue where a flattenable written twice might be written
differently (the first time the flat data may have a name, whereas
the second time it will have an index).

Also add a test which confirms that identical flattenables will have
the same SkFlatData representation.

BUG=https://code.google.com/p/skia/issues/detail?id=721
TEST=FlatDataTest.cpp

Review URL: https://codereview.appspot.com/6431057

git-svn-id: http://skia.googlecode.com/svn/trunk@4896 2bbb7eff-a529-9590-31e7-b0007b416f81
12 files changed:
gyp/tests.gyp
include/core/SkFlattenable.h
include/pipe/SkGPipe.h
src/core/SkFlattenable.cpp
src/core/SkOrderedReadBuffer.cpp
src/core/SkOrderedWriteBuffer.cpp
src/core/SkPictureFlat.cpp
src/core/SkPictureFlat.h
src/pipe/SkGPipePriv.h
src/pipe/SkGPipeRead.cpp
src/pipe/SkGPipeWrite.cpp
tests/FlatDataTest.cpp [new file with mode: 0644]