/* */ public VideoDataBuffer convertToFormat(VideoFormat newFormat) { /* 215 */ if (0L != this.nativePeer) /* */ { /* 217 */ if ((newFormat == VideoFormat.BGRA_PRE) && (null != this.cachedBGRARep)) { /* 218 */ this.cachedBGRARep.holdFrame(); /* 219 */ return this.cachedBGRARep; /* */ } /* */ /* 222 */ long newFrame = nativeConvertToFormat(this.nativePeer, newFormat.getNativeType()); /* 223 */ if (0L != newFrame) { /* 224 */ NativeVideoBuffer frame = createVideoBuffer(newFrame); /* 225 */ if (newFormat == VideoFormat.BGRA_PRE) { /* 226 */ frame.holdFrame(); /* 227 */ this.cachedBGRARep = frame; /* */ } /* 229 */ return frame; /* */ } /* 231 */ return null; /* */ } /* */ /* 235 */ return null; /* */ }
/* */ public void disposeResource(Object resource) /* */ { /* 249 */ if ((resource instanceof Long)) /* 250 */ NativeVideoBuffer.nativeDisposeBuffer(((Long) resource).longValue()); /* */ }