<div>I doubt if you have built and install VTK properly. I have VTK installed in 'C:\Program Files\VTK' because I set the CMAKE_INSTALL_PREFIX in CMake as it. Your VTK will be in the directory you set for CMAKE_INSTALL_PREFIX in CMake.
</div>
<div> </div>
<div>You must build INSTALL to make VTK really installed - just like typing 'make install' if you are using concole, which will create the include and lib directories and all the header files and lib files for you.<br><br>
By the way, I am using VTK 5.0.2 and CMake 2.4.<br><br>And the last hint: Don't criticize others for non-complete solution. These people are trying to help you. Think carefully over your problem and others' answers and try to ask right questions.
<br></div>
<div><br>Good luck.<br> </div>
<div><span class="gmail_quote">On 11/2/06, <b class="gmail_sendername">mam06bhv</b> <<a href="mailto:mam06bhv@studserv.uni-leipzig.de" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">mam06bhv@studserv.uni-leipzig.de
</a>> wrote:</span>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0px 0px 0px 0.8ex; padding-left: 1ex;">That's what I mean in some previous mails. Everyone give me hints but<br>bnothing is a complete solution.
<br>
<br>Ning Ye schrieb:<br>> Obada is right, don't give up VTK. It's really a cool stuff.<br>> Actually, you CAN use VTK in VC++ .NET 2005 for your own project<br>> without CMake.<br>> Here's my step in great detail:
<br>> -------- Build and install VTK, CMake is needed here for only once<br>> --------<br>> 1. Extract VTK source code to a directory, say,<br>> D:\Programming\VTK\vtk-5.0.2\src<br>> 2. Make another directory for build, say,
<br>> D:\Programming\VTK\vtk-5.0.2\build<br>> 3. Run CMake and configure it as shown in the picture attached, press OK<br>> 4. Enter the build directory, D:\Programming\VTK\vtk-5.0.2\build, open<br>> the solution file
VTK.sln<br>> 5. Set the solution configuration to Debug mode, right click<br>> ALL_BUILD, build<br>> 6. Right click INSTALL, build<br>someone told me that is not necessary, but I did it<br>> 7. Enter the install directory, for me, it's C:\Program Files\VTK
<br>whatr have you installed there. I don't have such a directory after all<br>I did<br>> 8. Enter the sub-directory for library, i.e., C:\Program<br>> Files\VTK\lib, for now, all the .lib files here are built under Debug,
<br>> you can use them for Debug in your own project<br>> 9. So, make a new directory here, say, C:\Program Files\VTK\lib\debug,<br>> and move all the .lib files into it<br>> 10. Back to VC++, this time, set your solution configuration to
<br>> Release mode and redo step 5 and 6<br>> 11. Enter C:\Program Files\VTK\lib again, now, all the .lib files are<br>> built under Release, you can use them for Release in your own project<br>> 12. So, make another new directory here, say, C:\Program
<br>> Files\VTK\lib\release, and move all the .lib files into it<br>> 13. Installation part is done.<br>> --------Configuration for your own project--------<br>> 1. Configure VC++ INCLUDE path: Tools->Options->Projects and
<br>> Solutions->VC++ Directories->Include files, add the VTK include<br>> directory into the list, for me, it's C:\Program Files\VTK\include<br>whre do you get the include directory from? I have (if I have count all)
<br>5 include directories<br>> 2. Configure your project property:<br>> Debug mode:<br>> - set Configuration Properties->Linker->General->Additional Library<br>> Directories as C:\Program Files\VTK\lib\debug
<br>> - set Configuration Properties->Linker->Input->Additional Dependencies<br>> as all the .lib files you need, well, you can just include all the<br>> library files here to make it work for sure<br>> Release mode:
<br>> - set Configuration Properties->Linker->General->Additional Library<br>> Directories as C:\Program Files\VTK\lib\release<br>> - set Configuration Properties->Linker->Input->Additional Dependencies
<br>> as all the .lib files you need, again, you can just include all the<br>> library files here to make it work for sure<br>> 3. Done.<br>><br>> Compile and build your projects as you want.<br>> Happy programming!
<br>><br>><br>> On 11/2/06, *<a href="mailto:mam06bhv@studserv.uni-leipzig.de" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">mam06bhv@studserv.uni-leipzig.de</a><br>> <mailto:<a href="mailto:mam06bhv@studserv.uni-leipzig.de" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
mam06bhv@studserv.uni-leipzig.de
</a>>*<br>> <<a href="mailto:mam06bhv@studserv.uni-leipzig.de" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">mam06bhv@studserv.uni-leipzig.de</a><br>> <mailto:<a href="mailto:mam06bhv@studserv.uni-leipzig.de" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
mam06bhv@studserv.uni-leipzig.de</a>>> wrote:
<br>><br>> Obada Mahdi schrieb:<br>> > Hi Markus!<br>> ><br>> > On 11/1/06, mam06bhv <<a href="mailto:mam06bhv@studserv.uni-leipzig.de" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
mam06bhv@studserv.uni-leipzig.de</a><br>> <mailto:
<a href="mailto:mam06bhv@studserv.uni-leipzig.de" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">mam06bhv@studserv.uni-leipzig.de</a>>> wrote:<br>> >> I've solved the problem but now I got these errors in the
<br>> VTK-window<br>> ><br>
> > Just for the record, what was the solution? It might be helpful to<br>> > others who search the mailing list and find themselves having a<br>> > similar problem.<br>> ><br>> >> ERROR: In ..\..\VTK\Rendering\vtkWin32OpenGLRenderWindow.cxx,
<br>> line 824<br>> >> vtkWin32OpenGLRenderWindow (01970FD0): wglCreateContext failed in<br>> >> CreateAWindow(), error: 1114<br>> >><br>> >> ERROR: In ..\..\VTK\Rendering\vtkWin32OpenGLRenderWindow.cxx,
<br>> line 824<br>> >> vtkWin32OpenGLRenderWindow (01970FD0): wglCreateContext failed in<br>> >> CreateAWindow(), error: 0<br>> >><br>> >> ERROR: In ..\..\VTK\Rendering\vtkWin32OpenGLRenderWindow.cxx,
<br>> line 824<br>> >> vtkWin32OpenGLRenderWindow (01970FD0): wglCreateContext failed in<br>> >> CreateAWindow(), error: 6<br>> ><br>> > I did a quick search in the mailing list archives for similar error
<br>> > messages and found a reply from Mathieu Malaterre:<br>> ><br>> <a href="http://public.kitware.com/pipermail/vtkusers/2004-January/071401.html" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
http://public.kitware.com/pipermail/vtkusers/2004-January/071401.html
</a><br>> ><br>> > Some other postings did not have replies or solutions, but it seems<br>> > that the problem is related to OpenGL drivers/libraries rather than<br>> > VTK. One suggestion for narrowing down the problem is to run other
<br>> > OpenGL applications and see if they work. For example, start by<br>> > building VTK with "BUILD_EXAMPLES" set to "ON" and run one of the<br>> > examples, like "Cone". If it does not work, try other, non-VTK
<br>> > programs that use OpenGL, and if they do not work either, it is very<br>> > likely a problem with your graphics card/OpenGL driver.<br>> ><br>> > I also agree with Prename that you should consider using CMake for
<br>> > creating your VisualStudio project. After seeing the same problems<br>> > reportet on the mailing like multiple times, I do not think that<br>> this<br>> > will make a difference--but the important point is that it is much
<br>> > easier to understand the steps involved in building your project and<br>> > to eliminate some possibilities that might be a result of an<br>> > unconventional build setup.<br>> >
<br>> > Here is a sample "CMakeLists.txt" file that should be sufficient for<br>> > creating a VS8 Solution for your sample program (I called it<br>> > "markus-test.cc ") using CMake:
<br>> ><br>> > [this is actually a stripped-down version of<br>> > "Examples/Medical/Cxx/CMakeLists.txt"]<br>> > ----BEGIN----<br>> > PROJECT (markus-test)<br>> >
<br>> > FIND_PACKAGE(VTK REQUIRED)<br>> > IF(NOT VTK_USE_RENDERING)<br>> > MESSAGE(FATAL_ERROR "Example ${PROJECT_NAME} requires<br>> VTK_USE_RENDERING.")<br>> > ENDIF(NOT VTK_USE_RENDERING)
<br>> > INCLUDE(${VTK_USE_FILE})<br>> ><br>> > ADD_EXECUTABLE(markus-test markus-test.cc)<br>> ><br>> > TARGET_LINK_LIBRARIES(markus-test vtkRendering)<br>> > ----END----
<br>> ><br>> > Just put this and "markus-test.cc" into the same directory, create a<br>> > build directory somewhere and use CMakeSetup.exe to create a VS8<br>> > Solution file. In the interactive configuratio process, you
<br>> will need<br>> > to specify the location of the directory ".../lib/vtk-<version>"<br>> from<br>> > your VTK installation.<br>> ><br>> ><br>> > Regards
<br>> ><br>> > Obada<br>> Sorry guys<br>> I'm tired to run it again and again. Is somewhere a tutorial or<br>> something else<br>> where I can go through step by step (downloading what installing
<br>> where what to<br>> build wehre to copy and everything in detail) and not only telling<br>> me the half.<br>> in the last 3 days I've installed Cmake and VTK deinstalled<br>> everything.
<br>> installed again and so one and nothing helped.<br>> Why should I use CMAKE to complie when I have Visual Studio where<br>> I create my<br>> projects? If I can use vtk only with Cmake I know why I've never
<br>> heard before<br>> of it.<br>><br>><br>><br>> ----------------------------------------------------------------<br>> This message was sent using IMP, the Internet Messaging Program.
<br>><br>> _______________________________________________<br>> This is the private VTK discussion list.<br>> Please keep messages on-topic. Check the FAQ at:<br>> <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
http://www.vtk.org/Wiki/VTK_FAQ</a> <<a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">http://www.vtk.org/Wiki/VTK_FAQ</a>><br>> Follow this link to subscribe/unsubscribe:
<br>> <a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank" onclick="return top.js.OpenExtLink(window,event,this)">
http://www.vtk.org/mailman/listinfo/vtkusers</a><br>><br>><br>><br>> ------------------------------------------------------------------------<br>><br><br></blockquote></div><br>