Show / Hide Table of Contents

Class FileDecoder

Provides methods for platform specific conversions of file content.

Inheritance
System.Object
FileDecoder
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ToString()
System.Object.ReferenceEquals(System.Object, System.Object)
Namespace: Fusee.Base.Imp.Android
Assembly: Fusee.Base.Imp.Android.dll
Syntax
public static class FileDecoder

Methods

LoadImage(Stream)

Creates a new Bitmap-Object from an image file, locks the bits in the memory and makes them available for further action (e.g. creating a texture). Method must be called before creating a texture to get the necessary ImageData struct.

Declaration
public static ImageData LoadImage(Stream file)
Parameters
Type Name Description
System.IO.Stream file

Stream containing the image in a supported format (png, jpg).

Returns
Type Description
ImageData

An ImageData object with all necessary information for the texture-binding process.

LoadImageAsync(Stream)

Creates a new Bitmap-Object from an image file, locks the bits in the memory and makes them available for further action (e.g. creating a texture). Method must be called before creating a texture to get the necessary ImageData struct.

Declaration
public static Task<ImageData> LoadImageAsync(Stream file)
Parameters
Type Name Description
System.IO.Stream file

Stream containing the image in a supported format (png, jpg).

Returns
Type Description
System.Threading.Tasks.Task<ImageData>

An ImageData object with all necessary information for the texture-binding process.

Generated by DocFX
GitHub Repo
Back to top