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

Side by Side Diff: webrtc/media/base/videoframe.h

Issue 2306953002: Revert of Delete cricket::VideoFrame::GetTimeStamp. (Closed)
Patch Set: Created 4 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
« no previous file with comments | « webrtc/media/base/videobroadcaster_unittest.cc ('k') | webrtc/media/base/videoframe_unittest.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) 2004 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2004 The WebRTC project authors. All Rights Reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
(...skipping 27 matching lines...) Expand all
38 virtual const rtc::scoped_refptr<webrtc::VideoFrameBuffer>& 38 virtual const rtc::scoped_refptr<webrtc::VideoFrameBuffer>&
39 video_frame_buffer() const = 0; 39 video_frame_buffer() const = 0;
40 40
41 // Frame ID. Normally RTP timestamp when the frame was received using RTP. 41 // Frame ID. Normally RTP timestamp when the frame was received using RTP.
42 virtual uint32_t transport_frame_id() const = 0; 42 virtual uint32_t transport_frame_id() const = 0;
43 43
44 // System monotonic clock, same timebase as rtc::TimeMicros(). 44 // System monotonic clock, same timebase as rtc::TimeMicros().
45 virtual int64_t timestamp_us() const = 0; 45 virtual int64_t timestamp_us() const = 0;
46 virtual void set_timestamp_us(int64_t time_us) = 0; 46 virtual void set_timestamp_us(int64_t time_us) = 0;
47 47
48 // Deprecated methods, for backwards compatibility.
49 // TODO(nisse): Delete when usage in Chrome and other applications
50 // have been replaced.
51 virtual int64_t GetTimeStamp() const {
52 return rtc::kNumNanosecsPerMicrosec * timestamp_us();
53 }
54
48 // Indicates the rotation angle in degrees. 55 // Indicates the rotation angle in degrees.
49 virtual webrtc::VideoRotation rotation() const = 0; 56 virtual webrtc::VideoRotation rotation() const = 0;
50 57
51 // Return a copy of frame which has its pending rotation applied. The 58 // Return a copy of frame which has its pending rotation applied. The
52 // ownership of the returned frame is held by this frame. 59 // ownership of the returned frame is held by this frame.
53 60
54 // TODO(nisse): Deprecated, no longer used within webrtc. Should be 61 // TODO(nisse): Deprecated, no longer used within webrtc. Should be
55 // deleted as soon as downstream applications are updated. Use 62 // deleted as soon as downstream applications are updated. Use
56 // webrtc::I420Buffer::Rotate instead. 63 // webrtc::I420Buffer::Rotate instead.
57 virtual const VideoFrame* GetCopyWithRotationApplied() const = 0; 64 virtual const VideoFrame* GetCopyWithRotationApplied() const = 0;
58 65
59 // Tests if sample is valid. Returns true if valid. 66 // Tests if sample is valid. Returns true if valid.
60 67
61 // TODO(nisse): Deprecated. Should be deleted in the cricket::VideoFrame and 68 // TODO(nisse): Deprecated. Should be deleted in the cricket::VideoFrame and
62 // webrtc::VideoFrame merge. Validation of sample_size possibly moved to 69 // webrtc::VideoFrame merge. Validation of sample_size possibly moved to
63 // libyuv::ConvertToI420. As an initial step, demote this method to protected 70 // libyuv::ConvertToI420. As an initial step, demote this method to protected
64 // status. Used only by WebRtcVideoFrame::Reset. 71 // status. Used only by WebRtcVideoFrame::Reset.
65 static bool Validate(uint32_t fourcc, 72 static bool Validate(uint32_t fourcc,
66 int w, 73 int w,
67 int h, 74 int h,
68 const uint8_t* sample, 75 const uint8_t* sample,
69 size_t sample_size); 76 size_t sample_size);
70 }; 77 };
71 78
72 } // namespace cricket 79 } // namespace cricket
73 80
74 #endif // WEBRTC_MEDIA_BASE_VIDEOFRAME_H_ 81 #endif // WEBRTC_MEDIA_BASE_VIDEOFRAME_H_
OLDNEW
« no previous file with comments | « webrtc/media/base/videobroadcaster_unittest.cc ('k') | webrtc/media/base/videoframe_unittest.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698