Lines Matching refs:polyLength

235  * @param polyLength The number of vertices of the polygon.
238 void SpotShadow::sort(Vector2* poly, int polyLength, const Vector2& center) {
239 quicksortCirc(poly, 0, polyLength - 1, center);
386 * @param polyLength number of vertexes of the occluding polygon
391 float lightSize, const Vector3* poly, int polyLength, const Vector3& polyCentroid,
397 if (CC_UNLIKELY(polyLength < 3)) {
403 OutlineData outlineData[polyLength];
421 projectCasterToOutline(outlineData[polyLength - 1].position, lightCenter,
422 poly[polyLength - 1]);
425 int currentNormalIndex = polyLength - 1;
428 for (int i = 0; i < polyLength; i++) {
436 currentNormalIndex = (currentNormalIndex + 1) % polyLength;
446 int allocatedPenumbraLength = 2 * polyLength + SPOT_MAX_EXTRA_CORNER_VERTEX_NUMBER;
450 Vector2 umbra[polyLength];
458 for (int i = 0; i < polyLength; i++) {
481 int preNormalIndex = (i + polyLength - 1) % polyLength;
563 for (int i = 0; i < polyLength; i++) {
571 int umbraLength = polyLength;
575 dumpPolygon(poly, polyLength, "input poly");
592 finalPenumbraLength, finalUmbra, finalUmbraLength, poly, polyLength,
669 const Vector2* polyToCentroid, int polyLength) {
671 for (int i = 0; i < polyLength; i++) {
672 int currentIndex = (i + startPolyIndex) % polyLength;
674 const Vector2& nextToCentroid = polyToCentroid[(currentIndex + 1) % polyLength];
793 inline bool genPolyToCentroid(const Vector2* poly2d, int polyLength,
795 for (int j = 0; j < polyLength; j++) {
802 for (int j = 0; j < polyLength; j++) {
803 refCrossProduct = polyToCentroid[j].cross(polyToCentroid[(j + 1) % polyLength]);
816 const Vector2* poly2d, int polyLength, const Vector2* polyToCentroid,
825 umbraToCentroid, polyToCentroid, polyLength);
830 poly2d[previousPolyIndex], poly2d[(previousPolyIndex + 1) % polyLength]);
852 const Vector3* poly, int polyLength, VertexBuffer& shadowTriangleStrip,
855 Vector2 poly2d[polyLength];
858 for (int i = 0; i < polyLength; i++) {
864 if (testPointInsidePolygon(centroid, poly2d, polyLength)) {
970 Vector2 polyToCentroid[polyLength];
971 bool isPositiveCross = genPolyToCentroid(poly2d, polyLength, centroid, polyToCentroid);
980 Vector2 closerVertex = getCloserVertex(umbra[i], centroid, poly2d, polyLength,
1042 void SpotShadow::dumpPolygon(const Vector2* poly, int polyLength, const char* polyName) {
1043 for (int i = 0; i < polyLength; i++) {
1051 void SpotShadow::dumpPolygon(const Vector3* poly, int polyLength, const char* polyName) {
1052 for (int i = 0; i < polyLength; i++) {