A 3D model map object (Wavefront OBJ) placed on the location view. More...
#include <com/navigine/idl/objc/NCModelMapObject.h>
Inheritance diagram for NCModelMapObject:Instance Methods | |
| (BOOL) | - setPosition:sublocationId: |
| Sets the anchor position of the model in WGS84 coordinates. | |
| (BOOL) | - setPositionAnimated:sublocationId:duration:type: |
| Animates the model anchor to a new position. | |
| (BOOL) | - setModel: |
| Sets the 3D asset (OBJ source + texture ImageProvider). | |
| (BOOL) | - setSize:height: |
| Sets the on-screen size of the model in pixels (width and height). | |
| (BOOL) | - setCollisionEnabled: |
| Enables or disables collision tests for this object. | |
| (BOOL) | - setAngle: |
| Sets rotation angle in radians (around the placement axis used by the engine). | |
| (BOOL) | - setAngleAnimated:duration:type: |
| Animates rotation to the given angle in radians. | |
| (BOOL) | - setBuffer:height: |
| Extra hit-test padding around the model in pixels. | |
| (BOOL) | - setPriority: |
| Render order priority (higher draws above). | |
| (int32_t) | - getId |
| Gets the unique identifier of the map object. | |
| (NCMapObjectType) | - getType |
| Gets the type of the map object. | |
| (nonnull NSData *) | - getData |
| Gets the user-defined data associated with the map object. | |
| (BOOL) | - setVisible: |
| Method is used to specify the visibility of the map object. | |
| (BOOL) | - setInteractive: |
| Method is used to specify whether the map object can be interacted with. | |
| (void) | - setData: |
| Method is used to set user-defined data for the map object. | |
| (BOOL) | - setTitle: |
| Method is used to set the title of the map object. | |
| (BOOL) | - setTitleWithStyle:style: |
| Method is used to set the title and its style for the map object. | |
| (BOOL) | - setAlpha: |
| Method is used to set the opacity of the map object. | |
Properties | |
| BOOL | valid |
A 3D model map object (Wavefront OBJ) placed on the location view.
Geometry and texture come from ModelProvider. The mesh is loaded asynchronously in the render pipeline; blocking calls occur only inside provider callbacks.
Referenced from LocationWindow (addModelMapObject).
Definition at line 25 of file NCModelMapObject.h.
| - (nonnull NSData *) getData |
Gets the user-defined data associated with the map object.
Swift code snippet:
Objective C code snippet:
| - (int32_t) getId |
Gets the unique identifier of the map object.
Swift code snippet:
Objective C code snippet:
| - (NCMapObjectType) getType |
Gets the type of the map object.
Swift code snippet:
Objective C code snippet:
| - (BOOL) setAlpha: | (float) | alpha |
Method is used to set the opacity of the map object.
| alpha | Opacity multiplier. Values below 0 will be set to 0. Values above 1 will be set to 1. Default: 1. |
Swift code snippet:
Objective C code snippet:
| - (BOOL) setAngle: | (float) | angle |
Sets rotation angle in radians (around the placement axis used by the engine).
| angle | Rotation angle in radians. Default: 0. |
Swift code snippet:
Objective C code snippet:
| - (BOOL) setAngleAnimated: | (float) | angle | |
| duration: | (float) | duration | |
| type: | (NCAnimationType) | type |
Animates rotation to the given angle in radians.
| angle | Rotation angle in radians. |
| duration | Animation duration in seconds. |
| type | Animation type AnimationType. |
Swift code snippet:
Objective C code snippet:
| - (BOOL) setBuffer: | (float) | width | |
| height: | (float) | height |
Extra hit-test padding around the model in pixels.
Swift code snippet:
Objective C code snippet:
| - (BOOL) setCollisionEnabled: | (BOOL) | enabled |
Enables or disables collision tests for this object.
Swift code snippet:
Objective C code snippet:
| - (void) setData: | (nonnull NSData *) | data |
Method is used to set user-defined data for the map object.
| data | Data to store in the map object. |
Swift code snippet:
Objective C code snippet:
| - (BOOL) setInteractive: | (BOOL) | interactive |
Method is used to specify whether the map object can be interacted with.
| interactive | Specifies whether the object can be picked in the pickMapObjectAt method (true) or not (false). Default: false. |
Swift code snippet:
Objective C code snippet:
| - (BOOL) setModel: | (nullable id< NCModelProvider >) | model |
Sets the 3D asset (OBJ source + texture ImageProvider).
| model | Model provider ModelProvider. |
Swift code snippet:
Objective C code snippet:
| - (BOOL) setPosition: | (nonnull NCGlobalPoint *) | point | |
| sublocationId: | (nullable NSNumber *) | sublocationId |
Sets the anchor position of the model in WGS84 coordinates.
| point | Center / placement point GlobalPoint. |
| sublocationId | Floor this object is attached to, or null for the outdoor map. |
Swift code snippet:
Objective C code snippet:
| - (BOOL) setPositionAnimated: | (nonnull NCGlobalPoint *) | point | |
| sublocationId: | (nullable NSNumber *) | sublocationId | |
| duration: | (float) | duration | |
| type: | (NCAnimationType) | type |
Animates the model anchor to a new position.
| point | Target WGS84 coordinates GlobalPoint. |
| sublocationId | Floor this object is attached to, or null for the outdoor map. |
| duration | Animation duration in seconds. |
| type | Animation easing AnimationType. |
Swift code snippet:
Objective C code snippet:
| - (BOOL) setPriority: | (float) | priority |
Render order priority (higher draws above).
Swift code snippet:
Objective C code snippet:
| - (BOOL) setSize: | (float) | width | |
| height: | (float) | height |
Sets the on-screen size of the model in pixels (width and height).
Swift code snippet:
Objective C code snippet:
| - (BOOL) setTitle: | (nonnull NSString *) | title |
Method is used to set the title of the map object.
| title | The title to display on the location view. |
Swift code snippet:
Objective C code snippet:
| - (BOOL) setTitleWithStyle: | (nonnull NSString *) | title | |
| style: | (nonnull NCTitleStyle *) | style |
Method is used to set the title and its style for the map object.
| title | The title to display on the location view. |
| style | Title style parameters TitleStyle. |
Swift code snippet:
Objective C code snippet:
| - (BOOL) setVisible: | (BOOL) | visible |
Method is used to specify the visibility of the map object.
| visible | Specifies whether the object is visible (true) or hidden (false). Default: true. |
Swift code snippet:
Objective C code snippet:
|
readnonatomicassign |
Tells if this object is valid or not. Any method called on an invalid object will throw an exception. The object becomes invalid only on UI thread, and only when its implementation depends on objects already destroyed by now.
Definition at line 196 of file NCModelMapObject.h.