版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
1、GMesh源码编译设置及如何转换成VS2010工程GMsh源码目录:GMsh的GUI使用Fltk开发。一FLTK简介:FLTK,如同其名字所表达的:The Fast Light Tool Kit,一个轻量级的GUI开发库。但这轻量级并不代表功能的羸弱,相反,FLTK在具有基本的GUI功能之外,还拥有一些特殊的功能,比如跨平台、内置 OpenGL功能、速度更快、尺寸更小、协议宽松等。当然,缺点也是有的,比如对于复杂的界面构件支持不够,资源支持的不足等。功能简介:1. 提供丰富的跨平台的GUI构件(Widget)。有按钮,菜单,窗口等,近六十个。2. 支持OpenGL,提供Fl_GL_Window
2、,支持OpenGL相关的操作。3. 提供界面设计工具FLUID,非常方便进行界面的设计。4. 良好的跨平台移植性。5. 支持多种C+编译器,Gcc,BC,VC等等。6. 灵活性。FLTK本身可以定制,以满足不同的需要。这使得FLTK在嵌入式开发上有着极大的竞争力,这正是我要推荐使用FLTK的原因。二基于VS2010搭建FLTK开发环境HOW TO BUILD FLTK USING VISUAL STUDIO 2010= Prerequisites-In order to build FLTK from within VisualStudio 2010, you need to install
3、the VisualC developer environment from the Microsoft web site. The Express edition is free of charge and sufficient to develop FLTK applications: Downloading and Unpacking-Download FLTK from here:If you are familiar with "subversion" and like to stay current with your version, you will fin
4、d the subversion access parameters at the bottom of that page.Unpack FLTK by using an appropriate unpacker and copy the new folder into a convenient location. I have set up a "dev" folder in my home folder for all my projects. Configuring FLTK-Launch VisualStudio. Open the project file inC
5、hoose "Debug" or "Release" mode from the "Solution Configurations" menu. Building FLTK-Use the context menu of the "demo" project to "Set as StartUp Project". Then select "Build Solution" from the "Build" menu or press F7 to build
6、 all libraries. Testing FLTK-Select "Start Debugging" from the "Debug" menu or just press F5 to run the Demo program. Use "Demo" to explore all test programs. Installing FLTK-The default location for VisualC 2010 libraries and headers is here: C:Program FilesMicrosoft V
7、isual Studio 10.0VCIt is possible to move the FLTK libraries, headers, and Fluid into the respective subdirectories, so that they are available for future development without adding link and include paths to the solution. copy the entire FL directory into the include path copy all .lib files from th
8、e fltk lib directory to the VC lib directory copy fluid.exe in the fluid directory to the bin directoryI highly discourage using dll's (dynamically linking libraries) on MSWindows because they will require an installation process and likely cause version conflicts. Use the static .lib libraries
9、instead. Creating new Projects-This chapter assumes that libraries and headers are copied into C:Program FilesMicrosoft Visual Studio 10.0VCCreate a new project of type "General", "Empty Project" and add a simple "C+" file to it. The FLTK "hello" source code i
10、s a good base.Now open the Project Properties dialog and add "Comctl32.lib" and all the FLTK libraries that you want to use (at least "fltk.lib") to Additional Dependencies (Configuration Properties > Linker > Additional Dependencies). In the same dialog, add "WIN32&qu
11、ot; to the C+ Preprocessor Definitions (Configuration Properties > C/C+ > Preprocessor > Preprocessor Definitions).Compile and run your test program with F5.You can also include .fl resources: add a new Header file to your project, but let the name end in .fl. Right-click and select "O
12、pen with.". Add "fluid.exe" from the "bin" directory and set it as the default editor.To automatically compile .fl files, open the Properties editor and change the Element Type to Custom Build and click Apply. Now set the Custom Build Steps to: Command Line: fluid.exe -c %(F
13、ullPath) Description: Compiling Fluid .fl file Outputs: $(InputDir)$(InputName).cxx; $(InputDir)$(InputName).hNow add the generated .cxx file to your project as well. Whenever the .fl file is changed, the corresponding .cxx file will be recompiled.三利用CMake将GMsh源码生成为VS2010工程Build Gmsh using CMake'
14、;s graphical user interface-* Launch CMake and fill-in the two top input fields (telling where the Gmsh source directory is located and where you want the Gmsh binary to be created).* Click on "Add entry" and define the variable CMAKE_PREFIX_PATH, of type "PATH", pointing to the
15、location(s) of any external package(s) (FLTK, BLAS/LAPACK, etc.) installed in non-standard directories. (If you are using our pre-compiled "gmsh dependencies" package(/gmsh/bin/Windows/gmsh-dep-msvc2008-release.zip) with Visual Studio on Windows simply point CMAKE_PREFIX_PATH
16、 to the "gmsh-dep" directory.)* Click on "Configure" and choose your compiler (e.g. Visual Studio).* Optionally change some configuration options (re-run "Configure" every time you change some options).* Once you are happy with all the configuration options, click on "Generate".* Go to the build directory and build Gmsh using your chosen compiler. (With Visual Studio double-click on "gmsh.sln". If you are using our pre-compiled "gmsh dependencies" package you m
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 2026年度企业安全生产知识竞赛题库及答案
- 培育积极心态远离心理困扰小学主题班会课件
- 库房安全管理规章制度
- 中级经济师考试真题及答案(经济基础)
- 2026年焊工(中级)复审考试题库及答案
- 儿科输血反应现场处置方案演练脚本
- 产房多器官功能障碍事故专项应急预案演练脚本
- 2026年航空航天概论习题及试题库(含答案)
- 2026年化工自动化控制仪表作业证理论考试笔试试题1附答案
- 厂房行车(吊车梁、轨道)安装方案
- 2025贵州遵义市大数据集团有限公司招聘工作人员及笔试历年参考题库附带答案详解
- Unit 7 A Day to Remember 第一课时Section A 1a-1d 说课稿 2024-2025学年人教版(2024)七年级英语下册
- 隐蔽工程监理实施细则范本
- 算力支撑的智能金融风控系统研究报告
- 外贸订单项目跟进甘特图(今日线)
- 苏州博特蒙电机有限公司扩建生产和研发无 刷永磁电机项目报告表
- 船舶电气系统的可靠性分析
- (高清版)JTG 3810-2017 公路工程建设项目造价文件管理导则
- 人教版四年级数学下册期末试卷-
- 《民宿文化与运营》课件-第四章 民宿建设
- JC-T 2536-2019水泥-水玻璃灌浆材料
评论
0/150
提交评论