Java-Gaming.org    
Featured games (81)
games approved by the League of Dukes
Games in Showcase (492)
Games in Android Showcase (112)
games submitted by our members
Games in WIP (556)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1] 2
  ignore  |  Print  
  Has any of you thought about going back to C/C++?  (Read 7279 times)
0 Members and 1 Guest are viewing this topic.
Offline Captain-Goatse

Junior Member




I suck at teh 2D. XBOX IS BIG LOL!111


« Posted 2003-05-04 12:17:53 »

I'm seriously thinking about going back to C, after all I found out that it is so much easier to develop portable OpenGL programs with C without all the boundaries set up. This is not because some faggot at gamedev.net told me that java sux omg omg noob.

Java is great and all, and I'm never going to forget it. Perhaps I will still write tools with Java, but I think C is just the right tool for what I'm doing. It wasn't the speed issue nor the inefficiency of java. It was more the reason that Java doesn't have direct OpenGL support and access to the hardware, which is quite useful. And the fact that I'm huge fan of parsimony and accessing OpenGL through LWJGL was quite pointless.

C++ is just a huge mess, so I'll continue with good old C. As I write this I'm firing up Watcom C/C++ 11c. I will definately miss Java.

I won't be leave these boards, though. This is one of the best overall sources for hobbyist game development. I'll just stay as an observer.
Offline princec

JGO Kernel


Medals: 369
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #1 - Posted 2003-05-04 14:09:49 »

You'll probably change your mind if you actually try writing something large and complete, like a full game. Besides, what's wrong with LWJGL anyway?

Cas Smiley

Offline Captain-Goatse

Junior Member




I suck at teh 2D. XBOX IS BIG LOL!111


« Reply #2 - Posted 2003-05-04 15:06:45 »

I don't think I'll change my mind. Why would I? C? More work, yes. I just thought it is worth it. It doesn't stop me from using Java though.

My grief with everything in Java is Sun's attitude towards everything else. If Sun isn't going to change, they'll loose the battle. If they keep building incredible machines like Swing, they'll never get to the point where the "fast" languages are.

I think I can write C++ code as fast as Java code, so what is the point? It isn't even that hard to port C++ code, and I'm going to consider porting when I have actually something worth porting.
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline erikd

JGO Ninja


Medals: 16
Projects: 4
Exp: 14 years


Maximumisness


« Reply #3 - Posted 2003-05-04 15:12:36 »

Yes, I have thought of going back to C (or C++ since I got quite fond of OO) and I actually did at one point.
Indeed, C++ is an over-complicated mess but OTOH you don't have to use everything and you can write neat code in C++ too. I fiddled a bit with it but after messed having to mess with windows API, MFC (aargh), direct-X (aaaargh) and after I made my 1st 2 pointer arithmetic errors (and accompanying BSODs. Yes, my C is rusty ;-) , I decided not to bother and get back to comfy java in which everything seems so much more elegant and easy.
I have a life too, you know.

Anyway, good luck.

Offline Breakfast

Senior Member




for great justice!


« Reply #4 - Posted 2003-05-04 19:02:36 »

I never did more than the most basics of C   - at uni it was all pascal and delphi and since then I've used Java for most of the practical programming- so there is no back for me to go to. Currently I'm being trained in C# for work so maybe I'll end up moving over to that but ultimately I think the ideas matter more than the language and currently I can make the quickest translation in Java, so I'll certainly be staying here for the time.
Offline shareme

Junior Member




Java games rock!


« Reply #5 - Posted 2003-05-05 01:51:22 »

Quote
I never did more than the most basics of C   - at uni it was all pascal and delphi and since then I've used Java for most of the practical programming- so there is no back for me to go to. Currently I'm being trained in C# for work so maybe I'll end up moving over to that but ultimately I think the ideas matter more than the language and currently I can make the quickest translation in Java, so I'll certainly be staying here for the time.



You may notice somehting funny or ironic going on..

