aboutsummaryrefslogtreecommitdiffhomepage
path: root/experimental/FileReaderApp/ReaderView.h
blob: 3f61eb80871bb9c4870cb9beece3fb527ae270cd (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29

/*
 * Copyright 2011 Google Inc.
 *
 * Use of this source code is governed by a BSD-style license that can be
 * found in the LICENSE file.
 */
#include "SkView.h"
#include "SkColor.h"
#include "SkBitmap.h"

/*
 * Pipe Reader with File IO. This view reads from the data file produced by the
 * Pipe Writer.
 */

class ReaderView : public SkView {
public:
    ReaderView();
    virtual void draw(SkCanvas* canvas);

private:
    int     fFilePos;
    int     fFront;
    int     fBack;
    SkColor fBGColor;
    SkBitmap fBufferBitmaps[2];
    typedef SkView INHERITED;
};