Rename I420VideoFrame to VideoFrame.
This is a mechanical change since it affects so many files. I420VideoFrame -> VideoFrame and reformatted. Rationale: in the next CL I420VideoFrame will get an indication of Pixel Format (I420 for starters) and of storage type: usually UNOWNED, could be SHMEM, and in the near future will be possibly TEXTURE. See https://codereview.chromium.org/1154153003 for the change that happened in Cr. BUG=4730, chromium:440843 R=jiayl@webrtc.org, niklas.enbom@webrtc.org, pthatcher@webrtc.org Review URL: https://webrtc-codereview.appspot.com/52629004 Cr-Commit-Position: refs/heads/master@{#9339}
This commit is contained in:
@ -46,8 +46,7 @@ VCMReceiveCallback* VCMDecodedFrameCallback::UserReceiveCallback()
|
||||
return _receiveCallback;
|
||||
}
|
||||
|
||||
int32_t VCMDecodedFrameCallback::Decoded(I420VideoFrame& decodedImage)
|
||||
{
|
||||
int32_t VCMDecodedFrameCallback::Decoded(VideoFrame& decodedImage) {
|
||||
// TODO(holmer): We should improve this so that we can handle multiple
|
||||
// callbacks from one call to Decode().
|
||||
VCMFrameInformation* frameInfo;
|
||||
|
||||
@ -40,7 +40,7 @@ public:
|
||||
void SetUserReceiveCallback(VCMReceiveCallback* receiveCallback);
|
||||
VCMReceiveCallback* UserReceiveCallback();
|
||||
|
||||
virtual int32_t Decoded(I420VideoFrame& decodedImage);
|
||||
virtual int32_t Decoded(VideoFrame& decodedImage);
|
||||
virtual int32_t ReceivedDecodedReferenceFrame(const uint64_t pictureId);
|
||||
virtual int32_t ReceivedDecodedFrame(const uint64_t pictureId);
|
||||
|
||||
|
||||
@ -98,10 +98,9 @@ VCMGenericEncoder::InitEncode(const VideoCodec* settings,
|
||||
return 0;
|
||||
}
|
||||
|
||||
int32_t
|
||||
VCMGenericEncoder::Encode(const I420VideoFrame& inputFrame,
|
||||
const CodecSpecificInfo* codecSpecificInfo,
|
||||
const std::vector<FrameType>& frameTypes) {
|
||||
int32_t VCMGenericEncoder::Encode(const VideoFrame& inputFrame,
|
||||
const CodecSpecificInfo* codecSpecificInfo,
|
||||
const std::vector<FrameType>& frameTypes) {
|
||||
std::vector<VideoFrameType> video_frame_types(frameTypes.size(),
|
||||
kDeltaFrame);
|
||||
VCMEncodedFrame::ConvertFrameTypes(frameTypes, &video_frame_types);
|
||||
@ -176,7 +175,7 @@ VCMGenericEncoder::SetPeriodicKeyFrames(bool enable)
|
||||
|
||||
int32_t VCMGenericEncoder::RequestFrame(
|
||||
const std::vector<FrameType>& frame_types) {
|
||||
I420VideoFrame image;
|
||||
VideoFrame image;
|
||||
std::vector<VideoFrameType> video_frame_types(frame_types.size(),
|
||||
kDeltaFrame);
|
||||
VCMEncodedFrame::ConvertFrameTypes(frame_types, &video_frame_types);
|
||||
|
||||
@ -99,7 +99,7 @@ public:
|
||||
* cameraFrameRate : Request or information from the remote side
|
||||
* frameType : The requested frame type to encode
|
||||
*/
|
||||
int32_t Encode(const I420VideoFrame& inputFrame,
|
||||
int32_t Encode(const VideoFrame& inputFrame,
|
||||
const CodecSpecificInfo* codecSpecificInfo,
|
||||
const std::vector<FrameType>& frameTypes);
|
||||
/**
|
||||
|
||||
@ -172,7 +172,7 @@ class VideoCodingModuleImpl : public VideoCodingModule {
|
||||
return receiver_->SetVideoProtection(videoProtection, enable);
|
||||
}
|
||||
|
||||
int32_t AddVideoFrame(const I420VideoFrame& videoFrame,
|
||||
int32_t AddVideoFrame(const VideoFrame& videoFrame,
|
||||
const VideoContentMetrics* contentMetrics,
|
||||
const CodecSpecificInfo* codecSpecificInfo) override {
|
||||
return sender_->AddVideoFrame(
|
||||
|
||||
@ -99,7 +99,7 @@ class VideoSender {
|
||||
int32_t RegisterProtectionCallback(VCMProtectionCallback* protection);
|
||||
void SetVideoProtection(bool enable, VCMVideoProtection videoProtection);
|
||||
|
||||
int32_t AddVideoFrame(const I420VideoFrame& videoFrame,
|
||||
int32_t AddVideoFrame(const VideoFrame& videoFrame,
|
||||
const VideoContentMetrics* _contentMetrics,
|
||||
const CodecSpecificInfo* codecSpecificInfo);
|
||||
|
||||
|
||||
@ -297,7 +297,7 @@ void VideoSender::SetVideoProtection(bool enable,
|
||||
}
|
||||
}
|
||||
// Add one raw video frame to the encoder, blocking.
|
||||
int32_t VideoSender::AddVideoFrame(const I420VideoFrame& videoFrame,
|
||||
int32_t VideoSender::AddVideoFrame(const VideoFrame& videoFrame,
|
||||
const VideoContentMetrics* contentMetrics,
|
||||
const CodecSpecificInfo* codecSpecificInfo) {
|
||||
CriticalSectionScoped cs(_sendCritSect);
|
||||
|
||||
@ -71,8 +71,8 @@ MATCHER_P(MatchesVp8StreamInfo, expected, "") {
|
||||
class EmptyFrameGenerator : public FrameGenerator {
|
||||
public:
|
||||
EmptyFrameGenerator(int width, int height) : width_(width), height_(height) {}
|
||||
I420VideoFrame* NextFrame() override {
|
||||
frame_.reset(new I420VideoFrame());
|
||||
VideoFrame* NextFrame() override {
|
||||
frame_.reset(new VideoFrame());
|
||||
frame_->CreateEmptyFrame(width_, height_, width_, (width_ + 1) / 2,
|
||||
(width_ + 1) / 2);
|
||||
return frame_.get();
|
||||
@ -81,7 +81,7 @@ class EmptyFrameGenerator : public FrameGenerator {
|
||||
private:
|
||||
const int width_;
|
||||
const int height_;
|
||||
rtc::scoped_ptr<I420VideoFrame> frame_;
|
||||
rtc::scoped_ptr<VideoFrame> frame_;
|
||||
};
|
||||
|
||||
class PacketizationCallback : public VCMPacketizationCallback {
|
||||
|
||||
Reference in New Issue
Block a user