Shadow mapping in MFC...

Started by
12 comments, last by PfhorSlayer 16 years, 10 months ago
Hai... I'm a beginner... Now I was try to make a shadow with shadow mapping algorithm in MFC C++. I confuse.. Is MFC C++ can support shadow mapping??? Because in many project that I see.. I never saw shadow mapping program with MFC C++. Maybe you can help me to create this project...
Advertisement
I'm sorry to inform you that MFC has nothing to do with Shadow Mapping. MFC is an API for creating windows and GUI's. You'll need to choose a graphics API (opengl or directx for instance) and implement shadow mapping with one of these.

http://www.codesampler.com
http://nehe.gamedev.net

MFC specific:
http://www.codeproject.com/useritems/mfcd3d.asp
http://www.codeproject.com/opengl/wrl_viewer.asp


Good Luck.
OK... I mean is MFC + OpenGL can create a shadow mapping????

Because I was try to created shadow mapping application with MFC+OpenGL+GLee..
But I was failed. I look on www.paulproject.com and i implement it in MFC+OpenGL..

Is somebody can give me some advise... how the best way to make shadow map in MFC+OpenGL??

Thanx...
Quote:Original post by coba2
OK... I mean is MFC + OpenGL can create a shadow mapping????

Yes. It can do everything else OpenGL can do, because MFC and OpenGL are essentially independent (except for the windowing part).

Quote:
Is somebody can give me some advise... how the best way to make shadow map in MFC+OpenGL??

The same way you do it without MFC.
OK... so I can using OpenGL+MFC to create a shadow map program...

if I create a shadow map application... Am I need a OpenGL extension??? If yes what is your advice.. I read many option like GLee.. GLSL... or GLext.. I'm confuse to decide it. Thnx for your help...
Yes, if you opted to use OpenGL you'll need to initialize at least some OpenGL extensions. The type of extensions you need depend on the type of shadows you want to do (projective shadows, volume shadows, shadow maps...).
OK2... If i want to try shadow map.. what the OpenGL extensions you recomended for me... And I hope you give the website or document or explanation about it...

Thanks,
First of all, there is no such extension that will give you automatic shadow maps via simple enable/disable switch. You'll need access to some OpenGL extension because the unextended OpenGL on pre-Vista OS is good enough only for rotating triangles (understatement but not far from truth). Just use one the free extension loaders (GLee, GLEW, whatever) and pray to the gnomish dark gods that your video card supports what you need.

Secondly, your Google-Fu is weak. The most detailed explanations are given in the books (Cg Tutoral, GPU Gems, Shader X series...) but if you cannot afford them, simple google search will yield enough information that you can spend months reading through it. People already gave you useful links (see honayboyz post above). It doesn't get any easier than that.
OK thanx about the advice..

Now after I read some article.. I want to try GLee.. And I create the application using VC++ 8.

Is GLee can be operated in VC++ 8????
GLee is just a single header and source code file. The provided lib is compiled on VC7 so you probably shouldn't use it in VC8 projects, but considering its source code is written in cross platform way and MS has one of the most standard compliant C++ compilers out there, you really shouldn't have any problems creating your own static lib.

Plus, you don't have to use static lib at all. Instead of linking with lib file, just include the source code file into your OpenGL project and everything should work out automagically.

http://www.opengl.org/sdk/libs/GLee/

This topic is closed to new replies.

Advertisement