evas canvas3d: doc conversion of mesh

This commit is contained in:
Daniel Kolesa 2015-07-30 13:00:25 +01:00
parent 70a8304495
commit e607cb6f6f
1 changed files with 180 additions and 347 deletions

View File

@ -5,524 +5,357 @@ class Evas.Canvas3D.Mesh (Evas.Canvas3D.Object, Evas.Common_Interface, Efl.File)
methods { methods {
frame_vertex_data_set { frame_vertex_data_set {
/*@ [[Set the vertex data of the key frame of the given mesh.
Set the vertex data of the key frame of the given mesh.
This function make evas read from the given buffer whenever it requires. This function make evas read from the given buffer whenever it
If you want to release the buffer after calling this functions, use requires. If you want to release the buffer after calling this
evas_canvas3d_mesh_frame_vertex_data_copy_set() instead. functions, use @.frame_vertex_data_copy_set instead.
After setting the vertex data, further modifications should be protected After setting the vertex data, further modifications should be
by map/unmap pair. protected by map/unmap pair.
@see evas_canvas3d_mesh_frame_vertex_data_copy_set() See also @.frame_vertex_data_map, @.frame_vertex_data_unmap.
@see evas_canvas3d_mesh_frame_vertex_data_map() ]]
@see evas_canvas3d_mesh_frame_vertex_data_unmap()
@ingroup Evas_Canvas3D_Mesh
*/
params { params {
@in frame: int; /*@ The number of the key frame. */ @in frame: int; [[The number of the key frame.]]
@in attrib: Evas.Canvas3D.Vertex_Attrib; /*@ Vertex attribute ID. */ @in attrib: Evas.Canvas3D.Vertex_Attrib; [[Vertex attribute ID.]]
@in stride: int; /*@ Stride to go to the next vertex (in bytes). */ @in stride: int; [[Stride to go to the next vertex (in bytes).]]
@in data: const(void)*; /*@ Pointer to the vertex data buffer. */ @in data: const(void)*; [[Pointer to the vertex data buffer.]]
} }
} }
frame_vertex_data_copy_set { frame_vertex_data_copy_set {
/*@ [[Set the vertex data of the key frame of the given mesh by copying
Set the vertex data of the key frame of the given mesh by copying from a buffer. from a buffer. This function allocates internal vertex buffer and
This function allocates internal vertex buffer and copy from the given copy from the given buffer. So you can release the buffer. If you
buffer. So you can release the buffer. If you want to modify the vertex data want to modify the vertex data use @.frame_vertex_data_map. After
use evas_canvas3d_mesh_frame_vertex_data_map(). After finishing the modifications, finishing the modifications, you should call @.frame_vertex_data_unmap.
you should call evas_canvas3d_mesh_frame_vertex_data_unmap().
@see evas_canvas3d_mesh_frame_vertex_data_set() See also @.frame_vertex_data_set.
@see evas_canvas3d_mesh_frame_vertex_data_map() ]]
@see evas_canvas3d_mesh_frame_vertex_data_unmap()
@ingroup Evas_Canvas3D_Mesh
*/
params { params {
@in frame: int; /*@ The number of the key frame. */ @in frame: int; [[The number of the key frame.]]
@in attrib: Evas.Canvas3D.Vertex_Attrib; /*@ Vertex attribute ID. */ @in attrib: Evas.Canvas3D.Vertex_Attrib; [[Vertex attribute ID.]]
@in stride: int; /*@ Stride to go to the next vertex (in bytes). */ @in stride: int; [[Stride to go to the next vertex (in bytes).]]
@in data: const(void)*; /*@ Pointer to the vertex data buffer. */ @in data: const(void)*; [[Pointer to the vertex data buffer.]]
} }
} }
frame_vertex_data_map { frame_vertex_data_map {
/*@ [[Map the vertex buffer of the key frame of the given mesh.
Map the vertex buffer of the key frame of the given mesh.
After manipulating the mapped buffer, evas_canvas3d_mesh_frame_vertex_data_unmap() After manipulating the mapped buffer, @.frame_vertex_data_unmap
should be called to properly download the data to the engine. If the data should be called to properly download the data to the engine. If
was set using evas_canvas3d_mesh_frame_vertex_data_set(), pointer to the original the data was set using @.frame_vertex_data_set, pointer to the
buffer will be returned. Otherwise, the returned pointer can differ every original buffer will be returned. Otherwise, the returned pointer
time calling this function. can differ every time calling this function.
]]
@see evas_canvas3d_mesh_frame_vertex_data_unmap() return: void *; [[Starting address of the mapped vertex buffer.]]
@return Starting address of the mapped vertex buffer.
@ingroup Evas_Canvas3D_Mesh
*/
return: void *;
params { params {
@in frame: int; /*@ The number of the key frame. */ @in frame: int; [[The number of the key frame.]]
@in attrib: Evas.Canvas3D.Vertex_Attrib; /*@ Vertex attribute ID. */ @in attrib: Evas.Canvas3D.Vertex_Attrib; [[Vertex attribute ID.]]
} }
} }
frame_vertex_data_unmap { frame_vertex_data_unmap {
/*@ [[Unmap the vertex buffer of the key frame of the given mesh.
Unmap the vertex buffer of the key frame of the given mesh.
@see evas_canvas3d_mesh_frame_vertex_data_map()
@ingroup Evas_Canvas3D_Mesh
*/
See also @.frame_vertex_data_map.
]]
params { params {
@in frame: int; /*@ The number of the key frame. */ @in frame: int; [[The number of the key frame.]]
@in attrib: Evas.Canvas3D.Vertex_Attrib; /*@ Vertex attribute ID. */ @in attrib: Evas.Canvas3D.Vertex_Attrib; [[Vertex attribute ID.]]
} }
} }
frame_vertex_stride_get @const { frame_vertex_stride_get @const {
/*@ [[Get the vertex buffer stride of the key frame of the given mesh.
Get the vertex buffer stride of the key frame of the given mesh.
This function returns valid stride only when the vertex buffer is mapped. This function returns valid stride only when the vertex buffer
If the data was set with evas_canvas3d_mesh_frame_vertex_data_set(), the original is mapped. If the data was set with @.frame_vertex_data_set, the
stride will be returned unchanged. original stride will be returned unchanged.
]]
@see evas_canvas3d_mesh_frame_vertex_data_map() return: int; [[Stride to go to the next vertex (in bytes).]]
@return Stride to go to the next vertex (in bytes).
@ingroup Evas_Canvas3D_Mesh
*/
return: int;
params { params {
@in frame: int; /*@ The number of the key frame. */ @in frame: int; [[The number of the key frame.]]
@in attrib: Evas.Canvas3D.Vertex_Attrib; /*@ Vertex attribute ID. */ @in attrib: Evas.Canvas3D.Vertex_Attrib; [[Vertex attribute ID.]]
} }
} }
index_data_set { index_data_set {
/*@ [[Set the vertex index data of the given mesh.
Set the vertex index data of the given mesh.
When the index data is set, Evas 3D assembles vertices using the index data. When the index data is set, Evas 3D assembles vertices using the
If you want to free the data buffer, use evas_canvas3d_mesh_index_data_copy_set(). index data. If you want to free the data buffer, use
Further modifications should be made within map/unmap pair. @.index_data_copy_set. Further modifications should be made
within map/unmap pair.
@see evas_canvas3d_mesh_index_data_copy_set() ]]
@see evas_canvas3d_mesh_index_data_map()
@see evas_canvas3d_mesh_index_data_unmap()
@ingroup Evas_Canvas3D_Mesh
*/
params { params {
@in format: Evas.Canvas3D.Index_Format; /*@ Vertex index data format. */ @in format: Evas.Canvas3D.Index_Format; [[Vertex index data format.]]
@in count: int; /*@ Vertex index count. */ @in count: int; [[Vertex index count.]]
@in indices: const(void)*; /*@ Pointer to the index data. */ @in indices: const(void)*; [[Pointer to the index data.]]
} }
} }
index_data_copy_set { index_data_copy_set {
/*@ [[Set the vertex index data of the given mesh by copying from a
Set the vertex index data of the given mesh by copying from a buffer. buffer.
This function allocates internal index buffer any copy data from the given This function allocates internal index buffer any copy data from
buffer. Futher modifications can be made within map/unmap pair. the given buffer. Futher modifications can be made within
map/unmap pair.
@see evas_canvas3d_mesh_index_data_set() See also @.index_data_set.
]]
@ingroup Evas_Canvas3D_Mesh
*/
params { params {
@in format: Evas.Canvas3D.Index_Format; /*@ Vertex index data format. */ @in format: Evas.Canvas3D.Index_Format; [[Vertex index data format.]]
@in count: int; /*@ Vertex index count. */ @in count: int; [[Vertex index count.]]
@in indices: const(void)*; /*@ Pointer to the index data. */ @in indices: const(void)*; [[Pointer to the index data.]]
} }
} }
index_format_get @const { index_format_get @const {
/*@ [[Get the format of the index data of the given mesh.
Get the format of the index data of the given mesh.
Returns valid format only when the index buffer is mapped. First
Returns valid format only when the index buffer is mapped. First map the map the index buffer and then query the properties of the mapped
index buffer and then query the properties of the mapped buffer. If the index buffer. If the index data was set by @.index_data_set, the
data was set by evas_canvas3d_mesh_index_data_set(), the original format will be original format will be returned. Otherwise the format can differ
returned. Otherwise the format can differ every time you call the every time you call the @.index_data_map function.
evas_canvas3d_mesh_index_data_map() function. ]]
return: Evas.Canvas3D.Index_Format; [[Format of the index data.]]
@see evas_canvas3d_mesh_index_data_map()
@return Format of the index data.
@ingroup Evas_Canvas3D_Mesh
*/
return: Evas.Canvas3D.Index_Format;
} }
index_count_get @const { index_count_get @const {
/*@ [[Get the count of the index data of the given mesh.
Get the count of the index data of the given mesh.
This function returns the index count of the last called data_set function. This function returns the index count of the last called data_set
function.
@see evas_canvas3d_mesh_index_data_set() ]]
@see evas_canvas3d_mesh_index_data_copy_set() return: int; [[Index data count.]]
@return Index data count.
@ingroup Evas_Canvas3D_Mesh
*/
return: int;
} }
index_data_map { index_data_map {
/*@ [[Map the index buffer of the given mesh.
Map the index buffer of the given mesh.
evas_canvas3d_mesh_index_data_unmap() should be called after modifications. If the @.index_data_unmap should be called after modifications. If the
data was set using evas_canvas3d_mesh_index_data_set(), the original pointer will data was set using @.index_data_set, the original pointer will
be returned, otherwise, the returned pointer may differ every time you call be returned, otherwise, the returned pointer may differ every
this function. time you call this function.
]]
@see evas_canvas3d_mesh_index_data_unmap() return: void *; [[Pointer to the mapped buffer.]]
@return Pointer to the mapped buffer.
@ingroup Evas_Canvas3D_Mesh
*/
return: void *;
} }
index_data_unmap { index_data_unmap {
/*@ [[Unmap the index buffer of the given mesh.
Unmap the index buffer of the given mesh.
@see evas_canvas3d_mesh_index_data_map() See also @.index_data_map.
]]
@ingroup Evas_Canvas3D_Mesh
*/
} }
frame_add { frame_add {
/*@ [[Add a key frame to the given mesh.
Add a key frame to the given mesh.
@param mesh The given mesh.
@param frame The number of the key frame to be added.
If specified frame is already exist, error message will be generated. If specified frame is already exist, error message will be generated.
]]
@ingroup Evas_Canvas3D_Mesh
*/
params { params {
@in frame: int; /*@ The number of the key frame to be added. */ @in frame: int; [[The number of the key frame to be added.]]
} }
} }
frame_del { frame_del {
/*@ [[Delete a key frame from the given mesh.]]
Delete a key frame from the given mesh.
@param mesh The given mesh.
@param frame The number of the key frame to be deleted.
@see evas_canvas3d_mesh_frame_add()
@ingroup Evas_Canvas3D_Mesh
*/
params { params {
@in frame: int; /*@ The number of the key frame to be added. */ @in frame: int; [[The number of the key frame to be added.]]
} }
} }
fog_color_set { fog_color_set {
/*@ [[Set the fog color and density for the given mesh.]]
Set the fog color and density for the given mesh.
@ingroup Evas_Canvas3D_Mesh
*/
params { params {
@in r: Evas_Real; /*@ The red component of the fog color.*/ @in r: Evas_Real; [[The red component of the fog color.]]
@in g: Evas_Real; /*@ The green component of the fog color.*/ @in g: Evas_Real; [[The green component of the fog color.]]
@in b: Evas_Real; /*@ The blue component of the fog color.*/ @in b: Evas_Real; [[The blue component of the fog color.]]
@in a: Evas_Real; /*@ The transparency of fog.*/ @in a: Evas_Real; [[The transparency of fog.]]
} }
} }
fog_color_get { fog_color_get {
/*@ [[Set the fog color and density for the given mesh.]]
Set the fog color and density for the given mesh.
@ingroup Evas_Canvas3D_Mesh
*/
params { params {
@out r: Evas_Real; /*@ Pointer to receive red component of the fog color.*/ @out r: Evas_Real; [[Pointer to receive red component of the fog color.]]
@out g: Evas_Real; /*@ Pointer to receive green component of the fog color.*/ @out g: Evas_Real; [[Pointer to receive green component of the fog color.]]
@out b: Evas_Real; /*@ Pointer to receive blue component of the fog color.*/ @out b: Evas_Real; [[Pointer to receive blue component of the fog color.]]
@out a: Evas_Real; /*@ Pointer to receive transparency of fog.*/ @out a: Evas_Real; [[Pointer to receive transparency of fog.]]
} }
} }
blending_func_set { blending_func_set {
/*@ [[Set the blending function for given mesh.]]
Set the blending function for given mesh
@ingroup Evas_Canvas3D_Mesh
*/
params { params {
@in sfactor: Evas.Canvas3D.Blend_Func; /*@ Specifies how the red, green, blue, and alpha source blending factors are computed.*/ @in sfactor: Evas.Canvas3D.Blend_Func; [[Specifies how the red, green, blue,
@in dfactor: Evas.Canvas3D.Blend_Func; /*@ Specifies how the red, green, blue, and alpha destination blending factors are computed.*/ and alpha source blending factors
are computed.
]]
@in dfactor: Evas.Canvas3D.Blend_Func; [[Specifies how the red, green, blue,
and alpha destination blending
factors are computed.
]]
} }
} }
blending_func_get { blending_func_get {
/*@ [[Get blending blending function for given mesh.]]
Get blending blending function for given mesh
@see eavs_3d_mesh_blending_func_set()
@ingroup Evas_Canvas3D_Mesh
*/
params { params {
@out sfactor: Evas.Canvas3D.Blend_Func; /*@ Pointer to receive source blendin factors key.*/ @out sfactor: Evas.Canvas3D.Blend_Func; [[Pointer to receive source blendin factors key.]]
@out dfactor: Evas.Canvas3D.Blend_Func; /*@ Pointer to receive destination blendin factors key.*/ @out dfactor: Evas.Canvas3D.Blend_Func; [[Pointer to receive destination blendin factors key.]]
} }
} }
from_primitive_set { from_primitive_set {
/*@ [[Set the data of given mesh frame from the given primitive.]]
Set the data of given mesh frame from the given primitive
@ingroup Evas_Canvas3D_Mesh
*/
params { params {
@in frame: int; /*@ Specifies data of which frame of given mesh will be set.*/ @in frame: int; [[Specifies data of which frame of given mesh will be set.]]
@in primitive: Evas.Canvas3D.Primitive *; /*@ Specifies which data will be set.*/ @in primitive: Evas.Canvas3D.Primitive *; [[Specifies which data will be set.]]
} }
} }
@property shade_mode { @property shade_mode {
set { set {
/*@ [[Set the shade mode of the given mesh.
* Set the shade mode of the given mesh.
* Default shade mode is EVAS_CANVAS3D_SHADE_MODE_VERTEX_COLOR.
* Default shade mode is EVAS_CANVAS3D_SHADE_MODE_VERTEX_COLOR. ]]
*
* @ingroup Evas_Canvas3D_Mesh
*/
} }
get { get {
/*@ [[Get the shade mode of the given mesh.]]
* Get the shade mode of the given mesh.
*
* @see eavs_3d_mesh_shade_mode_set()
*
* @ingroup Evas_Canvas3D_Mesh
*/
} }
values { values {
mode: Evas.Canvas3D.Shade_Mode; /*@ The shade mode.*/ mode: Evas.Canvas3D.Shade_Mode; [[The shade mode.]]
} }
} }
@property color_pick_enable { @property color_pick_enable {
set { set {
/*@ [[Set posibility color picking.]]
* Set posibility color picking.
*
* @ingroup Evas_Canvas3D_Mesh
*/
} }
get { get {
/*@ [[Get status of color picking of the mesh.]]
* Get status of color picking of the mesh.
*
* @see color_pick_enable_set()
*
* @ingroup Evas_Canvas3D_Mesh
*/
} }
values { values {
enabled: bool; /*@ Posibility flag */ enabled: bool; [[Posibility flag.]]
} }
} }
@property vertex_count { @property vertex_count {
set { set {
/*@ [[Set the vertex count of the given mesh.
* Set the vertex count of the given mesh.
*
* Each key frame should have same vertex count to be properly interpolated.
* Key frames have their own vertex data and the data should have more vertices
* than the mesh's vertex count.
* Default vertex count is 0. Each key frame should have same vertex count to be properly
interpolated. Key frames have their own vertex data and the
data should have more vertices than the mesh's vertex count.
* @ingroup Evas_Canvas3D_Mesh Default vertex count is 0.
*/ ]]
} }
get { get {
/*@ [[Get the vertex count of the given mesh.]]
* Get the vertex count of the given mesh. }
* values {
* @see evas_canvas3d_mesh_vertex_count_set() count: uint; [[Vertex count.]]
* }
* @ingroup Evas_Canvas3D_Mesh
*/
}
values {
count: uint; /*@ Vertex count.*/
}
} }
@property fog_enable { @property fog_enable {
set { set {
/*@ [[Enable or disable fog effect for given mesh.
* Enable or disable fog effect for given mesh.
* Default fog is disabled.
* Default fog is disabled. ]]
*
* @ingroup Evas_Canvas3D_Mesh
*/
} }
get { get {
/*@ [[Get the enable status of fog effect for given mesh.]]
* Get the enable status of fog effect for given mesh
*
* @see fog_enable_set()
*
* @ingroup Evas_Canvas3D_Mesh
*/
} }
values { values {
enabled: bool; /*@ Fog enabled status.*/ enabled: bool; [[Fog enabled status.]]
} }
} }
@property alpha_test_enable { @property alpha_test_enable {
set { set {
/*@ [[Get the enable status of alpha test for given mesh.
* Get the enable status of alpha test for given mesh
* Default alpha test disabled.
* Default alpha test disabled. ]]
*
* @ingroup Evas_Canvas3D_Mesh
*/
} }
get { get {
/*@ [[Get the enable status of alpha test for given mesh.]]
* Get the enable status of alpha test for given mesh
*
* @see alpha_test_enable_set()
*
* @ingroup Evas_Canvas3D_Mesh
*/
} }
values { values {
enabled: bool; /*@ Alpha test status.*/ enabled: bool; [[The alpha test status.]]
} }
} }
@property alpha_func { @property alpha_func {
set { set {
/*@ [[Set the alpha func.
* The alpha test discards fragments depending on the outcome of a comparison
* between an incoming fragment's alpha value and a constant reference value The alpha test discards fragments depending on the outcome of
* This func specifies the reference value and the comparison function. a comparison between an incoming fragment's alpha value and a
* constant reference value. This func specifies the reference
* @ingroup Evas_Canvas3D_Mesh value and the comparison function.
*/ ]]
} }
get { get {
/*@ [[Get the reference value and the comparison function for alpha
* Get the reference value and the comparison function for alpha testing testing.
* ]]
* @see eavs_3d_mesh_alpha_test_param_set()
*
* @ingroup Evas_Canvas3D_Mesh
*/
} }
values { values {
comparison_func: Evas.Canvas3D.Comparison; /*@ Specifies the alpha comparison function.*/ comparison_func: Evas.Canvas3D.Comparison; [[The alpha comparison function.]]
ref_value: Evas_Real; /*@ Specifies the reference value that incoming alpha values are compared to.*/ ref_value: Evas_Real; [[The reference value that incoming alpha values are compared to.]]
} }
} }
@property blending_enable { @property blending_enable {
set { set {
/*@ [[Enable or disable blending for given mesh.]]
* Enable or disable blending for given mesh.
*
* Default blending disabled.
*
* @ingroup Evas_Canvas3D_Mesh
*/
} }
get { get {
/*@ [[Get whether blending is enabled for the mesh.]]
* Get blending enable status for given mesh.
*
* @see eavs_3d_mesh_blending_enable_set()
*
* @ingroup Evas_Canvas3D_Mesh
*/
} }
values { values {
blending: bool; /*@ The blending state.*/ blending: bool; [[The blending state.]]
} }
} }
@property frame_material { @property frame_material {
set { set {
/*@ [[Set the material of the key frame of the given mesh.
Set the material of the key frame of the given mesh.
Setting different materials for each key frame is useful for doing animations Setting different materials for each key frame is useful for
like GIF images or color changing animationas. doing animations like GIF images or color changing animations.
]]
@ingroup Evas_Canvas3D_Mesh
*/
} }
get { get {
/*@ [[Get the material of the key frame of the given mesh.]]
Get the material of the key frame of the given mesh.
@see evas_canvas3d_mesh_frame_material_set()
@ingroup Evas_Canvas3D_Mesh
*/
} }
keys { keys {
frame: int; /*@ The number of the key frame.*/ frame: int; [[The number of the key frame.]]
} }
values { values {
material: Evas.Canvas3D.Material *; /*@ The material to be set to the key frame.*/ material: Evas.Canvas3D.Material *; [[The material to be set to the key frame.]]
} }
} }
@property vertex_assembly { @property vertex_assembly {
set { set {
/*@ [[Set the vertex assembly of the given mesh.
Set the vertex assembly of the given mesh.
Vertex assembly defines how the engine organizes vertices into geometric Vertex assembly defines how the engine organizes vertices into
primitives. geometric primitives.
Default vertex assembly is EVAS_CANVAS3D_VERTEX_ASSEMBLY_TRIANGLES. Default vertex assembly is EVAS_CANVAS3D_VERTEX_ASSEMBLY_TRIANGLES.
]]
@ingroup Evas_Canvas3D_Mesh
*/
} }
get { get {
/*@ [[Get the vertex assembly of the given mesh.]]
Get the vertex assembly of the given mesh.
@see evas_canvas3d_mesh_vertex_assembly_set()
@return The vertex assembly.
@ingroup Evas_Canvas3D_Mesh
*/
} }
values { values {
assembly: Evas.Canvas3D.Vertex_Assembly; /*@ Vertex assembly.*/ assembly: Evas.Canvas3D.Vertex_Assembly; [[The vertex assembly.]]
} }
} }