| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "media/base/media_log.h" | 5 #include "media/base/media_log.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/atomic_sequence_num.h" | 9 #include "base/atomic_sequence_num.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 121 case PIPELINE_ERROR_INVALID_STATE: | 121 case PIPELINE_ERROR_INVALID_STATE: |
| 122 return "pipeline: invalid state"; | 122 return "pipeline: invalid state"; |
| 123 case DEMUXER_ERROR_COULD_NOT_OPEN: | 123 case DEMUXER_ERROR_COULD_NOT_OPEN: |
| 124 return "demuxer: could not open"; | 124 return "demuxer: could not open"; |
| 125 case DEMUXER_ERROR_COULD_NOT_PARSE: | 125 case DEMUXER_ERROR_COULD_NOT_PARSE: |
| 126 return "dumuxer: could not parse"; | 126 return "dumuxer: could not parse"; |
| 127 case DEMUXER_ERROR_NO_SUPPORTED_STREAMS: | 127 case DEMUXER_ERROR_NO_SUPPORTED_STREAMS: |
| 128 return "demuxer: no supported streams"; | 128 return "demuxer: no supported streams"; |
| 129 case DECODER_ERROR_NOT_SUPPORTED: | 129 case DECODER_ERROR_NOT_SUPPORTED: |
| 130 return "decoder: not supported"; | 130 return "decoder: not supported"; |
| 131 case PIPELINE_STATUS_MAX: |
| 132 NOTREACHED(); |
| 131 } | 133 } |
| 132 NOTREACHED(); | 134 NOTREACHED(); |
| 133 return NULL; | 135 return NULL; |
| 134 } | 136 } |
| 135 | 137 |
| 136 MediaLog::MediaLog() : id_(g_media_log_count.GetNext()) {} | 138 MediaLog::MediaLog() : id_(g_media_log_count.GetNext()) {} |
| 137 | 139 |
| 138 MediaLog::~MediaLog() {} | 140 MediaLog::~MediaLog() {} |
| 139 | 141 |
| 140 void MediaLog::AddEvent(scoped_ptr<MediaLogEvent> event) {} | 142 void MediaLog::AddEvent(scoped_ptr<MediaLogEvent> event) {} |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 207 size_t start, size_t current, size_t end) { | 209 size_t start, size_t current, size_t end) { |
| 208 scoped_ptr<MediaLogEvent> event( | 210 scoped_ptr<MediaLogEvent> event( |
| 209 CreateEvent(MediaLogEvent::BUFFERED_EXTENTS_CHANGED)); | 211 CreateEvent(MediaLogEvent::BUFFERED_EXTENTS_CHANGED)); |
| 210 event->params.SetInteger("buffer_start", start); | 212 event->params.SetInteger("buffer_start", start); |
| 211 event->params.SetInteger("buffer_current", current); | 213 event->params.SetInteger("buffer_current", current); |
| 212 event->params.SetInteger("buffer_end", end); | 214 event->params.SetInteger("buffer_end", end); |
| 213 return event.Pass(); | 215 return event.Pass(); |
| 214 } | 216 } |
| 215 | 217 |
| 216 } //namespace media | 218 } //namespace media |
| OLD | NEW |