aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/evas/canvas/efl_gfx_map.eo
diff options
context:
space:
mode:
authorJean-Philippe Andre <jp.andre@samsung.com>2017-04-26 14:41:03 +0900
committerJean-Philippe Andre <jp.andre@samsung.com>2017-05-11 17:53:57 +0900
commitd111c6e1dd54e05a099fd36fbd64f53a55a2e7d8 (patch)
tree03aac283dd3f9eb527aa1dae295eebaa35a5a0c5 /src/lib/evas/canvas/efl_gfx_map.eo
parentevas map: Move Efl.Gfx.Map mixin to its own C file (diff)
downloadefl-d111c6e1dd54e05a099fd36fbd64f53a55a2e7d8.tar.gz
evas map: Replace EO APIs for populate with reset
Manual points population will eventually be useless as the map API will become more like a transformation API, where the current object geometry doesn't matter as much as which transformation is applied to it.
Diffstat (limited to 'src/lib/evas/canvas/efl_gfx_map.eo')
-rw-r--r--src/lib/evas/canvas/efl_gfx_map.eo58
1 files changed, 10 insertions, 48 deletions
diff --git a/src/lib/evas/canvas/efl_gfx_map.eo b/src/lib/evas/canvas/efl_gfx_map.eo
index 6c93d9eefd..720a972875 100644
--- a/src/lib/evas/canvas/efl_gfx_map.eo
+++ b/src/lib/evas/canvas/efl_gfx_map.eo
@@ -14,17 +14,9 @@ mixin Efl.Gfx.Map (Efl.Interface, Efl.Object)
3D effects.
At the moment of writing, maps can only have 4 points (no more, no less).
- Usually, it will be necessary to update the map points (start afresh with
- @.map_populate) whenever the object geometry changes.
Note: For now this mixin is only compatible with $Efl.Canvas.Object and
shouldn't be used anywhere else.
-
- Note: There are a few differences with legacy $Evas_Map:
- - A map is now a property of an object, rather than a separate entity.
- - @.map_move_sync is enabled by default
- - @.map_populate will be called automatically if another map function
- is called while the object has no map info.
]]
data: null;
methods {
@@ -49,6 +41,16 @@ mixin Efl.Gfx.Map (Efl.Interface, Efl.Object)
enabled: bool; [[Enabled state.]]
}
}
+ map_reset {
+ [[Resets the map transformation to its default state.
+
+ This will reset all transformations to identity, meaning the points'
+ colors, positions and UV coordinates will be reset to their default
+ values. This does not reset the @.map_enable flag.
+
+ @since 1.20
+ ]]
+ }
@property map_clockwise {
[[Clockwise state of a map (read-only).
@@ -163,46 +165,6 @@ mixin Efl.Gfx.Map (Efl.Interface, Efl.Object)
enable: bool; [[$true by default.]]
}
}
- @property map_point_z {
- [[Value of Z coordinate of point $idx.
-
- Useful to call @.map_populate without changing Z.
- ]]
- get {}
- keys {
- idx: int; [[Point]]
- }
- values {
- z: double; [[Z coordinate for point]]
- }
- }
- map_populate {
- [[Populate source and destination map points to match this object.
- ]]
- params {
- z: double @optional; [[Point Z coordinate (pre-pesrpective transform),
- used for all 4 points. 0 by default.]]
- }
- return: bool; [[$false in case of error.]]
- }
- map_populate_manual {
- [[Populate source and destination map points to match given geometry.
-
- Similar to @.map_populate, this call takes raw values instead of
- querying this object's unmapped geometry. The given size will be
- used to calculate destination points (@.map_point_coord) and set the
- image uv (@.map_point_image_uv).
- ]]
- params {
- x: double; [[X coordinate]]
- y: double; [[Y coordinate]]
- w: double; [[Width]]
- h: double; [[Height]]
- z: double @optional; [[Point Z coordinate (pre-perspective transform),
- used for all 4 points. 0 by default.]]
- }
- return: bool; [[$false in case of error.]]
- }
map_rotate {
[[Change the map to apply the given rotation.