GraphicsSerializerExtensions Class
Namespace: Stride.Graphics.DataAssembly: Stride.Graphics.dll
Various extension method for serialization of GPU types having separate CPU serialized data format.
public static class GraphicsSerializerExtensions
| Name | Description | |
|---|---|---|
| Methods | ||
| GetSerializationData(Buffer) | Gets the serialized data version of this Buffer. |
|
| GetSerializationData(Texture) | Gets the serialized data version of this Texture. |
|
| SetSerializationData(Buffer, BufferData) | Sets the serialized data version of this Buffer. |
|
| SetSerializationData(Texture, TextureSerializationData) | Sets the serialized data version of this Texture. |
|
| SetSerializationData(Texture, Image) | Sets the serialized data version of this Texture. |
|
| ToSerializableVersion(BufferData) | Creates a fake Buffer that will have the given serialized data version. |
|
| ToSerializableVersion(TextureSerializationData) | Creates a fake Texture that will have the given serialized data version. |
|
| ToSerializableVersion(Image) | Creates a fake Texture that will have the given serialized data version. |
|
Methods
GetSerializationData(Buffer)
Gets the serialized data version of this Buffer.
public static BufferData GetSerializationData(this Buffer buffer)
Parameters
| Type | Name | Description |
|---|---|---|
| Buffer | buffer | The buffer. |
Returns
| Type | Description |
|---|---|
| BufferData |
GetSerializationData(Texture)
Gets the serialized data version of this Texture.
public static TextureSerializationData GetSerializationData(this Texture texture)
Parameters
| Type | Name | Description |
|---|---|---|
| Texture | texture | The texture. |
Returns
| Type | Description |
|---|---|
| TextureSerializationData |
SetSerializationData(Buffer, BufferData)
Sets the serialized data version of this Buffer.
public static void SetSerializationData(this Buffer buffer, BufferData bufferData)
Parameters
| Type | Name | Description |
|---|---|---|
| Buffer | buffer | The buffer. |
| BufferData | bufferData | The buffer data. |
SetSerializationData(Texture, TextureSerializationData)
Sets the serialized data version of this Texture.
public static void SetSerializationData(this Texture texture, TextureSerializationData data)
Parameters
| Type | Name | Description |
|---|---|---|
| Texture | texture | The texture. |
| TextureSerializationData | data | The data. |
SetSerializationData(Texture, Image)
Sets the serialized data version of this Texture.
public static void SetSerializationData(this Texture texture, Image image)
Parameters
| Type | Name | Description |
|---|---|---|
| Texture | texture | The texture. |
| Image | image | The image. |
ToSerializableVersion(BufferData)
Creates a fake Buffer that will have the given serialized data version.
public static Buffer ToSerializableVersion(this BufferData bufferData)
Parameters
| Type | Name | Description |
|---|---|---|
| BufferData | bufferData | The buffer data. |
Returns
| Type | Description |
|---|---|
| Buffer |
ToSerializableVersion(TextureSerializationData)
Creates a fake Texture that will have the given serialized data version.
public static Texture ToSerializableVersion(this TextureSerializationData data)
Parameters
| Type | Name | Description |
|---|---|---|
| TextureSerializationData | data | The data. |
Returns
| Type | Description |
|---|---|
| Texture |
ToSerializableVersion(Image)
Creates a fake Texture that will have the given serialized data version.
public static Texture ToSerializableVersion(this Image image)
Parameters
| Type | Name | Description |
|---|---|---|
| Image | image | The image. |
Returns
| Type | Description |
|---|---|
| Texture |