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: |
| Sets the anchor position of the model in metric coordinates. | |
| (BOOL) | - setPositionAnimated: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 degrees (around the placement axis used by the engine). | |
| (BOOL) | - setAngleAnimated:duration:type: |
| Animates rotation to the given angle. | |
| (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) | - 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 degrees (around the placement axis used by the engine).
Swift code snippet:
Objective C code snippet:
| - (BOOL) setAngleAnimated: | (float) | angle | |
| duration: | (float) | duration | |
| type: | (NCAnimationType) | type |
Animates rotation to the given angle.
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 NCLocationPoint *) | point |
Sets the anchor position of the model in metric coordinates.
| point | Center / placement point LocationPoint. |
Swift code snippet:
Objective C code snippet:
| - (BOOL) setPositionAnimated: | (nonnull NCLocationPoint *) | point | |
| duration: | (float) | duration | |
| type: | (NCAnimationType) | type |
Animates the model anchor to a new position.
| point | Target metrics coordinates LocationPoint. |
| 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) 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 188 of file NCModelMapObject.h.