summaryrefslogtreecommitdiff
path: root/common/quicktime_win32/CVDirect3DBuffer.h
diff options
context:
space:
mode:
authorFluorescentCIAAfricanAmerican <[email protected]>2020-04-22 12:56:21 -0400
committerFluorescentCIAAfricanAmerican <[email protected]>2020-04-22 12:56:21 -0400
commit3bf9df6b2785fa6d951086978a3e66f49427166a (patch)
tree2c0f1f0c63c4832882bc93814ebd2c2b1c6224e5 /common/quicktime_win32/CVDirect3DBuffer.h
downloadarchived-source-engine-2018-hl2-src-master.tar.xz
archived-source-engine-2018-hl2-src-master.zip
Diffstat (limited to 'common/quicktime_win32/CVDirect3DBuffer.h')
-rw-r--r--common/quicktime_win32/CVDirect3DBuffer.h75
1 files changed, 75 insertions, 0 deletions
diff --git a/common/quicktime_win32/CVDirect3DBuffer.h b/common/quicktime_win32/CVDirect3DBuffer.h
new file mode 100644
index 0000000..3d6959e
--- /dev/null
+++ b/common/quicktime_win32/CVDirect3DBuffer.h
@@ -0,0 +1,75 @@
+/*
+ * CVDirect3DBuffer.h
+ * CoreVideo
+ *
+ * Copyright (c) 2004 Apple Computer, Inc. All rights reserved.
+ *
+ */
+
+ /*! @header CVDirect3DBuffer.h
+ @copyright 2004 Apple Computer, Inc. All rights reserved.
+ @discussion A CoreVideo buffer derives from a generic buffer and can be an ImageBuffer or PixelBuffer.
+
+*/
+
+#if !defined(__COREVIDEO_CVDIRECT3DBUFFER_H__)
+#define __COREVIDEO_CVDIRECT3DBUFFER_H__ 1
+
+#include <CVImageBuffer.h>
+
+#if defined(__cplusplus)
+extern "C" {
+#endif
+
+#define kCVDirect3DBufferWidth CFSTR("Width")
+#define kCVDirect3DBufferHeight CFSTR("Height")
+#define kCVDirect3DBufferTarget CFSTR("Direct3DTarget")
+#define kCVDirect3DBufferInternalFormat CFSTR("Direct3DInternalFormat")
+#define kCVDirect3DBufferMaximumMipmapLevel CFSTR("MaximumMipmapLevel")
+
+typedef CVImageBufferRef CVDirect3DBufferRef;
+
+CV_EXPORT CFTypeID CVDirect3DBufferGetTypeID();
+
+/*!
+ @function CVDirect3DBufferRetain
+ @abstract Retains a CVDirect3DBuffer object
+ @discussion Equivalent to CFRetain, but NULL safe
+ @param buffer A CVDirect3DBuffer object that you want to retain.
+ @result A CVDirect3DBuffer object that is the same as the passed in buffer.
+*/
+CV_EXPORT CVDirect3DBufferRef CVDirect3DBufferRetain( CVDirect3DBufferRef texture );
+
+/*!
+ @function CVDirect3DBufferRelease
+ @abstract Releases a CVDirect3DBuffer object
+ @discussion Equivalent to CFRelease, but NULL safe
+ @param buffer A CVDirect3DBuffer object that you want to release.
+*/
+CV_EXPORT void CVDirect3DBufferRelease( CVDirect3DBufferRef texture );
+
+/*!
+ @function CVDirect3DBufferCreate
+ @abstract Create a new CVDirect3DBuffer that may be used for D3D rendering purposes
+ @param width The width of the buffer in pixels
+ @param height The height of the buffer in pixels
+ @param attributes A CFDictionaryRef containing other desired attributes of the buffer (texture format, max mipmap level, etc.).
+ May be NULL.
+ @param bufferOut The newly created buffer will be placed here.
+ @result kCVReturnSuccess if the attachment succeeded
+*/
+CV_EXPORT CVReturn CVDirect3DBufferCreate(CFAllocatorRef allocator, size_t width, size_t height, void *d3dDevice, CFDictionaryRef attributes, CVDirect3DBufferRef *bufferOut);
+
+/*!
+ @function CVDirect3DBufferGetAttributes
+ @param openGLBuffer Target D3D Buffer.
+ @result CVDirect3DBuffer attributes dictionary, NULL if not set.
+*/
+CV_EXPORT CFDictionaryRef CVDirect3DBufferGetAttributes(CVDirect3DBufferRef d3DBuffer);
+
+
+#if defined(__cplusplus)
+}
+#endif
+
+#endif