public static RenderTexture2d Create(TextureManager manager,D3d.Format format, int width, int height, bool mipmap,int multisample)
        {
            RenderTexture2d newTexture = new RenderTexture2d();
            if ( newTexture.Initialize( manager,format,width,height,mipmap,multisample ) )
                return newTexture;

            return null;
        }
        public static RenderTexture2d Create(TextureManager manager, D3d.Format format, int width, int height, bool mipmap, int multisample)
        {
            RenderTexture2d newTexture = new RenderTexture2d();

            if (newTexture.Initialize(manager, format, width, height, mipmap, multisample))
            {
                return(newTexture);
            }

            return(null);
        }
Пример #3
0
        public RenderTexture2d CreateRenderTexture2d(D3d.Format format, int width, int height, bool mipmap, int multisample)
        {
            int depth = 128;

            if (ModifyParameters(D3d.ResourceType.Textures, format, false, mipmap, true, ref width, ref height, ref depth))
            {
                RenderTexture2d newTexture = RenderTexture2d.Create(this, format, width, height, mipmap, multisample);
                if (newTexture != null)
                {
                    textures.Add(newTexture);
                    textureTargets.Add(newTexture);
                    return(newTexture);
                }
            }

            return(null);
        }