Win32 console app

Hi,

I am trying to write a Win32 console app,
mixing SDL graphics and console functions.

let me explain…
I want my application to be able
to use scanf, getch… and other libc stuff,
and SDL to open a windows and output some graphics
some times…

as if I were in that old good dos, where
the user can input values, then the program
go in graphics mode and then go back the text mode.

I know I can write console apps, but when I link
with SDL, the libc library from microsoft won’t.
The only way I’ve found is to make a Win32 app,
but it is not really what I want since input
are asynchronous, get, scanf… are obsoleted…

I am looking for a way to write this console app
with visual studio 6… but perhaps it may better works
using mingw32 or cygwin ??

Thanks,–
damien.

Write it as a plain windows app, then use AllocConsole and related stuff.

You probably can tell it to direct stdin/stdout to that, but I don’t
recall the functions to do it offhand. MSDN is a win32 coder’s friend.
I’m not one, so you’ll have to look it up. =)

The allocated console is basically the same as a dos box, without the
ability to go fullscreen as far as I know/remember.On Sat, Jun 01, 2002 at 12:23:56PM +0200, Damien Mascr? wrote:

I am trying to write a Win32 console app,
mixing SDL graphics and console functions.


Joseph Carter Have chainsaw will travel

C’mon! political protest! sheesh. Where’s that anarchist spirit? :wink:
– Decklin Foster

-------------- next part --------------
A non-text attachment was scrubbed…
Name: not available
Type: application/pgp-signature
Size: 273 bytes
Desc: not available
URL: http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20020601/8f403d74/attachment.pgp

-----Message d’origine-----
Joseph Carter
Envoye : samedi 1 juin 2002 12:34

I am trying to write a Win32 console app,
mixing SDL graphics and console functions.

Write it as a plain windows app, then use AllocConsole and related stuff.

ok

You probably can tell it to direct stdin/stdout to that, but I don’t
recall the functions to do it offhand. MSDN is a win32 coder’s friend.
I’m not one, so you’ll have to look it up. =)

I am a friend (by obligation…) of MSDN… but not very experienced
with console stuff… I was not aware we are able to create our
own console inside a win32 app…

The allocated console is basically the same as a dos box, without the
ability to go fullscreen as far as I know/remember.

It is largely sufficient…

thank you much :)> De : sdl-admin at libsdl.org [mailto:sdl-admin at libsdl.org]De la part de

A : sdl at libsdl.org
Objet : Re: [SDL] win32 console app
On Sat, Jun 01, 2002 at 12:23:56PM +0200, Damien Mascr? wrote:


damien.

I am trying to write a Win32 console app,
mixing SDL graphics and console functions.

let me explain…
I want my application to be able
to use scanf, getch… and other libc stuff,
and SDL to open a windows and output some graphics
some times…

as if I were in that old good dos, where
the user can input values, then the program
go in graphics mode and then go back the text mode.

I know I can write console apps, but when I link
with SDL, the libc library from microsoft won’t.
The only way I’ve found is to make a Win32 app,
but it is not really what I want since input
are asynchronous, get, scanf… are obsoleted…

I am looking for a way to write this console app
with visual studio 6… but perhaps it may better works
using mingw32 or cygwin ??

mingw32 could be a great solution. The fact is, that when Micro$oft decides that something is obsolete, you
just can’t use it anymore. Linux, on the other hand, is completely the opposite (all distros install ed by
default,even if nobody is still using it any more). Sorry, this is off topic.

CRV?ADER/KY