go to gamasutra.com click on features and start reading the howto game design articles..the ones with code in them..

Guess what programming language over 75% of the articles is using ..it snot C++ or C either..

actually rather than swing you should be using SWT instead..and the people at eclipse.org are nice and helpfull when you have questions..



Offline Matzon

JGO Knight


Medals: 19
Projects: 1


I'm gonna wring your pants!


« Reply #6 - Posted 2003-05-05 03:12:05 »

Quote
actually rather than swing you should be using SWT instead..and the people at eclipse.org are nice and helpfull when you have questions..

Well thats a statement  Roll Eyes

Use whichever api suits you best ...

Offline Captain-Goatse

Junior Member




I suck at teh 2D. XBOX IS BIG LOL!111


« Reply #7 - Posted 2003-05-05 04:39:21 »

Quote

Well thats a statement  Roll Eyes

Use whichever api suits you best ...




Not really, is it SUN making the swt? No, what are they doing? Wasting resources on swing.
Offline Matzon

JGO Knight


Medals: 19
Projects: 1


I'm gonna wring your pants!


« Reply #8 - Posted 2003-05-05 04:49:59 »

Quote
No, what are they doing? Wasting resources on swing.

First up, I couldn't care less about either api, since I use LWJGL  Grin
However that said, SWT isn't all that good:
- It has no where near the flexibility (regarding component customization) that swing has
- You need to manually manage resources claimed, since it isn't automaticall GC'ed
- Speed isn't all that great! - I swear on my p4 @2.7, Netbeans performs just as great (and has *way* more features than Eclipse) - granted most don't have 2.7 GHz - but I don't give a f uck - for ME swing's performance "issues" are not an issue.
Swing has its own problems, which I won't argue here - but needless to say, *any* developer needs to evaluate an api before using it - there is no clearcut answer on when to use Swing or SWT - or AWT or LWJGL for that matter...

If you think that SWT is the answer to all your problems, then more power to you - but the fact remains that SWT/AWT/Swing/LWJGL (<-- yes I do need to advertise Smiley) are api's that serve the same thing, but has been implemented with different features in mind.

Offline Herkules

Senior Member




Friendly fire isn't friendly!


« Reply #9 - Posted 2003-05-05 05:57:20 »

I never want to go back to a non-garbage-collected OO-language.

Yes, you can access OpenGL best from C. But that's it. Then you have to do everything yourself. Integrating high-level libs with C/C++ is just pain in the ass compared to Java.
Imagine you cannot use HashMaps any more. I cannot remember how programming was when there were no such things like HashMap. C++ doesn't offer hashed containers until now (at least AFAIK).
Imagine you have to write an eventing system without GCed objects! Reference counting? Beware!
Imagine you cannot code most of the time but play with a debugger 2/3 of your day. *vomit*

I feel very comfortable with Swing. Powerful, complete and easy to use. Did you ever use MFC?? Wake up!


HARDCODE    --     DRTS/FlyingGuns/JPilot/JXInput  --    skype me: joerg.plewe
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline William

Junior Member




No Exit


« Reply #10 - Posted 2003-05-05 15:58:03 »

I recently finished a project in Java/Java3D and the only solution I would have considered switching to would have been Director and its Shockwave3D.  The focus of the project was productivity and I would have had no chance to build it on time if I would have had to implement basic funtionality like model loaders and scenegraph structure with picking etc.

Java3D currently performs too badly and much of its functionality, like the available model loaders and its 3D-sound functionality, are too immature to be competitive. However, if it ever catches up with Shockwave3D on maturity/performance and integration with 3rd party tools like Maya and physics engines we will have a very powerful API to build real games with (if you are only interested in building small 3D-demos using OpenGL, then I guess C/C++ would be an alternative too).
Offline erikd

JGO Ninja


Medals: 16
Projects: 4
Exp: 14 years


Maximumisness


« Reply #11 - Posted 2003-05-05 17:17:01 »

Quote
Java3D currently performs too badly

