{"id":815,"date":"2021-05-01T23:27:24","date_gmt":"2021-05-01T15:27:24","guid":{"rendered":"https:\/\/www.caiqinyi.cn\/?p=815"},"modified":"2021-05-01T23:27:56","modified_gmt":"2021-05-01T15:27:56","slug":"glew_freeglut_crt","status":"publish","type":"post","link":"https:\/\/www.caiqinyi.cn\/index.php\/2021\/05\/01\/glew_freeglut_crt\/","title":{"rendered":"glew, freeglut\u5e93\u914d\u7f6e\u53ca\u5176\u51b2\u7a81\u89e3\u51b3"},"content":{"rendered":"<p>\u6700\u8fd1\u5728\u770bMeshGit: Diffing and Merging Meshes for Polygonal Modeling. JD Denning, F Pellacini. ACM Transactions on Graphics (TOG) 32 (4), 35, 2013. 36, 2013.\u8fd9\u7bc7Siggraph\u6587\u7ae0, \u60f3\u7740\u8dd1\u4e00\u4e0b\u4f5c\u8005\u7684\u4ee3\u7801\u770b\u770b, CMake\u90a3\u91cc\u7684\u95ee\u9898\u8fd8\u597d\u89e3\u51b3, \u4f46\u5728\u7f16\u8bd1\u65f6\u5c31\u8e29\u4e86\u4e0d\u5c11\u5751, \u9664\u4e86\u91cc\u9762\u5c45\u7136\u7528and\u8868\u793a&#038;&#038;, or\u8868\u793a||, not\u8868\u793a!\u8fd9\u7c7b\u795e\u5947\u7684Python\u5199\u6cd5\u4e4b\u5916, \u8fd8\u5728\u4f7f\u7528glew\u548cfreeglut\u7684lib\u65f6\u9047\u5230\u4e0d\u5c11\u95ee\u9898, \u7279\u6b64\u603b\u7ed3\u4e00\u4e0b~<\/p>\n<p><!--more--><\/p>\n<p>\u4e3b\u8981\u53c2\u8003\u535a\u5ba2: <a href=\"https:\/\/blog.csdn.net\/hdanbang\/article\/details\/47617237\">\u914d\u7f6e\u81ea\u5df1\u7684OpenGL\u5e93\uff0cglew\u3001freeglut\u5e93\u7f16\u8bd1\uff0c\u5e93\u51b2\u7a81\u89e3\u51b3\uff08\u9644OpenGL Demo\u7a0b\u5e8f\uff09<\/a><\/p>\n<p>\u653e\u5230\u81ea\u5df1\u7684\u95ee\u9898\u4e0a\u6765, \u4e3b\u8981\u9700\u8981\u6ce8\u610f\u7684\u70b9\u662f\u5728\u4f7f\u7528\u7b2c\u4e09\u65b9\u5e93\u65f6\u8981\u4fdd\u8bc1\u4ed6\u4eec\u4e0e\u7a0b\u5e8f\u81ea\u8eab\u6240\u4f7f\u7528\u7684CRT\u662f\u4e00\u81f4\u7684, \u5373\u5982\u679c\u7f16\u8bd1\u7a0b\u5e8fB\u65f6\u4f7f\u7528\u4e86\u52a8\u6001\u7248\u672c\u7684CRT\u800c\u7f16\u8bd1A\u65f6\u4f7f\u7528\u7684\u662f\u9759\u6001\u7248\u672cCRT(\u5373A\u3001B\u4f7f\u7528\u4e86\u4e0d\u540c\u7248\u672c\u7684CRT), \u5219\u5927\u6982\u7387\u4f1a\u51fa\u73b0\u4e86\u7b26\u53f7\u91cd\u5b9a\u4e49\u4e4b\u7c7b\u7684\u94fe\u63a5\u9519\u8bef(\u9519\u8bef\u4ee3\u7801\u4e00\u822c\u4e3aLINK2001\u6216\u80052019). \u5f53\u7136\u5982\u679c\u7528\u52a8\u6001\u94fe\u63a5\u7248\u672c\u7684B, \u7a0b\u5e8fA\u8fd0\u884c\u65f6\u53ef\u6267\u884c\u6587\u4ef6\u641c\u7d22\u8def\u5f84\u4e2d\u5fc5\u987b\u5305\u542bB.dll. \u5426\u5219\u62a5\u544a&#8221;\u4e22\u5931xxx.dll&#8221;\u4e4b\u7c7b\u7684\u9519\u8bef. \u8bbe\u7f6e\u7a0b\u5e8f\u5230\u5e95\u4f7f\u7528\u54ea\u4e2a\u7248\u672c\u7684CRT\u53ef\u5728VS\u7684&#8221;\u9879\u76ee\u5c5e\u6027 >> \u914d\u7f6e\u5c5e\u6027 >> C\/C++ >> \u4ee3\u7801\u751f\u6210 >> \u8fd0\u884c\u5e93&#8221;\u4e2d\u8bbe\u7f6e, \u5982\u4e0b\u56fe\u6240\u793a:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.caiqinyi.cn\/wp-content\/uploads\/2021\/05\/\u5fae\u4fe1\u622a\u56fe_20210501231957.png\" alt=\"\" width=\"1111\" height=\"740\" class=\"alignnone size-full wp-image-817\" srcset=\"https:\/\/www.caiqinyi.cn\/wp-content\/uploads\/2021\/05\/\u5fae\u4fe1\u622a\u56fe_20210501231957.png 1111w, https:\/\/www.caiqinyi.cn\/wp-content\/uploads\/2021\/05\/\u5fae\u4fe1\u622a\u56fe_20210501231957-300x200.png 300w, https:\/\/www.caiqinyi.cn\/wp-content\/uploads\/2021\/05\/\u5fae\u4fe1\u622a\u56fe_20210501231957-768x512.png 768w\" sizes=\"(max-width: 1111px) 100vw, 1111px\" \/><\/p>\n<p>\u5176\u4e2d, MT\u4e3a\u662fmulti-thread\u7684\u7f29\u5199, \u5927\u5199D\u4ee3\u8868DLL, \u5c0f\u5199d\u4ee3\u8868debug, \u5982\/MDd\u4e0b\u5f15\u7528\u52a8\u6001\u94fe\u63a5\u8c03\u8bd5\u7248\u672c\u7684\u5e93, \u5e76\u4e14\u7f16\u8bd1\u5668\u5b9a\u4e49\u5b8f_DEBUG, _MT, _DLL(\u7a0b\u5e8f\u4e2d\u53ef\u4ee5\u7528#ifdef\u6307\u4ee4\u6765\u52a8\u6001\u9009\u62e9\u4f7f\u7528\u7684\u5e93\u7248\u672c, \u5982\u4e0b\u6240\u793a).<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"C++\" data-enlighter-theme=\"monokai\">\r\n#ifdef _DLL \/\/ dynamic link\r\n#ifdef _DEBUG\r\n#pragma comment (lib, \"glew32d.lib\")\r\n#pragma comment (lib, \"freeglutd.lib\")\r\n#else\r\n#pragma comment (lib, \"glew32.lib\")\r\n#pragma comment (lib, \"freeglut.lib\")\r\n#endif\r\n#else \/\/ static link\r\n#ifdef _DEBUG\r\n#pragma comment (lib, \"glew32sd.lib\")\r\n#pragma comment (lib, \"freeglut_staticd.lib\")\r\n#else\r\n#pragma comment (lib, \"glew32s.lib\")\r\n#pragma comment (lib, \"freeglut_static.lib\")\r\n#endif\r\n#define GLEW_STATIC\r\n#define FREEGLUT_STATIC\r\n#endif\r\n<\/pre>\n<p>\u5728\u7f16\u8bd1meshgit\u65f6, \u6211\u4f7f\u7528\u7684\u5e93\u53ca\u7a0b\u5e8f\u7684CRT\u90fd\u7edf\u4e00\u4e3a\u4e86\/MT(Release\u4e0b\u4f7f\u7528)\u548c\/MTd(Debug\u4e0b\u4f7f\u7528), \u56e0\u4e3a\u8fd9\u4e24\u79cd\u6a21\u5f0f\u4e0d\u9700\u8981\u4f7f\u7528Dll. \u7531\u6b64\u53ef\u4ee5\u770b\u51fa, \u5e93\u6700\u597d\u8fd8\u662f\u5c3d\u91cf\u4e0b\u8f7d\u6e90\u7801\u4e0b\u6765\u81ea\u5df1\u7f16\u8bd1, \u8fd9\u6837\u65b9\u4fbf\u63a7\u5236\u5176CRT, \u5982\u679c\u662f\u4f7f\u7528\u5b98\u65b9\u5e2e\u4f60\u7f16\u8bd1\u597d\u7684lib, \u5f53\u4f7f\u7528\u7684\u7b2c\u4e09\u65b9\u5e93\u6570\u76ee\u4e00\u591a, \u5c31\u5f88\u5bb9\u6613\u51fa\u73b0\u5404\u79cd\u5947\u5947\u602a\u602a\u7684\u9519\u8bef, \u5305\u62ec\u559c\u95fb\u4e50\u89c1\u7684&#8221;\u65e0\u6cd5\u89e3\u6790\u7684\u5916\u90e8\u7b26\u53f7&#8221;\u7cfb\u5217~<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6700\u8fd1\u5728\u770bMeshGit: Diffing and Merging Meshes for Polygonal M &hellip; <a href=\"https:\/\/www.caiqinyi.cn\/index.php\/2021\/05\/01\/glew_freeglut_crt\/\" class=\"more-link\">\u7ee7\u7eed\u9605\u8bfb<span class=\"screen-reader-text\">glew, freeglut\u5e93\u914d\u7f6e\u53ca\u5176\u51b2\u7a81\u89e3\u51b3<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11],"tags":[],"_links":{"self":[{"href":"https:\/\/www.caiqinyi.cn\/index.php\/wp-json\/wp\/v2\/posts\/815"}],"collection":[{"href":"https:\/\/www.caiqinyi.cn\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.caiqinyi.cn\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.caiqinyi.cn\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.caiqinyi.cn\/index.php\/wp-json\/wp\/v2\/comments?post=815"}],"version-history":[{"count":6,"href":"https:\/\/www.caiqinyi.cn\/index.php\/wp-json\/wp\/v2\/posts\/815\/revisions"}],"predecessor-version":[{"id":822,"href":"https:\/\/www.caiqinyi.cn\/index.php\/wp-json\/wp\/v2\/posts\/815\/revisions\/822"}],"wp:attachment":[{"href":"https:\/\/www.caiqinyi.cn\/index.php\/wp-json\/wp\/v2\/media?parent=815"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.caiqinyi.cn\/index.php\/wp-json\/wp\/v2\/categories?post=815"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.caiqinyi.cn\/index.php\/wp-json\/wp\/v2\/tags?post=815"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}