 Chromium Code Reviews
 Chromium Code Reviews Issue 1017183003:
  Make DOMTypedArray exported.  (Closed) 
  Base URL: https://chromium.googlesource.com/chromium/blink.git@master
    
  
    Issue 1017183003:
  Make DOMTypedArray exported.  (Closed) 
  Base URL: https://chromium.googlesource.com/chromium/blink.git@master| 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 * | 7 * | 
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright | 
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. | 
| 10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright | 
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 59 // Channel data access | 59 // Channel data access | 
| 60 unsigned numberOfChannels() const { return m_channels.size(); } | 60 unsigned numberOfChannels() const { return m_channels.size(); } | 
| 61 PassRefPtr<DOMFloat32Array> getChannelData(unsigned channelIndex, ExceptionS tate&); | 61 PassRefPtr<DOMFloat32Array> getChannelData(unsigned channelIndex, ExceptionS tate&); | 
| 62 DOMFloat32Array* getChannelData(unsigned channelIndex); | 62 DOMFloat32Array* getChannelData(unsigned channelIndex); | 
| 63 void zero(); | 63 void zero(); | 
| 64 | 64 | 
| 65 DEFINE_INLINE_TRACE() { } | 65 DEFINE_INLINE_TRACE() { } | 
| 66 | 66 | 
| 67 virtual v8::Handle<v8::Object> associateWithWrapper(v8::Isolate*, const Wrap perTypeInfo*, v8::Handle<v8::Object> wrapper) override; | 67 virtual v8::Handle<v8::Object> associateWithWrapper(v8::Isolate*, const Wrap perTypeInfo*, v8::Handle<v8::Object> wrapper) override; | 
| 68 | 68 | 
| 69 private: | |
| 70 static PassRefPtr<DOMFloat32Array> createFloat32Array(size_t length); | |
| 
Yuki
2015/03/24 11:12:56
nit: I'd slightly prefer createFloat32ArrayOrNull
 
tasak
2015/03/25 09:01:58
Done.
 | |
| 71 | |
| 69 protected: | 72 protected: | 
| 70 AudioBuffer(unsigned numberOfChannels, size_t numberOfFrames, float sampleRa te); | 73 AudioBuffer(unsigned numberOfChannels, size_t numberOfFrames, float sampleRa te); | 
| 71 explicit AudioBuffer(AudioBus*); | 74 explicit AudioBuffer(AudioBus*); | 
| 72 bool createdSuccessfully(unsigned desiredNumberOfChannels) const; | 75 bool createdSuccessfully(unsigned desiredNumberOfChannels) const; | 
| 73 | 76 | 
| 74 float m_sampleRate; | 77 float m_sampleRate; | 
| 75 size_t m_length; | 78 size_t m_length; | 
| 76 | 79 | 
| 77 Vector<RefPtr<DOMFloat32Array>> m_channels; | 80 Vector<RefPtr<DOMFloat32Array>> m_channels; | 
| 78 }; | 81 }; | 
| 79 | 82 | 
| 80 } // namespace blink | 83 } // namespace blink | 
| 81 | 84 | 
| 82 #endif // AudioBuffer_h | 85 #endif // AudioBuffer_h | 
| OLD | NEW |