getting from wxDevCpp to visual c++

If you are using wxDev-C++ for your wxWidgets design, please ask your questions here instead of in IDE Related.
Post Reply
aspa
Knows some wx things
Knows some wx things
Posts: 27
Joined: Mon Mar 17, 2008 5:00 pm

getting from wxDevCpp to visual c++

Post by aspa »

hi everybody

i have used wxDevCpp to write a program including GUI and multiple threads to control a helicopter model.

everything works fine as such, but now we have bought a new camera, to get some visual input from the helicopter.

together with the camera, we bought a framegrabber, to get the analog video signal digitalized so we can use and analyze it in the program.

unfortunately, the framegrabber come with an SDK and installer that only support visual c++ from microsoft. nobody could tell me how to get the framegrabber working with wxDevCpp.

so it seems that i need to convert my whole wxDevCpp project into a visual c++ project, so that i can then implement the framegrabber code to my program.

is this possible at all, or don't i stand a chance here?
unfortunately, i'm not very keen on all the library and build stuff...i know how to write c++ programs, but i do not know much about dev-cpp or visual c++.

if it is not possible to get my project to visual c++, maybe it would be possible to make the framegrabber work with wxDevCpp?

see the following link to a ZIP with all the files i got with the framegrabber. this stuff should make the framegrabber work with visual c++. could one use those files to make it work with wxDevCpp?

here: http://www.sensoray.com/downloads/2250-SDK-V116F.zip

i use win vista, and as i said before, i created my project with wxDevCpp.

as far as i know, wxWidgets as such can be used with visual c++, but what about the special stuff (*.wxform) etc that wxDevCpp created?

basically i do not need to be able to change anything in the GUI anymore. I only need to make some changes in one of the cpp files that runs one of the threads, then compile the whole thing and run my program. The GUI itself is finished.

i know this is probably a weird thing to ask, but i really need to get the framegrabber working with my current program.

thanks a lot in advance
Sof_T
Can't get richer than this
Can't get richer than this
Posts: 864
Joined: Thu Jul 28, 2005 9:48 pm
Location: New Forest, United Kingdom
Contact:

Post by Sof_T »

You can use Visual C++ compiler with wxDev-C++. That way you can use your existing project and add in your framegrabber SDK. Unfortunately the main wxDev-C++ site is down at present so I can't point you in the direction of a tutorial to show you how to add in the Microsoft compiler, maybe one of the other Devs can help.

Sof.T
The home of Sof.T http://www.sof-t.site88.net/
Author of Programming with wxDevC++
http://sourceforge.net/projects/wxdevcpp-book/
aspa
Knows some wx things
Knows some wx things
Posts: 27
Joined: Mon Mar 17, 2008 5:00 pm

Post by aspa »

i have seen such tutorials, but they are all for older versions of vc++. is it the same with vc 2008?

and if i then uuse the VC compiler, i will first have to install all the framegrabber SDK and the wxWidgets in VC right?
tbreina
Moderator
Moderator
Posts: 1289
Joined: Thu Nov 25, 2004 7:38 pm
Location: Coronado, CA

Post by tbreina »

aspa wrote:i have seen such tutorials, but they are all for older versions of vc++. is it the same with vc 2008?

and if i then uuse the VC compiler, i will first have to install all the framegrabber SDK and the wxWidgets in VC right?
We think so, but it hasn't been tested. The release candidate of wxDev-C++ 7.0 has a VC2008 template. If the SourceForge site ever gives me shell access again (they've been down for a few days), I'll upload the rc1 devpak and you can try it.

You'll need the VC2008 free compiler toolkit and you'll probably need to compile a version of wxWidgets with VC2008 (we have a VC2005 version; it might work too, I dunno).

I think this can be done much more easily than converting your project to a VC++ project.

-Tony
Everybody's got something to hide except for me and my monkey.
buildere
Super wx Problem Solver
Super wx Problem Solver
Posts: 358
Joined: Thu Oct 28, 2004 3:45 pm
Location: Costa Rica

Post by buildere »

Ok, you'll need to upgrade to the release candidate 1 for the next version, there are some steps, but is not that hard:

1- From this thread:
http://forums.wxwidgets.org/viewtopic.p ... ght=update

