| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2010, Google Inc. All rights reserved. | 2 * Copyright (C) 2010, Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 133 // node has gone away? 0 is a valid time. | 133 // node has gone away? 0 is a valid time. |
| 134 return m_destinationNode | 134 return m_destinationNode |
| 135 ? m_destinationNode->audioDestinationHandler().currentTime() | 135 ? m_destinationNode->audioDestinationHandler().currentTime() |
| 136 : 0; | 136 : 0; |
| 137 } | 137 } |
| 138 | 138 |
| 139 float sampleRate() const { | 139 float sampleRate() const { |
| 140 return m_destinationNode ? m_destinationNode->handler().sampleRate() : 0; | 140 return m_destinationNode ? m_destinationNode->handler().sampleRate() : 0; |
| 141 } | 141 } |
| 142 | 142 |
| 143 size_t callbackBufferSize() const { |
| 144 return m_destinationNode ? m_destinationNode->handler().callbackBufferSize() |
| 145 : 0; |
| 146 } |
| 147 |
| 143 String state() const; | 148 String state() const; |
| 144 AudioContextState contextState() const { return m_contextState; } | 149 AudioContextState contextState() const { return m_contextState; } |
| 145 void throwExceptionForClosedState(ExceptionState&); | 150 void throwExceptionForClosedState(ExceptionState&); |
| 146 | 151 |
| 147 AudioBuffer* createBuffer(unsigned numberOfChannels, | 152 AudioBuffer* createBuffer(unsigned numberOfChannels, |
| 148 size_t numberOfFrames, | 153 size_t numberOfFrames, |
| 149 float sampleRate, | 154 float sampleRate, |
| 150 ExceptionState&); | 155 ExceptionState&); |
| 151 | 156 |
| 152 // Asynchronous audio file data decoding. | 157 // Asynchronous audio file data decoding. |
| (...skipping 294 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 447 // This is considering 32 is large enough for multiple channels audio. | 452 // This is considering 32 is large enough for multiple channels audio. |
| 448 // It is somewhat arbitrary and could be increased if necessary. | 453 // It is somewhat arbitrary and could be increased if necessary. |
| 449 enum { MaxNumberOfChannels = 32 }; | 454 enum { MaxNumberOfChannels = 32 }; |
| 450 | 455 |
| 451 Optional<AutoplayStatus> m_autoplayStatus; | 456 Optional<AutoplayStatus> m_autoplayStatus; |
| 452 }; | 457 }; |
| 453 | 458 |
| 454 } // namespace blink | 459 } // namespace blink |
| 455 | 460 |
| 456 #endif // BaseAudioContext_h | 461 #endif // BaseAudioContext_h |
| OLD | NEW |