473,325 Members | 2,785 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,325 software developers and data experts.

Best custom output for c++? (want to make a videogame...)

101 100+
I'd like to create a game like a simple RPG. For this, I want something beyond just console output. I'd like to start working with something that's "industry standard", meaning that it is flexible, low level code, and can be used in many places.

I would also like to be able to compile it with g++, though I think that's a tall order. My ideal solution is to have a bunch of libraries that let me define a specific area to draw in and then let me make changes in that area. I also want it to be efficient and low level, not like the .NET objects.

Essentially, I want to be able to draw a pixelated screen in color and have sprites. The game would look like FF from the NES.

At this rate, should I even go that route, or should I focus on DirectX and OpenGL?
Jul 17 '07 #1
9 1697
zensunni
101 100+
I've been researching options and these are the options I've seen:

MFC
WTL
DirectX/OpenGL
Plain windows API

Just a couple of questions:
-Is WTL, in fact, Windows API?
-What does "Windows API" look like in c++ code, or how is it integrated.
-How does COM relate to all of this, or does it?
Jul 17 '07 #2
ilikepython
844 Expert 512MB
Also, SDL is a good choice, and you can combine it with OpenGL.
Jul 17 '07 #3
zensunni
101 100+
So, can I make GUI programs that uses windows OS features (like setting the desktop, or changing certain settings) without windows SDK? Or, are all these technologies tied into VC++ and/or will only compile using the SDK?
Jul 17 '07 #4
weaknessforcats
9,208 Expert Mod 8TB
Do not learn MFC. It was Microsoft's first crack at C++ design and it's terrible. The initial release 10 years ago was 1.0. It's still 1.0.

WTL is an extension of the Active Template LIbrary (ATL) to include graphic components for Windows programs. It is not Win32. Win32 is an interface to the Windows operating system and is very low level.

COM (Component Object Model) was an attempt at object programming in C. A way of making what today is called a mix-in class. This has been upgraded to C++. It uses a secondary interface language IDL which has its own compiler.

So, can I make GUI programs that uses windows OS features (like setting the desktop, or changing certain settings) without windows SDK? Or, are all these technologies tied into VC++ and/or will only compile using the SDK?
At some point you need the Platform SDK.

Read: Programming Windows by Charles Petzold.
Jul 17 '07 #5
qhimq
48
mingw g++ has the windows SDK built for it and is already included in the install. As well as openGL.

-What does "Windows API" look like in c++ code, or how is it integrated.
-How does COM relate to all of this, or does it?
OpenGL source code for a pacman like game, with extra opengl headers, and libraries to compile with g++. This is built on older opengl so thats why those headers need to be added. You need to replace libglaux.a since the one I have on the website is a library that takes out the requirement of a .dll file with the made executable.

https://netfiles.uiuc.edu/qmitche2/www/openGL

COM is a way of taking control of other programs. It is operated with the use of the windows API. Windows API can be operated with many languages. (A least thats what I thought maybe thats COM++)

To figure out windows api in c++ just google "win32 api tutorial".

But to show you an example specifically for g++. <<<<<
http://www.winprog.org/tutorial/app_one.html
to make it work for g++ I just added (HFONT) on line 23. It would have been made without any errors if you used gcc.
https://netfiles.uiuc.edu/qmitche2/www/app_one.cpp



Use some common sense and I think you'll be able to figure it out from that. I'll elaborate more if you can't figure out how to build those two.
Jul 17 '07 #6
tnga
27
I suggest SDL with OpenGL.
You can make a really nice 2D RPG using it and won't have too much trouble...
Trust me.

It is nice for you to learn DirectX if you really want to go into games programming...
But i suggest starting with SDL or even Allegro and then go to DirectX or OpenGL.

Best regards,

TNGA
Jul 17 '07 #7
zensunni
101 100+
SDL seems to be the way to go, and it's a good way into opengl.

But on the flipside, I would also like to know how to make windowed programs like winamp and steam. I think after pulling my hair out enough with windowed programming, I'll come back to my senses and start learning SDL.

Thanks guys for all thoughts and comments!
Oct 3 '07 #8
SDL seems to be the way to go, and it's a good way into opengl.

But on the flipside, I would also like to know how to make windowed programs like winamp and steam. I think after pulling my hair out enough with windowed programming, I'll come back to my senses and start learning SDL.

Thanks guys for all thoughts and comments!

Hey I found a good game tutorial for SDL

Check it out
Oct 7 '07 #9
Firecore
114 100+
Hey I found a good game tutorial for SDL

Check it out
Allegro is also very good. And its not just for beginners
Oct 7 '07 #10

Sign in to post your reply or Sign up for a free account.

Similar topics

16
by: D Witherspoon | last post by:
I am developing a Windows Forms application in VB.NET that will use .NET remoting to access the data tier classes. A very simple way I have come up with is by creating typed (.xsd) datasets. For...
12
by: Matt Garman | last post by:
I'd like to create a "custom output facility". In other words, I want an object whose use is similar to std::cout/std::cerr, but offers more flexibility. Instead of simply writing the parameter...
3
by: Joe Bloggs | last post by:
Does anyone know if its possible to pass parameters or the values of Request.QueryString from a web page to a custom control class? I'm using a C# Web Application. For Example I have Web Page1...
19
by: Dales | last post by:
I have a custom control that builds what we refer to as "Formlets" around some content in a page. These are basically content "wrapper" sections that are tables that have a colored header and...
5
by: Graham | last post by:
I have created a custom MembershipProvider called "LassieMembershipProvider" that derives from "MembershipProvider". This providor is located in a Businesslogic layer dll called...
1
by: rn5a | last post by:
I want to create a custom control that encapsulates a Button & a TextBox. When the Button is clicked, the user is asked a question using JavaScript confirm (which shows 2 buttons - 'OK' &...
0
by: rn5a | last post by:
A custom control is derived from the WebControl class & encapsulates a TextBox & a Button. When the Button is clicked, the user is shown the JavaScript confirm dialog with the 'OK' & 'Cancel'...
5
by: John Kotuby | last post by:
Hi all, This is my first time trying to creaet and use a custome Web Control in a Web Site project in ASP.NET 2.0 with VS 2005 and VB. I created the control in a separate Web Control Library...
11
by: =?Utf-8?B?bWljaGFlbCBzb3JlbnM=?= | last post by:
I have worked with application settings in VS2005 and C# for awhile, but usually with standard types. I have been trying to store a custom container/class/type in an application setting and I have...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.