evas-3D: primitives: cylinder is standardized now (normalized and z is a axis of symmetry)

Summary: {F13942}

Test Plan: D2248 gives app for testing.

Reviewers: cedric, Hermet, raster

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D2250
This commit is contained in:
Bogdan Devichev 2015-04-06 13:58:22 +09:00 committed by ChunEon Park
parent adb85bb8b4
commit c6a46319fa
1 changed files with 8 additions and 8 deletions

View File

@ -427,18 +427,18 @@ evas_3d_add_cylinder_frame(Eo *mesh, int frame, int p, vec2 tex_scale)
fi = i * dfi;
sinfi = sin(fi);
cosfi = cos(fi);
vertices[i + vccount].x = vertices[i].x = sinfi ;
vertices[i].y = -0.5;
vertices[i + vccount].z = vertices[i].z = cosfi;
vertices[i + vccount].y = 0.5;
vertices[i + vccount].x = vertices[i].x = sinfi / 2.0;
vertices[i + vccount].y = vertices[i].y = cosfi / 2.0;
vertices[i].z = -0.5;
vertices[i + vccount].z = 0.5;
normals[i + vccount].x = normals[i].x = sinfi;
normals[i + vccount].y = normals[i].y = 0;
normals[i + vccount].z = normals[i].z = cosfi;
normals[i + vccount].y = normals[i].y = cosfi;
normals[i + vccount].z = normals[i].z = 0;
tangents[i + vccount].x = tangents[i].x = cosfi;
tangents[i + vccount].y = tangents[i].y = 0;
tangents[i + vccount].z = tangents[i].z = -sinfi;
tangents[i + vccount].y = tangents[i].y = -sinfi;
tangents[i + vccount].z = tangents[i].z = 0;
tex_coord[i].x = i / (float)(vccount - 1) * tex_scale.x;
tex_coord[i].y = 0;