2019-03-11 05:31:55 -07:00
|
|
|
mixin @beta Ector.Surface extends Ector.Buffer
|
2015-04-03 07:14:58 -07:00
|
|
|
{
|
2016-04-22 01:53:09 -07:00
|
|
|
[[Surface interface for Ector]]
|
|
|
|
|
2019-05-09 07:16:42 -07:00
|
|
|
c_prefix: ector_surface;
|
2015-11-30 22:22:20 -08:00
|
|
|
data: null;
|
2015-05-07 08:36:45 -07:00
|
|
|
methods {
|
2019-12-05 22:22:56 -08:00
|
|
|
@property reference_point @pure_virtual {
|
2017-10-03 11:36:41 -07:00
|
|
|
[[This defines where (0,0) is in pixel coordinates inside the surface]]
|
2019-12-05 22:22:56 -08:00
|
|
|
set {}
|
|
|
|
get {}
|
2015-12-13 22:52:02 -08:00
|
|
|
values {
|
2016-04-22 01:53:09 -07:00
|
|
|
x: int; [[X coordinate for reference point]]
|
|
|
|
y: int; [[Y coordinate for reference point]]
|
2015-12-13 22:52:02 -08:00
|
|
|
}
|
2015-04-03 07:33:19 -07:00
|
|
|
}
|
2017-01-13 06:44:09 -08:00
|
|
|
renderer_factory_new @pure_virtual {
|
2016-04-22 01:53:09 -07:00
|
|
|
[[Create a new renderer factory for the given type]]
|
2016-11-15 06:55:09 -08:00
|
|
|
return: Efl.Object; [[Renderer factory object]] /* FIXME: Should be a more restricted type, only here for cyclic. */
|
2015-12-13 22:52:02 -08:00
|
|
|
params {
|
2019-05-26 08:25:15 -07:00
|
|
|
@in type: const(Efl.Class); [[Efl class]] /* FIXME: Should probably be a more restricted type */
|
2015-12-13 22:52:02 -08:00
|
|
|
}
|
2015-04-03 07:14:58 -07:00
|
|
|
}
|
2019-06-20 00:07:05 -07:00
|
|
|
draw_image @pure_virtual {
|
|
|
|
[[ Draw image's buffer to surface buffer. ]]
|
|
|
|
params {
|
|
|
|
@in image: Ector.Buffer; [[Image buffer]]
|
|
|
|
@in x: int; [[Buffer position x]]
|
|
|
|
@in y: int; [[Buffer position y]]
|
|
|
|
@in alpha: int; [[Buffer alpha value]]
|
|
|
|
}
|
|
|
|
return: bool; [[True if drawing was successful]]
|
|
|
|
}
|
2015-04-03 07:14:58 -07:00
|
|
|
}
|
|
|
|
}
|