forked from enlightenment/efl
efl: rename geometry to graphics to be more general.
This commit is contained in:
parent
3635b63708
commit
1d49ff7df2
|
@ -5,7 +5,7 @@ efl_eolian_files = \
|
||||||
lib/efl/interfaces/efl_player.eo \
|
lib/efl/interfaces/efl_player.eo \
|
||||||
lib/efl/interfaces/efl_text.eo \
|
lib/efl/interfaces/efl_text.eo \
|
||||||
lib/efl/interfaces/efl_text_properties.eo \
|
lib/efl/interfaces/efl_text_properties.eo \
|
||||||
lib/efl/interfaces/efl_geometry_shape.eo
|
lib/efl/interfaces/efl_graphics_shape.eo
|
||||||
|
|
||||||
efl_eolian_files_h = $(efl_eolian_files:%.eo=%.eo.h)
|
efl_eolian_files_h = $(efl_eolian_files:%.eo=%.eo.h)
|
||||||
efl_eolian_files_c = $(efl_eolian_files:%.eo=%.eo.c)
|
efl_eolian_files_c = $(efl_eolian_files:%.eo=%.eo.c)
|
||||||
|
|
|
@ -23,11 +23,11 @@ struct _Ector_Renderer_Shape_Data
|
||||||
int r, g, b, a;
|
int r, g, b, a;
|
||||||
} color;
|
} color;
|
||||||
|
|
||||||
Efl_Geometry_Dash *dash;
|
Efl_Graphics_Dash *dash;
|
||||||
unsigned int dash_length;
|
unsigned int dash_length;
|
||||||
|
|
||||||
Efl_Geometry_Cap cap;
|
Efl_Graphics_Cap cap;
|
||||||
Efl_Geometry_Cap join;
|
Efl_Graphics_Cap join;
|
||||||
} stroke;
|
} stroke;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -77,7 +77,7 @@ _ector_renderer_shape_stroke_marker_get(Eo *obj EINA_UNUSED,
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_ector_renderer_shape_efl_geometry_shape_stroke_scale_set(Eo *obj EINA_UNUSED,
|
_ector_renderer_shape_efl_graphics_shape_stroke_scale_set(Eo *obj EINA_UNUSED,
|
||||||
Ector_Renderer_Shape_Data *pd,
|
Ector_Renderer_Shape_Data *pd,
|
||||||
double s)
|
double s)
|
||||||
{
|
{
|
||||||
|
@ -85,14 +85,14 @@ _ector_renderer_shape_efl_geometry_shape_stroke_scale_set(Eo *obj EINA_UNUSED,
|
||||||
}
|
}
|
||||||
|
|
||||||
double
|
double
|
||||||
_ector_renderer_shape_efl_geometry_shape_stroke_scale_get(Eo *obj EINA_UNUSED,
|
_ector_renderer_shape_efl_graphics_shape_stroke_scale_get(Eo *obj EINA_UNUSED,
|
||||||
Ector_Renderer_Shape_Data *pd)
|
Ector_Renderer_Shape_Data *pd)
|
||||||
{
|
{
|
||||||
return pd->stroke.scale;
|
return pd->stroke.scale;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_ector_renderer_shape_efl_geometry_shape_stroke_color_set(Eo *obj EINA_UNUSED,
|
_ector_renderer_shape_efl_graphics_shape_stroke_color_set(Eo *obj EINA_UNUSED,
|
||||||
Ector_Renderer_Shape_Data *pd,
|
Ector_Renderer_Shape_Data *pd,
|
||||||
int r, int g, int b, int a)
|
int r, int g, int b, int a)
|
||||||
{
|
{
|
||||||
|
@ -104,7 +104,7 @@ _ector_renderer_shape_efl_geometry_shape_stroke_color_set(Eo *obj EINA_UNUSED,
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
_ector_renderer_shape_efl_geometry_shape_stroke_color_get(Eo *obj EINA_UNUSED,
|
_ector_renderer_shape_efl_graphics_shape_stroke_color_get(Eo *obj EINA_UNUSED,
|
||||||
Ector_Renderer_Shape_Data *pd,
|
Ector_Renderer_Shape_Data *pd,
|
||||||
int *r, int *g, int *b, int *a)
|
int *r, int *g, int *b, int *a)
|
||||||
{
|
{
|
||||||
|
@ -115,7 +115,7 @@ _ector_renderer_shape_efl_geometry_shape_stroke_color_get(Eo *obj EINA_UNUSED,
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_ector_renderer_shape_efl_geometry_shape_stroke_width_set(Eo *obj EINA_UNUSED,
|
_ector_renderer_shape_efl_graphics_shape_stroke_width_set(Eo *obj EINA_UNUSED,
|
||||||
Ector_Renderer_Shape_Data *pd,
|
Ector_Renderer_Shape_Data *pd,
|
||||||
double w)
|
double w)
|
||||||
{
|
{
|
||||||
|
@ -123,14 +123,14 @@ _ector_renderer_shape_efl_geometry_shape_stroke_width_set(Eo *obj EINA_UNUSED,
|
||||||
}
|
}
|
||||||
|
|
||||||
double
|
double
|
||||||
_ector_renderer_shape_efl_geometry_shape_stroke_width_get(Eo *obj EINA_UNUSED,
|
_ector_renderer_shape_efl_graphics_shape_stroke_width_get(Eo *obj EINA_UNUSED,
|
||||||
Ector_Renderer_Shape_Data *pd)
|
Ector_Renderer_Shape_Data *pd)
|
||||||
{
|
{
|
||||||
return pd->stroke.width;
|
return pd->stroke.width;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_ector_renderer_shape_efl_geometry_shape_stroke_location_set(Eo *obj EINA_UNUSED,
|
_ector_renderer_shape_efl_graphics_shape_stroke_location_set(Eo *obj EINA_UNUSED,
|
||||||
Ector_Renderer_Shape_Data *pd,
|
Ector_Renderer_Shape_Data *pd,
|
||||||
double centered)
|
double centered)
|
||||||
{
|
{
|
||||||
|
@ -138,19 +138,19 @@ _ector_renderer_shape_efl_geometry_shape_stroke_location_set(Eo *obj EINA_UNUSED
|
||||||
}
|
}
|
||||||
|
|
||||||
double
|
double
|
||||||
_ector_renderer_shape_efl_geometry_shape_stroke_location_get(Eo *obj EINA_UNUSED,
|
_ector_renderer_shape_efl_graphics_shape_stroke_location_get(Eo *obj EINA_UNUSED,
|
||||||
Ector_Renderer_Shape_Data *pd)
|
Ector_Renderer_Shape_Data *pd)
|
||||||
{
|
{
|
||||||
return pd->stroke.centered;
|
return pd->stroke.centered;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_ector_renderer_shape_efl_geometry_shape_stroke_dash_set(Eo *obj EINA_UNUSED,
|
_ector_renderer_shape_efl_graphics_shape_stroke_dash_set(Eo *obj EINA_UNUSED,
|
||||||
Ector_Renderer_Shape_Data *pd,
|
Ector_Renderer_Shape_Data *pd,
|
||||||
const Efl_Geometry_Dash *dash,
|
const Efl_Graphics_Dash *dash,
|
||||||
unsigned int length)
|
unsigned int length)
|
||||||
{
|
{
|
||||||
Efl_Geometry_Dash *tmp;
|
Efl_Graphics_Dash *tmp;
|
||||||
|
|
||||||
if (!dash)
|
if (!dash)
|
||||||
{
|
{
|
||||||
|
@ -160,18 +160,18 @@ _ector_renderer_shape_efl_geometry_shape_stroke_dash_set(Eo *obj EINA_UNUSED,
|
||||||
return ;
|
return ;
|
||||||
}
|
}
|
||||||
|
|
||||||
tmp = realloc(pd->stroke.dash, length * sizeof (Efl_Geometry_Dash));
|
tmp = realloc(pd->stroke.dash, length * sizeof (Efl_Graphics_Dash));
|
||||||
if (!tmp) return ;
|
if (!tmp) return ;
|
||||||
memcpy(tmp, dash, length * sizeof (Efl_Geometry_Dash));
|
memcpy(tmp, dash, length * sizeof (Efl_Graphics_Dash));
|
||||||
|
|
||||||
pd->stroke.dash = tmp;
|
pd->stroke.dash = tmp;
|
||||||
pd->stroke.dash_length = length;
|
pd->stroke.dash_length = length;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_ector_renderer_shape_efl_geometry_shape_stroke_dash_get(Eo *obj EINA_UNUSED,
|
_ector_renderer_shape_efl_graphics_shape_stroke_dash_get(Eo *obj EINA_UNUSED,
|
||||||
Ector_Renderer_Shape_Data *pd,
|
Ector_Renderer_Shape_Data *pd,
|
||||||
const Efl_Geometry_Dash **dash,
|
const Efl_Graphics_Dash **dash,
|
||||||
unsigned int *length)
|
unsigned int *length)
|
||||||
{
|
{
|
||||||
if (dash) *dash = pd->stroke.dash;
|
if (dash) *dash = pd->stroke.dash;
|
||||||
|
@ -179,39 +179,39 @@ _ector_renderer_shape_efl_geometry_shape_stroke_dash_get(Eo *obj EINA_UNUSED,
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_ector_renderer_shape_efl_geometry_shape_stroke_cap_set(Eo *obj EINA_UNUSED,
|
_ector_renderer_shape_efl_graphics_shape_stroke_cap_set(Eo *obj EINA_UNUSED,
|
||||||
Ector_Renderer_Shape_Data *pd,
|
Ector_Renderer_Shape_Data *pd,
|
||||||
Efl_Geometry_Cap c)
|
Efl_Graphics_Cap c)
|
||||||
{
|
{
|
||||||
pd->stroke.cap = c;
|
pd->stroke.cap = c;
|
||||||
}
|
}
|
||||||
|
|
||||||
Efl_Geometry_Cap
|
Efl_Graphics_Cap
|
||||||
_ector_renderer_shape_efl_geometry_shape_stroke_cap_get(Eo *obj EINA_UNUSED,
|
_ector_renderer_shape_efl_graphics_shape_stroke_cap_get(Eo *obj EINA_UNUSED,
|
||||||
Ector_Renderer_Shape_Data *pd)
|
Ector_Renderer_Shape_Data *pd)
|
||||||
{
|
{
|
||||||
return pd->stroke.cap;
|
return pd->stroke.cap;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_ector_renderer_shape_efl_geometry_shape_stroke_join_set(Eo *obj EINA_UNUSED,
|
_ector_renderer_shape_efl_graphics_shape_stroke_join_set(Eo *obj EINA_UNUSED,
|
||||||
Ector_Renderer_Shape_Data *pd,
|
Ector_Renderer_Shape_Data *pd,
|
||||||
Efl_Geometry_Join j)
|
Efl_Graphics_Join j)
|
||||||
{
|
{
|
||||||
pd->stroke.join = j;
|
pd->stroke.join = j;
|
||||||
}
|
}
|
||||||
|
|
||||||
Efl_Geometry_Join
|
Efl_Graphics_Join
|
||||||
_ector_renderer_shape_efl_geometry_shape_stroke_join_get(Eo *obj EINA_UNUSED,
|
_ector_renderer_shape_efl_graphics_shape_stroke_join_get(Eo *obj EINA_UNUSED,
|
||||||
Ector_Renderer_Shape_Data *pd)
|
Ector_Renderer_Shape_Data *pd)
|
||||||
{
|
{
|
||||||
return pd->stroke.join;
|
return pd->stroke.join;
|
||||||
}
|
}
|
||||||
|
|
||||||
Eina_Bool
|
Eina_Bool
|
||||||
_ector_renderer_shape_efl_geometry_shape_path_set(Eo *obj,
|
_ector_renderer_shape_efl_graphics_shape_path_set(Eo *obj,
|
||||||
Ector_Renderer_Shape_Data *pd,
|
Ector_Renderer_Shape_Data *pd,
|
||||||
const Efl_Geometry_Path_Command *op,
|
const Efl_Graphics_Path_Command *op,
|
||||||
const double *points)
|
const double *points)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
class Ector.Renderer.Shape (Ector.Renderer.Base, Efl.Geometry.Shape)
|
class Ector.Renderer.Shape (Ector.Renderer.Base, Efl.Graphics.Shape)
|
||||||
{
|
{
|
||||||
eo_prefix: ector_renderer_shape;
|
eo_prefix: ector_renderer_shape;
|
||||||
legacy_prefix: null;
|
legacy_prefix: null;
|
||||||
|
@ -32,14 +32,14 @@ class Ector.Renderer.Shape (Ector.Renderer.Base, Efl.Geometry.Shape)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
implements {
|
implements {
|
||||||
Efl.Geometry.Shape.stroke_scale;
|
Efl.Graphics.Shape.stroke_scale;
|
||||||
Efl.Geometry.Shape.stroke_color;
|
Efl.Graphics.Shape.stroke_color;
|
||||||
Efl.Geometry.Shape.stroke_width;
|
Efl.Graphics.Shape.stroke_width;
|
||||||
Efl.Geometry.Shape.stroke_location;
|
Efl.Graphics.Shape.stroke_location;
|
||||||
Efl.Geometry.Shape.stroke_dash;
|
Efl.Graphics.Shape.stroke_dash;
|
||||||
Efl.Geometry.Shape.stroke_cap;
|
Efl.Graphics.Shape.stroke_cap;
|
||||||
Efl.Geometry.Shape.stroke_join;
|
Efl.Graphics.Shape.stroke_join;
|
||||||
Efl.Geometry.Shape.path_set;
|
Efl.Graphics.Shape.path_set;
|
||||||
Ector.Renderer.Base.prepare;
|
Ector.Renderer.Base.prepare;
|
||||||
Eo.Base.constructor;
|
Eo.Base.constructor;
|
||||||
Eo.Base.destructor;
|
Eo.Base.destructor;
|
||||||
|
|
|
@ -38,28 +38,28 @@ extern "C"
|
||||||
* Path command enum.
|
* Path command enum.
|
||||||
*
|
*
|
||||||
* @since 1.13
|
* @since 1.13
|
||||||
* @ingroup Efl_Geometry_Shape
|
* @ingroup Efl_Graphics_Shape
|
||||||
*/
|
*/
|
||||||
typedef enum _Efl_Geometry_Path_Command
|
typedef enum _Efl_Graphics_Path_Command
|
||||||
{
|
{
|
||||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_END = 0, /**< End of the stream of command */
|
EFL_GRAPHICS_PATH_COMMAND_TYPE_END = 0, /**< End of the stream of command */
|
||||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_MOVE_TO, /**< A move command type */
|
EFL_GRAPHICS_PATH_COMMAND_TYPE_MOVE_TO, /**< A move command type */
|
||||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_LINE_TO, /**< A line command type */
|
EFL_GRAPHICS_PATH_COMMAND_TYPE_LINE_TO, /**< A line command type */
|
||||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_QUADRATIC_TO, /**< A quadratic command type */
|
EFL_GRAPHICS_PATH_COMMAND_TYPE_QUADRATIC_TO, /**< A quadratic command type */
|
||||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_SQUADRATIC_TO, /**< A smooth quadratic command type */
|
EFL_GRAPHICS_PATH_COMMAND_TYPE_SQUADRATIC_TO, /**< A smooth quadratic command type */
|
||||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_CUBIC_TO, /**< A cubic command type */
|
EFL_GRAPHICS_PATH_COMMAND_TYPE_CUBIC_TO, /**< A cubic command type */
|
||||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_SCUBIC_TO, /**< A smooth cubic command type */
|
EFL_GRAPHICS_PATH_COMMAND_TYPE_SCUBIC_TO, /**< A smooth cubic command type */
|
||||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_ARC_TO, /**< An arc command type */
|
EFL_GRAPHICS_PATH_COMMAND_TYPE_ARC_TO, /**< An arc command type */
|
||||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_CLOSE, /**< A close command type */
|
EFL_GRAPHICS_PATH_COMMAND_TYPE_CLOSE, /**< A close command type */
|
||||||
EFL_GEOMETRY_PATH_COMMAND_TYPE_LAST, /**< Not a valid command, but last one according to this version header */
|
EFL_GRAPHICS_PATH_COMMAND_TYPE_LAST, /**< Not a valid command, but last one according to this version header */
|
||||||
} Efl_Geometry_Path_Command;
|
} Efl_Graphics_Path_Command;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Type describing dash
|
* Type describing dash
|
||||||
* @since 1.13
|
* @since 1.13
|
||||||
*/
|
*/
|
||||||
typedef struct _Efl_Geometry_Dash Efl_Geometry_Dash;
|
typedef struct _Efl_Graphics_Dash Efl_Graphics_Dash;
|
||||||
struct _Efl_Geometry_Dash
|
struct _Efl_Graphics_Dash
|
||||||
{
|
{
|
||||||
double length;
|
double length;
|
||||||
double gap;
|
double gap;
|
||||||
|
@ -69,25 +69,25 @@ struct _Efl_Geometry_Dash
|
||||||
* Type defining how a line end.
|
* Type defining how a line end.
|
||||||
* @since 1.13
|
* @since 1.13
|
||||||
*/
|
*/
|
||||||
typedef enum _Efl_Geometry_Cap
|
typedef enum _Efl_Graphics_Cap
|
||||||
{
|
{
|
||||||
EFL_GEOMETRY_CAP_BUTT,
|
EFL_GRAPHICS_CAP_BUTT,
|
||||||
EFL_GEOMETRY_CAP_ROUND,
|
EFL_GRAPHICS_CAP_ROUND,
|
||||||
EFL_GEOMETRY_CAP_SQUARE,
|
EFL_GRAPHICS_CAP_SQUARE,
|
||||||
EFL_GEOMETRY_CAP_LAST
|
EFL_GRAPHICS_CAP_LAST
|
||||||
} Efl_Geometry_Cap;
|
} Efl_Graphics_Cap;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Type defining how join between path are drawn.
|
* Type defining how join between path are drawn.
|
||||||
* @since 1.13
|
* @since 1.13
|
||||||
*/
|
*/
|
||||||
typedef enum _Efl_Geometry_Join
|
typedef enum _Efl_Graphics_Join
|
||||||
{
|
{
|
||||||
EFL_GEOMETRY_JOIN_MITER,
|
EFL_GRAPHICS_JOIN_MITER,
|
||||||
EFL_GEOMETRY_JOIN_ROUND,
|
EFL_GRAPHICS_JOIN_ROUND,
|
||||||
EFL_GEOMETRY_JOIN_BEVEL,
|
EFL_GRAPHICS_JOIN_BEVEL,
|
||||||
EFL_GEOMETRY_JOIN_LAST
|
EFL_GRAPHICS_JOIN_LAST
|
||||||
} Efl_Geometry_Join;
|
} Efl_Graphics_Join;
|
||||||
|
|
||||||
#ifdef EFL_BETA_API_SUPPORT
|
#ifdef EFL_BETA_API_SUPPORT
|
||||||
|
|
||||||
|
@ -99,7 +99,7 @@ typedef enum _Efl_Geometry_Join
|
||||||
#include "interfaces/efl_text.eo.h"
|
#include "interfaces/efl_text.eo.h"
|
||||||
#include "interfaces/efl_text_properties.eo.h"
|
#include "interfaces/efl_text_properties.eo.h"
|
||||||
|
|
||||||
#include "interfaces/efl_geometry_shape.eo.h"
|
#include "interfaces/efl_graphics_shape.eo.h"
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
interface Efl.Geometry.Shape
|
interface Efl.Graphics.Shape
|
||||||
{
|
{
|
||||||
legacy_prefix: null;
|
legacy_prefix: null;
|
||||||
properties {
|
properties {
|
||||||
|
@ -47,7 +47,7 @@ interface Efl.Geometry.Shape
|
||||||
get {
|
get {
|
||||||
}
|
}
|
||||||
values {
|
values {
|
||||||
const(Efl_Geometry_Dash) *dash;
|
const(Efl_Graphics_Dash) *dash;
|
||||||
uint length;
|
uint length;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -57,7 +57,7 @@ interface Efl.Geometry.Shape
|
||||||
get {
|
get {
|
||||||
}
|
}
|
||||||
values {
|
values {
|
||||||
Efl_Geometry_Cap c;
|
Efl_Graphics_Cap c;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
stroke_join {
|
stroke_join {
|
||||||
|
@ -66,7 +66,7 @@ interface Efl.Geometry.Shape
|
||||||
get {
|
get {
|
||||||
}
|
}
|
||||||
values {
|
values {
|
||||||
Efl_Geometry_Join j;
|
Efl_Graphics_Join j;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -74,7 +74,7 @@ interface Efl.Geometry.Shape
|
||||||
path_set {
|
path_set {
|
||||||
return: bool;
|
return: bool;
|
||||||
params {
|
params {
|
||||||
@in const(Efl_Geometry_Path_Command) *op;
|
@in const(Efl_Graphics_Path_Command) *op;
|
||||||
@in const(double) *points;
|
@in const(double) *points;
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -11,4 +11,4 @@
|
||||||
#include "interfaces/efl_text.eo.c"
|
#include "interfaces/efl_text.eo.c"
|
||||||
#include "interfaces/efl_text_properties.eo.c"
|
#include "interfaces/efl_text_properties.eo.c"
|
||||||
|
|
||||||
#include "interfaces/efl_geometry_shape.eo.c"
|
#include "interfaces/efl_graphics_shape.eo.c"
|
||||||
|
|
|
@ -22,7 +22,7 @@ struct _Evas_VG_Container_Data
|
||||||
};
|
};
|
||||||
|
|
||||||
Eina_Bool
|
Eina_Bool
|
||||||
efl_geometry_path_dup(Efl_Geometry_Path_Command **out_cmd, double **out_pts,
|
efl_graphics_path_dup(Efl_Graphics_Path_Command **out_cmd, double **out_pts,
|
||||||
const Efl_Geometry_Path_Command *in_cmd, const double *in_pts);
|
const Efl_Graphics_Path_Command *in_cmd, const double *in_pts);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -8,13 +8,13 @@
|
||||||
typedef struct _Evas_VG_Shape_Data Evas_VG_Shape_Data;
|
typedef struct _Evas_VG_Shape_Data Evas_VG_Shape_Data;
|
||||||
struct _Evas_VG_Shape_Data
|
struct _Evas_VG_Shape_Data
|
||||||
{
|
{
|
||||||
Efl_Geometry_Path_Command *op;
|
Efl_Graphics_Path_Command *op;
|
||||||
double *points;
|
double *points;
|
||||||
|
|
||||||
Evas_VG_Node *fill;
|
Evas_VG_Node *fill;
|
||||||
|
|
||||||
struct {
|
struct {
|
||||||
Efl_Geometry_Dash *dash;
|
Efl_Graphics_Dash *dash;
|
||||||
Evas_VG_Node *fill;
|
Evas_VG_Node *fill;
|
||||||
Evas_VG_Node *marker;
|
Evas_VG_Node *marker;
|
||||||
|
|
||||||
|
@ -26,8 +26,8 @@ struct _Evas_VG_Shape_Data
|
||||||
|
|
||||||
unsigned int dash_count;
|
unsigned int dash_count;
|
||||||
|
|
||||||
Efl_Geometry_Cap cap;
|
Efl_Graphics_Cap cap;
|
||||||
Efl_Geometry_Join join;
|
Efl_Graphics_Join join;
|
||||||
} stroke;
|
} stroke;
|
||||||
|
|
||||||
unsigned int op_count;
|
unsigned int op_count;
|
||||||
|
@ -35,9 +35,9 @@ struct _Evas_VG_Shape_Data
|
||||||
};
|
};
|
||||||
|
|
||||||
Eina_Bool
|
Eina_Bool
|
||||||
_evas_vg_shape_efl_geometry_shape_path_set(Eo *obj EINA_UNUSED,
|
_evas_vg_shape_efl_graphics_shape_path_set(Eo *obj EINA_UNUSED,
|
||||||
Evas_VG_Shape_Data *pd,
|
Evas_VG_Shape_Data *pd,
|
||||||
const Efl_Geometry_Path_Command *op,
|
const Efl_Graphics_Path_Command *op,
|
||||||
const double *points)
|
const double *points)
|
||||||
{
|
{
|
||||||
free(pd->points);
|
free(pd->points);
|
||||||
|
@ -45,7 +45,7 @@ _evas_vg_shape_efl_geometry_shape_path_set(Eo *obj EINA_UNUSED,
|
||||||
free(pd->op);
|
free(pd->op);
|
||||||
pd->op = NULL;
|
pd->op = NULL;
|
||||||
|
|
||||||
return efl_geometry_path_dup(&pd->op, &pd->points, op, points);
|
return efl_graphics_path_dup(&pd->op, &pd->points, op, points);
|
||||||
}
|
}
|
||||||
|
|
||||||
Eina_Bool
|
Eina_Bool
|
||||||
|
@ -59,8 +59,8 @@ void
|
||||||
_evas_vg_shape_eo_base_constructor(Eo *obj, Evas_VG_Shape_Data *pd EINA_UNUSED)
|
_evas_vg_shape_eo_base_constructor(Eo *obj, Evas_VG_Shape_Data *pd EINA_UNUSED)
|
||||||
{
|
{
|
||||||
eo_do_super(obj, MY_CLASS, eo_constructor());
|
eo_do_super(obj, MY_CLASS, eo_constructor());
|
||||||
pd->stroke.cap = EFL_GEOMETRY_CAP_BUTT;
|
pd->stroke.cap = EFL_GRAPHICS_CAP_BUTT;
|
||||||
pd->stroke.join = EFL_GEOMETRY_JOIN_MITER;
|
pd->stroke.join = EFL_GRAPHICS_JOIN_MITER;
|
||||||
pd->stroke.scale = 1;
|
pd->stroke.scale = 1;
|
||||||
pd->stroke.a = 1;
|
pd->stroke.a = 1;
|
||||||
pd->stroke.centered = 0.5;
|
pd->stroke.centered = 0.5;
|
||||||
|
@ -90,7 +90,7 @@ _evas_vg_shape_fill_get(Eo *obj EINA_UNUSED, Evas_VG_Shape_Data *pd)
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_evas_vg_shape_efl_geometry_shape_stroke_scale_set(Eo *obj EINA_UNUSED,
|
_evas_vg_shape_efl_graphics_shape_stroke_scale_set(Eo *obj EINA_UNUSED,
|
||||||
Evas_VG_Shape_Data *pd,
|
Evas_VG_Shape_Data *pd,
|
||||||
double s)
|
double s)
|
||||||
{
|
{
|
||||||
|
@ -98,14 +98,14 @@ _evas_vg_shape_efl_geometry_shape_stroke_scale_set(Eo *obj EINA_UNUSED,
|
||||||
}
|
}
|
||||||
|
|
||||||
double
|
double
|
||||||
_evas_vg_shape_efl_geometry_shape_stroke_scale_get(Eo *obj EINA_UNUSED,
|
_evas_vg_shape_efl_graphics_shape_stroke_scale_get(Eo *obj EINA_UNUSED,
|
||||||
Evas_VG_Shape_Data *pd)
|
Evas_VG_Shape_Data *pd)
|
||||||
{
|
{
|
||||||
return pd->stroke.scale;
|
return pd->stroke.scale;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_evas_vg_shape_efl_geometry_shape_stroke_color_set(Eo *obj EINA_UNUSED,
|
_evas_vg_shape_efl_graphics_shape_stroke_color_set(Eo *obj EINA_UNUSED,
|
||||||
Evas_VG_Shape_Data *pd,
|
Evas_VG_Shape_Data *pd,
|
||||||
int r, int g, int b, int a)
|
int r, int g, int b, int a)
|
||||||
{
|
{
|
||||||
|
@ -116,7 +116,7 @@ _evas_vg_shape_efl_geometry_shape_stroke_color_set(Eo *obj EINA_UNUSED,
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_evas_vg_shape_efl_geometry_shape_stroke_color_get(Eo *obj EINA_UNUSED,
|
_evas_vg_shape_efl_graphics_shape_stroke_color_get(Eo *obj EINA_UNUSED,
|
||||||
Evas_VG_Shape_Data *pd,
|
Evas_VG_Shape_Data *pd,
|
||||||
int *r, int *g, int *b, int *a)
|
int *r, int *g, int *b, int *a)
|
||||||
{
|
{
|
||||||
|
@ -145,7 +145,7 @@ _evas_vg_shape_stroke_fill_get(Eo *obj EINA_UNUSED,
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_evas_vg_shape_efl_geometry_shape_stroke_width_set(Eo *obj EINA_UNUSED,
|
_evas_vg_shape_efl_graphics_shape_stroke_width_set(Eo *obj EINA_UNUSED,
|
||||||
Evas_VG_Shape_Data *pd,
|
Evas_VG_Shape_Data *pd,
|
||||||
double w)
|
double w)
|
||||||
{
|
{
|
||||||
|
@ -153,14 +153,14 @@ _evas_vg_shape_efl_geometry_shape_stroke_width_set(Eo *obj EINA_UNUSED,
|
||||||
}
|
}
|
||||||
|
|
||||||
double
|
double
|
||||||
_evas_vg_shape_efl_geometry_shape_stroke_width_get(Eo *obj EINA_UNUSED,
|
_evas_vg_shape_efl_graphics_shape_stroke_width_get(Eo *obj EINA_UNUSED,
|
||||||
Evas_VG_Shape_Data *pd)
|
Evas_VG_Shape_Data *pd)
|
||||||
{
|
{
|
||||||
return pd->stroke.width;
|
return pd->stroke.width;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_evas_vg_shape_efl_geometry_shape_stroke_location_set(Eo *obj EINA_UNUSED,
|
_evas_vg_shape_efl_graphics_shape_stroke_location_set(Eo *obj EINA_UNUSED,
|
||||||
Evas_VG_Shape_Data *pd,
|
Evas_VG_Shape_Data *pd,
|
||||||
double centered)
|
double centered)
|
||||||
{
|
{
|
||||||
|
@ -168,33 +168,33 @@ _evas_vg_shape_efl_geometry_shape_stroke_location_set(Eo *obj EINA_UNUSED,
|
||||||
}
|
}
|
||||||
|
|
||||||
double
|
double
|
||||||
_evas_vg_shape_efl_geometry_shape_stroke_location_get(Eo *obj EINA_UNUSED,
|
_evas_vg_shape_efl_graphics_shape_stroke_location_get(Eo *obj EINA_UNUSED,
|
||||||
Evas_VG_Shape_Data *pd)
|
Evas_VG_Shape_Data *pd)
|
||||||
{
|
{
|
||||||
return pd->stroke.centered;
|
return pd->stroke.centered;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_evas_vg_shape_efl_geometry_shape_stroke_dash_set(Eo *obj EINA_UNUSED,
|
_evas_vg_shape_efl_graphics_shape_stroke_dash_set(Eo *obj EINA_UNUSED,
|
||||||
Evas_VG_Shape_Data *pd,
|
Evas_VG_Shape_Data *pd,
|
||||||
const Efl_Geometry_Dash *dash,
|
const Efl_Graphics_Dash *dash,
|
||||||
unsigned int length)
|
unsigned int length)
|
||||||
{
|
{
|
||||||
free(pd->stroke.dash);
|
free(pd->stroke.dash);
|
||||||
pd->stroke.dash = NULL;
|
pd->stroke.dash = NULL;
|
||||||
pd->stroke.dash_count = 0;
|
pd->stroke.dash_count = 0;
|
||||||
|
|
||||||
pd->stroke.dash = malloc(sizeof (Efl_Geometry_Dash) * length);
|
pd->stroke.dash = malloc(sizeof (Efl_Graphics_Dash) * length);
|
||||||
if (!pd->stroke.dash) return ;
|
if (!pd->stroke.dash) return ;
|
||||||
|
|
||||||
memcpy(pd->stroke.dash, dash, sizeof (Efl_Geometry_Dash) * length);
|
memcpy(pd->stroke.dash, dash, sizeof (Efl_Graphics_Dash) * length);
|
||||||
pd->stroke.dash_count = length;
|
pd->stroke.dash_count = length;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_evas_vg_shape_efl_geometry_shape_stroke_dash_get(Eo *obj EINA_UNUSED,
|
_evas_vg_shape_efl_graphics_shape_stroke_dash_get(Eo *obj EINA_UNUSED,
|
||||||
Evas_VG_Shape_Data *pd,
|
Evas_VG_Shape_Data *pd,
|
||||||
const Efl_Geometry_Dash **dash,
|
const Efl_Graphics_Dash **dash,
|
||||||
unsigned int *length)
|
unsigned int *length)
|
||||||
{
|
{
|
||||||
if (dash) *dash = pd->stroke.dash;
|
if (dash) *dash = pd->stroke.dash;
|
||||||
|
@ -220,30 +220,30 @@ _evas_vg_shape_stroke_marker_get(Eo *obj EINA_UNUSED,
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_evas_vg_shape_efl_geometry_shape_stroke_cap_set(Eo *obj EINA_UNUSED,
|
_evas_vg_shape_efl_graphics_shape_stroke_cap_set(Eo *obj EINA_UNUSED,
|
||||||
Evas_VG_Shape_Data *pd,
|
Evas_VG_Shape_Data *pd,
|
||||||
Efl_Geometry_Cap c)
|
Efl_Graphics_Cap c)
|
||||||
{
|
{
|
||||||
pd->stroke.cap = c;
|
pd->stroke.cap = c;
|
||||||
}
|
}
|
||||||
|
|
||||||
Efl_Geometry_Cap
|
Efl_Graphics_Cap
|
||||||
_evas_vg_shape_efl_geometry_shape_stroke_cap_get(Eo *obj EINA_UNUSED,
|
_evas_vg_shape_efl_graphics_shape_stroke_cap_get(Eo *obj EINA_UNUSED,
|
||||||
Evas_VG_Shape_Data *pd)
|
Evas_VG_Shape_Data *pd)
|
||||||
{
|
{
|
||||||
return pd->stroke.cap;
|
return pd->stroke.cap;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
_evas_vg_shape_efl_geometry_shape_stroke_join_set(Eo *obj EINA_UNUSED,
|
_evas_vg_shape_efl_graphics_shape_stroke_join_set(Eo *obj EINA_UNUSED,
|
||||||
Evas_VG_Shape_Data *pd,
|
Evas_VG_Shape_Data *pd,
|
||||||
Efl_Geometry_Join j)
|
Efl_Graphics_Join j)
|
||||||
{
|
{
|
||||||
pd->stroke.join = j;
|
pd->stroke.join = j;
|
||||||
}
|
}
|
||||||
|
|
||||||
Efl_Geometry_Join
|
Efl_Graphics_Join
|
||||||
_evas_vg_shape_efl_geometry_shape_stroke_join_get(Eo *obj EINA_UNUSED,
|
_evas_vg_shape_efl_graphics_shape_stroke_join_get(Eo *obj EINA_UNUSED,
|
||||||
Evas_VG_Shape_Data *pd)
|
Evas_VG_Shape_Data *pd)
|
||||||
{
|
{
|
||||||
return pd->stroke.join;
|
return pd->stroke.join;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
class Evas.VG_Shape (Evas.VG_Node, Efl.Geometry.Shape)
|
class Evas.VG_Shape (Evas.VG_Node, Efl.Graphics.Shape)
|
||||||
{
|
{
|
||||||
eo_prefix: evas_vg_shape;
|
eo_prefix: evas_vg_shape;
|
||||||
legacy_prefix: null;
|
legacy_prefix: null;
|
||||||
|
@ -32,14 +32,14 @@ class Evas.VG_Shape (Evas.VG_Node, Efl.Geometry.Shape)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
implements {
|
implements {
|
||||||
Efl.Geometry.Shape.stroke_scale;
|
Efl.Graphics.Shape.stroke_scale;
|
||||||
Efl.Geometry.Shape.stroke_color;
|
Efl.Graphics.Shape.stroke_color;
|
||||||
Efl.Geometry.Shape.stroke_width;
|
Efl.Graphics.Shape.stroke_width;
|
||||||
Efl.Geometry.Shape.stroke_location;
|
Efl.Graphics.Shape.stroke_location;
|
||||||
Efl.Geometry.Shape.stroke_dash;
|
Efl.Graphics.Shape.stroke_dash;
|
||||||
Efl.Geometry.Shape.stroke_cap;
|
Efl.Graphics.Shape.stroke_cap;
|
||||||
Efl.Geometry.Shape.stroke_join;
|
Efl.Graphics.Shape.stroke_join;
|
||||||
Efl.Geometry.Shape.path_set;
|
Efl.Graphics.Shape.path_set;
|
||||||
Eo.Base.constructor;
|
Eo.Base.constructor;
|
||||||
Eo.Base.destructor;
|
Eo.Base.destructor;
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,33 +4,33 @@
|
||||||
#include "evas_vg_private.h"
|
#include "evas_vg_private.h"
|
||||||
|
|
||||||
static unsigned int
|
static unsigned int
|
||||||
efl_geometry_path_command_length(Efl_Geometry_Path_Command command)
|
efl_graphics_path_command_length(Efl_Graphics_Path_Command command)
|
||||||
{
|
{
|
||||||
switch (command)
|
switch (command)
|
||||||
{
|
{
|
||||||
case EFL_GEOMETRY_PATH_COMMAND_TYPE_END: return 0;
|
case EFL_GRAPHICS_PATH_COMMAND_TYPE_END: return 0;
|
||||||
case EFL_GEOMETRY_PATH_COMMAND_TYPE_MOVE_TO: return 2;
|
case EFL_GRAPHICS_PATH_COMMAND_TYPE_MOVE_TO: return 2;
|
||||||
case EFL_GEOMETRY_PATH_COMMAND_TYPE_LINE_TO: return 2;
|
case EFL_GRAPHICS_PATH_COMMAND_TYPE_LINE_TO: return 2;
|
||||||
case EFL_GEOMETRY_PATH_COMMAND_TYPE_QUADRATIC_TO: return 4;
|
case EFL_GRAPHICS_PATH_COMMAND_TYPE_QUADRATIC_TO: return 4;
|
||||||
case EFL_GEOMETRY_PATH_COMMAND_TYPE_SQUADRATIC_TO: return 2;
|
case EFL_GRAPHICS_PATH_COMMAND_TYPE_SQUADRATIC_TO: return 2;
|
||||||
case EFL_GEOMETRY_PATH_COMMAND_TYPE_CUBIC_TO: return 6;
|
case EFL_GRAPHICS_PATH_COMMAND_TYPE_CUBIC_TO: return 6;
|
||||||
case EFL_GEOMETRY_PATH_COMMAND_TYPE_SCUBIC_TO: return 4;
|
case EFL_GRAPHICS_PATH_COMMAND_TYPE_SCUBIC_TO: return 4;
|
||||||
case EFL_GEOMETRY_PATH_COMMAND_TYPE_ARC_TO: return 5;
|
case EFL_GRAPHICS_PATH_COMMAND_TYPE_ARC_TO: return 5;
|
||||||
case EFL_GEOMETRY_PATH_COMMAND_TYPE_CLOSE: return 0;
|
case EFL_GRAPHICS_PATH_COMMAND_TYPE_CLOSE: return 0;
|
||||||
case EFL_GEOMETRY_PATH_COMMAND_TYPE_LAST: return 0;
|
case EFL_GRAPHICS_PATH_COMMAND_TYPE_LAST: return 0;
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline void
|
static inline void
|
||||||
_efl_geometry_path_length(const Efl_Geometry_Path_Command *commands,
|
_efl_graphics_path_length(const Efl_Graphics_Path_Command *commands,
|
||||||
unsigned int *cmd_length,
|
unsigned int *cmd_length,
|
||||||
unsigned int *pts_length)
|
unsigned int *pts_length)
|
||||||
{
|
{
|
||||||
if (commands)
|
if (commands)
|
||||||
while (commands[*cmd_length] != EFL_GEOMETRY_PATH_COMMAND_TYPE_END)
|
while (commands[*cmd_length] != EFL_GRAPHICS_PATH_COMMAND_TYPE_END)
|
||||||
{
|
{
|
||||||
*pts_length += efl_geometry_path_command_length(commands[*cmd_length]);
|
*pts_length += efl_graphics_path_command_length(commands[*cmd_length]);
|
||||||
(*cmd_length)++;
|
(*cmd_length)++;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -39,49 +39,49 @@ _efl_geometry_path_length(const Efl_Geometry_Path_Command *commands,
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline Eina_Bool
|
static inline Eina_Bool
|
||||||
efl_geometry_path_grow(Efl_Geometry_Path_Command command,
|
efl_graphics_path_grow(Efl_Graphics_Path_Command command,
|
||||||
Efl_Geometry_Path_Command **commands, double **points,
|
Efl_Graphics_Path_Command **commands, double **points,
|
||||||
double **offset_point)
|
double **offset_point)
|
||||||
{
|
{
|
||||||
Efl_Geometry_Path_Command *cmd_tmp;
|
Efl_Graphics_Path_Command *cmd_tmp;
|
||||||
double *pts_tmp;
|
double *pts_tmp;
|
||||||
unsigned int cmd_length = 0, pts_length = 0;
|
unsigned int cmd_length = 0, pts_length = 0;
|
||||||
|
|
||||||
_efl_geometry_path_length(*commands, &cmd_length, &pts_length);
|
_efl_graphics_path_length(*commands, &cmd_length, &pts_length);
|
||||||
|
|
||||||
if (efl_geometry_path_command_length(command))
|
if (efl_graphics_path_command_length(command))
|
||||||
{
|
{
|
||||||
pts_length += efl_geometry_path_command_length(command);
|
pts_length += efl_graphics_path_command_length(command);
|
||||||
pts_tmp = realloc(*points, pts_length * sizeof (double));
|
pts_tmp = realloc(*points, pts_length * sizeof (double));
|
||||||
if (!pts_tmp) return EINA_FALSE;
|
if (!pts_tmp) return EINA_FALSE;
|
||||||
|
|
||||||
*points = pts_tmp;
|
*points = pts_tmp;
|
||||||
*offset_point = *points + pts_length - efl_geometry_path_command_length(command);
|
*offset_point = *points + pts_length - efl_graphics_path_command_length(command);
|
||||||
}
|
}
|
||||||
|
|
||||||
cmd_tmp = realloc(*commands,
|
cmd_tmp = realloc(*commands,
|
||||||
(cmd_length + 1) * sizeof (Efl_Geometry_Path_Command));
|
(cmd_length + 1) * sizeof (Efl_Graphics_Path_Command));
|
||||||
if (!cmd_tmp) return EINA_FALSE;
|
if (!cmd_tmp) return EINA_FALSE;
|
||||||
*commands = cmd_tmp;
|
*commands = cmd_tmp;
|
||||||
|
|
||||||
// Append the command
|
// Append the command
|
||||||
cmd_tmp[cmd_length - 1] = command;
|
cmd_tmp[cmd_length - 1] = command;
|
||||||
// NULL terminate the stream
|
// NULL terminate the stream
|
||||||
cmd_tmp[cmd_length] = EFL_GEOMETRY_PATH_COMMAND_TYPE_END;
|
cmd_tmp[cmd_length] = EFL_GRAPHICS_PATH_COMMAND_TYPE_END;
|
||||||
|
|
||||||
return EINA_TRUE;
|
return EINA_TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
Eina_Bool
|
Eina_Bool
|
||||||
efl_geometry_path_dup(Efl_Geometry_Path_Command **out_cmd, double **out_pts,
|
efl_graphics_path_dup(Efl_Graphics_Path_Command **out_cmd, double **out_pts,
|
||||||
const Efl_Geometry_Path_Command *in_cmd, const double *in_pts)
|
const Efl_Graphics_Path_Command *in_cmd, const double *in_pts)
|
||||||
{
|
{
|
||||||
unsigned int cmd_length = 0, pts_length = 0;
|
unsigned int cmd_length = 0, pts_length = 0;
|
||||||
|
|
||||||
_efl_geometry_path_length(in_cmd, &cmd_length, &pts_length);
|
_efl_graphics_path_length(in_cmd, &cmd_length, &pts_length);
|
||||||
|
|
||||||
*out_pts = malloc(pts_length * sizeof (double));
|
*out_pts = malloc(pts_length * sizeof (double));
|
||||||
*out_cmd = malloc(cmd_length * sizeof (Efl_Geometry_Path_Command));
|
*out_cmd = malloc(cmd_length * sizeof (Efl_Graphics_Path_Command));
|
||||||
if (!(*out_pts) || !(*out_cmd))
|
if (!(*out_pts) || !(*out_cmd))
|
||||||
{
|
{
|
||||||
free(*out_pts);
|
free(*out_pts);
|
||||||
|
@ -90,17 +90,17 @@ efl_geometry_path_dup(Efl_Geometry_Path_Command **out_cmd, double **out_pts,
|
||||||
}
|
}
|
||||||
|
|
||||||
memcpy(*out_pts, in_pts, pts_length * sizeof (double));
|
memcpy(*out_pts, in_pts, pts_length * sizeof (double));
|
||||||
memcpy(*out_cmd, in_cmd, cmd_length * sizeof (Efl_Geometry_Path_Command));
|
memcpy(*out_cmd, in_cmd, cmd_length * sizeof (Efl_Graphics_Path_Command));
|
||||||
return EINA_TRUE;
|
return EINA_TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
efl_geometry_path_append_move_to(Efl_Geometry_Path_Command **commands, double **points,
|
efl_graphics_path_append_move_to(Efl_Graphics_Path_Command **commands, double **points,
|
||||||
double x, double y)
|
double x, double y)
|
||||||
{
|
{
|
||||||
double *offset_point;
|
double *offset_point;
|
||||||
|
|
||||||
if (!efl_geometry_path_grow(EFL_GEOMETRY_PATH_COMMAND_TYPE_MOVE_TO,
|
if (!efl_graphics_path_grow(EFL_GRAPHICS_PATH_COMMAND_TYPE_MOVE_TO,
|
||||||
commands, points, &offset_point))
|
commands, points, &offset_point))
|
||||||
return ;
|
return ;
|
||||||
|
|
||||||
|
@ -109,12 +109,12 @@ efl_geometry_path_append_move_to(Efl_Geometry_Path_Command **commands, double **
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
efl_geometry_path_append_line_to(Efl_Geometry_Path_Command **commands, double **points,
|
efl_graphics_path_append_line_to(Efl_Graphics_Path_Command **commands, double **points,
|
||||||
double x, double y)
|
double x, double y)
|
||||||
{
|
{
|
||||||
double *offset_point;
|
double *offset_point;
|
||||||
|
|
||||||
if (!efl_geometry_path_grow(EFL_GEOMETRY_PATH_COMMAND_TYPE_LINE_TO,
|
if (!efl_graphics_path_grow(EFL_GRAPHICS_PATH_COMMAND_TYPE_LINE_TO,
|
||||||
commands, points, &offset_point))
|
commands, points, &offset_point))
|
||||||
return ;
|
return ;
|
||||||
|
|
||||||
|
@ -123,12 +123,12 @@ efl_geometry_path_append_line_to(Efl_Geometry_Path_Command **commands, double **
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
efl_geometry_path_append_quadratic_to(Efl_Geometry_Path_Command **commands, double **points,
|
efl_graphics_path_append_quadratic_to(Efl_Graphics_Path_Command **commands, double **points,
|
||||||
double x, double y, double ctrl_x, double ctrl_y)
|
double x, double y, double ctrl_x, double ctrl_y)
|
||||||
{
|
{
|
||||||
double *offset_point;
|
double *offset_point;
|
||||||
|
|
||||||
if (!efl_geometry_path_grow(EFL_GEOMETRY_PATH_COMMAND_TYPE_QUADRATIC_TO,
|
if (!efl_graphics_path_grow(EFL_GRAPHICS_PATH_COMMAND_TYPE_QUADRATIC_TO,
|
||||||
commands, points, &offset_point))
|
commands, points, &offset_point))
|
||||||
return ;
|
return ;
|
||||||
|
|
||||||
|
@ -139,12 +139,12 @@ efl_geometry_path_append_quadratic_to(Efl_Geometry_Path_Command **commands, doub
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
efl_geometry_path_append_squadratic_to(Efl_Geometry_Path_Command **commands, double **points,
|
efl_graphics_path_append_squadratic_to(Efl_Graphics_Path_Command **commands, double **points,
|
||||||
double x, double y)
|
double x, double y)
|
||||||
{
|
{
|
||||||
double *offset_point;
|
double *offset_point;
|
||||||
|
|
||||||
if (!efl_geometry_path_grow(EFL_GEOMETRY_PATH_COMMAND_TYPE_SQUADRATIC_TO,
|
if (!efl_graphics_path_grow(EFL_GRAPHICS_PATH_COMMAND_TYPE_SQUADRATIC_TO,
|
||||||
commands, points, &offset_point))
|
commands, points, &offset_point))
|
||||||
return ;
|
return ;
|
||||||
|
|
||||||
|
@ -153,14 +153,14 @@ efl_geometry_path_append_squadratic_to(Efl_Geometry_Path_Command **commands, dou
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
efl_geometry_path_append_cubic_to(Efl_Geometry_Path_Command **commands, double **points,
|
efl_graphics_path_append_cubic_to(Efl_Graphics_Path_Command **commands, double **points,
|
||||||
double x, double y,
|
double x, double y,
|
||||||
double ctrl_x0, double ctrl_y0,
|
double ctrl_x0, double ctrl_y0,
|
||||||
double ctrl_x1, double ctrl_y1)
|
double ctrl_x1, double ctrl_y1)
|
||||||
{
|
{
|
||||||
double *offset_point;
|
double *offset_point;
|
||||||
|
|
||||||
if (!efl_geometry_path_grow(EFL_GEOMETRY_PATH_COMMAND_TYPE_CUBIC_TO,
|
if (!efl_graphics_path_grow(EFL_GRAPHICS_PATH_COMMAND_TYPE_CUBIC_TO,
|
||||||
commands, points, &offset_point))
|
commands, points, &offset_point))
|
||||||
return ;
|
return ;
|
||||||
|
|
||||||
|
@ -173,13 +173,13 @@ efl_geometry_path_append_cubic_to(Efl_Geometry_Path_Command **commands, double *
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
efl_geometry_path_append_scubic_to(Efl_Geometry_Path_Command **commands, double **points,
|
efl_graphics_path_append_scubic_to(Efl_Graphics_Path_Command **commands, double **points,
|
||||||
double x, double y,
|
double x, double y,
|
||||||
double ctrl_x, double ctrl_y)
|
double ctrl_x, double ctrl_y)
|
||||||
{
|
{
|
||||||
double *offset_point;
|
double *offset_point;
|
||||||
|
|
||||||
if (!efl_geometry_path_grow(EFL_GEOMETRY_PATH_COMMAND_TYPE_SCUBIC_TO,
|
if (!efl_graphics_path_grow(EFL_GRAPHICS_PATH_COMMAND_TYPE_SCUBIC_TO,
|
||||||
commands, points, &offset_point))
|
commands, points, &offset_point))
|
||||||
return ;
|
return ;
|
||||||
|
|
||||||
|
@ -190,14 +190,14 @@ efl_geometry_path_append_scubic_to(Efl_Geometry_Path_Command **commands, double
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
efl_geometry_path_append_arc_to(Efl_Geometry_Path_Command **commands, double **points,
|
efl_graphics_path_append_arc_to(Efl_Graphics_Path_Command **commands, double **points,
|
||||||
double x, double y,
|
double x, double y,
|
||||||
double rx, double ry,
|
double rx, double ry,
|
||||||
double angle)
|
double angle)
|
||||||
{
|
{
|
||||||
double *offset_point;
|
double *offset_point;
|
||||||
|
|
||||||
if (!efl_geometry_path_grow(EFL_GEOMETRY_PATH_COMMAND_TYPE_ARC_TO,
|
if (!efl_graphics_path_grow(EFL_GRAPHICS_PATH_COMMAND_TYPE_ARC_TO,
|
||||||
commands, points, &offset_point))
|
commands, points, &offset_point))
|
||||||
return ;
|
return ;
|
||||||
|
|
||||||
|
@ -209,21 +209,21 @@ efl_geometry_path_append_arc_to(Efl_Geometry_Path_Command **commands, double **p
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
efl_geometry_path_append_close(Efl_Geometry_Path_Command **commands, double **points)
|
efl_graphics_path_append_close(Efl_Graphics_Path_Command **commands, double **points)
|
||||||
{
|
{
|
||||||
double *offset_point;
|
double *offset_point;
|
||||||
|
|
||||||
efl_geometry_path_grow(EFL_GEOMETRY_PATH_COMMAND_TYPE_ARC_TO,
|
efl_graphics_path_grow(EFL_GRAPHICS_PATH_COMMAND_TYPE_ARC_TO,
|
||||||
commands, points, &offset_point);
|
commands, points, &offset_point);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
efl_geometry_path_append_circle(Efl_Geometry_Path_Command **commands, double **points,
|
efl_graphics_path_append_circle(Efl_Graphics_Path_Command **commands, double **points,
|
||||||
double x, double y, double radius)
|
double x, double y, double radius)
|
||||||
{
|
{
|
||||||
efl_geometry_path_append_move_to(commands, points, x, y - radius);
|
efl_graphics_path_append_move_to(commands, points, x, y - radius);
|
||||||
efl_geometry_path_append_arc_to(commands, points, x + radius, y, radius, radius, 0);
|
efl_graphics_path_append_arc_to(commands, points, x + radius, y, radius, radius, 0);
|
||||||
efl_geometry_path_append_arc_to(commands, points, x, y + radius, radius, radius, 0);
|
efl_graphics_path_append_arc_to(commands, points, x, y + radius, radius, radius, 0);
|
||||||
efl_geometry_path_append_arc_to(commands, points, x - radius, y, radius, radius, 0);
|
efl_graphics_path_append_arc_to(commands, points, x - radius, y, radius, radius, 0);
|
||||||
efl_geometry_path_append_arc_to(commands, points, x, y - radius, radius, radius, 0);
|
efl_graphics_path_append_arc_to(commands, points, x, y - radius, radius, radius, 0);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue