michael@0: michael@0: /* michael@0: * Copyright 2006 The Android Open Source Project michael@0: * michael@0: * Use of this source code is governed by a BSD-style license that can be michael@0: * found in the LICENSE file. michael@0: */ michael@0: michael@0: michael@0: #include "SkDrawLine.h" michael@0: #include "SkAnimateMaker.h" michael@0: #include "SkCanvas.h" michael@0: #include "SkPaint.h" michael@0: michael@0: #if SK_USE_CONDENSED_INFO == 0 michael@0: michael@0: const SkMemberInfo SkLine::fInfo[] = { michael@0: SK_MEMBER(x1, Float), michael@0: SK_MEMBER(x2, Float), michael@0: SK_MEMBER(y1, Float), michael@0: SK_MEMBER(y2, Float) michael@0: }; michael@0: michael@0: #endif michael@0: michael@0: DEFINE_GET_MEMBER(SkLine); michael@0: michael@0: SkLine::SkLine() : x1(0), x2(0), y1(0), y2(0) { michael@0: } michael@0: michael@0: bool SkLine::draw(SkAnimateMaker& maker) { michael@0: SkBoundableAuto boundable(this, maker); michael@0: maker.fCanvas->drawLine(x1, y1, x2, y2, *maker.fPaint); michael@0: return false; michael@0: }