Texture.Save Method

Bb198803.note(en-US,XNAGameStudio.30).gifNote
This method is available only when developing for Windows.
Saves a texture to a file.

Namespace: Microsoft.Xna.Framework.Graphics
Assembly: Microsoft.Xna.Framework (in microsoft.xna.framework.dll)

public void Save (
         string filename,
         ImageFileFormat format
)

Parameters

filename
The file name of the destination image.
format
The file format to use when saving. This function supports saving to all ImageFileFormat formats except Portable Pixmap (.ppm) and Targa/Truevision Graphics Adapter (.tga).

This function handles conversion to and from compressed texture formats.

If the volume is nondynamic and located in video memory, Save will fail because this function cannot lock nondynamic volumes located in video memory.

Windows XP SP2, Windows Vista

Community Additions

ADD
Show: