| 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 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 107 | 107 |
| 108 DECLARE_VIRTUAL_TRACE(); | 108 DECLARE_VIRTUAL_TRACE(); |
| 109 | 109 |
| 110 // Is the destination node initialized and ready to handle audio? | 110 // Is the destination node initialized and ready to handle audio? |
| 111 bool isDestinationInitialized() const { | 111 bool isDestinationInitialized() const { |
| 112 AudioDestinationNode* dest = destination(); | 112 AudioDestinationNode* dest = destination(); |
| 113 return dest ? dest->audioDestinationHandler().isInitialized() : false; | 113 return dest ? dest->audioDestinationHandler().isInitialized() : false; |
| 114 } | 114 } |
| 115 | 115 |
| 116 // Document notification | 116 // Document notification |
| 117 void contextDestroyed() final; | 117 void contextDestroyed(ExecutionContext*) final; |
| 118 bool hasPendingActivity() const final; | 118 bool hasPendingActivity() const final; |
| 119 | 119 |
| 120 // Cannnot be called from the audio thread. | 120 // Cannnot be called from the audio thread. |
| 121 AudioDestinationNode* destination() const; | 121 AudioDestinationNode* destination() const; |
| 122 | 122 |
| 123 size_t currentSampleFrame() const { | 123 size_t currentSampleFrame() const { |
| 124 // TODO: What is the correct value for the current frame if the destination | 124 // TODO: What is the correct value for the current frame if the destination |
| 125 // node has gone away? 0 is a valid frame. | 125 // node has gone away? 0 is a valid frame. |
| 126 return m_destinationNode | 126 return m_destinationNode |
| 127 ? m_destinationNode->audioDestinationHandler() | 127 ? m_destinationNode->audioDestinationHandler() |
| (...skipping 328 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 456 // It is somewhat arbitrary and could be increased if necessary. | 456 // It is somewhat arbitrary and could be increased if necessary. |
| 457 enum { MaxNumberOfChannels = 32 }; | 457 enum { MaxNumberOfChannels = 32 }; |
| 458 | 458 |
| 459 Optional<AutoplayStatus> m_autoplayStatus; | 459 Optional<AutoplayStatus> m_autoplayStatus; |
| 460 AudioIOPosition m_outputPosition; | 460 AudioIOPosition m_outputPosition; |
| 461 }; | 461 }; |
| 462 | 462 |
| 463 } // namespace blink | 463 } // namespace blink |
| 464 | 464 |
| 465 #endif // BaseAudioContext_h | 465 #endif // BaseAudioContext_h |
| OLD | NEW |