blob: e93b106702c1e361a2db44e2f495e4ee64e5d2a1 [file] [log] [blame]
epoger@google.comec3ed6a2011-07-28 14:26:00 +00001
2/*
3 * Copyright 2006 The Android Open Source Project
4 *
5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file.
7 */
8
reed@android.com8a1c16f2008-12-17 15:59:43 +00009
10#ifndef SkTypedArray_DEFINED
11#define SkTypedArray_DEFINED
12
13#include "SkScript.h"
14#include "SkTDArray_Experimental.h"
15
16class SkTypedArray : public SkTDOperandArray {
17public:
18 SkTypedArray();
19 SkTypedArray(SkDisplayTypes type);
20 bool getIndex(int index, SkOperand* operand);
21 SkDisplayTypes getType() { return fType; }
22 SkScriptEngine::SkOpType getOpType() { return SkScriptEngine::ToOpType(fType); }
rmistry@google.comd6176b02012-08-23 18:14:13 +000023 void setType(SkDisplayTypes type) {
reed@android.com8a1c16f2008-12-17 15:59:43 +000024 // SkASSERT(count() == 0);
25 fType = type;
26 }
27protected:
28 SkDisplayTypes fType;
29};
30
31#endif // SkTypedArray_DEFINED