Duplicate / Copy CVPixelBufferRef with CVPixelBufferCreate
问题 I need to create a copy of a CVPixelBufferRef in order to be able to manipulate the original pixel buffer in a bit-wise fashion using the values from the copy. I cannot seem to achieve this with CVPixelBufferCreate , or with CVPixelBufferCreateWithBytes . According to this question, it could possibly also be done with memcpy(). However, there is no explanation on how this would be achieved, and which Core Video library calls would be needed regardless. 回答1: This seems to work: - (void