Skip to content

Commit 3604c6f

Browse files
hiroshihoriedavidliu
authored andcommitted
Update RTCVideoEncoderH264.mm (webrtc-sdk#6)
1 parent 17fcc45 commit 3604c6f

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

sdk/objc/components/video_codec/RTCVideoEncoderH264.mm

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -387,8 +387,8 @@ - (NSInteger)startEncodeWithSettings:(RTC_OBJC_TYPE(RTCVideoEncoderSettings) *)s
387387
- (NSInteger)encode:(RTC_OBJC_TYPE(RTCVideoFrame) *)frame
388388
codecSpecificInfo:(nullable id<RTC_OBJC_TYPE(RTCCodecSpecificInfo)>)codecSpecificInfo
389389
frameTypes:(NSArray<NSNumber *> *)frameTypes {
390-
RTC_DCHECK_EQ(frame.width, _width);
391-
RTC_DCHECK_EQ(frame.height, _height);
390+
// RTC_DCHECK_EQ(frame.width, _width);
391+
// RTC_DCHECK_EQ(frame.height, _height);
392392
if (!_callback || !_compressionSession) {
393393
return WEBRTC_VIDEO_CODEC_UNINITIALIZED;
394394
}
@@ -571,6 +571,7 @@ - (BOOL)resetCompressionSessionIfNeededWithFrame:(RTC_OBJC_TYPE(RTCVideoFrame) *
571571
OSType framePixelFormat = [self pixelFormatOfFrame:frame];
572572

573573
if (_compressionSession) {
574+
_pixelBufferPool = VTCompressionSessionGetPixelBufferPool(_compressionSession);
574575
// The pool attribute `kCVPixelBufferPixelFormatTypeKey` can contain either an array of pixel
575576
// formats or a single pixel format.
576577
NSDictionary *poolAttributes =

0 commit comments

Comments
 (0)