add index in getPixels for F16
authorreed <reed@google.com>
Thu, 14 Apr 2016 20:34:45 +0000 (13:34 -0700)
committerCommit bot <commit-bot@chromium.org>
Thu, 14 Apr 2016 20:34:45 +0000 (13:34 -0700)
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1888883003

Review URL: https://codereview.chromium.org/1888883003

src/core/SkLinearBitmapPipeline_sample.h

index d436e393996db035a77344e0d8fb4da0ce175abd..539ce006156e6714d46e78159b37c5d731e6dc42 100644 (file)
@@ -777,7 +777,7 @@ public:
     }
 
     Sk4f getPixelAt(const void* vsrc, int index) {
-        const uint64_t* src = static_cast<const uint64_t*>(vsrc);
+        const uint64_t* src = static_cast<const uint64_t*>(vsrc) + index;
         return SkHalfToFloat_01(*src);
     }