help > Matlab toolbox
Showing 1-15 of 15 posts
Display:
Results per page:
Sep 9, 2017  07:09 AM | li annine - shantouuniversity
Matlab toolbox
Hi
I tried to compile Matlab toolbox on a windows 10, 64 bit machine with Matlab R2016a. I have installed MinGW64 Compiler (C++) successfully. When I run makeosmex_rawfile_io.m, the line ,"mex saveStack2File_c.cpp mg_image_lib.cpp mg_utilities.cpp -L../v3d_main/common_lib/lib -lv3dtiff", had an error. The v3dtiff.lib couldn't be found. Later I found that there doesn't exist a folder called "lib" in the directory ../v3d_main/common_lib. Could you tell me how to solve the problem?
Thanks.
Sep 9, 2017  02:09 PM | Zhi Zhou
RE: Matlab toolbox
Sep 11, 2017  12:09 PM | li annine - shantouuniversity
RE: Matlab toolbox
According to your suggestion , I ran the build.linux in the v3d_external directory in the linux system.The "lib" folder could be generated in the v3d_external\v3d_main\common_lib directory automatically.Then I could run makeosmex_rawfile_io.m successfully and use the functions like  load_v3d_raw_img_file in MATLAB R2016a. But I couldn't build Vaa3D on Windows.(Qmake). I followed the steps on your wiki page:
          https://github.com/Vaa3D/Vaa3D_Wiki/wiki...
When I click "Build->Build Solution F7", there are three kinds of errors.:
         fatal error C1083: can't open :"tiffconf.h";
         fatal error C1083: can't open :"stdint.h";
         C1189: #error : "GLM requires Visual C++ 2010 or higher".
By the way, Should I build Vaa3D on the windows before I compiled the s2 plug-in?
Thanks.
Sep 15, 2017  05:09 PM | Hsienchi Kuo
RE: Matlab toolbox
Theoretically, you don't have to have Vaa3D built before you build S2. But you should know you need to have Vaa3D in order to use S2.

As for the other 3 errors:

1. tiffconf.h should be in '\common_lib\include\' directory. Please make sure you copied "all files" rather than the folder into designated place, as stated in our instruction: [copy all the tiff header (.h) files from the "tiff-4.0.2\libtiff" folder into "v3d_main\common_lib\include"] 

2. Please navigate to your \common_lib\include\hdf5 directory, change stdint_VS.h to stdint.h. 

3. VS2008 is obsolete and some keywords and syntax are deprecated due to C++11 standard. Our VS2010 instruction is the most up to date and all Vaa3D features and plugins have been tested on VS2010 platform. I strongly recommend that you migrate your development platform from VS2008 to VS2010.
Image
Attachment: screenShot1.png
Sep 16, 2017  04:09 PM | li annine - shantouuniversity
RE: Matlab toolbox
I have built vaa3d and s2 plugin on vs2010 platflom according to the new web information about Build Vaa3D on Windows (VS2010 and QMake),but I still came cross some problems.
when I build vaa3d,there is an error,that is:
1>QtOpenGL4.lib(QtOpenGL4.dll) : fatal error LNK1112: 模块计算机类型"X86"与目标计算机类型"x64"冲突
I added src_packages\tiff-4.0.2\libtiff.lib into additional library directories before building s2 plugin,then s2 complied sucessfully.And I could find s2 folder in v3d_external\bin\plugins list,it includes s2.dll、s2.exp and s2.lib. Putting s2 folder into the "plugins" folder of the Vaa3D program folder,but s2 plugin doesn't work in vaa3d.
Thanks
Sep 18, 2017  09:09 PM | Hsienchi Kuo
RE: Matlab toolbox
1. When you build Vaa3D, you need to check your solution platform x64. If that field is left with Win32, which is usually the default, your build will be going to X86 platform.

2. I don't quite understand your second issue. I thought you couldn't build Vaa3D in the first place as you suggested in your post?  If you can compile S2 successfully, you should be able to use that plugin without a problem on running-ok Vaa3D.
Sep 19, 2017  08:09 AM | li annine - shantouuniversity
RE: Matlab toolbox
1. Actually, we exactly built vaa3d_msvc project in "Release" and "x64" mode in vs2010. Though analysis of this error: 1>QtOpenGL4.lib(QtOpenGL4.dll) : fatal error LNK1112: 模块计算机类型"X86"与目标计算机类型"x64"冲突, we found that qt libraries are compiled in win32 mode by running configure -debug-and-release -opensource -platform win32-msvc2010.
2.We downloaded InstallVaa3D-3.20-Windows_MSVC_64.exe directly and vaa3d is ok. To use s2 plugin in vaa3d, we compile s2 plugin from source code in in "Release" and "win32"mode in vs2010, it was compiled successfully.

