         if let fLock = frameLock, let format = frame.format {
             fLock.lock()
             assert(format.pixelFormat == .I420)
-            if lastVideoFrameRendered == false {
-                deallocateFrame(lastVideoFrame ?? nil)
-            }
+
+            deallocateFrame(lastVideoFrame)
+            
             lastVideoFrame = OTVideoFrame(format: format)
             lastVideoFrame?.timestamp = frame.timestamp
             

    
    var needsRendererUpdate: Bool {
        get {
            return renderer?.lastFrameTime != lastVideoFrame?.timestamp.value
                || clearRenderer != 0
        }
    }
        

        yPlane?.deallocate()
        uPlane?.deallocate()
        vPlane?.deallocate()

    }
    
}