I have uploaded the file mirrors.cfg. Replace it on the Documents and Settings\username\App Data\Dev-Cpp folder (on XP, use AppData\Roaming if you're on Vista), as they say on that forum.

2- Run wx-devcpp. Select Tools->Check for Updates/Packages
and download and install the Release Candidate 1 for version 7 of wxdevcpp.

3- Close the IDE. You'll have to give up on all your current settings in order to upgrade; delete all the files on the same location as mentioned on step 1, or if you want, create a backup folder and place them there if you want to downgrade later.

4- I guess you have VS2008 C++ already installed. If not, install it (express version works).

5- Run the executable "wxdevcpp.exe" from the installation folder of wxdevcpp. This is the release candidate version. Again, go to Select Tools->Check for Updates/Packages and download wxWidgets 2.8.7 MS VC 2008.

6- Now, create a new wxWidgets project, selecting the VC++ 2008 profile. You could also change the profile on a current project, by going to Tools->Compiler Options->Compiler Set. However, remember that VS2008 support have had very little testing, so you are kind of helping us here...

7- I'm not sure if its an error from us, but the wxWidgets 2.8.7 MS VC 2008 package installs libraries into (C:\Program Files or equivalent)\Dev-Cpp\lib\vc2005, so you'll have to include this path in Tools->Compiler Options->Directories->Libraries:

(C:\Program Files or equivalent)\Dev-Cpp\Lib\VC2005

Also, include this one:

(C:\Program Files or equivalent)\Microsoft SDKs\Windows\v6.0A\Lib

Now, you're ready to try out if you can compile with VC++ 2008. Any feedback would be appreciated before we release the final 7.0 version. The next release candidate will probably include the tweaks mentioned here. Good luck.
Attachments
mirrors.zip
(288 Bytes) Downloaded 88 times
tbreina
Moderator
Moderator
Posts: 1289
Joined: Thu Nov 25, 2004 7:38 pm
Location: Coronado, CA

Post by tbreina »

Don't get the release candidate that is listed on the WebUpdate site! The wxdsgn.bpl is an older version that will screw up your project forms.

I've been trying for 2 days to get shell access to SF and update the package. Perhaps I'm doing something wrong in the login. I think SF is in the process of migrating their servers.

Hopefully, I'll have the corrected rc1 out in the next day or two.

-Tony
Everybody's got something to hide except for me and my monkey.
tbreina
Moderator
Moderator
Posts: 1289
Joined: Thu Nov 25, 2004 7:38 pm
Location: Coronado, CA

Post by tbreina »

Ok. I figured out the SF access problem. They changed the server name for shell access and the username.

Anyway, I uploaded the latest release candidate (7.0rc1_20080916). It should work for you. Just remember that the executable name will be wxdevcpp.exe (not devcpp.exe, which is the old executable). Also, you should probably backup your configuration files and your project files (just in case). Then, delete the old configuration files (search for devcpp.ini and delete the files in that directory).

-Tony
Everybody's got something to hide except for me and my monkey.
aspa
Knows some wx things
Knows some wx things
Posts: 27
Joined: Mon Mar 17, 2008 5:00 pm

Post by aspa »

thanks a lot guys, i'll try all of this tomorrow, when i've got a whole day to work on the project.

let's see if thats working :-)
aspa
Knows some wx things
Knows some wx things
Posts: 27
Joined: Mon Mar 17, 2008 5:00 pm

Post by aspa »

alright, i did what you said. following things happened:

first of all, i also use OpenCV image analysis. To make wxdev get all the includes, i had to add them not at the place you specified, but in project->project options->directories.

i also added to the two lib paths buildere told me there, and it worked.

also, to make the project use the vc2008 compiler, i had to change it there, not in tools->compiler options->compiler set. changing it there didn't help, it switched back immediately.

so i made all the changes in the compiler options and in the project options, which seems to have helped, since at the begining i got errors like "couldn't find cv.h: no such file or directory". now those errors do not occur anymore.

so, now i still get some errors...
every time I open the compiler options, or the project->project options, i get a warning popup telling me that some include directories don't exist. unfortunately, the warning does not show the full path of the wrong dir, but only:

c:\Program Files\Dev-C

and thats it. so i don't know what the problem is there...

and then again if i try to compile my project, i get the following errors that you can see in the image i attached to this posting. I don't have a clue what they mean unfortunately...
Attachments
the errors i get when trying to build and debug
the errors i get when trying to build and debug
buildere
Super wx Problem Solver
Super wx Problem Solver
Posts: 358
Joined: Thu Oct 28, 2004 3:45 pm
Location: Costa Rica

Post by buildere »

aspa, the next release candidate will hopefully fix these problems with VS 2008 profiles. Please, check it out next week (I think we'll have it out by tuesday). Just remember to cleanup your config files then.

Also, remember that Tony have updated the wxWidgets package for VS 2008 (step 5 above) and corrected the problem with the old one, so uninstall the old one, and download wxWidgets 2.8.8 MS VC 2008.
aspa
Knows some wx things
Knows some wx things
Posts: 27
Joined: Mon Mar 17, 2008 5:00 pm

Post by aspa »

thanks

by the way, i have manageed to get the stuff running in th real VS 2008.

i just installed wxwidgets and all the other library stuff etc in VS 2008, then opened a new project and added all the cpp and header files from my wxDev-Cpp project (without the .wxform ones).

after that i got some hundred errors due to slightly different declaration standards in VS and dev, but those could be changed very easily and wuite fast...so i can now compile my program in VS 2008, which for the moment solves my problem.

i willhave to see what happens if i need to add another buitton to my GUI, which i can only do in wxDev, but at the moent there is no need for that, so i can just work in VS 2008 for now .-)
Post Reply