Using VS2015 64-bit compiler to build up igllib

based on previous blog: http://blog.csdn.net/seamanj/article/details/49368907



To ensure all the projects compiled successfully, 64-bit CGAL4.7 is required. refer to the following blog to config it:

http://blog.csdn.net/seamanj/article/details/51033490


After doing this preparing work, let's begin:


1. download igllib

turn to page :

https://github.com/libigl/libigl/

click "Clone in Desktop" to Clone into your computer somewhere.

here, our clone address is:

C:\work_files


2. config tutorial by cmake


source code: C:/work_files/libigl/tutorial

build the binaries: C:/work_files/libigl/tutorial/build_vs2015_x64

choose Visual Studio 14 2015 Win64 as Generator


if some errors occur at this point, there is a great possibility you download the file through "Download Zip" button. the correct way is through "Clone in Desktop"


3. compile tutorial


Although there are still some errors, we just leave them at that. I will deal with them when necessary.


Last but not least, please comment out the function igl::copyleft::cgal::string_to_mesh_boolean_type like this:

IGL_INLINE bool igl::copyleft::cgal::string_to_mesh_boolean_type( 
  const std::string & s,
  MeshBooleanType & type)
{
  /*using namespace std;
  string eff_s = s;
  transform(eff_s.begin(), eff_s.end(), eff_s.begin(), ::tolower);
  const auto & find_any = 
    [](const vector<string> & haystack, const string & needle)->bool
  {
    return find(haystack.begin(), haystack.end(), needle) != haystack.end();
  };
  if(find_any({"union","unite","u","∪"},eff_s))
  {
    type = MESH_BOOLEAN_TYPE_UNION;
  }else if(find_any({"intersect","intersection","i","∩"},eff_s))
  {
    type = MESH_BOOLEAN_TYPE_INTERSECT;
  }else if(
    find_any(
      {"minus","subtract","difference","relative complement","m","\\"},eff_s))
  {
    type = MESH_BOOLEAN_TYPE_MINUS;
  }else if(find_any({"xor","symmetric difference","x","∆"},eff_s))
  {
    type = MESH_BOOLEAN_TYPE_XOR;
  }else if(find_any({"resolve"},eff_s))
  {
    type = MESH_BOOLEAN_TYPE_RESOLVE;
  }else
  {
    return false;
  }*/
  return true;
}








  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值