===================================================== Liste_Funktionen_Beginn: UT3D_pt_cisn evaluate sample-point on circle UT3D_pt_elsn evaluate sample-point on ellipse UT3D_pt_lnsn evaluate sample-point on line UT3D_pt_midnpt center point <-- points UT3D_pt_sampnr evaluate sample-curve-point UT3D_vc_tgsampnr evaluate sample-tangent-vector u3d_LinComb2Pts po = a1 * p1 + a2 * p2 Liste_Funktionen_Ende: =====================================================
#include <stdio.h>
#include <math.h>
#include <stdlib.h>
#include <string.h>
#include "../ut/ut_geo.h"
Functions | |
int | UT3D_pt_sampnr (Point *po, void *cv, int cvtype, int np, int sn) |
int | UT3D_vc_tgsampnr (Vector *tg, void *cv, int cvtype, Point *ps, int np, int sn) |
int | UT3D_pt_lnsn (Point *po, Line *ln, int np, int sn) |
int | UT3D_pt_cisn (Point *po, Circ *ci, int np, int sn) |
int | UT3D_pt_elsn (Point *po, CurvElli *el, int np, int sn) |
int UT3D_pt_sampnr | ( | Point * | po, | |
void * | cv, | |||
int | cvtype, | |||
int | np, | |||
int | sn | |||
) |
UT3D_pt_sampnr evaluate sample-curve-point (teilen) Evaluate a point on a curve (line, circle, ellipse, b-spline,...) with a sample-number. From the sample-number the curve-parameter t follows by t = a + sn * (b-a)/np, where [a,b] is the support of the curve. IN: void *cv ... curve int cvtype ... type of curve int np ... number of point-positions on curve (without endpoint) int sn ... sample-number of point to evaluate (0 <= sn <= np) OUT: Point *po ... evaluated point Returncodes: 0 = OK -1 = internal error -2 = input error
UT3D_vc_tgsampnr evaluate sample-tangent-vector (teilen) Evaluate the tangent-vector in a point on a curve (line, circle, ellipse, b-spline,...) with a sample-number. From the sample-number the curve-parameter t follows by t = a + sn * (b-a)/np, where [a,b] is the support of the curve. IN: void *cv ... curve int cvtype ... type of curve Point *ps ... curve-point with sample-number sn int np ... number of sample-points on curve (without endpoint) int sn ... sample-number of position of tangent (0 <= sn <= np) OUT: Vector *tg ... tangent vector (not normalized) Returncodes: 0 = OK -1 = input error
UT3D_pt_lnsn evaluate sample-point on line (teilen) Evaluate a point on a 3D-line by a sample-number. The sample-number is the number of the point between ln->p1 and ln->p2 in relation to the total number of sample-points. IN: Line *ln ... 3D-line int np ... total number of sample-points (without ci->p2) int sn ... sample-number of point to evaluate (0 <= sn <= np) OUT: Point *po ... evaluated point Returncodes: 0 = OK -1 = input error
UT3D_pt_cisn evaluate sample-point on circle (teilen) Evaluate a point on a 3D-circle by a sample-number. The sample-number is the number of the point between ci->p1 and ci->p2 in relation to the total number of sample-points. IN: Circ *ci ... 3D-circle int np ... total number of sample-points (without ci->p2) int sn ... sample-number of point to evaluate (0 <= sn <= np) OUT: Point *po ... evaluated point Returncodes: 0 = OK -1 = input error
UT3D_pt_elsn evaluate sample-point on ellipse (teilen) Evaluate a point on a 3D-ellipse by a sample-number. The sample-number is the number of the point between el->p1 and el->p2 in relation to the total number of sample-points. IN: CurvElli *el ... 3D-ellipse int np ... total number of sample-points (without el->p2) int sn ... sample-number of point to evaluate (0 <= sn <= np) OUT: Point *po ... evaluated point Returncodes: 0 = OK -1 = internal error