OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/blink/webmediaplayer_util.h" | 5 #include "media/blink/webmediaplayer_util.h" |
6 | 6 |
7 #include <math.h> | 7 #include <math.h> |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 #include <string> | 9 #include <string> |
10 #include <utility> | 10 #include <utility> |
(...skipping 19 matching lines...) Expand all Loading... |
30 blink::WebMediaPlayer::NetworkState PipelineErrorToNetworkState( | 30 blink::WebMediaPlayer::NetworkState PipelineErrorToNetworkState( |
31 PipelineStatus error) { | 31 PipelineStatus error) { |
32 switch (error) { | 32 switch (error) { |
33 case PIPELINE_ERROR_NETWORK: | 33 case PIPELINE_ERROR_NETWORK: |
34 case PIPELINE_ERROR_READ: | 34 case PIPELINE_ERROR_READ: |
35 case CHUNK_DEMUXER_ERROR_EOS_STATUS_NETWORK_ERROR: | 35 case CHUNK_DEMUXER_ERROR_EOS_STATUS_NETWORK_ERROR: |
36 return blink::WebMediaPlayer::NetworkStateNetworkError; | 36 return blink::WebMediaPlayer::NetworkStateNetworkError; |
37 | 37 |
38 case PIPELINE_ERROR_INITIALIZATION_FAILED: | 38 case PIPELINE_ERROR_INITIALIZATION_FAILED: |
39 case PIPELINE_ERROR_COULD_NOT_RENDER: | 39 case PIPELINE_ERROR_COULD_NOT_RENDER: |
| 40 case PIPELINE_ERROR_EXTERNAL_RENDERER_FAILED: |
40 case DEMUXER_ERROR_COULD_NOT_OPEN: | 41 case DEMUXER_ERROR_COULD_NOT_OPEN: |
41 case DEMUXER_ERROR_COULD_NOT_PARSE: | 42 case DEMUXER_ERROR_COULD_NOT_PARSE: |
42 case DEMUXER_ERROR_NO_SUPPORTED_STREAMS: | 43 case DEMUXER_ERROR_NO_SUPPORTED_STREAMS: |
43 case DECODER_ERROR_NOT_SUPPORTED: | 44 case DECODER_ERROR_NOT_SUPPORTED: |
44 return blink::WebMediaPlayer::NetworkStateFormatError; | 45 return blink::WebMediaPlayer::NetworkStateFormatError; |
45 | 46 |
46 case PIPELINE_ERROR_DECODE: | 47 case PIPELINE_ERROR_DECODE: |
47 case PIPELINE_ERROR_ABORT: | 48 case PIPELINE_ERROR_ABORT: |
48 case PIPELINE_ERROR_INVALID_STATE: | 49 case PIPELINE_ERROR_INVALID_STATE: |
49 case CHUNK_DEMUXER_ERROR_APPEND_FAILED: | 50 case CHUNK_DEMUXER_ERROR_APPEND_FAILED: |
(...skipping 199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
249 | 250 |
250 } // namespace | 251 } // namespace |
251 | 252 |
252 OutputDeviceStatusCB ConvertToOutputDeviceStatusCB( | 253 OutputDeviceStatusCB ConvertToOutputDeviceStatusCB( |
253 blink::WebSetSinkIdCallbacks* web_callbacks) { | 254 blink::WebSetSinkIdCallbacks* web_callbacks) { |
254 return media::BindToCurrentLoop( | 255 return media::BindToCurrentLoop( |
255 base::Bind(RunSetSinkIdCallback, SetSinkIdCallback(web_callbacks))); | 256 base::Bind(RunSetSinkIdCallback, SetSinkIdCallback(web_callbacks))); |
256 } | 257 } |
257 | 258 |
258 } // namespace media | 259 } // namespace media |
OLD | NEW |