I hear different views on that and I haven't done enough Java3D to really comment on that. But *if* this is true, does anyone know *why* Java3D performs badly? Is it because it's just badly written, because it's not written especially for games, because java is just too slow for this kinda thing, or what? I'm having a hard time with either of these arguments, but I'd love to see anyone to profile java3d in a typical 3d game and show where the bottlenecks are then and why it is slow.

Quote
accessing OpenGL through LWJGL was quite pointless

Why is that?


Offline princec

JGO Kernel


Medals: 369
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #12 - Posted 2003-05-05 17:25:00 »

Nah, it's mainly because it's a) really big footprint and b) because it's so difficult to understand most people use it wrongly and c) because it's still not perfect yet.

I'm sticking with me LWJGL and Java code, it's fast as feck and it's just so damned nice to be able to say new MessageBox()... and forget about what happens to it later...

... now give my my structs or I'll sulk.

Cas Smiley

Offline Herkules

Senior Member




Friendly fire isn't friendly!


« Reply #13 - Posted 2003-05-05 17:42:56 »

Quote

But *if* this is true, does anyone know *why* Java3D performs badly? Is it because it's just badly written, because it's not written especially for games, because java is just too slow for this kinda thing, or what?


I don't feel it's slow. But J3D is a big machine. Therefore it lacks the bare speed of OpenGL. And if you apply that big machine to a problem that can easily be solved with direct OpenGL, the performance appears to be poor. J3D is somewhat biased in that respect.
But if you leave the field of special-purpose rendering towards more general environments, where who-knows-what can appear for rendering any time, J3D catches up.

Sure, typically many games are of the first type. But some are of the latter. If you have one of these, J3D performs well.

J3D for sure was not made for games. It's for VR, CAD, scientific visualization.

Loaders indeed could be better and better be maintained and supported. But at least J3D offers an infrastructure that allows to *write* loaders independantly, just bc. it is a complete engine. So we can wait for the real one.

Check your needs!

HARDCODE    --     DRTS/FlyingGuns/JPilot/JXInput  --    skype me: joerg.plewe
Offline William

Junior Member




No Exit


« Reply #14 - Posted 2003-05-05 18:42:22 »

When I say that Java3D performs too badly, I really mean that it performs too badly "out of the box" for an unproven API that wants to compete in a performance-sensitive market with proven solutions like raw OpenGL or Shockwave3D.

I have used Java3D with great success in several academic projects where performance has not really been a priority and where I have been able to throw lots of hardware at the problem. However, I do not feel confident enough in that the API can be tuned to perform well enough for mainstream games to recommend it for use in a performance-sensitive commercial project. I am very interested in seeing what the Magicosm guys will be able to turn out.

The problem I am working on right now is how to get sound playback (and eventually video texture playback)  without stuttering using JMF while performing a basic flight simulation in an indoors environment with collision detection at 50 fps (or even 30 fps) on a 2Ghz PC and Geforce4 Ti4600 gfx card. It is quite funny since my artist friend who wrote his first piece of code in december has spent the last few weeks building a 3D-environment in Director where he is playing several 3D-sounds while doing physics simulations using collisions with Havoc on a 700 Mhz PC.

I am sure I will solve the problem eventually, but I am also surprised that I have to spend so much time on tuning considering the hardware difference.
Offline Herkules

Senior Member




Friendly fire isn't friendly!


« Reply #15 - Posted 2003-05-05 18:54:03 »

Quote

The problem I am working on right now is how to get sound playback (and eventually video texture playback)  without stuttering using JMF while performing a basic flight simulation in an indoors environment with collision detection at 50 fps (or even 30 fps) on a 2Ghz PC and Geforce4 Ti4600 gfx card. It is quite funny since my artist friend who wrote his first piece of code in december has spent the last few weeks building a 3D-environment in Director where he is playing several 3D-sounds while doing physics simulations using collisions with Havoc on a 700 Mhz PC.


Hm - I feel that sound is not really very good in Java3D. We play a couple of ambient sounds w/o problem, but our needs are not very sophisticated.
I would be suprised if video textures with JMF would be very fast indeed....
Despite that, a Java3D environment on THAT hardware can perform very well with >100FPS. Ok, whatever hardware you use, you will be able to kill it - but quite a lot of things can be displayed on such a beast at high framerates.

But if I had to guess - I'd consider the havoc stuff to be faster... that's true. BTW, the Quake engine is faster as well....


HARDCODE    --     DRTS/FlyingGuns/JPilot/JXInput  --    skype me: joerg.plewe
Offline Captain-Goatse

Junior Member




I suck at teh 2D. XBOX IS BIG LOL!111


« Reply #16 - Posted 2003-05-06 08:21:33 »

LWJGL through java? Mainly, because it feels unnatural and the fact that things can be done more easily in C/C++ resulting in better performance makes me feel sick.
Offline Herkules

Senior Member




Friendly fire isn't friendly!


« Reply #17 - Posted 2003-05-06 09:26:55 »

But if ONLY OpenGL access is better? For a game, that's kind of a minor detail!

It's the whole package that counts!

HARDCODE    --     DRTS/FlyingGuns/JPilot/JXInput  --    skype me: joerg.plewe
Offline princec

JGO Kernel


Medals: 369
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #18 - Posted 2003-05-06 11:34:18 »

I have to say that there's really hardly any OpenGL going on in A.F. For sure dealing with buffers is rather ugly but it's less than 1% of the code.

Cas Smiley

Offline Herkules

Senior Member




Friendly fire isn't friendly!


« Reply #19 - Posted 2003-05-06 11:55:25 »

Maybe something like structs could help??   Grin

HARDCODE    --     DRTS/FlyingGuns/JPilot/JXInput  --    skype me: joerg.plewe
Offline William

Junior Member




No Exit


« Reply #20 - Posted 2003-05-06 13:53:03 »

Quote
But if I had to guess - I'd consider the havoc stuff to be faster... that's true. BTW, the Quake engine is faster as well....

I'm not saying that Java3D has to be the fastest API around, just that it has to be fast enough. It is very possible that my particular issue may just be some small thread priority thing, but it could also be an indication of some more serious bug (like what happened in Jacob Marner's benchmark). Either way, it is a sign of immaturity that the API does not correctly perform basic game tasks without much tweaking (I have done some tweaking, like implementing Switch-culling, removing Link and SharedGroup nodes from the model graphs that are returned by the Xj3D loader and tweaking the world geometry to fit bounds-based collision culling).

Sure, raw OpenGL requires a lot more work to get things up and running, but at least John Carmack has been providing proof for the last few years that OpenGL can be used for top-performance game production. Would you dare go with Java3D in a real commercial game project that requires some amount of performance and that you are responsible for? Are you that confident in that the API can be tuned to perform well enough on the computers of average consumers? Personally I have built two slightly complex applications in Java3D and a number of small demos and sadly I would have to say no, at this time.

Java3D really needs projects that show that the APIs immaturities and initial bumps that most people seem to run into can be worked around and that they do not pose a risk to commercial use of the API. My project contains a lot of typical 3D-game functionality and I hope I can make it work well enough to act as a positive demo of Java3D's usability as a gaming API.
Offline Herkules

Senior Member




Friendly fire isn't friendly!


« Reply #21 - Posted 2003-05-06 14:07:43 »

Quote

Would you dare go with Java3D in a real commercial game project that requires some amount of performance and that you are responsible for? Are you that confident in that the API can be tuned to perform well enough on the computers of average consumers?


For a common, mainstream project? No. But I also wouldn't dare to start with OpenGL neither. I'd buy RenderWare as most companies do.


HARDCODE    --     DRTS/FlyingGuns/JPilot/JXInput  --    skype me: joerg.plewe
Offline William

Junior Member




No Exit


« Reply #22 - Posted 2003-05-06 15:39:57 »

