Java-Gaming.org Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (513)
Games in Android Showcase (120)
games submitted by our members
Games in WIP (577)
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  
  Why C# teams try to port C++ engines to pure C# quite often(?), but Java dont?  (Read 8456 times)
0 Members and 1 Guest are viewing this topic.
Offline whome

Junior Duke




Carte Noir Java


« Posted 2006-03-13 18:17:25 »

Irrlicth 3D engine
http://irrlicht.sourceforge.net/links.html
http://irrlicht.sourceforge.net/phpBB2/viewtopic.php?t=8865&postdays=0&postorder=asc&start=90

Ogre 3D engine
http://www.ogre3d.org/
http://www.ogre4j.org/drupal/
http://axiomengine.sourceforge.net/wiki/index.php/Main_Page

Irrlictht and Ogre are very capable and feature rich cross-platform engines implemented in C++ language. Both have many physics plugins and so on...

Both have more or less successfull Java binding subprojects. Both have full-port-to-dotNet-c# spinoff projects underway. I was wondering why most such source ports from a native engines go to dotNet environment, but I have seen none trying same to do pure Java port.

Is it that copying implementation from C++ files is more natural, easier to create in c# language?

I know C# language has structs, a way to use pointers if one is absolutely required (using unmanaged flags), inout ref variables  function params (allows swap(int, int) for example), etc...

It is not DirectX interface problem, because most engines support OpenGL rendering as well, those engines run in MacOSX and Linux. Meaning, no engines use directxAPI only helper methods and classes to minimize some of the engine work.

Is it just that trying to port such a gigantic c++ code like fullsized 3D engine is just too much to solve language problems?

I tend to believe it's too big language differences between C++ and Java. Java code should think so much doing things differently it created a great problem. Doing things so much differently will create maintenance hell when should follow C++ development speed and implement new things or port bug fixes.
Offline cborders

Junior Duke





« Reply #1 - Posted 2006-03-13 18:25:36 »

I tend to believe it's too big language differences between C++ and Java.
I don't think that's the case.  I mean there is the JOODE project that is porting ODE to Java, besides going from one language to another always has issues, regarless of which two they are.  There could never be a purely Java port of these engines because in order to talk to the hardware there needs to be at least a little native code.  So a wrapper is really the only solution.
Offline whome

Junior Duke




Carte Noir Java


« Reply #2 - Posted 2006-03-13 18:54:45 »

Well, I mean "pure java" engine where we _can_ use OpenGL renderer api (lwjgl, jogl). DirectX renderer API is valid as well if one existed similar to Jogl library. Without this rule we did not have any hardware accelerated apps in Java.

Wrapper is not the only solution as Axiom/IrrlicthC# projects have shown it.  I keep Java language wrapper just a B class citizen and always preffed a full port A class citizen. But such ports does not exist what I know of. Probably PHP/Ruby or similar must use binding wrappers, but Java is a full sized programming environment with all the gears.

Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Jeff

JGO Coder




Got any cats?


« Reply #3 - Posted 2006-03-13 23:38:19 »

Micrsoft is pushign the C developers hard to go to C#.  And they tell them its not muc hwork since "its just another kind of C".

The latter is true to some extent, C# certainly is closer to C++ then Java is.

Got a question about Java and game programming?  Just new to the Java Game Development Community?  Try my FAQ.  Its likely you'll learn something!

http://wiki.java.net/bin/view/Games/JeffFAQ
Offline Breakfast

Senior Duke




for great justice!


« Reply #4 - Posted 2006-03-14 00:05:15 »

I'd say C# may be in a C++ direction but it is a lot closer to Java when you're actually working with it.

Well, it is when I'm working with it anyways, and that's what counts.

Quote
I keep Java language wrapper just a B class citizen and always preffed a full port A class citizen. But such ports does not exist what I know of.
Why would there be any point in porting an existing C++ engine to Java? They are already written in C++. There are 3D engines (very full featured ones) written in Java. I'm not certain but I don't believe that is true of C# - I haven't really looked into writing games on .net because there doesn't seem to be the degree of helpful and  enthusiastic community support that I find here, although I narrowly prefer C# to Java as a language.

I can't imagine someone using the C++ version of the engine saying "ooh, there is a java version, I guess I'll use that instead" so I don't see any real benefit apart perhaps from brand recognition and before either Ihrlicht or Ogre really has that they will need to have some good games created with them, which is another matter entirely. At the end of the day the engine is about 10% of the game, at most.

Quote
Probably PHP/Ruby or similar must use binding wrappers
Surely you mean Python, not PHP? PHP is convenient for hacking together web pages but it is not an application programming language (nor has it really pretended to be) and you would actually be insane to try and write a game with it. I believe Ruby has some openGL wrappers, but I can't imagine using it for 3D programming for a while yet, brilliant as it is as a programming language in other respects. I can certainly imagine using it as a scripting language on top of a game engine, though.
Offline zero

Junior Duke





« Reply #5 - Posted 2006-03-14 07:10:02 »

.., although I narrowly prefer C# to Java as a language.

Really? One of the main reason developing in java again, after a 2 year excurse on C# was the language, not being platform independent or what ever..


Well, comments here seem to be right. C# is becoming very popular in gamedev. IMHO porting a C/C++ to both java or c# is nonsense, I still hope that Java is becoming popular for developing tools. Actually, that's the way Microsofts promotes C#. Another example is this book Game Engine Toolset Development.
Offline princec

JGO Kernel


Medals: 405
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #6 - Posted 2006-03-14 10:54:23 »

It's becoming popular in gamedev because surprise surprise it's soon going to be in a console and all over the new release of Windows and the IDE is a very familiar one to C++ hacks...

Cas Smiley

Offline whome

Junior Duke




Carte Noir Java


« Reply #7 - Posted 2006-03-14 16:12:16 »

Sad but true, Java may miss the gamedev wagon. Sure it has a strong position in mobile gaming, but "serious gamedevs" use another tools. It is quite easy to estimate we see sooner a fullsized blockbuster game developed in C# than similar happen in Java (you may disagree). And it gives more credits to C# if you think how young language it is compared to Java. We had our headstart but are soon second runners.

And porting well featured and layered opnesource C++ engine to opensource C# engine seems a good idea. Why invent all from scratch. Porting engine to C# is a lot easier than to Java.
Offline cylab

JGO Ninja


Medals: 52



« Reply #8 - Posted 2006-03-14 17:04:22 »

I am perfectly happy with doing my stuff in java and others probably, too. If there will be a blockbuster game in C# I don't think this will change. And since the gamers are unaware of the used programming-language, it will not have a big impact either. Seen from the game developer perspective it seems a good thing to be able to use a more robust language than C++ to use a game engine. It really doesn't matter if it is Java or C#, cosmetic and religous aspects aside ;-).

And to forestall a C++ vs. Java flamewar: Yes, C++ is sh**t (I know it, I've used it. There is rarely anything other to produce than segmentation fault)
* cylab runs for cover Tongue

Mathias - I Know What [you] Did Last Summer!
Offline Breakfast

Senior Duke




for great justice!


« Reply #9 - Posted 2006-03-14 17:11:19 »

Quote
And it gives more credits to C# if you think how young language it is compared to Java.
Certainly is, but developed by a lot of Java engineers who were very conscious of the problems they had run into first time round...
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline Amos Wenger

Senior Duke




Everything's possible, but not everything's fun...


« Reply #10 - Posted 2006-03-14 17:27:28 »

Sad but true, Java may miss the gamedev wagon. Sure it has a strong position in mobile gaming, but "serious gamedevs" use another tools. It is quite easy to estimate we see sooner a fullsized blockbuster game developed in C# than similar happen in Java (you may disagree). And it gives more credits to C# if you think how young language it is compared to Java. We had our headstart but are soon second runners.

And porting well featured and layered opnesource C++ engine to opensource C# engine seems a good idea. Why invent all from scratch. Porting engine to C# is a lot easier than to Java.

<ironical>Well, so I think we should all give up Java and go C#, close this forum and say shit to Sun</ironical>
Well we just begin having great libraries in Java and then people says "Oh C# seems more interesting".
Pah, grr.

"Once you start working on something, don't be afraid of failure and don't abandon it. People who work sincerely are the happiest"
Offline Breakfast

Senior Duke




for great justice!


« Reply #11 - Posted 2006-03-14 17:42:35 »

On the contrary, I'm sticking with Java. But I'm doing it for religious rather than practical reasons (and cos I like that the jvm is less likely to take windows with it when it dies) and because the community here is really good, which may sound like an odd reason to stick with a platform, but is certainly the case.

If I ever get any middleware written that is worth selling on you can bet the first thing I'll do is port it to C#. Very easy to do from Java and the hard reality of it is that if you want to make profit you need to be ready to go where the money is...
Offline Jeff

JGO Coder




Got any cats?


« Reply #12 - Posted 2006-03-14 17:57:21 »

Sad but true, Java may miss the gamedev wagon. Sure it has a strong position in mobile gaming, but "serious gamedevs" use another tools.

Say that to Oddlabs or Three Rings Cool


Got a question about Java and game programming?  Just new to the Java Game Development Community?  Try my FAQ.  Its likely you'll learn something!

http://wiki.java.net/bin/view/Games/JeffFAQ
Offline Jeff

JGO Coder




Got any cats?


« Reply #13 - Posted 2006-03-14 18:00:25 »

BTW I doubt e will see a blockbuster in C# for awhile because, from all I've seen, C# VM speed still sucks and the VM seems pretty unstable.

When C# is as fast as Java, maybe we'll see such a thing...

(Anyone else see the irony of that? Cool  )

Got a question about Java and game programming?  Just new to the Java Game Development Community?  Try my FAQ.  Its likely you'll learn something!

http://wiki.java.net/bin/view/Games/JeffFAQ
Offline thiagosc

Senior Newbie





« Reply #14 - Posted 2006-03-14 18:02:20 »

Quote
And porting well featured and layered opnesource C++ engine to opensource C# engine seems a good idea. Why invent all from scratch. Porting engine to C# is a lot easier than to Java.

Why porting instead of writing a decent one in Java taking advantage of the platform's features!?  I understand that the size of the problem (writing an engine from scratch) will be similar, so I can't  just believe why would anyone want to "port" something instead of writing a Java one.

Java has several advantages over statically compiled code that could be used in software like games. It's beyond comprehension why to throw it all away.
Offline Jeff

JGO Coder




Got any cats?


« Reply #15 - Posted 2006-03-14 18:02:52 »

Quote
And it gives more credits to C# if you think how young language it is compared to Java.
Certainly is, but developed by a lot of Java engineers who were very conscious of the problems they had run into first time round...

Um... no offense B but  I smell the smell of FUD here...

Can you actually name the "lot of Java engineers" who desigend on and/or worked on C#?

Got a question about Java and game programming?  Just new to the Java Game Development Community?  Try my FAQ.  Its likely you'll learn something!

http://wiki.java.net/bin/view/Games/JeffFAQ
Offline thiagosc

Senior Newbie





« Reply #16 - Posted 2006-03-14 18:04:51 »

And porting well featured and layered opnesource C++ engine to opensource C# engine seems a good idea. Why invent all from scratch. Porting engine to C# is a lot easier than to Java.

?? A good idea ??
Offline kevglass

JGO Kernel


Medals: 188
Projects: 24
Exp: 18 years


Coder, Trainee Pixel Artist, Game Reviewer


« Reply #17 - Posted 2006-03-14 18:13:02 »

Quote
Say that to Oddlabs or Three Rings

Not quite sure if two use cases (no matter how cool) is going to be enough to convince the game development masses. Though I don't see many C# use cases yet either.

Kev

Offline Orangy Tang

JGO Kernel


Medals: 56
Projects: 11


Monkey for a head


« Reply #18 - Posted 2006-03-14 18:18:09 »

BTW I doubt e will see a blockbuster in C# for awhile because, from all I've seen, C# VM speed still sucks and the VM seems pretty unstable.

When C# is as fast as Java, maybe we'll see such a thing...

(Anyone else see the irony of that? Cool  )
Except that public/developer opinion thinks that C# is nearly as fast as C++, and Java is miles behind (regardless of what the actual facts may or may not be).

Although it's not a good example, head over to gamedev.net and view some of the opinions towards C# - lots of people proclaiming that VMs are great, that GC isn't an issue, but only when it's C# they're talking about.

[ TriangularPixels.com - Play Growth Spurt, Rescue Squad and Snowman Village ] [ Rebirth - game resource library ]
Offline swpalmer

JGO Coder


Exp: 12 years


Where's the Kaboom?


« Reply #19 - Posted 2006-03-14 18:41:14 »

BTW I doubt e will see a blockbuster in C# for awhile because, from all I've seen, C# VM speed still sucks and the VM seems pretty unstable.

When C# is as fast as Java, maybe we'll see such a thing...

(Anyone else see the irony of that? Cool  )
Except that public/developer opinion thinks that C# is nearly as fast as C++, and Java is miles behind (regardless of what the actual facts may or may not be).

Any benchmarks that I have seen puts the C# VM at par with or better than Sun's client VM.   It's only the server VM that seems to have a clear advantage, and it isn't even installed with the standard JRE.

Offline Jeff

JGO Coder




Got any cats?


« Reply #20 - Posted 2006-03-14 19:17:44 »

BTW I doubt e will see a blockbuster in C# for awhile because, from all I've seen, C# VM speed still sucks and the VM seems pretty unstable.

When C# is as fast as Java, maybe we'll see such a thing...

(Anyone else see the irony of that? Cool  )
Except that public/developer opinion thinks that C# is nearly as fast as C++, and Java is miles behind (regardless of what the actual facts may or may not be).

Any benchmarks that I have seen puts the C# VM at par with or better than Sun's client VM.   It's only the server VM that seems to have a clear advantage, and it isn't even installed with the standard JRE.

Well the server/client VM distinction is slated to go away.

And, at risk of sounding like an ignorant Java basher, I have one C# app so far on my machine which is Sony's PSP media manager and I actually read a reviewer that said "... It's GUI makes Java look speedy... "

A speed daemon its not.  Now maybe its a crappy C# program.  Its only one data point but riught now its the only datapoint I have.

And we all knwo about lies, damn lies, and benchmarks, right?  What sort of independant benchamrks are there and what are their test cases?
AIUI C# always compiles completely before running, so ist going to get an unfair (and untrue) advantage on your typical C type microbenchmark.


Got a question about Java and game programming?  Just new to the Java Game Development Community?  Try my FAQ.  Its likely you'll learn something!

http://wiki.java.net/bin/view/Games/JeffFAQ
Offline Orangy Tang

JGO Kernel


Medals: 56
Projects: 11


Monkey for a head


« Reply #21 - Posted 2006-03-14 20:08:23 »

BTW I doubt e will see a blockbuster in C# for awhile because, from all I've seen, C# VM speed still sucks and the VM seems pretty unstable.

When C# is as fast as Java, maybe we'll see such a thing...

(Anyone else see the irony of that? Cool  )
Except that public/developer opinion thinks that C# is nearly as fast as C++, and Java is miles behind (regardless of what the actual facts may or may not be).

Any benchmarks that I have seen puts the C# VM at par with or better than Sun's client VM.   It's only the server VM that seems to have a clear advantage, and it isn't even installed with the standard JRE.
You're missing the point - benchmarks are irrelevant. Microsoft's marketing is managing to convince C++ users that C# is just as good if not better. If theres one thing that Java's history provides, its that programmers are just as suceptible to marketing and bias as everyone else.

[ TriangularPixels.com - Play Growth Spurt, Rescue Squad and Snowman Village ] [ Rebirth - game resource library ]
Offline whome

Junior Duke




Carte Noir Java


« Reply #22 - Posted 2006-03-14 20:27:41 »

Quote
>>>And it gives more credits to C# if you think  how young language it is compared to Java.
>>Certainly is, but developed by a lot of Java engineers who  were very conscious of the problems they had run into first time round...
>Can you actually name the "lot of Java engineers" who desigend on and/or worked on C#?
And, at risk of sounding like an ignorant Java basher, I have one C# app so  far on my machine which is Sony's PSP media manager and I actually read a  reviewer that said "... It's GUI makes Java look speedy... "
Creating a decent GUI app in Java or C# requires programmer to adapt a new way of doing it used to be. If they come from VB or Delphi IDEs things don't go similar, far from that.

I know one name who jumped from Java wagon to C# wagon. Anders "The Delphi Man" Helsberg from Borland, one of the core members creating C# language. I remember reading (maybe is an internet gossip), he tried everything to bring a true properties attribute to Java classes. And he wanted to implement delegate methods for listener patterns but both were rejected by Sun. Both which he did in Delphi previously.

Then Microsoft came along, bought him to create a new language. He saw his moment to recreate properties+delegate once again. He was first sent to Hawaii with his family for few months holiday before started working at Microsoft :-)

