Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
If we do not hit our goal we will be forced to close the site.

Current status: https://keepboardsalive.com/

Annual subs are best for most impact. If you are still undecided on going Ad Free - you can also donate using the Paypal Donate option. All contribution helps. Thank you.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.

Anyone used PHP-GTK

  • 16-05-2008 08:48PM
    #1
    Registered Users, Registered Users 2 Posts: 9,579 ✭✭✭


    Hi There,

    Has anyone used PHP-GTK. I just discovered this a few days ago when researching GUI stuff for a project.

    I am very interested in this. I must create a GUI application that will graph something from a process but the problem is the process is doing major cryptography so processor usage is at 100% constant. Just wondering the performance from PHP-GTK.

    I was going to do it in Java but I don't think this would be the best idea with performance in mind but maybe someone could disagree with me there.
    Bare in mind the app must run on Linux.

    Cheers.


Comments

  • Closed Accounts Posts: 1,444 ✭✭✭Cantab.


    Webmonkey wrote: »
    Hi There,

    Has anyone used PHP-GTK. I just discovered this a few days ago when researching GUI stuff for a project.

    I am very interested in this. I must create a GUI application that will graph something from a process but the problem is the process is doing major cryptography so processor usage is at 100% constant. Just wondering the performance from PHP-GTK.

    I was going to do it in Java but I don't think this would be the best idea with performance in mind but maybe someone could disagree with me there.
    Bare in mind the app must run on Linux.

    Cheers.

    I use gnuplot. Very satisfactory results. The graphs are top quality. I use image magic to convert the .eps to .png format.

    http://gnuplot.sourceforge.net/demo_4.3/


  • Registered Users, Registered Users 2 Posts: 9,579 ✭✭✭Webmonkey


    Yes gnuplot was what I was checking out before I hit GTK - problem is this gui application has to update the graph real time but only maybe every few seconds.

    I could of course use GNU Plot to keep generating the image in background and keep refreshing it in the GUI application.


  • Closed Accounts Posts: 1,444 ✭✭✭Cantab.


    Webmonkey wrote: »
    Yes gnuplot was what I was checking out before I hit GTK - problem is this gui application has to update the graph real time but only maybe every few seconds.

    I could of course use GNU Plot to keep generating the image in background and keep refreshing it in the GUI application.

    Is it a web GUI application?

    To avoid polling, why don't you do a server push to the application whenever the data on the server changes? You could then refresh the graph using XMLHttpRequest.


  • Registered Users, Registered Users 2 Posts: 9,579 ✭✭✭Webmonkey


    No this is not a web application, its going to be a Linux GUI application.

    I won't be polling Id say - more running the process from the GUI app, and waiting for a response from it which will update the graph.

    It needs to use as little resources as possible, might just use GTK in C, about as low level as I can go.


  • Closed Accounts Posts: 1,444 ✭✭✭Cantab.


    Webmonkey wrote: »
    No this is not a web application, its going to be a Linux GUI application.

    I won't be polling Id say - more running the process from the GUI app, and waiting for a response from it which will update the graph.

    It needs to use as little resources as possible, might just use GTK in C, about as low level as I can go.

    Hi Webmonkey,

    I think that might be a good solution if speed is of the essence.

    I wrote a Python GUI in wxWidgets and connected it to gnuplot. The graph creation time wasn't 100% satisfactory (I was plotting a medium amount of data arranged in cvs format). Also the .eps to .png time using imagemagic took up a couple of milliseconds. When a user pressed a button, the refresh time was a bit longer than I was expecting.

    gnuplot's great for scientific reports etc. and I actually prefer using it compared to what I used to use, MATLAB.


  • Advertisement
Advertisement