亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? dt2.c

?? 是Computational Geometry in C中的原程序
?? C
?? 第 1 頁 / 共 3 頁
字號:
   f1->edge[2]->adjface[1] = f0;	   /* Find a fourth, non-coplanar point to form tetrahedron. */   v3 = v2->next;   vol = VolumeSign( f0, v3 );   while ( !vol )   {      if ( ( v3 = v3->next ) == v0 )          printf("DoubleTriangle:  All points are coplanar!\n"), exit(0);      vol = VolumeSign( f0, v3 );   }	   /* Insure that v3 will be the first added. */   vertices = v3;   if ( debug ) {      fprintf(stderr, "DoubleTriangle: finished. Head repositioned at v3.\n");      PrintOut( vertices );   }	}  /*---------------------------------------------------------------------ConstructHull adds the vertices to the hull one at a time.  The hullvertices are those in the list marked as onhull.---------------------------------------------------------------------*/void	ConstructHull( void ){   tVertex  v, vnext;   int 	    vol;   bool	    changed;	/* T if addition changes hull; not used. */   v = vertices;   do {      vnext = v->next;      if ( !v->mark ) {         v->mark = PROCESSED;	 changed = AddOne( v );	 CleanUp();	 if ( check ) {	    fprintf(stderr,"ConstructHull: After Add of %d & Cleanup:\n",                v->vnum);	    Checks();	 }	 if ( debug )            PrintOut( v );      }      v = vnext;   } while ( v != vertices );}/*---------------------------------------------------------------------AddOne is passed a vertex.  It first determines all faces visible from that point.  If none are visible then the point is marked as not onhull.  Next is a loop over edges.  If both faces adjacent to an edgeare visible, then the edge is marked for deletion.  If just one of theadjacent faces is visible then a new face is constructed.---------------------------------------------------------------------*/bool 	AddOne( tVertex p ){   tFace  f;    tEdge  e;   int 	  vol;   bool	  vis = FALSE;   if ( debug ) {      fprintf(stderr, "AddOne: starting to add v%d.\n", p->vnum);      PrintOut( vertices );   }   /* Mark faces visible from p. */   f = faces;   do {      vol = VolumeSign( f, p );      if (debug) fprintf(stderr,          "faddr: %6x   paddr: %6x   Vol = %d\n", f,p,vol);      if ( vol < 0 ) {	 f->visible = VISIBLE;  	 vis = TRUE;                            }      f = f->next;   } while ( f != faces );   /* If no faces are visible from p, then p is inside the hull. */   if ( !vis ) {      p->onhull = !ONHULL;        return FALSE;    }   /* Mark edges in interior of visible region for deletion.      Erect a newface based on each border edge. */   e = edges;   do {      tEdge temp;      temp = e->next;      if ( e->adjface[0]->visible && e->adjface[1]->visible )	 /* e interior: mark for deletion. */	 e->delete = REMOVED;      else if ( e->adjface[0]->visible || e->adjface[1]->visible ) 	 /* e border: make a new face. */	 e->newface = MakeConeFace( e, p );      e = temp;   } while ( e != edges );   return TRUE;}/*---------------------------------------------------------------------VolumeSign returns the sign of the volume of the tetrahedron determined by fand p.  VolumeSign is +1 iff p is on the negative side of f,where the positive side is determined by the rh-rule.  So the volume is positive if the ccw normal to f points outside the tetrahedron.The final fewer-multiplications form is due to Robert Fraczkiewicz.---------------------------------------------------------------------*/int  VolumeSign( tFace f, tVertex p ){   double  vol;   int     voli;   double  ax, ay, az, bx, by, bz, cx, cy, cz, dx, dy, dz;   double  bxdx, bydy, bzdz, cxdx, cydy, czdz;   ax = f->vertex[0]->v[X];   ay = f->vertex[0]->v[Y];   az = f->vertex[0]->v[Z];   bx = f->vertex[1]->v[X];   by = f->vertex[1]->v[Y];   bz = f->vertex[1]->v[Z];   cx = f->vertex[2]->v[X];   cy = f->vertex[2]->v[Y];   cz = f->vertex[2]->v[Z];   dx = p->v[X];   dy = p->v[Y];   dz = p->v[Z];      bxdx=bx-dx;   bydy=by-dy;   bzdz=bz-dz;   cxdx=cx-dx;   cydy=cy-dy;   czdz=cz-dz;   vol =   (az-dz) * (bxdx*cydy - bydy*cxdx)         + (ay-dy) * (bzdz*cxdx - bxdx*czdz)	 + (ax-dx) * (bydy*czdz - bzdz*cydy);   if ( debug )      fprintf(stderr,"Face=%6x; Vertex=%d: vol(int) = %d, vol(double) = %lf\n",	      f,p->vnum,voli,vol);   /* The volume should be an integer. */   if      ( vol > 0.5 )   return  1;   else if ( vol < -0.5 )  return -1;   else                    return  0;}/*---------------------------------------------------------------------*/int  Volumei( tFace f, tVertex p ){   int 	   vol;   int 	   ax, ay, az, bx, by, bz, cx, cy, cz, dx, dy, dz;   int	   bxdx, bydy, bzdz, cxdx, cydy, czdz;   double  vold;   int	   i;   ax = f->vertex[0]->v[X];   ay = f->vertex[0]->v[Y];   az = f->vertex[0]->v[Z];   bx = f->vertex[1]->v[X];   by = f->vertex[1]->v[Y];   bz = f->vertex[1]->v[Z];   cx = f->vertex[2]->v[X];   cy = f->vertex[2]->v[Y];   cz = f->vertex[2]->v[Z];   dx = p->v[X];   dy = p->v[Y];   dz = p->v[Z];      bxdx=bx-dx;   bydy=by-dy;   bzdz=bz-dz;   cxdx=cx-dx;   cydy=cy-dy;   czdz=cz-dz;   vol =   (az-dz)*(bxdx*cydy-bydy*cxdx)         + (ay-dy)*(bzdz*cxdx-bxdx*czdz)	 + (ax-dx)*(bydy*czdz-bzdz*cydy);   return vol;}		/*---------------------------------------------------------------------Volumed is the same as VolumeSign but computed with doubles.  For protection against overflow.---------------------------------------------------------------------*/double 	Volumed( tFace f, tVertex p ){   double  vol;   double  ax, ay, az, bx, by, bz, cx, cy, cz, dx, dy, dz;   double  bxdx, bydy, bzdz, cxdx, cydy, czdz;   ax = f->vertex[0]->v[X];   ay = f->vertex[0]->v[Y];   az = f->vertex[0]->v[Z];   bx = f->vertex[1]->v[X];   by = f->vertex[1]->v[Y];   bz = f->vertex[1]->v[Z];   cx = f->vertex[2]->v[X];   cy = f->vertex[2]->v[Y];   cz = f->vertex[2]->v[Z];   dx = p->v[X];   dy = p->v[Y];   dz = p->v[Z];      bxdx=bx-dx;   bydy=by-dy;   bzdz=bz-dz;   cxdx=cx-dx;   cydy=cy-dy;   czdz=cz-dz;   vol = (az-dz)*(bxdx*cydy-bydy*cxdx)         + (ay-dy)*(bzdz*cxdx-bxdx*czdz)	 + (ax-dx)*(bydy*czdz-bzdz*cydy);   return vol;}/*-------------------------------------------------------------------*/void	PrintPoint( tVertex p ){   int	i;   for ( i = 0; i < 3; i++ )      printf("\t%d", p->v[i]);   putchar('\n');}/*---------------------------------------------------------------------MakeConeFace makes a new face and two new edges between the edge and the point that are passed to it. It returns a pointer tothe new face.---------------------------------------------------------------------*/tFace	MakeConeFace( tEdge e, tVertex p ){   tEdge  new_edge[2];   tFace  new_face;   int 	  i, j;   /* Make two new edges (if don't already exist). */   for ( i=0; i < 2; ++i )       /* If the edge exists, copy it into new_edge. */      if ( !( new_edge[i] = e->endpts[i]->duplicate) ) {	 /* Otherwise (duplicate is NULL), MakeNullEdge. */	 new_edge[i] = MakeNullEdge();	 new_edge[i]->endpts[0] = e->endpts[i];	 new_edge[i]->endpts[1] = p;	 e->endpts[i]->duplicate = new_edge[i];      }   /* Make the new face. */   new_face = MakeNullFace();      new_face->edge[0] = e;   new_face->edge[1] = new_edge[0];   new_face->edge[2] = new_edge[1];   MakeCcw( new_face, e, p );            /* Set the adjacent face pointers. */   for ( i=0; i < 2; ++i )      for ( j=0; j < 2; ++j )  	 /* Only one NULL link should be set to new_face. */	 if ( !new_edge[i]->adjface[j] ) {	    new_edge[i]->adjface[j] = new_face;	    break;	 }           return new_face;}/*---------------------------------------------------------------------MakeCcw puts the vertices in the face structure in counterclock wise order.  We want to store the vertices in the same order as in the visible face.  The third vertex is always p.---------------------------------------------------------------------*/void	MakeCcw( tFace f, tEdge e, tVertex p ){   tFace  fv;   /* The visible face adjacent to e */   int    i;    /* Index of e->endpoint[0] in fv. */   tEdge  s;	/* Temporary, for swapping */         if  ( e->adjface[0]->visible )              fv = e->adjface[0];   else fv = e->adjface[1];          /* Set vertex[0] & [1] of f to have the same orientation      as do the corresponding vertices of fv. */    for ( i=0; fv->vertex[i] != e->endpts[0]; ++i )      ;   /* Orient f the same as fv. */   if ( fv->vertex[ (i+1) % 3 ] != e->endpts[1] ) {      f->vertex[0] = e->endpts[1];        f->vertex[1] = e->endpts[0];       }   else {                                     f->vertex[0] = e->endpts[0];         f->vertex[1] = e->endpts[1];            SWAP( s, f->edge[1], f->edge[2] );   }   /* This swap is tricky. e is edge[0]. edge[1] is based on endpt[0],      edge[2] on endpt[1].  So if e is oriented "forwards," we      need to move edge[1] to follow [0], because it precedes. */      f->vertex[2] = p;} /*---------------------------------------------------------------------MakeNullEdge creates a new cell and initializes all pointers to NULLand sets all flags to off.  It returns a pointer to the empty cell.---------------------------------------------------------------------*/tEdge 	MakeNullEdge( void ){   tEdge  e;   NEW( e, tsEdge );   e->adjface[0] = e->adjface[1] = e->newface = NULL;   e->endpts[0] = e->endpts[1] = NULL;   e->delete = !REMOVED;   ADD( edges, e );   return e;}/*--------------------------------------------------------------------MakeNullFace creates a new face structure and initializes all of itsflags to NULL and sets all the flags to off.  It returns a pointerto the empty cell.---------------------------------------------------------------------*/tFace 	MakeNullFace( void ){   tFace  f;   int    i;   NEW( f, tsFace);   for ( i=0; i < 3; ++i ) {      f->edge[i] = NULL;      f->vertex[i] = NULL;   }   f->visible = !VISIBLE;   ADD( faces, f );   return f;}/*---------------------------------------------------------------------MakeFace creates a new face structure from three vertices (in ccworder).  It returns a pointer to the face.---------------------------------------------------------------------*/tFace   MakeFace( tVertex v0, tVertex v1, tVertex v2, tFace fold ){   tFace  f;   tEdge  e0, e1, e2;   /* Create edges of the initial triangle. */   if( !fold ) {     e0 = MakeNullEdge();     e1 = MakeNullEdge();     e2 = MakeNullEdge();   }   else { /* Copy from fold, in reverse order. */     e0 = fold->edge[2];     e1 = fold->edge[1];     e2 = fold->edge[0];   }   e0->endpts[0] = v0;              e0->endpts[1] = v1;   e1->endpts[0] = v1;              e1->endpts[1] = v2;   e2->endpts[0] = v2;              e2->endpts[1] = v0;	   /* Create face for triangle. */   f = MakeNullFace();   f->edge[0]   = e0;  f->edge[1]   = e1; f->edge[2]   = e2;   f->vertex[0] = v0;  f->vertex[1] = v1; f->vertex[2] = v2;	   /* Link edges to face. */   e0->adjface[0] = e1->adjface[0] = e2->adjface[0] = f;

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产电影一区在线| 亚洲欧美综合色| 亚洲不卡av一区二区三区| 成人av先锋影音| 国产精品久久久一本精品| 韩国成人福利片在线播放| 日韩欧美中文一区二区| 理论片日本一区| 久久久www成人免费毛片麻豆| 狠狠色综合色综合网络| 亚洲精品在线观| 国产精品一区二区不卡| 久久精品视频在线免费观看| 国产xxx精品视频大全| 中文字幕一区二区视频| 91美女蜜桃在线| 亚洲国产欧美日韩另类综合 | 午夜精品久久久久影视| 欧美日韩在线综合| 亚洲bdsm女犯bdsm网站| 欧美日韩免费一区二区三区视频| 亚洲主播在线播放| 欧美日韩和欧美的一区二区| 一区二区成人在线观看| 一本久久a久久免费精品不卡| 亚洲午夜精品在线| 91精品国产综合久久精品 | 国产午夜亚洲精品午夜鲁丝片| 激情久久久久久久久久久久久久久久| 日韩欧美国产一二三区| 国产一区二区免费视频| 亚洲国产精品av| 色综合天天综合狠狠| 亚洲国产视频直播| 日韩午夜精品电影| 韩国毛片一区二区三区| 欧美国产日产图区| 色94色欧美sute亚洲13| 丝袜亚洲另类欧美综合| 2021中文字幕一区亚洲| av一区二区三区四区| 亚洲一区二区三区四区在线免费观看 | 国产三级精品视频| www.日本不卡| 亚洲国产精品久久人人爱| 91精品国产色综合久久不卡蜜臀 | 亚洲成人av一区二区三区| 91精品国产综合久久精品图片| 国产真实精品久久二三区| 日本一区二区三区四区在线视频| 97久久超碰精品国产| 日本免费新一区视频| 国产日本一区二区| 欧美视频一区二区在线观看| 久久av老司机精品网站导航| 亚洲欧美中日韩| 欧美电影影音先锋| 91理论电影在线观看| 秋霞电影网一区二区| 国产精品国产精品国产专区不片 | 欧美色精品天天在线观看视频| 亚洲第一激情av| 亚洲欧洲精品成人久久奇米网| 欧美一区二区不卡视频| 不卡一卡二卡三乱码免费网站| 丝袜亚洲精品中文字幕一区| 国产精品乱码一区二三区小蝌蚪| 欧美精品aⅴ在线视频| 99久久精品免费精品国产| 美国十次了思思久久精品导航| 国产精品高潮久久久久无| 精品黑人一区二区三区久久| 欧美性猛交xxxxxx富婆| 不卡av在线网| 国产精品一区免费视频| 日韩国产精品久久久久久亚洲| 亚洲午夜久久久久久久久电影网| 日韩二区三区四区| 国产精品久久精品日日| 欧美精品一区二区三区高清aⅴ| 欧美影视一区在线| 99精品久久只有精品| 国产精品亚洲第一区在线暖暖韩国| 亚洲国产中文字幕在线视频综合| 亚洲国产精品av| 国产丝袜欧美中文另类| 欧美大片顶级少妇| 久久众筹精品私拍模特| 日韩精品一区二区三区swag | 极品少妇xxxx精品少妇| 婷婷久久综合九色综合伊人色| 亚洲免费av网站| 久久精品视频在线免费观看| 精品少妇一区二区三区在线播放 | 蜜臀91精品一区二区三区| 亚洲一区二区三区四区五区黄| 亚洲国产精品高清| 国产欧美精品一区aⅴ影院| 久久美女高清视频| 精品国产一区二区三区忘忧草| 国产午夜精品一区二区| 国产午夜精品一区二区三区四区 | 亚洲精品免费视频| 国产精品高潮呻吟| 一区在线观看视频| 一区二区三区国产精华| 亚洲制服丝袜在线| 亚洲成人自拍偷拍| 日本欧美肥老太交大片| 六月丁香婷婷色狠狠久久| 美美哒免费高清在线观看视频一区二区 | 亚洲午夜在线观看视频在线| 亚洲欧洲国产日本综合| 亚洲欧洲另类国产综合| 亚洲欧美一区二区三区久本道91| 亚洲精品中文在线影院| 亚洲国产精品久久久男人的天堂 | xnxx国产精品| 国产日韩精品视频一区| 国产精品嫩草影院av蜜臀| 国产精品国产精品国产专区不片| 日韩理论片中文av| 亚洲一区二区欧美激情| 精品一区二区免费| 成人午夜精品一区二区三区| 成人性色生活片免费看爆迷你毛片| 成人免费看的视频| 日本乱人伦一区| 欧美日韩www| 久久亚洲免费视频| 中文字幕va一区二区三区| 天天综合色天天综合色h| 毛片一区二区三区| 99久久综合99久久综合网站| 欧美影院精品一区| 日韩欧美色综合网站| 亚洲国产精品传媒在线观看| 一区二区三区在线免费| 国产综合色产在线精品| 91麻豆精品秘密| 91精品国产一区二区人妖| 国产性天天综合网| 亚洲国产中文字幕| 国产精品一区不卡| 欧美做爰猛烈大尺度电影无法无天| 精品国产一区二区亚洲人成毛片| 国产精品久久久久久久久晋中 | 色美美综合视频| 久久在线观看免费| 亚洲一区在线免费观看| 裸体一区二区三区| 成人av免费观看| 91精品久久久久久蜜臀| 中文字幕一区日韩精品欧美| 日本aⅴ免费视频一区二区三区| 成人黄色片在线观看| 欧美精品成人一区二区三区四区| 国产精品久久久久天堂| 日韩av在线播放中文字幕| 91丝袜美女网| 久久综合色之久久综合| 偷拍与自拍一区| 91亚洲精品乱码久久久久久蜜桃| 日韩精品最新网址| 亚洲三级免费电影| av电影在线观看一区| 精品久久五月天| 亚洲国产视频在线| 99视频一区二区三区| 久久综合九色综合97婷婷| 丝袜脚交一区二区| 色综合咪咪久久| 亚洲国产成人在线| 亚洲国产乱码最新视频| 色综合天天性综合| 欧美一区二区三区不卡| 亚洲图片自拍偷拍| 日本道精品一区二区三区| 国产欧美日韩不卡| 国产精品亚洲午夜一区二区三区 | 狠狠色丁香婷婷综合| 欧美日韩国产欧美日美国产精品| 一区二区三区四区视频精品免费| 国产成人精品三级麻豆| 久久亚洲一区二区三区明星换脸 | 欧美系列一区二区| 亚洲欧美日韩国产成人精品影院| 国产·精品毛片| 久久精品亚洲麻豆av一区二区| 免费精品视频在线| 欧美色中文字幕| 日本 国产 欧美色综合| 制服丝袜成人动漫| 日本成人在线一区| 欧美丰满高潮xxxx喷水动漫| 手机精品视频在线观看| 国产精品国产三级国产aⅴ原创| 成人黄色在线视频| 亚洲欧洲成人精品av97| 国产成人精品免费|