Java is great and I use Java daily basis. I want to use it for every aspect of programming. But boring business part and corporation projects force me to study C#/asp.net technology. I have managed to avoid any project assignents so far, but my luck is running low every week :-( :-(
Offline thiagosc

Senior Newbie





« Reply #23 - Posted 2006-03-14 21:13:00 »

Java is great and I use Java daily basis. I want to use it for every aspect of programming. But boring business part and corporation projects force me to study C#/asp.net technology. I have managed to avoid any project assignents so far, but my luck is running low every week :-( :-(

Is it my impression or there's a sense of inevitability in some posts lately? In an old job I also got forced to learn C#, the solution was: I got a better job in a better company to work with Java all day long (and Perl, nothing is perfect).
Offline princec

JGO Kernel


Medals: 405
Projects: 3
Exp: 16 years


Eh? Who? What? ... Me?


« Reply #24 - Posted 2006-03-14 22:46:02 »

There are so many Java jobs, there is no need to learn C# to get another job. Really.

Cas Smiley

Offline Mr_Light

Senior Duke


Medals: 1


shiny.


« Reply #25 - Posted 2006-03-14 23:29:26 »

many game gaints use or have used java in there games, server side perhaps but I'd doubt ppl or managers want next to java, another language like c# its redudant.

It's harder to read code than to write it. - it's even harder to write readable code.

The gospel of brother Riven: "The guarantee that all bugs are in *your* code is worth gold." Amen brother a-m-e-n.
Offline nonnus29

Senior Duke




Giving Java a second chance after ludumdare fiasco


« Reply #26 - Posted 2006-03-15 02:01:10 »

I started 'porting' irrlicht along time ago during a slow period at work.  I say 'porting' because I never intended to create a complete port; I was just bored.  I got part way through the math classes then work picked up again.

The thing that sucked about going from c++ to java was operator overloading.  Everyone wants to overload vector and matrix operations  Roll Eyes .  My personal preference is to not use operator overloading, even in c++, so it was even more of a pain.  Then those overloaded operators trickle down into the rest of the code and it becomes right squidgy.
Offline zero

Junior Duke





« Reply #27 - Posted 2006-03-15 02:33:47 »

Quote
Say that to Oddlabs or Three Rings

Not quite sure if two use cases (no matter how cool) is going to be enough to convince the game development masses. Though I don't see many C# use cases yet either.

Arena Wars, I read a article/interview in a german gamedev mag. Pretty much the same as the oddlab interviews, a bit longer and one has to exchange C# with Java. Wink


Any benchmarks that I have seen puts the C# VM at par with or better than Sun's client VM. It's only the server VM that seems to have a clear advantage, and it isn't even installed with the standard JRE.

