| OLD | NEW |
| 1 /* | 1 /* |
| 2 * libjingle | 2 * libjingle |
| 3 * Copyright 2013 Google Inc. | 3 * Copyright 2013 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 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 75 } | 75 } |
| 76 | 76 |
| 77 - (NSInteger)uPitch { | 77 - (NSInteger)uPitch { |
| 78 return _videoFrame->GetUPitch(); | 78 return _videoFrame->GetUPitch(); |
| 79 } | 79 } |
| 80 | 80 |
| 81 - (NSInteger)vPitch { | 81 - (NSInteger)vPitch { |
| 82 return _videoFrame->GetVPitch(); | 82 return _videoFrame->GetVPitch(); |
| 83 } | 83 } |
| 84 | 84 |
| 85 - (BOOL)makeExclusive { | |
| 86 return _videoFrame->MakeExclusive(); | |
| 87 } | |
| 88 | |
| 89 @end | 85 @end |
| 90 | 86 |
| 91 @implementation RTCI420Frame (Internal) | 87 @implementation RTCI420Frame (Internal) |
| 92 | 88 |
| 93 - (instancetype)initWithVideoFrame:(cricket::VideoFrame*)videoFrame { | 89 - (instancetype)initWithVideoFrame:(cricket::VideoFrame*)videoFrame { |
| 94 if (self = [super init]) { | 90 if (self = [super init]) { |
| 95 // Keep a shallow copy of the video frame. The underlying frame buffer is | 91 // Keep a shallow copy of the video frame. The underlying frame buffer is |
| 96 // not copied. | 92 // not copied. |
| 97 _videoFrame.reset(videoFrame->Copy()); | 93 _videoFrame.reset(videoFrame->Copy()); |
| 98 } | 94 } |
| 99 return self; | 95 return self; |
| 100 } | 96 } |
| 101 | 97 |
| 102 @end | 98 @end |
| OLD | NEW |