gCAD3D 2.40
ut_surstd.c File Reference

Planar & Revolved-Surface-Functions. More...

#include <math.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "../ut/ut_geo.h"
#include "../ut/ut_cast.h"
#include "../ut/ut_ox_base.h"
#include "../db/ut_DB.h"
#include "../ut/func_types.h"

Functions

int UTO_get_suppSurf (void **ssDat, ObjGX *surTps)
 
int SUR_pt2_prjptsur (Point *pt2o, Point *pt3i, ObjGX *oSur)
 
int UT3D_cv_scir__ (int *pNr, Point *pa, int paSiz, ObjGX *oxi, int mode)
 
int SUP_sup_ContTab (void *oSpc, int *oSiz, Memspc *memSeg1, ContTab *cTab, int cNr)
 
int SUP_ContTab_pTab (ContTab *cTab, int pNr, Point *pTab, Vector *vcn)
 
int SUP_orient (Vector *vcz, ContTab *cTab, int cNr)
 
int SUP_load_c (ContTab *cTab, int *cNr, int cMax, Point *pTab, int pMax, ObjGX *oxi, int sTyp)
 
int SUP_addBound (ContTab *cTab, int *cNr, int cMax, Point *pTab, int pMax, ObjGX *oxi, double tol)
 
int SPU_ckMinSiz (int pNr, Point *pTab)
 
int UT3D_ptvc_sur (Point *pto, Vector *vco, Memspc *memSeg1, ObjGX *su1)
 
int UT3D_ptvc_sus (Point *pto, Vector *vco, Memspc *memSeg1, SurStd *sus)
 
int UT3D_parscon_pt (double *parU, double *parV, Point *pti, Mat_4x3 imat)
 
int UT3D_pt_evparscon (Point *pto, Conus *con, double parU, double parV, Mat_4x3 mat)
 
int UT3D_pt_projptbcon (Point *pto, Conus *co1, Point *pti)
 
int UT3D_bcon_pt2rd2 (Conus *co1, Point *pt1, Point *pt2, double rd1, double rd2)
 
int UT3D_parsph_pt (double *parU, double *parV, Point *pti, double rds, Mat_4x3 imat)
 
int UT3D_pt_evparsph (Point *pto, double rds, double parU, double parV, Mat_4x3 mat)
 
int UT3D_angsph_pt (double *as, int mode, Plane *pls, Point *pt1)
 
int UT3D_parstor_pt (double *parU, double *parV, Point *pti, Torus *tor, Mat_4x3 imat)
 
int UT3D_pt_evparstor (Point *pto, Torus *tor, double parU, double parV, Mat_4x3 mat)
 
int UT3D_pt_projptbtor (Point *pto, Torus *to1, Point *pti)
 
int SUR_ck_typ (int *suTyp, ObjGX **sSur, int *cNr, ObjGX *o1)
 
int SUR_Disp_Sur (ObjGX *o1, Memspc *wrkSpc, int att,...)
 

Detailed Description

Planar & Revolved-Surface-Functions.

