Advertisement

SDL and MFC under VS 2003

Started by September 28, 2004 03:19 PM
1 comment, last by Duke_Matheffy 20 years, 4 months ago
Hello. First of all, i read some threads about this topic, but if i'm repeating something, i'm sorry. How exactly do i manage to separate( if i need to) the windows event handling from the SDL one? First of all, if i try to create the main window, using : hWnd=CreateWindow (theApp.m_pszAppName, " Main window " ,WS_OVERLAPPEDWINDOW,CW_USEDEFAULT,CW_USEDEFAULT,CW_USEDEFAULT,CW_USEDEFAULT,NULL,NULL,theApp.m_hInstance,NULL); the hWnd will become 0. Beyond that it's futile to try to create a button for example, by: hButton = CreateWindow( " button " , " Yessss " , WS_CHILD|WS_VISIBLE|BS_PUSHBUTTON,20,10,100,30,(HWND)theApp.m_pMainWnd,0, theApp.m_hInstance,NULL); It's not working. I worked in SDL before, and in MFC too, but i'm new to VS.Net 2003 so i might be using some MFC stuff wrong. Thank you for your help. Mathe Jeno
you do not use MFC in combination with SDL.
That violates the whole operating system indepencence aspect.
HxRender | Cornerstone SDL TutorialsCurrently picking on: Hedos, Programmer One
Advertisement
Thank you. I know.
That's not the answer i was expecting for.
I need the combination of the two, for one project i'm working on.
I want to use SDL, for the simplicity of the SDL graphics and sound,etc. , but i need the standard windows controls.
I know somebody has done it, i'm waiting for their answer.

Mathe Jeno

This topic is closed to new replies.

Advertisement