diff options
author | John Reck <jreck@google.com> | 2018-04-09 09:41:29 -0700 |
---|---|---|
committer | John Reck <jreck@google.com> | 2018-04-09 14:50:40 -0700 |
commit | 617673f83f30a36eecd429df586e5ef6598116e1 (patch) | |
tree | da52e88529e4e5e992243483431003d87fc73684 /libs/hwui/RenderNode.cpp | |
parent | 325f7284d9b45d1a673b69dc8bf64d4d33b32305 (diff) |
Remove dead code
Remove an old protobuf serialization experiement, skp capture
does this better
Test: builds
Change-Id: Icd875eabee6b517729f901841e48e579d0e8de4d
Diffstat (limited to 'libs/hwui/RenderNode.cpp')
-rw-r--r-- | libs/hwui/RenderNode.cpp | 74 |
1 files changed, 0 insertions, 74 deletions
diff --git a/libs/hwui/RenderNode.cpp b/libs/hwui/RenderNode.cpp index d93a7578cfd7..5ac330bcadb8 100644 --- a/libs/hwui/RenderNode.cpp +++ b/libs/hwui/RenderNode.cpp @@ -29,9 +29,6 @@ #include "utils/StringUtils.h" #include "utils/TraceUtils.h" -#include "protos/ProtoHelpers.h" -#include "protos/hwui.pb.h" - #include <SkPathOps.h> #include <algorithm> #include <sstream> @@ -101,77 +98,6 @@ void RenderNode::output(std::ostream& output, uint32_t level) { output << std::endl; } -void RenderNode::copyTo(proto::RenderNode* pnode) { - pnode->set_id(static_cast<uint64_t>(reinterpret_cast<uintptr_t>(this))); - pnode->set_name(mName.string(), mName.length()); - - proto::RenderProperties* pprops = pnode->mutable_properties(); - pprops->set_left(properties().getLeft()); - pprops->set_top(properties().getTop()); - pprops->set_right(properties().getRight()); - pprops->set_bottom(properties().getBottom()); - pprops->set_clip_flags(properties().getClippingFlags()); - pprops->set_alpha(properties().getAlpha()); - pprops->set_translation_x(properties().getTranslationX()); - pprops->set_translation_y(properties().getTranslationY()); - pprops->set_translation_z(properties().getTranslationZ()); - pprops->set_elevation(properties().getElevation()); - pprops->set_rotation(properties().getRotation()); - pprops->set_rotation_x(properties().getRotationX()); - pprops->set_rotation_y(properties().getRotationY()); - pprops->set_scale_x(properties().getScaleX()); - pprops->set_scale_y(properties().getScaleY()); - pprops->set_pivot_x(properties().getPivotX()); - pprops->set_pivot_y(properties().getPivotY()); - pprops->set_has_overlapping_rendering(properties().getHasOverlappingRendering()); - pprops->set_pivot_explicitly_set(properties().isPivotExplicitlySet()); - pprops->set_project_backwards(properties().getProjectBackwards()); - pprops->set_projection_receiver(properties().isProjectionReceiver()); - set(pprops->mutable_clip_bounds(), properties().getClipBounds()); - - const Outline& outline = properties().getOutline(); - if (outline.getType() != Outline::Type::None) { - proto::Outline* poutline = pprops->mutable_outline(); - poutline->clear_path(); - if (outline.getType() == Outline::Type::Empty) { - poutline->set_type(proto::Outline_Type_Empty); - } else if (outline.getType() == Outline::Type::ConvexPath) { - poutline->set_type(proto::Outline_Type_ConvexPath); - if (const SkPath* path = outline.getPath()) { - set(poutline->mutable_path(), *path); - } - } else if (outline.getType() == Outline::Type::RoundRect) { - poutline->set_type(proto::Outline_Type_RoundRect); - } else { - ALOGW("Uknown outline type! %d", static_cast<int>(outline.getType())); - poutline->set_type(proto::Outline_Type_None); - } - poutline->set_should_clip(outline.getShouldClip()); - poutline->set_alpha(outline.getAlpha()); - poutline->set_radius(outline.getRadius()); - set(poutline->mutable_bounds(), outline.getBounds()); - } else { - pprops->clear_outline(); - } - - const RevealClip& revealClip = properties().getRevealClip(); - if (revealClip.willClip()) { - proto::RevealClip* prevealClip = pprops->mutable_reveal_clip(); - prevealClip->set_x(revealClip.getX()); - prevealClip->set_y(revealClip.getY()); - prevealClip->set_radius(revealClip.getRadius()); - } else { - pprops->clear_reveal_clip(); - } - - pnode->clear_children(); - if (mDisplayList) { - for (auto&& child : mDisplayList->getChildren()) { - child->renderNode->copyTo(pnode->add_children()); - } - } -} - int RenderNode::getDebugSize() { int size = sizeof(RenderNode); if (mStagingDisplayList) { |