⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 2004-september.txt

📁 acis说明文档
💻 TXT
📖 第 1 页 / 共 3 页
字号:
From: PG02104852 at ntu.edu.sg (#TANG SHAOHUI#)Date: Tue Sep 14 04:02:14 2004Subject: [Acis-alliance] how to remove faces and repair body?Message-ID: <0C42D409AF10B1428A0B026FB160A5BE11B014@mail02.student.main.ntu.edu.sg>hi, everyoneI am trying to use api_remove_and_repair_body or api_remove_faces to remove faces and reconstruct body but failed with an error. following is my program, can you kindly tell me what's wrong with it or give me an example on how to use these api functions? I am using ACIS 7.0.  ENTITY_LIST f_element; ENTITY_LIST n_face_list; ATTRIB* mylabel;  result = api_get_faces(save_part, n_face_list);                check_outcome(result, "Error geting face list");  for(int i=0; i<n_face_list.count(); i++)  {  mylabel=n_face_list[i]->attrib();  ATTRIB_BLOCKLABEL* new_label = (ATTRIB_BLOCKLABEL*)mylabel;  ENTITY* label_owner= new_label->get_featureid();  if(label_owner==(ENTITY*)myblock_attrib1)     {        f_element.add(n_face_list[i]);     } } cout<<f_element.count()<<endl;  FACE*  d_face[10]; for(i=0; i< f_element.count(); i++) { d_face[i]= (FACE*)f_element[i]; cout<< d_face[i]<<endl; }  position box_low; position box_high; result= api_remove_faces(f_element.count(),  d_face, box_low, box_high); check_outcome(result, "Error delete faces");  error occured as: error 6015, Acess violationbest regardsshaohui-------------- next part --------------An HTML attachment was scrubbed...URL: http://lists.cs.columbia.edu/pipermail/acis-alliance/attachments/20040914/f7485c2a/attachment.htmlFrom Samuel.Mazel at cedrat.com  Tue Sep 14 10:37:47 2004From: Samuel.Mazel at cedrat.com (Samul Mazel)Date: Tue Sep 14 10:35:22 2004Subject: [Acis-alliance] Allocating MemoryMessage-ID: <005b01c49a68$67703660$8201a8c0@cedratgrenoble.fr>Hi    I try to allocate a matrix of faces like that    FACE ***matFaces = ACIS_NEW FACE**[10];    VC++ accept at the compilation    but when access to, during runing,    matFaces[0][0] = block->lump()->shell()->face();    say Access violation !!    I can allocate a simple table    FACE **tabFace = ACIS_NEW FACE*[10];    It's possible to use a "matrix" of entities ? and if Yes how allocate ?    thanks    SamuelFrom alames at sandia.gov  Tue Sep 14 10:59:37 2004From: alames at sandia.gov (Ames, Arlo)Date: Tue Sep 14 11:00:23 2004Subject: [Acis-alliance] how to set color or material information to	a n entityMessage-ID: <16F54D8E44BBEE4BBBDB5EFB3AEEB86D01C52338@es06snlnt.sandia.gov>If you want an attribute to survive boolean operations, you need to ensurethe following:  that the attribute class has member functions that supportboolean operations, and that the attribute code is linked in the applicationperforming the booleans.  Member functions, such as split_owner andmerge_owner, are called during boolean operations -- if you writeappropriate content, you can ensure that the attribute is copied through theoperation.  ACIS aupports the notion of attributes that don't have theirclass definitions linked into the application -- such attributes areessentially "dead", copied through if their owning entities are leftunmodified, with somewhat arbitrary-seeming results if their owners aremodified.In the end, writing your own attributes is the only way to ensure that thesplit and merge functions are written as you want them, and you need to besure your attribute code is linked into whatever applications are being usedto operate on the geometry you're interested in.Arlo Amesalames@sandia.gov-----Original Message-----From: Sanjay Kumar [mailto:sp52@buffalo.edu] Sent: Tuesday, September 14, 2004 6:14 AMTo: Ames, ArloSubject: RE: [Acis-alliance] how to set color or material information to a nentityhello, i would like to thank you for your valuable inputs. i used ATTRIB_COL which allows to set color to individual entities within the same part. i set color to individual entities and then add them to a list before i write it to a sat file. this way the color features are maintaited, but however if i perform a boolean operation of two entities then the color info is lost. can you give me some suggestions on how to overcome this problem. i think i have to mention the attribute properties to be kept after the bool operation. some code snippets would be very useful. i really appreciate you help. thanks, sanjay--On Thursday, September 09, 2004 8:21 AM -0600 "Ames, Arlo" <alames@sandia.gov> wrote:> Are you trying to color objects for your own application, or feed > color information to other applications?  If the former, any attribute > will do> -- define your own from scratch or use the generic attribute mechanisms.> If the latter, you need to use whatever attribute structure is used by the> application in question.>> Arlo Ames> alames@sandia.gov>> -----Original Message-----> From: Sanjay Kumar [mailto:sp52@buffalo.edu]> Sent: Wednesday, September 08, 2004 8:28 PM> To: acis-alliance@cs.columbia.edu> Subject: [Acis-alliance] how to set color or material information to > an entity>>> hi alliance grp members,>  i need to set color to various entities stored ina single SAT file. > i'm not able to use the RH_MATERIAL or ATTRIB_COL components of ENTITY > class (Rendering base component). Any comments or suggestions throwing > light on how to set these properties to a part will be very useful. > i'm using ACIS R13SP5 with visual c++ 6.0>>  thanks,>  sanjay>>>>> _______________________________________________> Acis-alliance mailing list> Acis-alliance@cs.columbia.edu > http://lists.cs.columbia.edu/mailman/listinfo/acis-alliance>>Sanjay Kumar P,Graduate Student,Department of Industrial Engineering,University at Buffalo, The State University of New York,339, Bell Hall,Buffalo, New York 14260-2050E-mail: sp52@buffalo.eduTel: (716)-645-2357 Ext.2163From alames at sandia.gov  Tue Sep 14 11:03:51 2004From: alames at sandia.gov (Ames, Arlo)Date: Tue Sep 14 11:04:17 2004Subject: [Acis-alliance] Allocating MemoryMessage-ID: <16F54D8E44BBEE4BBBDB5EFB3AEEB86D01C52339@es06snlnt.sandia.gov>Your question isn't an ACIS question, but a C/C++ question.Try this:FACE *** matFaces = ACIS_NEW FACE**[10];for (int i = 0; i < 10; i++){   matFaces[i] = ACIS_NEW FACE*[10];   for (int j = 0; j < 10; j++)   {      matFaces[i][j] = block->lump...   }}-----Original Message-----From: Samul Mazel [mailto:Samuel.Mazel@cedrat.com] Sent: Tuesday, September 14, 2004 8:38 AMTo: acis-alliance@cs.columbia.eduSubject: [Acis-alliance] Allocating MemoryHi    I try to allocate a matrix of faces like that    FACE ***matFaces = ACIS_NEW FACE**[10];    VC++ accept at the compilation    but when access to, during runing,    matFaces[0][0] = block->lump()->shell()->face();    say Access violation !!    I can allocate a simple table    FACE **tabFace = ACIS_NEW FACE*[10];    It's possible to use a "matrix" of entities ? and if Yes how allocate ?    thanks    Samuel_______________________________________________Acis-alliance mailing listAcis-alliance@cs.columbia.eduhttp://lists.cs.columbia.edu/mailman/listinfo/acis-allianceFrom e_wwg at 163.com  Thu Sep 23 05:04:04 2004From: e_wwg at 163.com (=?gb2312?B?ZV93d2c=?=)Date: Thu Sep 23 05:04:06 2004Subject: [Acis-alliance] About api_cover_wiresMessage-ID: <41529184.000191.13009@m252.163.com>Hi,all    I have some ploblems when i use the api_cover_wires fuction. i tried to draw the side face of a cylinder(i read the data form a constructed model and i want to reconstruct it myself):    First i draw all the edge of the top and bottom loop(both external) then unit them as two wire bodys--a top one and a bottom one; then use api_cover_wires fuction to make a face. it works well when the edges are consist of circles or ellipse, but when one of these edges happens to be a intcurve, or a straight sometimes, it fails!     I guess it may be because that i make these intcurves using the api_mk_ed_int_ctrlpts fuction(these intcurves can be drawn well). These intcurves are intersectant curves of two faces, and i know that in the .sat file when it record an intcurve it also record the intersectant faces' geometry feature(cone or plane...).    Then I want to get the data of these intersectant faces from the intcurve. --------------------------------------------------------------------------------------    EDGE* eg = (the intcurve i have got)      CURVE * GeoCurve = eg->edge()->geometry();      curve const & EqtCurve = GeoCurve->equation();      intcurve* ic = (intcurve*&)EqtCurve;      if(ic != NULL)          surface const & tempsurf = ic->surf1();--------------------------------------------------------------------------------------It breaks out at the last line. It seems as if it cannot access the members of "ic"(ic != NULL), and I donnot know what to do.I have seen that someone said that the function of api_cover_faces is very limited, but is there some other APIs I can chose?It also meet problems some times.Any help will be appreciated! Thanks in advance!Weiguo WangShandong University, China2004-9-23-------------------------------------------------------------------------------------周杰伦在"第一现场"与你面对面 http://smspop.163.com/special/jay200408/index2.htmlFrom davidkou at hkusua.hku.hk  Fri Sep 24 02:20:30 2004From: davidkou at hkusua.hku.hk (David)Date: Fri Sep 24 02:21:00 2004Subject: [Acis-alliance] Re: About api_cover_wiresMessage-ID: <200409240620.i8O6KRGE008441@hkusua.hku.hk>Dear Weiguo,If you just want to draw (render) the side surface, I suggest you use other functions. e.g.//[1] Construct a cylinder use whatever functions you like:	BODY *pCylinder;	api_make_frustum(, , , , pCylinder);//[2] Get the side face	FACE * pSideFace;	ENTITY_LIST FaceList;	api_get_faces(pCylinder,FaceList);	FaceList.init();		ENTITY* pFace=FaceList.next();	while(pFace!=NULL) 	{		if(is_cylindrical_face(pFace))		{		    pSideFace=pFace;			break;		}		pFace=FaceList.next();	}//[3] Facet the side face with polygons:	api_facet_face(pSideFace);//[4] Use opengl etc. to render it:	...Hope this helps.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -