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

Side by Side Diff: talk/app/webrtc/mediastreaminterface.h

Issue 1313753003: Remove VideoRendererInterface::CanApplyRotation() (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 5 years, 3 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
OLDNEW
1 /* 1 /*
2 * libjingle 2 * libjingle
3 * Copyright 2012 Google Inc. 3 * Copyright 2012 Google Inc.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are met: 6 * modification, are permitted provided that the following conditions are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright notice, 8 * 1. Redistributions of source code must retain the above copyright notice,
9 * this list of conditions and the following disclaimer. 9 * this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright notice, 10 * 2. Redistributions in binary form must reproduce the above copyright notice,
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 // well as pending rotation. If it can't apply the frame rotation by itself, 120 // well as pending rotation. If it can't apply the frame rotation by itself,
121 // it should call |frame|.GetCopyWithRotationApplied() to get a frame that has 121 // it should call |frame|.GetCopyWithRotationApplied() to get a frame that has
122 // the rotation applied. 122 // the rotation applied.
123 virtual void SetSize(int width, int height) {} 123 virtual void SetSize(int width, int height) {}
124 124
125 // |frame| may have pending rotation. For clients which can't apply rotation, 125 // |frame| may have pending rotation. For clients which can't apply rotation,
126 // |frame|->GetCopyWithRotationApplied() will return a frame that has the 126 // |frame|->GetCopyWithRotationApplied() will return a frame that has the
127 // rotation applied. 127 // rotation applied.
128 virtual void RenderFrame(const cricket::VideoFrame* frame) = 0; 128 virtual void RenderFrame(const cricket::VideoFrame* frame) = 0;
129 129
130 // TODO(guoweis): Remove this function. This is added as a temporary solution
131 // until chrome renderers can apply rotation.
132 // Whether the VideoRenderer has the ability to rotate the frame before being
133 // displayed. The rotation of a frame is carried by
134 // VideoFrame.GetVideoRotation() and is the clockwise angle the frames must be
135 // rotated in order to display the frames correctly. If returning false, the
136 // frame's rotation must be applied before being delivered by RenderFrame.
137 virtual bool CanApplyRotation() { return false; }
138
139 protected: 130 protected:
140 // The destructor is protected to prevent deletion via the interface. 131 // The destructor is protected to prevent deletion via the interface.
141 // This is so that we allow reference counted classes, where the destructor 132 // This is so that we allow reference counted classes, where the destructor
142 // should never be public, to implement the interface. 133 // should never be public, to implement the interface.
143 virtual ~VideoRendererInterface() {} 134 virtual ~VideoRendererInterface() {}
144 }; 135 };
145 136
146 class VideoSourceInterface; 137 class VideoSourceInterface;
147 138
148 class VideoTrackInterface : public MediaStreamTrackInterface { 139 class VideoTrackInterface : public MediaStreamTrackInterface {
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after
273 virtual bool RemoveTrack(AudioTrackInterface* track) = 0; 264 virtual bool RemoveTrack(AudioTrackInterface* track) = 0;
274 virtual bool RemoveTrack(VideoTrackInterface* track) = 0; 265 virtual bool RemoveTrack(VideoTrackInterface* track) = 0;
275 266
276 protected: 267 protected:
277 virtual ~MediaStreamInterface() {} 268 virtual ~MediaStreamInterface() {}
278 }; 269 };
279 270
280 } // namespace webrtc 271 } // namespace webrtc
281 272
282 #endif // TALK_APP_WEBRTC_MEDIASTREAMINTERFACE_H_ 273 #endif // TALK_APP_WEBRTC_MEDIASTREAMINTERFACE_H_
OLDNEW
« no previous file with comments | « talk/app/webrtc/java/jni/peerconnection_jni.cc ('k') | talk/app/webrtc/test/fakevideotrackrenderer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698