Finally, port the GTS in UNIX to Windows ~ Hard

Source: Internet
Author: User
Recently, we have consistently searched for a good library for Boolean operations on geometric entities, and found sgcore, which is small and exquisite but has special functions to charge. It is powerful and does not know how to use opencascade, GNU Triangulated Surface Library (GTS) of GNU open-source Unix systems also heard of charged hoops.

At the very beginning, sgcore made me very satisfied with its exquisite structure, easy-to-use programming style, powerful functions, and small size ~~~ However, when you need to convert a triangle model into an entity model, you will be charged. The minimum charge is USD 400. My God, it's amazing ~~~

Finally, I gave up this beautiful "trap ".

The opencascade library borrowed a popular sentence on the sofa Forum: very good, very powerful! Unparalleled functions, including all aspects of CAD/CAM, from two-dimensional splines to three-dimensional entity Operations, everything else, but, too big ~~~ More than 600 m installation package, with M documentation, the sourceProgramOr *. cxx. It's so powerful that I don't know how to get started, so I finally gave up ~~~~~~

The final hope comes from gnu gts, which is small, free, exquisite, and powerful. Only one drawback is that only the unix version is available. Although it can be compiled under Win32, but its makefile is still in the vc6 era, three dependency packages are required. The dependency packages of these two well-prepared Win32 libraries are still compiled by vc6. Even if the GTS compilation is successful under VC ++ 2005, it cannot be used. These two DLL files use msvcrt. dll, while the GTS library compiled by VC ++ 2005 uses msvcrt80.dll, which causes incompatibility.

After reading a large amount of data, we found that the solutions are as follows:

1. Use cygwin for compilation. The disadvantage is that I have to compile the program under cygwin, which is obviously inconvenient. The compiled DLL is not easy to use.

2. Use VC ++ 2005 to re-compile all dependent packages.

3. Give up ~~~~

 

Finally, 2 is selected. GTS should also be compiled to fight for life.

The first problem is the compilation of glib. Because GTS needs to use glib, go to the Internet to find the Win32 version of glib. Actually, only the vc6 version is available. Fortunately, glib's latestSource codeIt already contains the makefile of VC ++ 2005. You also need to find the Win32 version of gettext and libiconv.

After query, find gettext 0.14.4. It is said that the compilation is successful. I tried N for a long time and found that the header file relocate. h was missing. Even if the file was compiled, the problem still exists. Google again. The problem of finding a person is the same as that of me. The solution is to compile it in version 0.14.6. It was successful. Happiness ~~~

Compiling libiconv also encountered some inexplicable problems. Some of them were not defined, and some macros were not defined, which was annoying. Glib is also required to update some old Win32 makefiles .......

These things have been made in four days, and I cannot remember exactly how he succeeded. Finally, an installation package is installed. You only need to execute a batch process to complete compilation and installation .~~~

PS: I'm going to start studying SMS-related things again ~~ Ah, busy all day

 

Download: http://www.hesicong.net/pjblog/article.asp? Id = 271

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.