Results 1 to 10 of 29

Thread: Abstracting Graphical APIs

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Quote Originally Posted by SilverWarior View Post
    I must agree with phibermon about the fact that FMX is not best example of abstracting Graphical API.
    The main reason for this is the fact that in FMX both graphical and logical part are tightly coupled together while most grahpical engines try to keep graphical and logical part uncoupled.
    Keeping logical and graphical parts uncoupled means that logical part won't be slowing down the graphical part or vice versa. Not to mention that it is much easier to implement multithreading support when you have graphical part decoupled from logical part.

    Do you want example to see how logical part can affect graphical part in FMX?
    Simply create a FMX form with let us say 200 panels positioned on it. Compile the project and then go and rapidly move the mouse over the form and you will see significant increase in CPU utilization. On my laptop this is enough to lower FPS below 15 and having 400 panels on the form I can easily lower the FPS to single digits. And don't think that my laptop is weak. It is still powerfull enough to run farCry3 with athleast 30 FPS on medium graphical settings provided that I disable the AntiAliasing and MultiSampling.


    Anywhay when I first tried FireMonkey I was verry exited but got quickly disapointed with its performance.
    And what disapointed me even more is that even with that fraction of FMX code that Embarcadero made avalable (mosty source code for certain components) you can't help yourself much if you decide to go and try creating some custom components.
    So in the end I ended up making my own UI library which is on hold for about a year now. I don't like talking about it to much becouse I feel ashamed that I still haven't gotten it to a usable state even thou I started working on it about two years ago if not even earlier.


    Hi SilverWarrior,

    Yes, I'm aware of quick performance deprecation you can have with this product : Even in 2D. There are no acceleration structure, so, FMX performance on "stress" is very bad.

    In fact, I spoke about low level part (FMX.Context and FMX.Context.[Platform]) but, even if we consider only this part of the product, certainly many issues could be pointed : More or less, the easyness of technology access seduce me.

    But as I said juste before, and As I recognized, talking about this subject here was a mistake.
    The subject could be closed.


    Scuse me cause I'm not understand : When you speak about your UI library, you build it upon which framework ? OpenGL ?

    Kind regards,

  2. #2
    Quote Originally Posted by Vinzvega View Post
    When you speak about your UI library, you build it upon which framework ? OpenGL ?
    The basc design of my UI library is not to directly interface with graphical API's but instead with already built graphical engines. This is done through special abstract layer which serves as interface between my UI library and the graphical engine being used. This would hopefully alo it to be used with most graphical engines out there wheter they are pascal based or not.
    So in a way it is more like an extension for existing graphical engines. The reason why I chose this approach is that at the time when I was starting to work on it there were several good pascal based graphical engines available like Asphyre Sphinx 3 or ZenGL.

    So basically I'm focusing on high level development. I will leave midle level development (special abstract layer) to the developers or users of specific graphical engines since they have best knowledge of them. It would probably be posible to even develop the middle layer so that it directly interfaces with graphical API's for certain things.

    Anywhay I'm afraid I'm still far from finishing it. It turned out to be much more difficult than I imagined, and my original design has already been replaced a few times

  3. #3
    PGD Staff / News Reporter phibermon's Avatar
    Join Date
    Sep 2009
    Location
    England
    Posts
    524
    I apologize if I caused offence and yes I was not very diplomatic much to my shame. I'm sorry.

    Embarcadero and FMX is very much a hot topic for me - Like many Pascal developers in England I was taught Object Pascal and Delphi at School, College and University - Borland were making a big push to get the language recognized throughout the industry and we were all assured through our national institutions backed by the commercial might of Borland that Object Pascal had a future and it *did*, we all dedicated ourselves and our initial careers to Delphi. And all looked good until Embarcadero took over. Their lack of vision and effort followed by a series of poor quality control decisions that has allowed things like FMX to persist despite *repeated* failures and widespread criticism, things like IOS + Android support delayed for many years and Linux support *totally ignored*? these things basically say to the tens of thousands of people across the world that were counting on Embarcadero : We don't care about your future.

    Delphi was the only thing keeping mine and many other peoples career prospects open. Just a few years ago Delphi jobs were abundant! and they still would be if Delphi had moved with the times.

    Instead of a mighty cross platform system that works on all major platforms with a first rate library to match that of any C++ suite? We get a product stuck on Windows with poor cross platform support that was years and years late (and still woefully incomplete) and FMX : far from being the future of Delphi represents all that is wrong with the decisions made over the past few years. It's slow, badly layed out when compared to the *standard* VCL and enforces a design that makes game development next to impossible on IOS and Android (in pipeline as well GPU resources locked) you know Embarcadero, games? the number one source of revenue on Android and IOS? Thanks for that, really helpful.

    So yeah, not a big fan of FMX on either technical or even general grounds. We should of had enterprise class database development on Linux, seamless RAD across all platforms, Android/IOS support *the moment* those systems came out. We should of had a professional, world class compiler and tool-chain. Instead we get animated buttons on IOS. Great. So for me the push for FMX is why Delphi is *no longer* the worlds greatest database client development tool and why mine and many thousands of people's careers have been ruined.

    I wouldn't mind having support for other platforms years too late, I wouldn't even mind the total lack of Linux support (you know Embarcadero? the world standard in database servers? Delphi was the world standard for database client development? are you literally not seeing this?) But for FMX to be so *badly* designed as to be unsuitable for exploiting the main revenue streams on the platforms it was designed for? it's nothing short of insulting given the dedication that I and many people have shown in the past.

    I hope FMX turns into some amazing fully capable system and we see support for spinning, hardware accelerated buttons on all major platforms and I wish all of its users happiness and joy.

    But I won't be recommending FMX for games development and indeed I wouldn't recommend any other proprietary tech that ships with Delphi. It's too much of a gamble on a company that doesn't care about your future. Use open-source / standard libraries and API's even with Delphi - that way your hard work and effort will survive any poor commercial decisions.

    I do want to see a brighter future for the language and for those looking to develop games in Pascal I do want to be able to recommend and advise what I objectively see as the best options.

    I apologize again for my tone, it is unjustified unless you actually have an affiliation with Embarcadero - I just don't want anybody else's careers ruined on the promises of a company that can't deliver and the thought of an Embarcadero employee pushing FMX as suitable for games development in light of this made me angry. In such a context it is nothing short of greedy lying at the cost of people's future. Given that I can't see how anybody but an Embarcadero employee would recommend FMX? I assumed you were.

    I'm sorry. I will now go and write a tetris clone with FMX as way of penance
    Last edited by phibermon; 02-02-2015 at 07:39 PM.
    When the moon hits your eye like a big pizza pie - that's an extinction level impact event.

  4. #4
    Hi Phibermon,

    Thank you for your gentle response. I understand much better your reaction now.

    Sorry on my side to not understand that more quickly.

    I understand now too at what level you suffer about all the 5 last years of delphi actuality. I lived that with more distance, because not directly stuck with this market : I confess that when EMB bought the FMX technology from a component supplier and out DXE2 with IOS support throught FPC I honestly believe that was a proof of opening, and was very excited about. I was wrong. Sincerly, I'm just a little more optimist (naive ?) than you

    You now, I grow up too with turbo pascal and Delhi1/2/3 and it was a fabulous period : I was angry when people compare it to VisualBasic, in this time already, Delphi began to be not well understood : Native compiler, advanced VCL : tremendous.

    Today, Delphi change (not the VCL, despite the fact it is alway supported, good point !) RTL change, low level change and this new GUI library. Then, come the first problem with compiler deprecation and FMX "yoyo" quality, and persistant bugs. I excused all of that for 2 reasons : FMX was young technology and EMB was (is) alone in the market to get a chance to put Pascal again in front scene. All the other compiler, despite their top technical quality, is far behind. It is sad, but it is.

    So, I shared near of all your technical analyze of EMB act about delphi : It is unfortunally true. But when you enumerate all the problem in one time, it is so hard to hear :/
    In fact, the fact that EMB target only money (It is a Fund, behind EMB, and this is terrible for a firm, nothing count unless money behind the corporate action holder decision) is a kind of justification of the sad way taken by delphi today.

    But I want to be more optimist : Perhaps, from those bad seeds, could grow again a beautifull and strong tree ? I hope. And for me, community is very important for that, but I see here and elsewhere (torry, Delphi.de) that community is less and less present. That is entirely the consequence of EMB act. You right again.
    The worst, is that after all this heavy delphi break, EMB try with a new brand (appmethod) to get new people : I think this a loss of energy : Hope it will have good consequence on Delphi EcoSystem, but I doubt.

    Hope, as you do, all will be better later. After the war, there are rebirth. Normally..

    If, as a redemption, you make a Tetris in FMX, I'll install FPC (command line) and start make OpenGL stuffs with it right this afternoon !
    (Ok, it is not really a punishment, but what to do else ?)

    By !

  5. #5
    PGD Staff / News Reporter phibermon's Avatar
    Join Date
    Sep 2009
    Location
    England
    Posts
    524
    Quote Originally Posted by Vinzvega View Post
    Hi Phibermon, Thank you for your gentle response. I understand much better your reaction now.!
    Thank you for being gracious and accepting my apology

    I would dearly love to see Delphi at the top of the tree again. A product that I can say to anybody "You want to make games? 3D applications? you want to get to market faster with a more stable code-base than your competitors? use Delphi". I do understand why EMB have made the push with FMX, I totally get it - I really do. I just think they're totally wrong in doing so. I'm sure that mobile platforms were at the top of the wish list for users - I'm also sure that what they wished for was comparable support to C++, access to the standard API's. EMB ticked the right box, they used the wrong pen.

    Delphi is great, it should be right up there on the front page of Slashdot, not laughed about in some random comments at the bottom of a post about alternative languages. At the very minimum, the commercial, expensive Delphi should be far better and more capable than a free alternative. They're getting paid to make it, it should be the best.

    Sadly that's not true, Freepascal (and in many IDE respects, Lazarus) supports far more platforms, has a more complete (and standard) API for all of the mobile platforms - it's just a better compiler.

    I'm happy that I've got a good cross platform Object Pascal compiler. I can do *everything* (sans target some specific propitiatory platforms like the Xbox) in Object Pascal that I can do with C++. There's nothing but my skill and time stopping me. But that's thanks to Freepascal. It *should* be thanks to Delphi.

    Delphi (XE7) at absolute minimum price of £1526 to target all supported platforms, I can only hope to match my C++ rivals on Windows. That's it. I sure as hell can't compete on IOS and Android without access to the standard API and FMX taking up resources I need and enforcing a design I can't work with.

    I think that's rather sad :\ I would love to see Delphi at the top of the tree, I've loved it, I've been dedicated to it. I was *proud* to be a Delphi developer.

    Delphi is arguably a better IDE than Lazarus and does have some fantastic RAD database components - but at the price of a small car to get the functionality everybody else gets as standard, it's not enough. Especially without Linux support (And I'll be kind and forget the rest)

    They should cater for us too, the lone games developers, the small teams. Games are the biggest source of revenue on mobile platforms, it's a fact. And I and everybody else here says Object Pascal is a fully capable language for game development, we know it is, we're doing it right now. In Freepascal - again, it should be Delphi. Would it really kill them to give us a cross platform Delphi at a decent price? dump all of the components! give us a cross platform compiler and the Delphi IDE, surely EMB can do that at a price we can afford? Their price list is proof that it's the components that make up a vast amount of the cost. Starter + Mobile pack would be £713! I'd *almost* stretch to that (with Linux support) just to be able to use the Delphi IDE. But I've got to pay £800 more for a bunch of components I don't want just to be able to target Android and IOS?

    --

    Off topic.

    I think we should all agree not to discuss religion, politics or EMB pricing
    Last edited by phibermon; 03-02-2015 at 04:35 PM.
    When the moon hits your eye like a big pizza pie - that's an extinction level impact event.

  6. #6
    Quote Originally Posted by SilverWarrior
    Anywhay we are getting a bit off topic here. I just hope that we haven't scared Anton with to much information here

    @Anton
    How ever you decide I'm sure you can count on the help from more knowlegable pepole here on PGD when you will need it.
    Unfortuantely I can't count myself into that group but if you will need any help in working with classes I belive I could be usefull as I belive I have pretty god knowlege about them. Not so much about interfaces but that is mostly becouse I myself don't see the need to use them. So far I have always managed to solve everything with classes alone.
    Oh, on the contrary, I find everything very interesting. I didn't post anything since I solved my problem by not making such a layer. Thanks for your help. I'm now writing a small library for rendering in D3D11. About interfaces, for the last year or two I began to love working with interfaces.

    As for FMX I can't really comment, since I have no experience with it. The only thing I know is from other people that it is heavy in terms of performance.

    Quote Originally Posted by phibermonn
    My passion is for my game engine I'll hopefully get some appreciation for my engine one day and I can live with downplaying my UI work so that you may get the maximum respect for something you're passionate about too
    This is very interesting. Can you tell more? What features do you plan/support in your engine /do you have a demo video?

    You now, I grow up too with turbo pascal and Delhi1/2/3 and it was a fabulous period : I was angry when people compare it to VisualBasic
    it should be right up there on the front page of Slashdot, not laughed about in some random comments at the bottom of a post about alternative languages.
    Yeah, this is sad. Very often I meet people with novice skills on programming (in lets say C/C++) to tell me that it Delphi/Pascal is not a serious language (more like something which someone invented because he had much free time) but maybe this is more a mainstream unconscious view, rather than objective. Most of the times when I mention "Delphi" often people ask me "Does anyone use this anymore?" BTW, I have seen forums with people fighting C against C++, so what's left for C++ against Delphi.

  7. #7
    Quote Originally Posted by Anton View Post
    Yeah, this is sad. Very often I meet people with novice skills on programming (in lets say C/C++) to tell me that it Delphi/Pascal is not a serious language (more like something which someone invented because he had much free time) but maybe this is more a mainstream unconscious view, rather than objective. Most of the times when I mention "Delphi" often people ask me "Does anyone use this anymore?" BTW, I have seen forums with people fighting C against C++, so what's left for C++ against Delphi.
    When I talk with other programmers about Delphi/Objet Pascal their response is usually something like this:
    1. Programmer that have never done any programming in Delphi/Object Pascal: "What Delphi? You can't do any serious application with it. You need much more than simply placing some components on the form."
    And the main reason for their response to be like this is that Emb arcadero always advertise how Delphi comes with bunch of usefull components, Live Bindings, etc but rarely advertize any language properies. Only recently you could see a few of new language features being advertized like Generics, Advanced Referencing, etc.
    2. Programmer that has athleast tried doing some programming in Delphi/Object Pascal: "That isn't a bad language but I don't think it is capable enough for some serious applications. There arent many usefull examples or libraries for it available."
    3. Programmers that have done quite some prgramming in Delphi/Object Pascal but have switched to other programming languages: "Pretty good language, lacking some of the newest features. Has rather poor and dwindling comunity and its development IDE is verry expensive. So it is better that you switch to some mainstream language soon if you want to be able to get any programing job in the future".
    What these guys fail to realize that they are the main reason why the comunity keeps getting smaller and smaller. But stayung wold mean that they wouldn't have acces to the newest windows features like those that come out in .NET programming language.

    So one day I have asked one of them who migrated from Delphi/Object Pascal to Visual Studio/.NET: "Why have you decided to migrate to .NET?"
    And his answer was: For the software I'm developing I requires access to NFC hardware."
    So my next question was: "Isn't there a library for Delphi available that would support this."
    He says: "No ther isnt."
    So I ask him: "Have you considered making such library yourself?"
    He looks at me and goes: "Are you crazy? Why should I spent several weaks or perhaps even a month designing and implementing such library if one already exists for .NET?"
    So my next question was: "Could you share how much time have you spent porting your application from Delphi to .NET?"
    His asnwer that he harldy said it was: "I have spent four months proting the code to .NET"
    And my response was: "So you spent four months porting your whole application to .NET instead of spending one month implementing the missing library. It haredly seems woth it"
    And then my final question was: "How many new bugs have crawled in during the porting of your program?"
    I have never got the answer to the last question. I hues that is becuse I hit the nerve of that programmer with it. He definitly knew that the choice of porting the whole application to .NET just becouse of one library was a poor one but he wasn't prepared to admit it.

    Anywhay when someone asks me as to which programming language they should use I usually say something like this:
    "Chose the one whose sintax structure suits you more. It is definitly better to program in programming language that feels natural to you and lack some features becouse in the end you can probably implement them yourself rather than programming in a programming language that offers you all of the features but you are having problems with its sytax structure becouse it doesen't seems logical to you.
    It is like talking in foregin language. You can easily learn meaing of certain words but if the languages syntax isn't logical to you you will have realy hard time creating a meaningfull sentace out of those words."

  8. #8
    We are getting far away from the topic by the way

    Yeah, I agree that everyone should use that language/tools which fits them better and makes them comfortable.
    I see a tendency, anyway, that people would reject to learning something which looks simple, but prefer complex-looking thing (with more symbols, slashes, all kinds of braces, etcetra) for the aim that they look smarter in world's eyes (which I doubt is a smart choice by itself).

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •