Archived

This topic is now archived and is closed to further replies.

kirby92

Couple questions about Windows programming.

Recommended Posts

kirby92    122
First off, I''m new to c++ and so far I have only been programming in Dos, but i want to break into windows programming and some time in the distant future, game programming. My first question is What is the difference between MFC, and Win32? What are the purposes of each. Is one better than the other in different areas. Also, are there any links that you would recommend for Win32 programming or books. And finally, when people say "windows api, or windows programming" do they mean win32 or mfc or something else.

Share this post


Link to post
Share on other sites
Nytegard    839
MFC is just the Win32 API encapsulated. It makes the Win32 API more OO, which to some people (especially beginners), is really nice, as when learning the pure Win32 API is really difficult (very high learning curve).

Anything you can do in MFC you can do in the pure Win32 API, it just takes a lot more code. But, MFC has high overhead.

So if you just need to make a quick program with a windows feel to it, MFC is the way to go. If you need to worry about space and speed, use the Win32 API.


The WinProg homepage.
MSDN. Nuff said.

For MFC, there are tons of books. I can''t possibly give a recommendation, because I tend not to use it.

The general Win32 API book most people use is Programming Windows 5th Edition by Charles Petzold. It''s very general and beginner, but once you understand everything in it, the MSDN library is the best way to go.

Share this post


Link to post
Share on other sites
shaft    126
Windows 9X programming with MFC by Jeff Prosise - Best MFC book out there

Windows 9X programming by Charles Petzold - Best Win32 book out there.

Share this post


Link to post
Share on other sites
SkyRat    122
Well as a game programmer for Windows you tend to use the API. Because is it faster and you only need to do the basic Win stuff like open a window and such. Everything else is then done by the Graphic API like OpenGL or DirectX

Share this post


Link to post
Share on other sites
kirby92    122
I understand now, and thanks for the help, but do you know any links for win32 programming. I''ve seen some things on it, but it was way to confusing for me.

Share this post


Link to post
Share on other sites
LX Liquid    122
oooooooooooooooohhhhhhhhhhhhhhhh

I was wondering the same MFC Win 32 question asswell

I tried some tutorials on Win 32 and none seemed to work but I''m just going to s*d it and buy the Tricks of the Win Game Programming Gurus Book and learn Win 32 if I need to.

I just have a question too tho, The Book says it deals in C language mainly and I ahve learnt C++ does this matter?
And What if I wanted to program in C++ do I just put C++ code in or do I need to change anything?

Share this post


Link to post
Share on other sites
Drakonite    215
quote:
Original post by LX Liquid
I just have a question too tho, The Book says it deals in C language mainly and I ahve learnt C++ does this matter?
And What if I wanted to program in C++ do I just put C++ code in or do I need to change anything?


C++ is just C with some stuff added. As far as I can find, every statement, and command in C can be done in C++ (not vise versa though)

Most comilers nowadays are c/c++, so you can compile whatever, you want, such as MSVC++ (the most popular win32 compiler)

If you read a book on how to do something in c, it should work just the same in c++.



Drakonite

[Insert Witty Signature Here]

Share this post


Link to post
Share on other sites
LX Liquid    122
Great thats good news

I was also jus wondering if you know whether those tutorials are Bloodshed Software DEV C++ Compatible cuz mine never compiles them.... I might be doing somethign wrong

****EDIT****

Yes It was me doing things wrong because the source code compiles right... now to find the mistakes....

Edited by - LX Liquid on July 16, 2001 8:23:17 PM

Share this post


Link to post
Share on other sites