Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(48)

Side by Side Diff: Source/modules/webaudio/AudioNode.h

Issue 18778002: Inherit EventTarget interface instead of duplicating its code (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 class AudioParam; 44 class AudioParam;
45 45
46 typedef int ExceptionCode; 46 typedef int ExceptionCode;
47 47
48 // An AudioNode is the basic building block for handling audio within an AudioCo ntext. 48 // An AudioNode is the basic building block for handling audio within an AudioCo ntext.
49 // It may be an audio source, an intermediate processing module, or an audio des tination. 49 // It may be an audio source, an intermediate processing module, or an audio des tination.
50 // Each AudioNode can have inputs and/or outputs. An AudioSourceNode has no inpu ts and a single output. 50 // Each AudioNode can have inputs and/or outputs. An AudioSourceNode has no inpu ts and a single output.
51 // An AudioDestinationNode has one input and no outputs and represents the final destination to the audio hardware. 51 // An AudioDestinationNode has one input and no outputs and represents the final destination to the audio hardware.
52 // Most processing nodes such as filters will have one input and one output, alt hough multiple inputs and outputs are possible. 52 // Most processing nodes such as filters will have one input and one output, alt hough multiple inputs and outputs are possible.
53 53
54 class AudioNode : public ScriptWrappable, public EventTarget { 54 class AudioNode : public EventTarget, public ScriptWrappable {
55 public: 55 public:
56 enum { ProcessingSizeInFrames = 128 }; 56 enum { ProcessingSizeInFrames = 128 };
57 57
58 AudioNode(AudioContext*, float sampleRate); 58 AudioNode(AudioContext*, float sampleRate);
59 virtual ~AudioNode(); 59 virtual ~AudioNode();
60 60
61 AudioContext* context() { return m_context.get(); } 61 AudioContext* context() { return m_context.get(); }
62 const AudioContext* context() const { return m_context.get(); } 62 const AudioContext* context() const { return m_context.get(); }
63 63
64 enum NodeType { 64 enum NodeType {
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
231 231
232 protected: 232 protected:
233 unsigned m_channelCount; 233 unsigned m_channelCount;
234 ChannelCountMode m_channelCountMode; 234 ChannelCountMode m_channelCountMode;
235 AudioBus::ChannelInterpretation m_channelInterpretation; 235 AudioBus::ChannelInterpretation m_channelInterpretation;
236 }; 236 };
237 237
238 } // namespace WebCore 238 } // namespace WebCore
239 239
240 #endif // AudioNode_h 240 #endif // AudioNode_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698