That's a excactly my experience, SUN's client vm very similiar in speed. Maybe the Java 5 client is a bit slower, but version 6 is definitely faster! And yes, testing was done with a real app (a 3d virtual beergarden), which I've ported from c# to Java.
Of cource winforms are faster, but hey with swing you got a fully skinable, plattform idependent GUI, which is also really fast since Java 6  Smiley
(Offtopic: I read that there will be layout managers in .NET 3.0, hehe)


Btw. can anyone tell why peoble are so f5#king interested in delegates? I mean anomymous classes are a better coding style and and you are not limited to a single method. Or what about properties, if every class attribute would be a property I woud prefer that, but having both is no win. And last but not least my favorite thing about the java language is that it uses late-binding, it's really thumb to have to now wether a method will be possibly overriden..

(sorry for the last part, just my 2 cents  Lips Sealed)
Offline swpalmer

JGO Coder


Exp: 12 years


Where's the Kaboom?


« Reply #28 - Posted 2006-03-15 03:40:34 »

Any benchmarks that I have seen puts the C# VM at par with or better than Sun's client VM.   It's only the server VM that seems to have a clear advantage, and it isn't even installed with the standard JRE.
You're missing the point - benchmarks are irrelevant. Microsoft's marketing is managing to convince C++ users that C# is just as good if not better.

No, I got that point.  I was only commenting on Jeff's performance comment.. and I'm aware of how misleading benchmarks can be.

Quote
If theres one thing that Java's history provides, its that programmers are just as suceptible to marketing and bias as everyone else.

Replace "programmers" with "inexperienced and/or bad programmers" and I agree completely.   Most of the people that *really* know what they are talking about aren't so easily fooled.  In the last decade the market has been flooded with shitty programmers... I know, I've been going through resumes like crazy and the pickings are slim.   People entered the field because some guidance counsellor told them to, they have no natural abilty, no aptitude for it, and no passion.  Some of them have the interest but sadly not the learning ability to pull it off.

It is precisely because of this influx of code drones that "bad Java" gets written and those that should know better point at the bad code and say "see, Java is slow and ugly and I hate it"
It is precisely because of all of this hype and the generally poor skills of the programmers that Sun's marketing fails.. they can only generate real data and attack things logically... they can't create a "buzz" with double talk like MS. Smiley
(Ok, Sun does their share of marketing BS too.. but it was fun to vent.)

Offline Breakfast

Senior Duke




for great justice!


« Reply #29 - Posted 2006-03-15 10:56:50 »

Quote
Um... no offense B but  I smell the smell of FUD here...

Can you actually name the "lot of Java engineers" who desigend on and/or worked on C#?
Well, I was kind of assuming (and I think it's a pretty common assumption) that all of the MSVM folk who weren't allowed to "embrace and extend" java during the court case that lasted for most of the last five years must have been doing something, especially given the timing of the relase of the MSIL interpreter.

All the benchmark discussions are completely irrelevant anyways. To get anything meaningful you would need to benchmark a whole development process, start to finish, time spent writing code, time spent debugging, problems that come up after release, the whole thing. And once you're testing that the outcome is more that you're testing the skills of developers or development teams rather than the language unless you have many teams working independently on the same project at the same time and I can't honestly see anyone caring enough to do that...
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.

Longarmx (52 views)
2014-10-17 03:59:02

Norakomi (43 views)
2014-10-16 15:22:06

Norakomi (33 views)
2014-10-16 15:20:20

lcass (37 views)
2014-10-15 16:18:58

TehJavaDev (68 views)
2014-10-14 00:39:48

TehJavaDev (67 views)
2014-10-14 00:35:47

TehJavaDev (60 views)
2014-10-14 00:32:37

BurntPizza (73 views)
2014-10-11 23:24:42

BurntPizza (45 views)
2014-10-11 23:10:45

BurntPizza (86 views)
2014-10-11 22:30:10
Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02

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
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!