PositionIndicatorMeshRepresentationBuilder

public class PositionIndicatorMeshRepresentationBuilder
extension PositionIndicatorMeshRepresentationBuilder: NativeBase
extension PositionIndicatorMeshRepresentationBuilder: Hashable

Builder for creating immutable PositionIndicatorMeshRepresentation instances. Only the geometry URI is required. All other properties have documented defaults.

  • Creates a new builder with the required geometry URI. The URI can reference a registered asset in the AssetManager or a file. The referenced content is expected in the Wavefront obj format.

    Declaration

    Swift

    public init(_ geometryUri: String)

    Parameters

    geometryUri

    Uniform resource identifier for data in Wavefront obj format.

  • Sets the diffuse texture URI. Default is empty (no texture).

    Declaration

    Swift

    public func withTextureUri(_ textureUri: String) -> PositionIndicatorMeshRepresentationBuilder

    Parameters

    textureUri

    Uniform resource identifier for the diffuse texture.

    Return Value

    This builder instance.

  • Sets whether the texture image is flipped vertically before use. Default is true.

    Declaration

    Swift

    public func withFlipTextureVertically(_ flip: Bool) -> PositionIndicatorMeshRepresentationBuilder

    Parameters

    flip

    If true, the texture image is flipped vertically.

    Return Value

    This builder instance.

  • Sets the modulation color. Default is white (1, 1, 1, 1).

    Declaration

    Swift

    public func withColor(_ color: UIColor) -> PositionIndicatorMeshRepresentationBuilder

    Parameters

    color

    The modulation color.

    Return Value

    This builder instance.

  • Sets the ambient lighting factor in range 0.0 to 1.0. Default is 0.0.

    Declaration

    Swift

    public func withAmbientFactor(_ ambientFactor: Double) -> PositionIndicatorMeshRepresentationBuilder

    Parameters

    ambientFactor

    The ambient lighting factor.

    Return Value

    This builder instance.

  • Sets the diffuse lighting factor in range 0.0 to 1.0. Default is 1.0.

    Declaration

    Swift

    public func withDiffuseFactor(_ diffuseFactor: Double) -> PositionIndicatorMeshRepresentationBuilder

    Parameters

    diffuseFactor

    The diffuse lighting factor.

    Return Value

    This builder instance.

  • Sets whether lighting is applied to the object color. Default is false.

    Declaration

    Swift

    public func withLightingEnabled(_ lightingEnabled: Bool) -> PositionIndicatorMeshRepresentationBuilder

    Parameters

    lightingEnabled

    If true, lighting is applied.

    Return Value

    This builder instance.

  • Builds an immutable PositionIndicatorMeshRepresentation with the configured properties.

    Declaration

    Swift

    public func build() -> PositionIndicatorMeshRepresentation

    Return Value

    A new PositionIndicatorMeshRepresentation instance.