[webkit-dev] Audio directory layout
Adam Barth
abarth at webkit.org
Tue Mar 30 18:44:56 PDT 2010
It sounds like you're thinking about the audio feature as vertically
integrated instead of thinking about how its different layers related
to the other layering decisions in WebCore. (This is, of course,
without understanding the code at all, so I might be wildly off base.)
Adam
On Tue, Mar 30, 2010 at 6:04 PM, Chris Rogers <crogers at google.com> wrote:
> Still, I'll need a directory outside of platform for the IDL files and
> associated .cpp/.h files. And the .cpp/.h files really feel like they ought
> to live in the same directory as the other cross-platform files, because of
> the way the dependencies work there. That seems to point to keeping most of
> these files outside of the platform directory.
>
> On Tue, Mar 30, 2010 at 5:58 PM, Chris Rogers <crogers at google.com> wrote:
>>
>> Oh, I guess wtf doesn't really count as part of WebCore, so then I guess
>> not...
>>
>> On Tue, Mar 30, 2010 at 5:57 PM, Chris Rogers <crogers at google.com> wrote:
>>>
>>> Most of my files so far use wtf stuff (OwnPtr, RefPtr, and Vector) so I
>>> guess there are dependencies.
>>>
>>> On Tue, Mar 30, 2010 at 5:55 PM, Adam Barth <abarth at webkit.org> wrote:
>>>>
>>>> Will there be dependencies on the rest of WebCore? If not,
>>>> platform/audio might sense as a peer to platform/graphics.
>>>>
>>>> Adam
>>>>
>>>>
>>>> On Tue, Mar 30, 2010 at 5:45 PM, Chris Rogers <crogers at google.com>
>>>> wrote:
>>>> > Thanks everyone for your answers.
>>>> > Darin, I agree that "audio" might be confusing since HTMLAudioElement
>>>> > would
>>>> > not be in there, but it still might be the simplest name. Otherwise,
>>>> > how
>>>> > about:
>>>> > WebCore/audio-engine
>>>> > or
>>>> > WebCore/audio-processing
>>>> > ??
>>>> >
>>>> > On Tue, Mar 30, 2010 at 5:31 PM, Darin Adler <darin at apple.com> wrote:
>>>> >>
>>>> >> On Mar 30, 2010, at 5:19 PM, Adam Barth wrote:
>>>> >>
>>>> >> The platform directory contains a lot more than just
>>>> >> platform-specific files. It's the platform upon which WebCore is
>>>> >> built. For
>>>> >> example, KURL is in platform even though it's shared by all the
>>>> >> ports. I
>>>> >> think the main consideration for whether to put things in platform
>>>> >> relate
>>>> >> to the dependencies. For example, platform doesn't depend on the rest
>>>> >> of WebCore.
>>>> >>
>>>> >> That’s right.
>>>> >> The WebCore/platform directory’s name is a bit of a pun. It contains
>>>> >> the
>>>> >> platform abstraction, exposing things present in the underlying
>>>> >> operating
>>>> >> system such as a way to find out about events and screen sizes and
>>>> >> such, and
>>>> >> also contains other basics that provide a “platform” for the rest
>>>> >> of WebCore code, without dependencies on that code. It can be though
>>>> >> of as a
>>>> >> largely-separate lower level module within WebCore.
>>>> >> The platform directory does not contain all platform-specific files.
>>>> >> Nor
>>>> >> should it. Directories such as WebCore/loader and WebCore/plugins
>>>> >> contain
>>>> >> platform-specific subdirectories as needed.
>>>> >>
>>>> >> As for whether audio should be a top-level concept, that might
>>>> >> make sense.
>>>> >> It seems similar to notifications and storage, which are top-level
>>>> >> concepts.
>>>> >>
>>>> >> Code that is specifically about how the web models audio, and not how
>>>> >> that
>>>> >> is integrated with the underlying audio capabilities of the OS, more
>>>> >> naturally would go somewhere outside the platform directory. A top
>>>> >> level
>>>> >> directory named audio might be confusing since HTMLAudioElement would
>>>> >> not be
>>>> >> in there.
>>>> >> -- Darin
>>>> >
>>>> >
>>>
>>
>
>
More information about the webkit-dev
mailing list