1>------ 已启动全部重新生成: 项目: s2, 配置: Release Win32 ------
1> Moc'ing SimScope.h...
1> Qt: Untested Windows version 6.2 detected!
1> Moc'ing eventLogger.h...
1> Qt: Untested Windows version 6.2 detected!
1> Moc'ing noteTaker.h...
1> Qt: Untested Windows version 6.2 detected!
1> Moc'ing s2Controller.h...
1> Qt: Untested Windows version 6.2 detected!
1> Moc'ing s2UI.h...
1> Qt: Untested Windows version 6.2 detected!
1> Moc'ing s2_plugin.h...
1> Qt: Untested Windows version 6.2 detected!
1> Moc'ing s2monitor.h...
1> Qt: Untested Windows version 6.2 detected!
1> Moc'ing stackAnalyzer.h...
1> Qt: Untested Windows version 6.2 detected!
1> Moc'ing targetList.h...
1> Qt: Untested Windows version 6.2 detected!
1> Uic'ing s2plot.ui...
1> Qt: Untested Windows version 6.2 detected!
1> Displacement.cpp
1> DisplacementMIPNCC.cpp
1> IM_config.cpp
1> MergeTiles.cpp
1> PDAlgo.cpp
1> PDAlgoMIPNCC.cpp
1> ProgressBar.cpp
1> RawFmtMngr.cpp
1> RawVolume.cpp
1> moc_eventLogger.cpp
1> moc_noteTaker.cpp
1> moc_s2Controller.cpp
1> moc_s2monitor.cpp
1> moc_s2UI.cpp
1> moc_s2_plugin.cpp
1> moc_SimScope.cpp
1> moc_stackAnalyzer.cpp
1> moc_targetList.cpp
1> SimScope.cpp
1> SimpleVolume.cpp
1> 正在生成代码...
1> 正在编译...
1> SimpleVolumeRaw.cpp
1> Stack.cpp
1> StackRaw.cpp
1> StackRestorer.cpp
1> StackStitcher.cpp
1> StackedVolume.cpp
1> TPAlgo.cpp
1> TPAlgoMST.cpp
1> Tiff3DMngr.cpp
1> TiledMCVolume.cpp
1> TiledVolume.cpp
1> TimeSeries.cpp
1> VirtualFmtMngr.cpp
1> VirtualVolume.cpp
1> app2_connector.cpp
1> basic_4dimage_create.cpp
1> basic_surf_objs.cpp
1> compute_funcs.cpp
1> eventLogger.cpp
1> exampleplugin2D.cpp
1> 正在生成代码...
1> 正在编译...
1> imBlock.cpp
1> imProgressBar.cpp
1> iomanager.config.cpp
1> libcrossmips.cpp
1> my_surf_objs.cpp
1> noteTaker.cpp
1> resumer.cpp
1> s2Controller.cpp
1> s2UI.cpp
1> s2_plugin.cpp
1> s2monitor.cpp
1> stackAnalyzer.cpp
1> swc_convert.cpp
1> targetList.cpp
1> tiff2D.cpp
1> tiff3D.cpp
1> tileInfo.cpp
1> tinystr.cpp
1> tinyxml.cpp
1> tinyxmlerror.cpp
1> 正在生成代码...
1> 正在编译...
1> tinyxmlparser.cpp
1> v3d_message.cpp
1> vmBlock.cpp
1> vmBlockVolume.cpp
1> vmStack.cpp
1> vmStackedVolume.cpp
1> vmVirtualStack.cpp
1> vmVirtualVolume.cpp
1> vn_imgpreprocess.cpp
1> volumemanager.config.cpp
1> 正在生成代码...
1> 正在创建库 ..\..\..\..\v3d_external\bin\plugins\s2\s2.lib 和对象 ..\..\..\..\v3d_external\bin\plugins\s2\s2.exp
1> s2.vcxproj -> D:\Program Files\Vaa3D-3.20\vaa3d_tools\hackathon\brl\s2\..\..\..\..\v3d_external\bin\plugins\s2\s2.dll
========== 全部重新生成: 成功 1 个,失败 0 个,跳过 0 个 ==========
"s2" folder generated automatically, including s2.exp、s2.lib、s2.dll. Putting s2 folder into the "plugins" folder of the Vaa3D program folder, but s2 plugin doesn't work in vaa3d. When compiling s2 plugin from source code in in "Release" and "x64"mode in vs2010, a dialog box popped up(you can see in the picture I have attached).
Thanks!
Sep 19, 2017  04:09 PM | Hsienchi Kuo
RE: Matlab toolbox
It seems like you used Qt Add-in to convert qt project file to VS vcxproj file, is that correct?
If that's the case, you need to go to Qt Tools -> Options and specify the path where your qmake is located. It's usually your QTDIR but without \bin because it adds \bin by itself.
Sep 22, 2017  03:09 AM | li annine - shantouuniversity
RE: Matlab toolbox
Yes, that is correct and I configured "Qt Tools -> Options" as what you said. Last time I built Vaa3D using jom instead of nmake. I neglect there was an error after the step of jom. So I just input nmake to proceed according to Build Vaa3D on Windows (VS2010 and QMake) again. Nothing went wrong when I built Vaa3D in VS2010. vaa3d_msvc.exe is generated in v3d_external\bin\release directory. However, any image or stack couldn't be opened successfully using Vaa3D I just built. A dialog box popped up, you can see it in the attachment. Could you give me some advice?
Thanks.
Attachment: 20170922170401.png
Sep 22, 2017  07:09 AM | li annine - shantouuniversity
RE: Matlab toolbox
We could compile s2 plugin from source code in "Release" and "x64"mode in vs2010 and s2 folder was generated automatically in v3d_external\bin\plugins directory, it includes s2.dll、s2.exp and s2.lib. After putting s2 folder into the "plugins" folder of the Vaa3D program folder, the interface of s2 could be opened in vaa3d. Most of the buttons are ok except three buttons, including "Simulator/select data to trace", "tracing/trace single stack", "tracing/process smartScan files". Clicking the three buttons, vaa3d_msvc.exe would stop running and exit. How could I solve the problems?
Thanks.
Attachment: 20170922170121.png
Sep 29, 2017  07:09 PM | Hsienchi Kuo
RE: Matlab toolbox
I have replied to one of your colleagues, 梁博森. Please find him for further advise.

