From 15740faf9fe9fe4be08965098bbf2947e096aeeb Mon Sep 17 00:00:00 2001 From: chai Date: Wed, 14 Aug 2019 22:50:43 +0800 Subject: +Unity Runtime code --- Runtime/GfxDevice/opengl/TexturesGL.h | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 Runtime/GfxDevice/opengl/TexturesGL.h (limited to 'Runtime/GfxDevice/opengl/TexturesGL.h') diff --git a/Runtime/GfxDevice/opengl/TexturesGL.h b/Runtime/GfxDevice/opengl/TexturesGL.h new file mode 100644 index 0000000..746c342 --- /dev/null +++ b/Runtime/GfxDevice/opengl/TexturesGL.h @@ -0,0 +1,25 @@ +#pragma once + +#include "Runtime/Graphics/TextureFormat.h" +#include "Runtime/GfxDevice/GfxDeviceTypes.h" +#include "Configuration/UnityConfigure.h" + +class ImageReference; + +void UploadTexture2DGL( + TextureID tid, TextureDimension dimension, UInt8* srcData, int width, int height, + TextureFormat format, int mipCount, UInt32 uploadFlags, int masterTextureLimit, TextureUsageMode usageMode, TextureColorSpace colorSpace ); + +void UploadTextureSubData2DGL( + TextureID tid, UInt8* srcData, + int mipLevel, int x, int y, int width, int height, TextureFormat format, TextureColorSpace colorSpace ); + +void UploadTextureCubeGL( + TextureID tid, UInt8* srcData, int faceDataSize, int size, + TextureFormat format, int mipCount, UInt32 uploadFlags, TextureColorSpace colorSpace ); + +void UploadTexture3DGL( + TextureID tid, UInt8* srcData, int width, int height, int depth, + TextureFormat format, int mipCount, UInt32 uploadFlags ); + +bool ReadbackTextureGL( ImageReference& image, int left, int bottom, int width, int height, int destX, int destY ); -- cgit v1.1-26-g67d0