Actually, I would guess that more companies use Director than Renderware for games. Sure, they're not making AAA-titles, but their games are still sensitive to performance issues since they have to run on typical office computers rather than on the monster machines of hardcore gamers.
Offline Breakfast

Senior Member




for great justice!


« Reply #23 - Posted 2003-05-06 18:42:24 »

Director? Ouch.
Offline Javaholic

Senior Newbie





« Reply #24 - Posted 2003-05-07 20:43:54 »

Unlike most, I started in Java, and I am now trying to learn C++.  I don't plan on leaving Java completely, but knowing both would be realy useful skill in the programming industry.
Offline mill

Junior Member




popcorn freak


« Reply #25 - Posted 2003-05-08 07:05:55 »

Quote
Has any of you thought about going back to C/C++?


i go back and forth. for instance, i have to write a heap manager in C and some other stuff in VB; it's up to the client.

Offline Backmask

Junior Member




586: The average IQ needed to understand a PC


« Reply #26 - Posted 2003-05-08 07:40:39 »

Quote

Has any of you thought about going back to C/C++?


I use the language that meet my projects requirements the best.  Mostly Java at home, but also C/C++ and VB and even some old nice pascal some time. At work it is most VB and Java.

My choice of Game programing language has changed alot during the years. As for now I use Java, and that is not thanks to the game friendly none existens game apis but mainly because I like the language and large part of the api:s. And with LWJGL you can build a high performence game in Java so I can't see in a near future that I will move from Java to another language.

Offline erikd

JGO Ninja


Medals: 16
Projects: 4
Exp: 14 years


Maximumisness


« Reply #27 - Posted 2003-05-09 05:26:09 »

Quote
and some other stuff in VB

Ouch.
Currently, at work I have to do a project in VB too. Man, VB is really a foul smelling garbage bin of rotten uglyness that you have to make look cute.

Oh right, we were talking about C  Grin
The best thing going for C/C++ for creating games is that there are tons of good game API's and game engines and such, but other than that I feel it's rather legacy, error prone and on the long run expensive because of that.
I also believe that the transition to Java would become easier if we would create native bindings to some of those libraries (JRenderWare anyone?  Wink)

Offline nickdotjava

Junior Member




I have fallen to the dark side. &nbsp;I'm using DX9


« Reply #28 - Posted 2003-05-23 20:33:23 »

I won't be going back to C/C++ for a while, particularly because the online C/C++ gaming community is no where near as friendly as the Java community.  They insult anyone who has a newbie question.  As a result, I gave up on writing games in C++ (after I finished Shmetris, a tetris clone) and moved to Java.  I have to say that everyone at java-gaming.org has been very helpful.  The community really helps.


-Nick

"Oh ya, that's trivial.  I should have it done in an hour."
Offline nickdotjava

Junior Member




I have fallen to the dark side. &nbsp;I'm using DX9


« Reply #29 - Posted 2003-05-25 03:57:10 »

I visited renderware.com and am unsure of what exactly it is.  Is it a completely new programming language?  Is it an IDE?  Or a project management software?

-Nick

"Oh ya, that's trivial.  I should have it done in an hour."
Pages: [1] 2
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

Nickropheliac (15 views)
2014-08-31 22:59:12

TehJavaDev (23 views)
2014-08-28 18:26:30

CopyableCougar4 (33 views)
2014-08-22 19:31:30

atombrot (41 views)
2014-08-19 09:29:53

Tekkerue (40 views)
2014-08-16 06:45:27

Tekkerue (35 views)
2014-08-16 06:22:17

Tekkerue (25 views)
2014-08-16 06:20:21

Tekkerue (37 views)
2014-08-16 06:12:11

Rayexar (72 views)
2014-08-11 02:49:23

BurntPizza (49 views)
2014-08-09 21:09:32
List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06

List of Learning Resources
by SilverTiger
2014-07-31 11:54:12

HotSpot Options
by dleskov
2014-07-08 01:59:08
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!