RenderableSource

public class RenderableSource

Provides support for importing a glTF file into an InputStream in a way that is appropriate for use with setSource(Context, Callable).

Nested Classes

class RenderableSource.Builder Builder used to configure and create a converter. 
enum RenderableSource.RecenterMode Recenter modes that control placement of the local origin with respect to the geometry. 
enum RenderableSource.SourceType Asset types that can be loaded by RenderableSource. 

Public Methods

static RenderableSource.Builder
builder()
Creates a builder object used to create and configure a RenderableSource.
InputStream
call()
Generates the binary data for an SFB from the source and conversion parameters provided to this RenderableSource via its builder, and returns an InputStream providing the raw contents of the SFB.

Inherited Methods

Public Methods

public static RenderableSource.Builder builder ()

Creates a builder object used to create and configure a RenderableSource.

Returns
  • a builder appropriate for configuring and creating a Converter.

public InputStream call ()

Generates the binary data for an SFB from the source and conversion parameters provided to this RenderableSource via its builder, and returns an InputStream providing the raw contents of the SFB. This should not be called on the main thread since it is a blocking call.

Returns
  • an InputStream providing access to the raw contents of the SFB
Throws
IOException when indicated source cannot be loaded.
URISyntaxException when source is not a valid URI.