| OLD | NEW |
| 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 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 48 // Deprecated methods, for backwards compatibility. | 48 // Deprecated methods, for backwards compatibility. |
| 49 // TODO(nisse): Delete when usage in Chrome and other applications | 49 // TODO(nisse): Delete when usage in Chrome and other applications |
| 50 // have been replaced. | 50 // have been replaced. |
| 51 virtual int64_t GetTimeStamp() const { | 51 virtual int64_t GetTimeStamp() const { |
| 52 return rtc::kNumNanosecsPerMicrosec * timestamp_us(); | 52 return rtc::kNumNanosecsPerMicrosec * timestamp_us(); |
| 53 } | 53 } |
| 54 | 54 |
| 55 // Indicates the rotation angle in degrees. | 55 // Indicates the rotation angle in degrees. |
| 56 virtual webrtc::VideoRotation rotation() const = 0; | 56 virtual webrtc::VideoRotation rotation() const = 0; |
| 57 | 57 |
| 58 // Return a copy of frame which has its pending rotation applied. The | |
| 59 // ownership of the returned frame is held by this frame. | |
| 60 | |
| 61 // TODO(nisse): Deprecated, no longer used within webrtc. Should be | |
| 62 // deleted as soon as downstream applications are updated. Use | |
| 63 // webrtc::I420Buffer::Rotate instead. | |
| 64 virtual const VideoFrame* GetCopyWithRotationApplied() const = 0; | |
| 65 | |
| 66 // Tests if sample is valid. Returns true if valid. | 58 // Tests if sample is valid. Returns true if valid. |
| 67 | 59 |
| 68 // TODO(nisse): Deprecated. Should be deleted in the cricket::VideoFrame and | 60 // TODO(nisse): Deprecated. Should be deleted in the cricket::VideoFrame and |
| 69 // webrtc::VideoFrame merge. Validation of sample_size possibly moved to | 61 // webrtc::VideoFrame merge. Validation of sample_size possibly moved to |
| 70 // libyuv::ConvertToI420. As an initial step, demote this method to protected | 62 // libyuv::ConvertToI420. As an initial step, demote this method to protected |
| 71 // status. Used only by WebRtcVideoFrame::Reset. | 63 // status. Used only by WebRtcVideoFrame::Reset. |
| 72 static bool Validate(uint32_t fourcc, | 64 static bool Validate(uint32_t fourcc, |
| 73 int w, | 65 int w, |
| 74 int h, | 66 int h, |
| 75 const uint8_t* sample, | 67 const uint8_t* sample, |
| 76 size_t sample_size); | 68 size_t sample_size); |
| 77 }; | 69 }; |
| 78 | 70 |
| 79 } // namespace cricket | 71 } // namespace cricket |
| 80 | 72 |
| 81 #endif // WEBRTC_MEDIA_BASE_VIDEOFRAME_H_ | 73 #endif // WEBRTC_MEDIA_BASE_VIDEOFRAME_H_ |
| OLD | NEW |