Table of Contents

Class GltfImporter

Namespace
ReFuel.IO.Model
Assembly
ReFuel.dll
public class GltfImporter : IResourceImporterWithReporter, IResourceImporter
Inheritance
GltfImporter
Implements
Inherited Members

Properties

AllowDownload

public bool AllowDownload { get; set; }

Property Value

bool

ImporterExtensions

The file extensions for this resource importer.

public IEnumerable<string> ImporterExtensions { get; }

Property Value

IEnumerable<string>

ImporterMimeTypes

The mime types for this resource importer.

public IEnumerable<string> ImporterMimeTypes { get; }

Property Value

IEnumerable<string>

ResourceSystem

Set the resource system for this importer.

public ResourceSystem ResourceSystem { set; }

Property Value

ResourceSystem

Methods

Import(Stream, EcsContainer?, string?)

Begins importing a resource in the given stream into the given ECS context.

public Task<ResourceResult> Import(Stream source, EcsContainer? parent = null, string? fileName = null)

Parameters

source Stream

The resource source stream.

parent EcsContainer

The parent node for file types that contain a node hierarchy. If null, hierarchy is loaded into the root node.

fileName string

Base name of the file.

Returns

Task<ResourceResult>

A task that returns a reference to all the resources in the file.

Import(Stream, IProcessReporter, EcsContainer?, string?)

public Task<ResourceResult> Import(Stream source, IProcessReporter reporter, EcsContainer? parent = null, string? fileName = null)

Parameters

source Stream
reporter IProcessReporter
parent EcsContainer
fileName string

Returns

Task<ResourceResult>

IsImportable(ReadOnlySpan<byte>, string?)

Checks if this importer could import a stream with the given start bytes.

public bool IsImportable(ReadOnlySpan<byte> page, string? fileName = null)

Parameters

page ReadOnlySpan<byte>

The start bytes of the resource stream.

fileName string

The name of the file, as a hint.

Returns

bool

True if the importer could import this file.