| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "mojo/services/gfx/composition/cpp/formatting.h" | 5 #include "mojo/services/gfx/composition/cpp/formatting.h" |
| 6 | 6 |
| 7 #include <ostream> | 7 #include <ostream> |
| 8 | 8 |
| 9 namespace mojo { | 9 namespace mojo { |
| 10 namespace gfx { | 10 namespace gfx { |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 73 | 73 |
| 74 std::ostream& operator<<(std::ostream& os, | 74 std::ostream& operator<<(std::ostream& os, |
| 75 const mojo::gfx::composition::SceneResource& value) { | 75 const mojo::gfx::composition::SceneResource& value) { |
| 76 return os << "{scene_token=" << value.scene_token << "}"; | 76 return os << "{scene_token=" << value.scene_token << "}"; |
| 77 } | 77 } |
| 78 | 78 |
| 79 std::ostream& operator<<( | 79 std::ostream& operator<<( |
| 80 std::ostream& os, | 80 std::ostream& os, |
| 81 const mojo::gfx::composition::MailboxTextureResource& value) { | 81 const mojo::gfx::composition::MailboxTextureResource& value) { |
| 82 return os << "{sync_point=" << value.sync_point << ", size=" << value.size | 82 return os << "{sync_point=" << value.sync_point << ", size=" << value.size |
| 83 << "}"; | 83 << ", origin=" << &value.origin << "}"; |
| 84 } |
| 85 |
| 86 std::ostream& operator<<( |
| 87 std::ostream& os, |
| 88 const mojo::gfx::composition::MailboxTextureResource::Origin* value) { |
| 89 switch (*value) { |
| 90 case mojo::gfx::composition::MailboxTextureResource::Origin::TOP_LEFT: |
| 91 return os << "TOP_LEFT"; |
| 92 case mojo::gfx::composition::MailboxTextureResource::Origin::BOTTOM_LEFT: |
| 93 return os << "BOTTOM_LEFT"; |
| 94 default: |
| 95 return os << "???"; |
| 96 } |
| 84 } | 97 } |
| 85 | 98 |
| 86 std::ostream& operator<<(std::ostream& os, | 99 std::ostream& operator<<(std::ostream& os, |
| 87 const mojo::gfx::composition::Node& value) { | 100 const mojo::gfx::composition::Node& value) { |
| 88 os << "{"; | 101 os << "{"; |
| 89 Delimiter d(os); | 102 Delimiter d(os); |
| 90 if (value.content_transform) | 103 if (value.content_transform) |
| 91 d.Append() << "content_transform=" << value.content_transform; | 104 d.Append() << "content_transform=" << value.content_transform; |
| 92 if (value.content_clip) | 105 if (value.content_clip) |
| 93 d.Append() << "content_clip=" << value.content_clip; | 106 d.Append() << "content_clip=" << value.content_clip; |
| (...skipping 133 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 227 | 240 |
| 228 std::ostream& operator<<(std::ostream& os, | 241 std::ostream& operator<<(std::ostream& os, |
| 229 const mojo::gfx::composition::NodeHit& value) { | 242 const mojo::gfx::composition::NodeHit& value) { |
| 230 return os << "{node_id=" << value.node_id | 243 return os << "{node_id=" << value.node_id |
| 231 << ", intersection=" << value.intersection << "}"; | 244 << ", intersection=" << value.intersection << "}"; |
| 232 } | 245 } |
| 233 | 246 |
| 234 } // namespace composition | 247 } // namespace composition |
| 235 } // namespace gfx | 248 } // namespace gfx |
| 236 } // namespace mojo | 249 } // namespace mojo |
| OLD | NEW |