=====================================================
List_functions_start:
----------- all surfaces --------------------
SUR_Disp_Sur temp. Display Surfaces
UTO_get_suppSurf get supportSurface of SURTPS <surTps>
UTO_ck_surfTyp returns surfSubTyp ((../ut/ut_obj.c)
SUR_ck_typ get typ & index of supportSurf, nr of contours.
SPU_ckMinSiz Kontur testen ob groesser als tol
SUP_orient Orientieren der Konturen
SUP_load_c alle Konturen laden
SUP_addBound Tabelle aus 3D-Punkten aufbauen
SUR_pt2_prjptsur project 3D-point on surface (get 2D-point)
UT3D_ptvc_sus Point+Vector from SurStd (Normalvec auf Flaeche)
----------- SURCIR (tesselated fan) ---------
UT3D_cv_scir__ get boundary-points from SURCIR (tesselated fan)
----------- Planar --------------------------
UT3D_cv_pls__ get boundary-points from planar surface
SUP_sup_ContTab make planar surf from ContTab
SUP_ContTab_pTab make ContTab from points
----------- Conus --------------------------
UT3D_parscon_pt u/v-Parameter from 3D-conic-surfacePoint
UT3D_pt_evparscon 3D-point <-- evaluate conic-surfaceParameters
UT3D_bcon_pt2rd2 Conus from 2 points + 2 radius
----------- Torus --------------------------
UT3D_parstor_pt u/v-Parameter from 3D-toric-surfacePoint
UT3D_pt_evparstor 3D-point <-- evaluate toric-surfaceParameters
----------- Sphere -------------------------
UT3D_parsph_pt u/v-Parameter from sphere
UT3D_pt_evparsph 3D-point <-- evaluate spher-surfaceParameters
UT3D_angsph_pt compute hor/vert angle of point on sphere
List_functions_end:
=====================================================
- see also:
../ut/ut_srv.c (Revolved-Surface-Functions)
../ut/ut_sru.c (Ruled-Surface-Functions)

Function Documentation

int UTO_get_suppSurf ( void **  ssDat,
ObjGX surTps 
)
int SUR_pt2_prjptsur ( Point pt2o,
Point pt3i,
ObjGX oSur 
)
* SUR_pt2_prjptsur project 3D-point on surface (get 2D-point)
* = get 2D-parameters of 3D-point on surface
*
int UT3D_cv_scir__ ( int *  pNr,
Point pa,
int  paSiz,
ObjGX oxi,
int  mode 
)
* UT3D_cv_scir__ get boundary-points from SURCIR (tesselated fan)
* mode 0=perm, fix PRCV; 1=temp, do not use PRCV; 2=unknown
* returns array of points; max. 4
* see also UT3D_cv_sru_ UT3D_cv_pls__
*
int SUP_sup_ContTab ( void *  oSpc,
int *  oSiz,
Memspc memSeg1,
ContTab cTab,
int  cNr 
)
int SUP_ContTab_pTab ( ContTab cTab,
int  pNr,
Point pTab,
Vector vcn 
)
int SUP_orient ( Vector vcz,
ContTab cTab,
int  cNr 
)
int SUP_load_c ( ContTab cTab,
int *  cNr,
int  cMax,
Point pTab,
int  pMax,
ObjGX oxi,
int  sTyp 
)
int SUP_addBound ( ContTab cTab,
int *  cNr,
int  cMax,
Point pTab,
int  pMax,
ObjGX oxi,
double  tol 
)
int SPU_ckMinSiz ( int  pNr,
Point pTab 
)
int UT3D_ptvc_sur ( Point pto,
Vector vco,
Memspc memSeg1,
ObjGX su1 
)
* UT3D_ptvc_sur Point+normalVector from Surface
* Input:
* su1 surface
* Output:
* pto centerpoint of surf
* vco normalvector of surf
* RetCod -1 not yet implemented
*
*
int UT3D_ptvc_sus ( Point pto,
Vector vco,
Memspc memSeg1,
SurStd sus 
)
int UT3D_parscon_pt ( double *  parU,
double *  parV,
Point pti,
Mat_4x3  imat 
)
int UT3D_pt_evparscon ( Point pto,
Conus con,
double  parU,
double  parV,
Mat_4x3  mat 
)
int UT3D_pt_projptbcon ( Point pto,
Conus co1,
Point pti 
)
int UT3D_bcon_pt2rd2 ( Conus co1,
Point pt1,
Point pt2,
double  rd1,
double  rd2 
)
int UT3D_parsph_pt ( double *  parU,
double *  parV,
Point pti,
double  rds,
Mat_4x3  imat 
)
int UT3D_pt_evparsph ( Point pto,
double  rds,
double  parU,
double  parV,
Mat_4x3  mat 
)
int UT3D_angsph_pt ( double *  as,
int  mode,
Plane pls,
Point pt1 
)
int UT3D_parstor_pt ( double *  parU,
double *  parV,
Point pti,
Torus tor,
Mat_4x3  imat 
)
int UT3D_pt_evparstor ( Point pto,
Torus tor,
double  parU,
double  parV,
Mat_4x3  mat 
)
int UT3D_pt_projptbtor ( Point pto,
Torus to1,
Point pti 
)
int SUR_ck_typ ( int *  suTyp,
ObjGX **  sSur,
int *  cNr,
ObjGX o1 
)
* SUR_ck_typ get typ & index of supportSurf, nr of contours.
* Output:
* suTyp Typ supportSurface:
* Typ_Error = Error
* Typ_SURPLN = Planar surf
* Typ_SURRV = Revolved Sur
* Typ_SURRU = Ruled Sur
* Typ_SURBSP = B_Spline Surf
* nurb (SBSP)
* sSur the ObjGX-Record of the supportSurface
* cNr Anzahl Konturen: 0=unbegrenzte Stuetzflaeche; 1=nur Aussenkontur;
* > 1 = Aussenkontur + (iCont-1) LochKonturen.
* RetCod: DB-Index of supportSurface.
*
int SUR_Disp_Sur ( ObjGX o1,
Memspc wrkSpc,
int  att,
  ... 
)

wrkSpc unused !