Triangle学习之旅——下载与安装

Triangle是一款强大的二维网格剖分工具,适用于Linux系统,特别是Ubuntu。本文详细介绍了从下载a.zip文件到使用makefile进行编译安装的过程,以及如何验证安装是否成功。在Ubuntu中,如果在编译showme时遇到问题,可能是因为缺少X11库,通过安装相关库即可解决。
摘要由CSDN通过智能技术生成

Triangle学习之旅1

0 Triangle简介

  • Triangle是一款简单好用但是功能强大的网格剖分程序,可以将任意二维图形根据需要剖分为三角网格,其源程序为免费程序,只有很小的几个C语言程序,附官网:(http://www.cs.cmu.edu/~quake/triangle.html),官网中有很详细的软件和命令介绍。

1 下载与安装

  • Triangle官网提供了下载通道,可以下载a.zip和a.shar两个文件,这里安装时选择了a.zip文件,安装过程如下:

  • 1)使用unzip命令解压a.zip文件,如果没有unzip命令需要先安装命令;解压后,a.zip中含有如下文件:

    三描述

  • 其中,几个C文件为Triangle源文件,makefile为其内置编写好的安装命令,h文件为编译时需要的头文件,poly文件为Triangle自带的一个简单图形示例,README为Triangle说明文件,里面详细介绍了Triangle软件使用方法。

  • 2) 编译安装有两种方法,第一种为上文提到的直接使用make命令进行编译;也可以选择人工编译,输入以下命令:

cc -O -o triangl
/*****************************************************************************/ /* */ /* 888888888 ,o, / 888 */ /* 888 88o88o " o8888o 88o8888o o88888o 888 o88888o */ /* 888 888 888 88b 888 888 888 888 888 d888 88b */ /* 888 888 888 o88^o888 888 888 "88888" 888 8888oo888 */ /* 888 888 888 C888 888 888 888 / 888 q888 */ /* 888 888 888 "88o^888 888 888 Cb 888 "88oooo" */ /* "8oo8D */ /* */ /* A Two-Dimensional Quality Mesh Generator and Delaunay Triangulator. */ /* (triangle.c) */ /* */ /* Version 1.6 */ /* July 28, 2005 */ /* */ /* Copyright 1993, 1995, 1997, 1998, 2002, 2005 */ /* Jonathan Richard Shewchuk */ /* 2360 Woolsey #H */ /* Berkeley, California 94705-1927 */ /* jrs@cs.berkeley.edu */ /* */ /* This program may be freely redistributed under the condition that the */ /* copyright notices (including this entire header and the copyright */ /* notice printed when the `-h' switch is selected) are not removed, and */ /* no compensation is received. Private, research, and institutional */ /* use is free. You may distribute modified versions of this code UNDER */ /* THE CONDITION THAT THIS CODE AND ANY MODIFICATIONS MADE TO IT IN THE */ /* SAME FILE REMAIN UNDER COPYRIGHT OF THE ORIGINAL AUTHOR, BOTH SOURCE */ /* AND OBJECT CODE ARE MADE FREELY AVAILABLE WITHOUT CHARGE, AND CLEAR */ /* NOTICE IS GIVEN OF THE MODIFICATIONS. Distribution of this code as */ /* part of a commercial system is permissible ONLY BY DIRECT ARRANGEMENT */ /* WITH THE AUTHOR. (If you are not directly supplying this code to a */ /* customer, and you are instead telling them how they can obtain it for */ /* free, then you are not required to make any arrangement with me.)
评论 2
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值