private Internal_Create ( [ mono, int width, int height, int depth, TextureFormat format, bool mipmap ) : void | ||
mono | [ | |
width | int | |
height | int | |
depth | int | |
format | TextureFormat | |
mipmap | bool | |
return | void |
public Texture3D(int width, int height, int depth, GraphicsFormat format, TextureCreationFlags flags, int mipCount) { bool flag = !base.ValidateFormat(format, FormatUsage.Sample); if (!flag) { Texture3D.ValidateIsNotCrunched(flags); Texture3D.Internal_Create(this, width, height, depth, mipCount, format, flags, IntPtr.Zero); } }
public Texture3D(int width, int height, int depth, TextureFormat textureFormat, int mipCount, IntPtr nativeTex) { bool flag = !base.ValidateFormat(textureFormat); if (!flag) { GraphicsFormat graphicsFormat = GraphicsFormatUtility.GetGraphicsFormat(textureFormat, false); TextureCreationFlags textureCreationFlags = (mipCount != 1) ? TextureCreationFlags.MipChain : TextureCreationFlags.None; bool flag2 = GraphicsFormatUtility.IsCrunchFormat(textureFormat); if (flag2) { textureCreationFlags |= TextureCreationFlags.Crunch; } Texture3D.ValidateIsNotCrunched(textureCreationFlags); Texture3D.Internal_Create(this, width, height, depth, mipCount, graphicsFormat, textureCreationFlags, nativeTex); } }
/// <summary> /// <para>Create a new empty 3D Texture.</para> /// </summary> /// <param name="width">Width of texture in pixels.</param> /// <param name="height">Height of texture in pixels.</param> /// <param name="depth">Depth of texture in pixels.</param> /// <param name="format">Texture data format.</param> /// <param name="mipmap">Should the texture have mipmaps?</param> public Texture3D(int width, int height, int depth, TextureFormat format, bool mipmap) { Texture3D.Internal_Create(this, width, height, depth, format, mipmap); }