2 * Copyright (C) 2013 HERE Global B.V. All rights reserved.
3 * This software, including documentation, is protected by copyright controlled by
4 * HERE Global B.V. (“Software”). All rights are reserved. Copying, including reproducing,
5 * storing, adapting or translating, any or all of this material requires the prior
6 * written consent of HERE Global B.V. You may use this
7 * Software in accordance with the terms and conditions defined in the
8 * HERE Location Platform Services Terms and Conditions, available at
9 * http://developer.here.com/terms-conditions-base
11 * As an additional permission to the above, you may distribute Software,
12 * in object code format as part of an Application, according to, and subject to, terms and
13 * conditions defined in the Tizen Software Development kit (“SDK”) License Agreement.
14 * You may distribute such object code format Application under terms of your choice,
15 * provided that the header and source files of the Software have not been modified.
18 #ifndef MAPOBJECTMARKER_H
19 #define MAPOBJECTMARKER_H
21 #include "common/HereMaps_global.h"
22 #ifndef TIZEN_MIGRATION
23 #include <FGraphics.h>
26 #include "maps/GeoMapObject.h"
27 #ifdef TIZEN_MIGRATION
28 #include "graphic/Dimension.h"
29 #include "graphic/Point.h"
30 #include "graphic/Bitmap.h"
31 #include "graphic/FloatPoint.h"
34 HERE_MAPS_BEGIN_NAMESPACE
40 * This class encapsulates a map marker object that indicates a location
41 * with an image (icon).
45 class EXPORT_API GeoMapObjectMarker : public GeoMapObject
50 * This method is the default constructor.
55 * This method is the (virtual) destructor.
57 virtual ~GeoMapObjectMarker();
60 * This method retrieves the object type.
62 * @return A member of the enumerated data type indicating the type of the
65 virtual Type GetType() const;
68 * This method retrieves the object bounding box.
70 * @return An object encapsulating the bounding box of the given object.
72 virtual GeoBoundingBox GetBoundingBox() const;
75 * This method sets the position of the given object.
77 * @param rCoord A constant reference to an object containing the geographic
78 * coordinates of the position of the given object.
80 virtual void SetPosition(const GeoCoordinates& rCoord);
83 * This method retrieves the position of the given object.
85 * @return A constant reference to an object containing the geographic
86 * coordinates of the position of the given object.
88 const GeoCoordinates& GetPosition() const;
91 * This method sets the marker image (icon).
93 * @param rBitmap A constant reference to an object encapsulating the icon
96 void SetBitmap(const Tizen::Maps::Bitmap& rBitmap);
99 * This method retrieves the width of the bitmap (icon).
101 * @return A value indicating the width of the bitmap (icon) in pixels.
103 unsigned int GetWidth() const;
106 * This method retrieves the height of the bitmap (icon).
108 * @return A value indicating the height of the bitmap (icon) in pixels.
110 unsigned int GetHeight() const;
113 * This method sets a value that defines the point on the marker bitmap that
114 * touches the map. The point is calculated relative to the top-left corner
117 * @param rOrigin A floating point value defining the origin.
119 void SetMarkerOrigin(const Tizen::Maps::FloatPoint& rOrigin);
122 * This method retrieves a value that represents the point on the marker
123 * bitmap that "touches" the map. The point is calculated relative to the
124 * top-left corner of the bitmap.
126 * @return A floating point value defining the bitmap origin.
128 Tizen::Maps::FloatPoint GetMarkerOrigin() const;
131 * This method retrieves a value that represents the point on the marker
132 * bitmap that "touches" the map. The point is calculated relative to the
133 * top-left corner of the bitmap.
135 * @return An object containing the pixel coordinates of the bitmap origin
136 * relative to the top-left corner of the bitmap.
138 Tizen::Maps::Point GetMarkerOriginInPx() const;
141 * This method retrieves the marker bitmap as a GL texture.
143 * @return A pointer to the GL texture of the bitmap.
145 GlTexture* GetGlTexture() const;
148 * This method checks if the object is valid (it geographic location is
151 * @return visible A Boolean, <code>true</code> if the object is valid,
152 * otherwise <code>false</code>.
154 virtual bool IsValid() const;
156 #ifdef TIZEN_MIGRATION
158 * This method retrieves the marker z-order.
160 * @return A value indicating z-order to the bitmap.
162 int GetZOrder() const;
165 * This method sets the marker z-order.
167 * @param nZorder A constant value of z-order.
169 void SetZOrder(int nZorder);
173 HERE_MAPS_NO_COPY_NO_ASSIGN(GeoMapObjectMarker);
175 class GeoMapObjectMarkerImpl;
176 GeoMapObjectMarkerImpl* m_impl;
179 HERE_MAPS_END_NAMESPACE