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

Side by Side Diff: Source/Platform/chromium/public/WebMediaStream.h

Issue 12326102: Merge 142773 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1410/
Patch Set: Created 7 years, 10 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
« no previous file with comments | « no previous file | Source/Platform/chromium/public/WebMediaStreamTrack.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 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 18 matching lines...) Expand all
29 #include "WebNonCopyable.h" 29 #include "WebNonCopyable.h"
30 #include "WebPrivatePtr.h" 30 #include "WebPrivatePtr.h"
31 #include "WebVector.h" 31 #include "WebVector.h"
32 32
33 namespace WebCore { 33 namespace WebCore {
34 class MediaStreamDescriptor; 34 class MediaStreamDescriptor;
35 } 35 }
36 36
37 namespace WebKit { 37 namespace WebKit {
38 38
39 class WebMediaStreamSource;
39 class WebMediaStreamTrack; 40 class WebMediaStreamTrack;
40 class WebMediaStreamSource;
41 class WebString; 41 class WebString;
42 42
43 class WebMediaStream { 43 class WebMediaStream {
44 public: 44 public:
45 class ExtraData { 45 class ExtraData {
46 public: 46 public:
47 virtual ~ExtraData() { } 47 virtual ~ExtraData() { }
48 }; 48 };
49 49
50 WebMediaStream() { } 50 WebMediaStream() { }
51 WebMediaStream(const WebMediaStream& other) { assign(other); } 51 WebMediaStream(const WebMediaStream& other) { assign(other); }
52 ~WebMediaStream() { reset(); } 52 ~WebMediaStream() { reset(); }
53 53
54 WebMediaStream& operator=(const WebMediaStream& other) 54 WebMediaStream& operator=(const WebMediaStream& other)
55 { 55 {
56 assign(other); 56 assign(other);
57 return *this; 57 return *this;
58 } 58 }
59 59
60 WEBKIT_EXPORT void assign(const WebMediaStream&); 60 WEBKIT_EXPORT void assign(const WebMediaStream&);
61 61
62 // DEPRECATED
62 WEBKIT_EXPORT void initialize(const WebString& label, const WebVector<WebMed iaStreamSource>& audioSources, const WebVector<WebMediaStreamSource>& videoSourc es); 63 WEBKIT_EXPORT void initialize(const WebString& label, const WebVector<WebMed iaStreamSource>& audioSources, const WebVector<WebMediaStreamSource>& videoSourc es);
64
65 WEBKIT_EXPORT void initialize(const WebString& label, const WebVector<WebMed iaStreamTrack>& audioTracks, const WebVector<WebMediaStreamTrack>& videoTracks);
66
63 WEBKIT_EXPORT void reset(); 67 WEBKIT_EXPORT void reset();
64 bool isNull() const { return m_private.isNull(); } 68 bool isNull() const { return m_private.isNull(); }
65 69
66 // DEPRECATED 70 // DEPRECATED
67 WEBKIT_EXPORT WebString label() const; 71 WEBKIT_EXPORT WebString label() const;
68 72
69 WEBKIT_EXPORT WebString id() const; 73 WEBKIT_EXPORT WebString id() const;
70 74
71 WEBKIT_EXPORT void audioSources(WebVector<WebMediaStreamTrack>&) const; 75 WEBKIT_EXPORT void audioTracks(WebVector<WebMediaStreamTrack>&) const;
72 WEBKIT_EXPORT void videoSources(WebVector<WebMediaStreamTrack>&) const; 76 WEBKIT_EXPORT void videoTracks(WebVector<WebMediaStreamTrack>&) const;
77
78 // DEPRECATED
79 void audioSources(WebVector<WebMediaStreamTrack>& tracks) const { audioTrack s(tracks); }
80 void videoSources(WebVector<WebMediaStreamTrack>& tracks) const { videoTrack s(tracks); }
73 81
74 // Extra data associated with this WebMediaStream. 82 // Extra data associated with this WebMediaStream.
75 // If non-null, the extra data pointer will be deleted when the object is de stroyed. 83 // If non-null, the extra data pointer will be deleted when the object is de stroyed.
76 // Setting the extra data pointer will cause any existing non-null 84 // Setting the extra data pointer will cause any existing non-null
77 // extra data pointer to be deleted. 85 // extra data pointer to be deleted.
78 WEBKIT_EXPORT ExtraData* extraData() const; 86 WEBKIT_EXPORT ExtraData* extraData() const;
79 WEBKIT_EXPORT void setExtraData(ExtraData*); 87 WEBKIT_EXPORT void setExtraData(ExtraData*);
80 88
81 #if WEBKIT_IMPLEMENTATION 89 #if WEBKIT_IMPLEMENTATION
82 WebMediaStream(WebCore::MediaStreamDescriptor*); 90 WebMediaStream(WebCore::MediaStreamDescriptor*);
83 WebMediaStream(const WTF::PassRefPtr<WebCore::MediaStreamDescriptor>&); 91 WebMediaStream(const WTF::PassRefPtr<WebCore::MediaStreamDescriptor>&);
84 operator WTF::PassRefPtr<WebCore::MediaStreamDescriptor>() const; 92 operator WTF::PassRefPtr<WebCore::MediaStreamDescriptor>() const;
85 operator WebCore::MediaStreamDescriptor*() const; 93 operator WebCore::MediaStreamDescriptor*() const;
86 WebMediaStream& operator=(const WTF::PassRefPtr<WebCore::MediaStreamDescript or>&); 94 WebMediaStream& operator=(const WTF::PassRefPtr<WebCore::MediaStreamDescript or>&);
87 #endif 95 #endif
88 96
89 private: 97 private:
90 WebPrivatePtr<WebCore::MediaStreamDescriptor> m_private; 98 WebPrivatePtr<WebCore::MediaStreamDescriptor> m_private;
91 }; 99 };
92 100
93 } // namespace WebKit 101 } // namespace WebKit
94 102
95 #endif // WebMediaStream_h 103 #endif // WebMediaStream_h
OLDNEW
« no previous file with comments | « no previous file | Source/Platform/chromium/public/WebMediaStreamTrack.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698