LuciadCPillar C# 2026.1.02
Loading...
Searching...
No Matches
Luciad.Models.ProjectedImagery.IProjectedImageryModel Interface Reference

Model interface for projected imagery: single images, live video, and 360-degree panoramas. More...

Inheritance diagram for Luciad.Models.ProjectedImagery.IProjectedImageryModel:
Luciad.Models.Model Luciad.Models.ProjectedImagery.PanoramaModel Luciad.Models.ProjectedImagery.ProjectedVideoModel

Public Member Functions

void AddObserver (IProjectedImageryModelObserver observer)
 Registers an observer that will be notified of changes to this model.
IList< ProjectedImagery > GetProjections ()
 Returns the projections held by this model.
ProjectionTileQueryResult QueryTile (string projectionId, ProjectionTileCoordinate tile, CancellationToken cancellationToken)
 Queries a single tile of a single projection.
void RemoveObserver (IProjectedImageryModelObserver observer)
 Unregisters a previously added observer.
Public Member Functions inherited from Luciad.Models.Model
ModelMetadata GetModelMetadata ()
 Returns the meta data for this model.
Bounds QueryBounds ()
 Returns the bounds of this model, if available.

Detailed Description

Model interface for projected imagery: single images, live video, and 360-degree panoramas.

A model exposes a set of posed projections and serves their tiles on request. A single access pattern covers every case. The layer lists the projections, requests the tiles it needs, and reacts to change notifications:

Implement this interface to supply projected imagery to a ProjectedImageryLayer, or obtain an implementation from a decoder.

Thread safety is the responsibility of the implementer. queryTile must be thread-safe: LuciadCPillar may call it from any thread. Typically, it will be called on a background thread for initial tile loads, and on the render thread when a projection is invalidated (see IProjectedImageryModelObserver.OnImageryInvalidated), for example for every video frame. It is also recommended to make addObserver / removeObserver thread-safe so that the layer can safely subscribe and unsubscribe from any thread.

Related article: Projecting images, video and panoramas onto the map

Since
2026.1

Member Function Documentation

◆ AddObserver()

void Luciad.Models.ProjectedImagery.IProjectedImageryModel.AddObserver ( IProjectedImageryModelObserver observer)

Registers an observer that will be notified of changes to this model.

Parameters
observerthe observer to add. Must not be null.

Implemented in Luciad.Models.ProjectedImagery.PanoramaModel, and Luciad.Models.ProjectedImagery.ProjectedVideoModel.

◆ GetProjections()

IList< ProjectedImagery > Luciad.Models.ProjectedImagery.IProjectedImageryModel.GetProjections ( )

Returns the projections held by this model.

Returns
the projections.

Implemented in Luciad.Models.ProjectedImagery.PanoramaModel, and Luciad.Models.ProjectedImagery.ProjectedVideoModel.

◆ QueryTile()

ProjectionTileQueryResult Luciad.Models.ProjectedImagery.IProjectedImageryModel.QueryTile ( string projectionId,
ProjectionTileCoordinate tile,
CancellationToken cancellationToken )

Queries a single tile of a single projection.

This method must be thread-safe. It may be called on a background thread, for example for an initial tile load, but also on the render thread, for example when a projection is invalidated. A projection that fires IProjectedImageryModelObserver.OnImageryInvalidated must serve its tiles cheaply and synchronously. Honor the cancellation token for long-running work.

The possible outcomes are not interchangeable, because each one decides whether the tile is ever requested again:

  • A result holding an image supplies the tile.
  • A result without an image means the tile does not exist, and that tile is not requested again.
  • A failed retrieval also stops the tile from being requested again.
  • A canceled request is the only outcome that leaves the tile eligible for a later request. Throw a System.OperationCanceledException to report a canceled request. Any other exception counts as a failed retrieval, after which the tile is never requested again.
Parameters
projectionIdthe identifier of the projection, as returned by ProjectedImagery.Id.
tilethe coordinate of the requested tile.
cancellationTokena token that signals when the result is no longer needed.
Returns
the tile result, or a result without an image when the tile does not exist.
Exceptions
System.IO.IOExceptionwhen the tile could not be retrieved.

Implemented in Luciad.Models.ProjectedImagery.PanoramaModel, and Luciad.Models.ProjectedImagery.ProjectedVideoModel.

◆ RemoveObserver()

void Luciad.Models.ProjectedImagery.IProjectedImageryModel.RemoveObserver ( IProjectedImageryModelObserver observer)

Unregisters a previously added observer.

If the given observer was not previously added, this method has no effect.

Parameters
observerthe observer to remove.

Implemented in Luciad.Models.ProjectedImagery.PanoramaModel, and Luciad.Models.ProjectedImagery.ProjectedVideoModel.