NITRIC sometimes cancels my subscription to this forum and makes me miss messages. Sorry about that.
Sep 30, 2017  03:09 AM | li annine - shantouuniversity
RE: Matlab toolbox
You're welcome. He has told me the advise.  Thanks.
Attachment: vaa3d_msvc.rar
Sep 30, 2017  06:09 AM | li annine - shantouuniversity
RE: Matlab toolbox
We attained v3d_external folders by git operation referring to
https://github.com/Vaa3D/Vaa3D_Wiki/wiki...
git clone --recursive https://github.com/Vaa3D/v3d_external.gi...
is this latest v3d_external main code, if not, how could we get it. Thanks.
Oct 6, 2017  10:10 PM | Hsienchi Kuo
RE: Matlab toolbox
Yes. If you clone the codes from git, it'll be the latest.
Oct 6, 2017  10:10 PM | Hsienchi Kuo
RE: Matlab toolbox
I have tested your s2.dll with my own built Vaa3D (VS2010/Qt472), and it worked just fine. This means you built s2 correctly and that this s2.dll you sent me is valid. No need to further check your s2 pro file and vcxproj files.

I recommend that you carefully follow the instruction of building Vaa3D with VS2010 and qmake (Qt472) and rebuild it again. If your vaa3d_msvc.exe is built correctly, you HAVE TO be able to use s2 without a problem.

You cannot use the release Vaa3D with this s2 plugin yet. Since that release version, Vaa3D has undergone many changes and upgrades, and some s2 functionalities are associated with those new stuff. Therefore this release version is not able to handle s2. Other plugins in hackathon folder may or may not have the same issue with this release version. That's why it doesn't include those newly developed plugins at this moment.

Note, in s2 when you want to see how the tracing goes, you need to zoom the ROI window all the way in. Currently that ROI window is a bit off scale, so you need to play around with it in order to see the real-time image display happen in the ROI window.