internal RenderTarget2D CreateRenderTarget(int width, int height, CCSurfaceFormat colorFormat, CCDepthFormat depthFormat, CCRenderTargetUsage usage) { if (!allowNonPower2Textures) { width = CCUtils.CCNextPOT(width); height = CCUtils.CCNextPOT(height); } return(new RenderTarget2D(graphicsDevice, width, height, false, (SurfaceFormat)colorFormat, (DepthFormat)depthFormat, 0, (RenderTargetUsage)usage)); }
internal Texture2D CreateTexture2D(int width, int height) { PresentationParameters pp = graphicsDevice.PresentationParameters; if (!allowNonPower2Textures) { width = CCUtils.CCNextPOT(width); height = CCUtils.CCNextPOT(height); } return(new Texture2D(graphicsDevice, width, height, false, SurfaceFormat.Color)); }