| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 "services/media/framework_mojo/mojo_formatting.h" | 5 #include "services/media/framework_mojo/mojo_formatting.h" |
| 6 | 6 |
| 7 namespace mojo { | 7 namespace mojo { |
| 8 namespace media { | 8 namespace media { |
| 9 | 9 |
| 10 template<typename T> | 10 template <typename T> |
| 11 std::ostream& operator<<(std::ostream& os, const InterfacePtr<T>& value) { | 11 std::ostream& operator<<(std::ostream& os, const InterfacePtr<T>& value) { |
| 12 if (!value.is_bound()) { | 12 if (!value.is_bound()) { |
| 13 return os << "<not bound>" << std::endl; | 13 return os << "<not bound>" << std::endl; |
| 14 } else { | 14 } else { |
| 15 return os << "<bound>" << std::endl; | 15 return os << "<bound>" << std::endl; |
| 16 } | 16 } |
| 17 } | 17 } |
| 18 | 18 |
| 19 std::ostream& operator<<( | 19 std::ostream& operator<<(std::ostream& os, |
| 20 std::ostream& os, | 20 const MediaSourceStreamDescriptorPtr& value) { |
| 21 const MediaSourceStreamDescriptorPtr& value) { | |
| 22 if (!value) { | 21 if (!value) { |
| 23 return os << "<nullptr>" << std::endl; | 22 return os << "<nullptr>" << std::endl; |
| 24 } else { | 23 } else { |
| 25 os << std::endl; | 24 os << std::endl; |
| 26 } | 25 } |
| 27 | 26 |
| 28 os << indent; | 27 os << indent; |
| 29 os << begl << "uint32_t index: " << int(value->index) << std::endl; | 28 os << begl << "uint32_t index: " << int(value->index) << std::endl; |
| 30 os << begl << "MediaTypePtr media_type: " << value->media_type; | 29 os << begl << "MediaTypePtr media_type: " << value->media_type; |
| 31 os << begl << "MediaTypePtr original_media_type: " << | 30 os << begl |
| 32 value->original_media_type; | 31 << "MediaTypePtr original_media_type: " << value->original_media_type; |
| 33 return os << outdent; | 32 return os << outdent; |
| 34 } | 33 } |
| 35 | 34 |
| 36 std::ostream& operator<<(std::ostream& os, const MediaTypePtr& value) { | 35 std::ostream& operator<<(std::ostream& os, const MediaTypePtr& value) { |
| 37 if (!value) { | 36 if (!value) { |
| 38 return os << "<nullptr>" << std::endl; | 37 return os << "<nullptr>" << std::endl; |
| 39 } else { | 38 } else { |
| 40 os << std::endl; | 39 os << std::endl; |
| 41 } | 40 } |
| 42 | 41 |
| 43 os << indent; | 42 os << indent; |
| 44 os << begl << "MediaTypeScheme scheme: " << | 43 os << begl |
| 45 StringFromMediaTypeScheme(value->scheme) << std::endl; | 44 << "MediaTypeScheme scheme: " << StringFromMediaTypeScheme(value->scheme) |
| 45 << std::endl; |
| 46 os << begl << "MediaTypeDetailsPtr details: " << value->details; | 46 os << begl << "MediaTypeDetailsPtr details: " << value->details; |
| 47 return os << outdent; | 47 return os << outdent; |
| 48 } | 48 } |
| 49 | 49 |
| 50 std::ostream& operator<<(std::ostream& os, const MediaTypeSetPtr& value) { | 50 std::ostream& operator<<(std::ostream& os, const MediaTypeSetPtr& value) { |
| 51 if (!value) { | 51 if (!value) { |
| 52 return os << "<nullptr>" << std::endl; | 52 return os << "<nullptr>" << std::endl; |
| 53 } else { | 53 } else { |
| 54 os << std::endl; | 54 os << std::endl; |
| 55 } | 55 } |
| 56 | 56 |
| 57 os << indent; | 57 os << indent; |
| 58 os << begl << "MediaTypeScheme scheme: " << | 58 os << begl |
| 59 StringFromMediaTypeScheme(value->scheme) << std::endl; | 59 << "MediaTypeScheme scheme: " << StringFromMediaTypeScheme(value->scheme) |
| 60 << std::endl; |
| 60 os << begl << "MediaTypeSetDetailsPtr details: " << value->details; | 61 os << begl << "MediaTypeSetDetailsPtr details: " << value->details; |
| 61 return os << outdent; | 62 return os << outdent; |
| 62 } | 63 } |
| 63 | 64 |
| 64 std::ostream& operator<<(std::ostream& os, const MediaTypeDetailsPtr& value) { | 65 std::ostream& operator<<(std::ostream& os, const MediaTypeDetailsPtr& value) { |
| 65 if (!value) { | 66 if (!value) { |
| 66 return os << "<nullptr>" << std::endl; | 67 return os << "<nullptr>" << std::endl; |
| 67 } else if (value->has_unknown_tag()) { | 68 } else if (value->has_unknown_tag()) { |
| 68 return os << "<empty>" << std::endl; | 69 return os << "<empty>" << std::endl; |
| 69 } else { | 70 } else { |
| 70 os << std::endl; | 71 os << std::endl; |
| 71 } | 72 } |
| 72 | 73 |
| 73 os << indent; | 74 os << indent; |
| 74 if (value->is_multiplexed()) { | 75 if (value->is_multiplexed()) { |
| 75 return os << begl << "MultiplexedMediaTypeDetailsPtr* multiplexed: " << | 76 return os << begl << "MultiplexedMediaTypeDetailsPtr* multiplexed: " |
| 76 value->get_multiplexed() << outdent; | 77 << value->get_multiplexed() << outdent; |
| 77 } | 78 } |
| 78 if (value->is_lpcm()) { | 79 if (value->is_lpcm()) { |
| 79 return os << begl << "LpcmMediaTypeDetailsPtr* lpcm: " << | 80 return os << begl << "LpcmMediaTypeDetailsPtr* lpcm: " << value->get_lpcm() |
| 80 value->get_lpcm() << outdent; | 81 << outdent; |
| 81 } | 82 } |
| 82 if (value->is_compressed_audio()) { | 83 if (value->is_compressed_audio()) { |
| 83 return os << begl << | 84 return os << begl |
| 84 "CompressedAudiomMediaTypeDetailsPtr* compressed_audio: " << | 85 << "CompressedAudiomMediaTypeDetailsPtr* compressed_audio: " |
| 85 value->get_compressed_audio() << outdent; | 86 << value->get_compressed_audio() << outdent; |
| 86 } | 87 } |
| 87 if (value->is_video()) { | 88 if (value->is_video()) { |
| 88 return os << begl << "VideoMediaTypeDetailsPtr* video: " << | 89 return os << begl |
| 89 value->get_video() << outdent; | 90 << "VideoMediaTypeDetailsPtr* video: " << value->get_video() |
| 91 << outdent; |
| 90 } | 92 } |
| 91 return os << begl << "UNKNOWN TAG" << std::endl << outdent; | 93 return os << begl << "UNKNOWN TAG" << std::endl << outdent; |
| 92 } | 94 } |
| 93 | 95 |
| 94 std::ostream& operator<<( | 96 std::ostream& operator<<(std::ostream& os, |
| 95 std::ostream& os, | 97 const MediaTypeSetDetailsPtr& value) { |
| 96 const MediaTypeSetDetailsPtr& value) { | |
| 97 if (!value) { | 98 if (!value) { |
| 98 return os << "<nullptr>" << std::endl; | 99 return os << "<nullptr>" << std::endl; |
| 99 } else if (value->has_unknown_tag()) { | 100 } else if (value->has_unknown_tag()) { |
| 100 return os << "<empty>" << std::endl; | 101 return os << "<empty>" << std::endl; |
| 101 } else { | 102 } else { |
| 102 os << std::endl; | 103 os << std::endl; |
| 103 } | 104 } |
| 104 | 105 |
| 105 os << indent; | 106 os << indent; |
| 106 if (value->is_multiplexed()) { | 107 if (value->is_multiplexed()) { |
| 107 return os << begl << "MultiplexedMediaTypeSetDetailsPtr* multiplexed: " << | 108 return os << begl << "MultiplexedMediaTypeSetDetailsPtr* multiplexed: " |
| 108 value->get_multiplexed() << outdent; | 109 << value->get_multiplexed() << outdent; |
| 109 } | 110 } |
| 110 if (value->is_lpcm()) { | 111 if (value->is_lpcm()) { |
| 111 return os << begl << "LpcmMediaTypeSetDetailsPtr* lpcm: " << | 112 return os << begl |
| 112 value->get_lpcm() << outdent; | 113 << "LpcmMediaTypeSetDetailsPtr* lpcm: " << value->get_lpcm() |
| 114 << outdent; |
| 113 } | 115 } |
| 114 if (value->is_compressed_audio()) { | 116 if (value->is_compressed_audio()) { |
| 115 return os << begl << | 117 return os << begl |
| 116 "CompressedAudioMediaTypeSetDetailsPtr* compressed_audio: " << | 118 << "CompressedAudioMediaTypeSetDetailsPtr* compressed_audio: " |
| 117 value->get_compressed_audio() << outdent; | 119 << value->get_compressed_audio() << outdent; |
| 118 } | 120 } |
| 119 if (value->is_video()) { | 121 if (value->is_video()) { |
| 120 return os << begl << "VideoMediaTypeSetDetailsPtr* video: " << | 122 return os << begl |
| 121 value->get_video() << outdent; | 123 << "VideoMediaTypeSetDetailsPtr* video: " << value->get_video() |
| 124 << outdent; |
| 122 } | 125 } |
| 123 return os << begl << "UNKNOWN TAG" << std::endl << outdent; | 126 return os << begl << "UNKNOWN TAG" << std::endl << outdent; |
| 124 } | 127 } |
| 125 | 128 |
| 126 std::ostream& operator<<( | 129 std::ostream& operator<<(std::ostream& os, |
| 127 std::ostream& os, | 130 const MultiplexedMediaTypeDetailsPtr& value) { |
| 128 const MultiplexedMediaTypeDetailsPtr& value) { | |
| 129 if (!value) { | 131 if (!value) { |
| 130 return os << "<nullptr>" << std::endl; | 132 return os << "<nullptr>" << std::endl; |
| 131 } else { | 133 } else { |
| 132 os << std::endl; | 134 os << std::endl; |
| 133 } | 135 } |
| 134 | 136 |
| 135 os << indent; | 137 os << indent; |
| 136 os << begl << "MediaTypePtr multiplex_type: " << value->multiplex_type; | 138 os << begl << "MediaTypePtr multiplex_type: " << value->multiplex_type; |
| 137 os << begl << "Array<MediaTypePtr> substream_types: " << | 139 os << begl |
| 138 value->substream_types; | 140 << "Array<MediaTypePtr> substream_types: " << value->substream_types; |
| 139 return os << outdent; | 141 return os << outdent; |
| 140 } | 142 } |
| 141 | 143 |
| 142 std::ostream& operator<<( | 144 std::ostream& operator<<(std::ostream& os, |
| 143 std::ostream& os, | 145 const MultiplexedMediaTypeSetDetailsPtr& value) { |
| 144 const MultiplexedMediaTypeSetDetailsPtr& value) { | |
| 145 if (!value) { | 146 if (!value) { |
| 146 return os << "<nullptr>" << std::endl; | 147 return os << "<nullptr>" << std::endl; |
| 147 } else { | 148 } else { |
| 148 os << std::endl; | 149 os << std::endl; |
| 149 } | 150 } |
| 150 | 151 |
| 151 os << indent; | 152 os << indent; |
| 152 os << begl << "MediaTypeSetPtr multiplex_type_set: " << | 153 os << begl |
| 153 value->multiplex_type_set; | 154 << "MediaTypeSetPtr multiplex_type_set: " << value->multiplex_type_set; |
| 154 os << begl << "Array<MediaTypeSetPtr> substream_type_sets: " << | 155 os << begl << "Array<MediaTypeSetPtr> substream_type_sets: " |
| 155 value->substream_type_sets; | 156 << value->substream_type_sets; |
| 156 return os << outdent; | 157 return os << outdent; |
| 157 } | 158 } |
| 158 | 159 |
| 159 std::ostream& operator<<( | 160 std::ostream& operator<<(std::ostream& os, |
| 160 std::ostream& os, | 161 const LpcmMediaTypeDetailsPtr& value) { |
| 161 const LpcmMediaTypeDetailsPtr& value) { | |
| 162 if (!value) { | 162 if (!value) { |
| 163 return os << "<nullptr>" << std::endl; | 163 return os << "<nullptr>" << std::endl; |
| 164 } else { | 164 } else { |
| 165 os << std::endl; | 165 os << std::endl; |
| 166 } | 166 } |
| 167 | 167 |
| 168 os << indent; | 168 os << indent; |
| 169 os << begl << "LpcmSampleFormat sample_format: " << | 169 os << begl << "LpcmSampleFormat sample_format: " |
| 170 StringFromLpcmSampleFormat(value->sample_format) << std::endl; | 170 << StringFromLpcmSampleFormat(value->sample_format) << std::endl; |
| 171 os << begl << "uint32_t channels: " << int(value->channels) << std::endl; | 171 os << begl << "uint32_t channels: " << int(value->channels) << std::endl; |
| 172 os << begl << "uint32_t frames_per_second: " << value->frames_per_second << | 172 os << begl << "uint32_t frames_per_second: " << value->frames_per_second |
| 173 std::endl; | 173 << std::endl; |
| 174 return os << outdent; | 174 return os << outdent; |
| 175 } | 175 } |
| 176 | 176 |
| 177 std::ostream& operator<<( | 177 std::ostream& operator<<(std::ostream& os, |
| 178 std::ostream& os, | 178 const LpcmMediaTypeSetDetailsPtr& value) { |
| 179 const LpcmMediaTypeSetDetailsPtr& value) { | |
| 180 if (!value) { | 179 if (!value) { |
| 181 return os << "<nullptr>" << std::endl; | 180 return os << "<nullptr>" << std::endl; |
| 182 } else { | 181 } else { |
| 183 os << std::endl; | 182 os << std::endl; |
| 184 } | 183 } |
| 185 | 184 |
| 186 os << indent; | 185 os << indent; |
| 187 os << begl << "LpcmSampleFormat sample_format: " << | 186 os << begl << "LpcmSampleFormat sample_format: " |
| 188 StringFromLpcmSampleFormat(value->sample_format) << std::endl; | 187 << StringFromLpcmSampleFormat(value->sample_format) << std::endl; |
| 189 os << begl << "uint32_t min_channels: " << int(value->min_channels) << | 188 os << begl << "uint32_t min_channels: " << int(value->min_channels) |
| 190 std::endl; | 189 << std::endl; |
| 191 os << begl << "uint32_t max_channels: " << int(value->max_channels) << | 190 os << begl << "uint32_t max_channels: " << int(value->max_channels) |
| 192 std::endl; | 191 << std::endl; |
| 193 os << begl << "uint32_t min_frames_per_second: " << | 192 os << begl |
| 194 value->min_frames_per_second << std::endl; | 193 << "uint32_t min_frames_per_second: " << value->min_frames_per_second |
| 195 os << begl << "uint32_t max_cframes_per_second: " << | 194 << std::endl; |
| 196 value->max_frames_per_second << std::endl; | 195 os << begl |
| 196 << "uint32_t max_cframes_per_second: " << value->max_frames_per_second |
| 197 << std::endl; |
| 197 return os << outdent; | 198 return os << outdent; |
| 198 } | 199 } |
| 199 | 200 |
| 200 std::ostream& operator<<( | 201 std::ostream& operator<<(std::ostream& os, |
| 201 std::ostream& os, | 202 const CompressedAudioMediaTypeDetailsPtr& value) { |
| 202 const CompressedAudioMediaTypeDetailsPtr& value) { | |
| 203 if (!value) { | 203 if (!value) { |
| 204 return os << "<nullptr>" << std::endl; | 204 return os << "<nullptr>" << std::endl; |
| 205 } else { | 205 } else { |
| 206 os << std::endl; | 206 os << std::endl; |
| 207 } | 207 } |
| 208 | 208 |
| 209 os << indent; | 209 os << indent; |
| 210 os << begl << "AudioEncoding encoding: " << | 210 os << begl |
| 211 StringFromAudioEncoding(value->encoding) << std::endl; | 211 << "AudioEncoding encoding: " << StringFromAudioEncoding(value->encoding) |
| 212 os << begl << "LpcmSampleFormat sample_format: " << | 212 << std::endl; |
| 213 StringFromLpcmSampleFormat(value->sample_format) << std::endl; | 213 os << begl << "LpcmSampleFormat sample_format: " |
| 214 << StringFromLpcmSampleFormat(value->sample_format) << std::endl; |
| 214 os << begl << "uint32_t channels: " << int(value->channels) << std::endl; | 215 os << begl << "uint32_t channels: " << int(value->channels) << std::endl; |
| 215 os << begl << "uint32_t frames_per_second: " << value->frames_per_second << | 216 os << begl << "uint32_t frames_per_second: " << value->frames_per_second |
| 216 std::endl; | 217 << std::endl; |
| 217 return os << outdent; | 218 return os << outdent; |
| 218 } | 219 } |
| 219 | 220 |
| 220 std::ostream& operator<<( | 221 std::ostream& operator<<(std::ostream& os, |
| 221 std::ostream& os, | 222 const CompressedAudioMediaTypeSetDetailsPtr& value) { |
| 222 const CompressedAudioMediaTypeSetDetailsPtr& value) { | |
| 223 if (!value) { | 223 if (!value) { |
| 224 return os << "<nullptr>" << std::endl; | 224 return os << "<nullptr>" << std::endl; |
| 225 } else { | 225 } else { |
| 226 os << std::endl; | 226 os << std::endl; |
| 227 } | 227 } |
| 228 | 228 |
| 229 os << indent; | 229 os << indent; |
| 230 os << begl << "AudioEncoding encoding: " << | 230 os << begl |
| 231 StringFromAudioEncoding(value->encoding) << std::endl; | 231 << "AudioEncoding encoding: " << StringFromAudioEncoding(value->encoding) |
| 232 os << begl << "LpcmSampleFormat sample_format: " << | 232 << std::endl; |
| 233 StringFromLpcmSampleFormat(value->sample_format) << std::endl; | 233 os << begl << "LpcmSampleFormat sample_format: " |
| 234 os << begl << "uint32_t min_channels: " << int(value->min_channels) << | 234 << StringFromLpcmSampleFormat(value->sample_format) << std::endl; |
| 235 std::endl; | 235 os << begl << "uint32_t min_channels: " << int(value->min_channels) |
| 236 os << begl << "uint32_t max_channels: " << int(value->max_channels) << | 236 << std::endl; |
| 237 std::endl; | 237 os << begl << "uint32_t max_channels: " << int(value->max_channels) |
| 238 os << begl << "uint32_t min_frames_per_second: " << | 238 << std::endl; |
| 239 value->min_frames_per_second << std::endl; | 239 os << begl |
| 240 os << begl << "uint32_t max_cframes_per_second: " << | 240 << "uint32_t min_frames_per_second: " << value->min_frames_per_second |
| 241 value->max_frames_per_second << std::endl; | 241 << std::endl; |
| 242 os << begl |
| 243 << "uint32_t max_cframes_per_second: " << value->max_frames_per_second |
| 244 << std::endl; |
| 242 return os << outdent; | 245 return os << outdent; |
| 243 } | 246 } |
| 244 | 247 |
| 245 std::ostream& operator<<( | 248 std::ostream& operator<<(std::ostream& os, |
| 246 std::ostream& os, | 249 const VideoMediaTypeDetailsPtr& value) { |
| 247 const VideoMediaTypeDetailsPtr& value) { | |
| 248 if (!value) { | 250 if (!value) { |
| 249 return os << "<nullptr>" << std::endl; | 251 return os << "<nullptr>" << std::endl; |
| 250 } else { | 252 } else { |
| 251 os << std::endl; | 253 os << std::endl; |
| 252 } | 254 } |
| 253 | 255 |
| 254 os << indent; | 256 os << indent; |
| 255 os << begl << "VideoEncoding encoding: " << | 257 os << begl |
| 256 StringFromVideoEncoding(value->encoding) << std::endl; | 258 << "VideoEncoding encoding: " << StringFromVideoEncoding(value->encoding) |
| 259 << std::endl; |
| 257 os << begl << "VideoProfile profile: " << value->profile << std::endl; | 260 os << begl << "VideoProfile profile: " << value->profile << std::endl; |
| 258 os << begl << "PixelFormat pixel_format: " << | 261 os << begl << "PixelFormat pixel_format: " << value->pixel_format |
| 259 value->pixel_format << std::endl; | 262 << std::endl; |
| 260 os << begl << "ColorSpace color_space: " << value->color_space << std::endl; | 263 os << begl << "ColorSpace color_space: " << value->color_space << std::endl; |
| 261 os << begl << "uint32_t width: " << value->width << std::endl; | 264 os << begl << "uint32_t width: " << value->width << std::endl; |
| 262 os << begl << "uint32_t height: " << value->height << std::endl; | 265 os << begl << "uint32_t height: " << value->height << std::endl; |
| 263 os << begl << "uint32_t coded_width: " << value->coded_width << std::endl; | 266 os << begl << "uint32_t coded_width: " << value->coded_width << std::endl; |
| 264 os << begl << "uint32_t coded_height: " << value->coded_height << std::endl; | 267 os << begl << "uint32_t coded_height: " << value->coded_height << std::endl; |
| 265 return os << outdent; | 268 return os << outdent; |
| 266 } | 269 } |
| 267 | 270 |
| 268 std::ostream& operator<<( | 271 std::ostream& operator<<(std::ostream& os, |
| 269 std::ostream& os, | 272 const VideoMediaTypeSetDetailsPtr& value) { |
| 270 const VideoMediaTypeSetDetailsPtr& value) { | |
| 271 if (!value) { | 273 if (!value) { |
| 272 return os << "<nullptr>" << std::endl; | 274 return os << "<nullptr>" << std::endl; |
| 273 } else { | 275 } else { |
| 274 os << std::endl; | 276 os << std::endl; |
| 275 } | 277 } |
| 276 | 278 |
| 277 os << indent; | 279 os << indent; |
| 278 os << begl << "VideoEncoding encoding: " << | 280 os << begl |
| 279 StringFromVideoEncoding(value->encoding) << std::endl; | 281 << "VideoEncoding encoding: " << StringFromVideoEncoding(value->encoding) |
| 282 << std::endl; |
| 280 os << begl << "uint32_t min_width: " << value->min_width << std::endl; | 283 os << begl << "uint32_t min_width: " << value->min_width << std::endl; |
| 281 os << begl << "uint32_t max_width: " << value->max_width << std::endl; | 284 os << begl << "uint32_t max_width: " << value->max_width << std::endl; |
| 282 os << begl << "uint32_t min_height: " << value->min_height << std::endl; | 285 os << begl << "uint32_t min_height: " << value->min_height << std::endl; |
| 283 os << begl << "uint32_t max_height: " << value->max_height << std::endl; | 286 os << begl << "uint32_t max_height: " << value->max_height << std::endl; |
| 284 return os << outdent; | 287 return os << outdent; |
| 285 } | 288 } |
| 286 | 289 |
| 287 std::ostream& operator<<( | 290 std::ostream& operator<<(std::ostream& os, const TimelineQuadPtr& value) { |
| 288 std::ostream& os, | |
| 289 const TimelineQuadPtr& value) { | |
| 290 if (!value) { | 291 if (!value) { |
| 291 return os << "<nullptr>" << std::endl; | 292 return os << "<nullptr>" << std::endl; |
| 292 } else { | 293 } else { |
| 293 os << std::endl; | 294 os << std::endl; |
| 294 } | 295 } |
| 295 | 296 |
| 296 os << indent; | 297 os << indent; |
| 297 os << begl << "int64 reference_offset: " | 298 os << begl << "int64 reference_offset: " << value->reference_offset |
| 298 << value->reference_offset << std::endl; | 299 << std::endl; |
| 299 os << begl << "int64 target_offset: " | 300 os << begl << "int64 target_offset: " << value->target_offset << std::endl; |
| 300 << value->target_offset << std::endl; | 301 os << begl << "int32 reference_delta: " << value->reference_delta |
| 301 os << begl << "int32 reference_delta: " | 302 << std::endl; |
| 302 << value->reference_delta << std::endl; | 303 os << begl << "uint32 target_delta: " << value->target_delta << std::endl; |
| 303 os << begl << "uint32 target_delta: " | |
| 304 << value->target_delta << std::endl; | |
| 305 return os << outdent; | 304 return os << outdent; |
| 306 } | 305 } |
| 307 | 306 |
| 308 std::ostream& operator<<( | 307 std::ostream& operator<<(std::ostream& os, const TimelineTransformPtr& value) { |
| 309 std::ostream& os, | |
| 310 const TimelineTransformPtr& value) { | |
| 311 if (!value) { | 308 if (!value) { |
| 312 return os << "<nullptr>" << std::endl; | 309 return os << "<nullptr>" << std::endl; |
| 313 } else { | 310 } else { |
| 314 os << std::endl; | 311 os << std::endl; |
| 315 } | 312 } |
| 316 | 313 |
| 317 os << indent; | 314 os << indent; |
| 318 os << begl << "TimelineQuad quad: " << value->quad; | 315 os << begl << "TimelineQuad quad: " << value->quad; |
| 319 os << begl << "uint32 reference_timeline_id: " | 316 os << begl << "uint32 reference_timeline_id: " << value->reference_timeline_id |
| 320 << value->reference_timeline_id << std::endl; | 317 << std::endl; |
| 321 os << begl << "uint32 target_timeline_id: " | 318 os << begl << "uint32 target_timeline_id: " << value->target_timeline_id |
| 322 << value->target_timeline_id << std::endl; | 319 << std::endl; |
| 323 return os << outdent; | 320 return os << outdent; |
| 324 } | 321 } |
| 325 | 322 |
| 326 const char* StringFromMediaTypeScheme(MediaTypeScheme value) { | 323 const char* StringFromMediaTypeScheme(MediaTypeScheme value) { |
| 327 switch (value) { | 324 switch (value) { |
| 328 case MediaTypeScheme::UNKNOWN: | 325 case MediaTypeScheme::UNKNOWN: |
| 329 return "UNKNOWN"; | 326 return "UNKNOWN"; |
| 330 case MediaTypeScheme::NONE: | 327 case MediaTypeScheme::NONE: |
| 331 return "NONE"; | 328 return "NONE"; |
| 332 case MediaTypeScheme::ANY_ELEMENTARY: | 329 case MediaTypeScheme::ANY_ELEMENTARY: |
| (...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 408 case MediaState::PAUSED: | 405 case MediaState::PAUSED: |
| 409 return "PAUSED"; | 406 return "PAUSED"; |
| 410 case MediaState::PLAYING: | 407 case MediaState::PLAYING: |
| 411 return "PLAYING"; | 408 return "PLAYING"; |
| 412 case MediaState::ENDED: | 409 case MediaState::ENDED: |
| 413 return "ENDED"; | 410 return "ENDED"; |
| 414 } | 411 } |
| 415 return "UNKNOWN MEDIA STATE"; | 412 return "UNKNOWN MEDIA STATE"; |
| 416 } | 413 } |
| 417 | 414 |
| 418 } // namespace media | 415 } // namespace media |
| 419 } // namespace mojo | 416 } // namespace mojo |
| OLD | NEW |