why isnt java been used to write major game titles?

Discussion in 'Programming & Software Development' started by MadOnion87, Mar 30, 2006.

  1. Ze.

    Ze. Member

    Joined:
    Sep 13, 2003
    Messages:
    7,871
    Location:
    Newcastle, NSW
    Well thats not really programming is it :) The problem isn't with swing being slow but rather your code being crap.
    It's not hard to do, to write an interactive swing program you simply need to write multi-threaded code , with care to avoid doing too much non gui work in the swing thread. There is nothing special about it.
    Actually it was 6000 rows hence why i used thousands and i had a custom table cell renderer. The particular dataset i was using although the program could work with other datasets , was the NCI60 dataset for around 60 different cancers and around 6000 different genes.
    6000 features and 60 examples isn't a good idea , thats why feature set selection is important.
    However 6000 rows is tiny compared to some datasets.
     
  2. Ze.

    Ze. Member

    Joined:
    Sep 13, 2003
    Messages:
    7,871
    Location:
    Newcastle, NSW
    In my opinion you haven't been taught how to write good code. However i'm not surprised by that.
     
  3. hyperstyle

    hyperstyle Member

    Joined:
    May 24, 2003
    Messages:
    1,731
    Location:
    Brisbane
    That's an assumption. How would you know if i haven't been taught how to write good code? I progam for a living, obviously not in java. But you are right, i wasn't taught well even though i did get 6's and higher for java subjects i never really felt as though we learnt it properly. My statement still stands though, still think it runs like a turd.
     
    Last edited: May 22, 2006
  4. Ze.

    Ze. Member

    Joined:
    Sep 13, 2003
    Messages:
    7,871
    Location:
    Newcastle, NSW
    There are no secret tricks to writing decent code in java , so if you can't do it then i'm taking a wild stab and saying you can't code well. I also know how well university teaches students to code , in most cases its utterly crap with no finesse,efficency or elegance. I dunno about you but we weren't marked on the quality of our code since first year and only barely then , it was more about functionality and occasionally the markers would check error handling.

    It can be taught, its not a secret art based upon raw talent.

    Just because you code for living doesn't mean you can do it well. Surely you know that by now.
     
    Last edited: May 22, 2006
  5. hyperstyle

    hyperstyle Member

    Joined:
    May 24, 2003
    Messages:
    1,731
    Location:
    Brisbane
    Who said i can't write decent code in java? I merely said i dislike the language, not that i can't use it.
    Bit of an over statement, they do teach it but don't really enforce it in the marking.
    True
    Yet another assumption. I know very well that it's possible to program like shit for a living. I also know that when you're progamming all day everyday you relax the elegance factor in your code. For a number of reasons. When apps get quite large, tricky elegent programming in the details just isn't worth it (takes longer to program and is harder to understand). As long as the program structure is efficient and elegent the let the basics flow.
     
  6. Ze.

    Ze. Member

    Joined:
    Sep 13, 2003
    Messages:
    7,871
    Location:
    Newcastle, NSW
    You said it runs like a turd :) the results tell the story :)
    They taught the absolute basics on trivial code in first semester first year and that was it.

    I'm talking simple stuff like proper use of a constructor etc.
    I'm not talking about tricky coding that's a different ballgame.

    Your code doesn't have to be tricky to be elegant, nor just because your code is tricky does it mean its elegant.
     
  7. MetalSkin

    MetalSkin Member

    Joined:
    Sep 24, 2002
    Messages:
    856
    Location:
    Brisbane, Australia
    you said to quote:
    Obviously a very subjective statement only backed up by your experiance, which I suspect is extreamly limited.

    Anyone who is a decent developer knows that learning how to program in a language has a massive impact on the performance of said language. A classic example is 4GL's, if you dont use transaction scoping and indexing correctly then you can have a performance hog. Same issue applies with Cobol, C, C++, ASM, Java, Progress, etc. In fact I would have to say that every single language I have developed in over the last 16 years would have performance related issues that have a massive impact on the perception of said language if you didn't know what the f*ck you were doing.
    From a purely subjective point of view I would say that you fall into the last category.

    I'm not a 'beleiver' in any one language, although I have programmed extensivly in c, c++ and Java and in my opinion correctly written code in any of the above languages will result in software that will not run like a Turd.

    In my first job as a programmer my boss used to say that a bad programmer always blames their tools. Back then we used to use the Watcom compiler to get the best optimised C++ code. Ahh them were the days when you had to try and get an app to only use 510K of RAM.
     
  8. Luke212

    Luke212 Member

    Joined:
    Feb 26, 2003
    Messages:
    9,999
    Location:
    Sydney
    Are you talking about a display table having 6000 rows, or the data having 6000? If its the later then I concede. However, IMO any table that requires a scroll bar may be too big.

    To qualify that, ill add that I work with large datasets, but I never show all the data at once to the user. A key ingredient in good user interfaces is consumability and accessability. Instead of showing all the rows, use quick Sorting, SubTotalling and Filtering to eliminate unwanted data.

    So from Database to Query to User-Interface to the User you will show them what they need and no more.

    Romance your customers. Tell them what they want to hear. Show them what they want to see.
     
  9. Luke212

    Luke212 Member

    Joined:
    Feb 26, 2003
    Messages:
    9,999
    Location:
    Sydney
    I dont care. I dont want to be a programmer anyway. I want to make money programming, retire, and then travel the world adventuring.

    The less time I spend programming, and the more time I spend invoicing the quicker my dreams come true :)
     
    Last edited: May 22, 2006
  10. Ze.

    Ze. Member

    Joined:
    Sep 13, 2003
    Messages:
    7,871
    Location:
    Newcastle, NSW
    MetalSkin : I would have to say i agree with all your points in your last post.

    I displayed the data having 6000 rows :) However my point was too demonstrate that java isn't slow for GUI's. The main problem with people using writing SwingGUI's is doing non GUI stuff in the event handling thread for GUI's.
    You didn't know what the important rows were prior to running the feature set selection algorithm. That was the whole point of it :) It was a data mining problem not your typical business app. Mind you a GUI wasn't nesscary i just felt like displaying it so i could get a feel for the data.
    It's entirely dependent upon the application. Some you can do it , some you can't.
    In this case i was the customer :)
     
    Last edited: May 22, 2006
  11. Luke212

    Luke212 Member

    Joined:
    Feb 26, 2003
    Messages:
    9,999
    Location:
    Sydney
    well then would you like some romance?
     
  12. akashra

    akashra Member

    Joined:
    Apr 25, 2003
    Messages:
    3,883
    Location:
    Melbourne, AU
    6,000 rows is absolultely not a lot of data.

    I am yet to find a control thaht comes anywhere near the speed of the Delphi TVirtualTreeView control, which I've used for displaying millions of rows (~10m) without it hiccuping.
     
  13. Luke212

    Luke212 Member

    Joined:
    Feb 26, 2003
    Messages:
    9,999
    Location:
    Sydney
    maybe its caus you use a mac
     
  14. nav

    nav Member

    Joined:
    Aug 20, 2001
    Messages:
    4,215
    Location:
    melbourne
    Interesting thread guys.

    We did our major project in Java3D a few years back, advanced terrain visualisation of digital elevation models using Realtime Optimally-Adapting Meshes (roaming algorithm). This was a year long project, and when we began researching feasible graphics libraries, Java3D was quiet infantile and in it's beta stages. But anyway, to cut a long story short:- We bit the bullet used Java3D, and really struggled to with performance issues. We found Java's "sandbox" methodology and lack of garbage collection options to be very restrictive and cumbersome when trying to access hardware directly. I believe this is possibly the major reason why the developers avoid using Java.

    But, having said all that. My project partner said he recently recompiled our code (for a job interview, and he landed the job! hehe), against the latest sdk. And surprisingly, it all ran super smooth! On pretty much the exact same hardware we'd developed upon all those years ago. Anyway, I lost interest in the project a while ago, we were pretty dismayed at the time, having an application that ran like crap. But it's nice to finally know that our code and algorithms weren't to blame, we'd just chosen a library that wasn't up to the task.

    So, I don't really know where this really fits into this thread... just thought I'd share.
     
  15. MetalSkin

    MetalSkin Member

    Joined:
    Sep 24, 2002
    Messages:
    856
    Location:
    Brisbane, Australia
    Thanks for that nav, your experiance is actualy quite common and helps explain people's perception that Java is bad. 1.1 and 1.2 sucked majorly from a performance point of view (well actualy up till 1.5 if truth be known), from a gui point of view that is. 1.5 is quite good and I have written quite a lot of fat gui clients using 1.4/1.5 and never had major performance issues. This includes for both embedded use and normal pc use. The embedded use was running on an XScale 400, so we are not talking a lot of grunt (screen was 640x480, did a home automation control system and some production line interfaces).

    1.6 is shaping up to be very impressive and the openGL stuff that is available is very impressive if you want to go the 3D path. The link i did in the other thread is of a gui done in a mix of 2d and 3d (the 3d taking advantage of openGL optimisation) and is very impressive.
     
  16. Daemon

    Daemon Member

    Joined:
    Jun 27, 2001
    Messages:
    5,471
    Location:
    qld.au
    The latest 1.6 might make me interested in Java a little bit again, in the mean time I've turned to Python and C# for higher level programming.

    C# is excellent to work with considering I've come from a C++ / MFC background and the Mono project to run it on multiple platforms actually works well. The rate at which you can produce programs is great, especially since it's very easy to work with different data (XML, ODBC etc).

    Python is quite easy to read syntax wise and I've been using it for some web and console scripting for a few projects. Although Ruby on Rails is the flavour of the month for this, I found that Django was much better suited to how I like to work and gives me access to heaps of other Python code.

    My main gripes with Java were probably with the older SDK's, but I found it's performance (1.2 days) to be quite horrid and it was fiddly to have cross platform code always work. The problem is that I'm already using C# for my gui apps, so 1.6 would have to be pretty damn impressive to make me bother.
     
  17. MetalSkin

    MetalSkin Member

    Joined:
    Sep 24, 2002
    Messages:
    856
    Location:
    Brisbane, Australia
    In your shoes i would most prob stick to c#, specialy if your doing a lot of work on the windows platform and considering your background.

    I cannot comment on Mono, dont know what the performance is like or how it looks on Linux but I am curious as to what it's like in low resource environments.

    I've heard a lot about python but never had the reason to invest the time to learn it, so for now i spose i will stick to java. however i would like to get into c# at sometime if its good for cross windows/linux development.
     
  18. res

    res Member

    Joined:
    Feb 7, 2003
    Messages:
    839
    Location:
    California
    Just want to shed some light on the mobile games market and try to clear up some general misconceptions...

    Flash is non existent in the mobile games market, yes there are plans for it try and "take-over" in the future but i can't see that happening anytime soon.


    If only this was true, if you have ever tried to download a mobile game from a dodgey site you will realise most of the time it wont work correctly. There are so many inconsistencies within the market, basically anything you can think of will be different from one handset to another from screen sizes(often getHeight() reports the wrong value), key values to the way sound is handled and graphics are drawn. Yes most of these issues could be fixed if all the vendor's agreed on a standard but this wont happen.

    The larger company's have specialist teams devoted to "porting" a single game on to all the handsets.

    It's a harder market to get into than you may believe, I wouldn't want to try getting into it now thats for sure. Let's use EA as an example as one the largest games company on the planet?

    They recently ventured into the mobile market and thought they could tell people what to do because they are EA. On one particular instance they went to Vodaphone and told them to sell one of there popular franchises. Vodaphone turned round and basically told them to go away, you see in the mobile market the telco's rule the roost, what they say goes! They are far bigger company's than EA will ever be.
    So EA had to go and buy JAMDAT so they could understand how the market operates.

    Yes there are some indie developers doing quite well for themselves and the mobile market is still waiting for that 1 game that will make everyone situp and take notice. Currently the industry is worth over US$2billion(predictions of 7billion by 2010) anually with only about 10% of users downloading games, thats alot of growth potential.

    edit: the games are only written in Java because thats what is available to developers. If symbian was on nearly every phone like Java was then it would be a different story.
     
    Last edited: May 22, 2006

Share This Page

Advertisement: