bugGNU Octave - Bugs: bug #41583, "view" gives incorrect...

 
 

bug #41583: "view" gives incorrect viewpoint in gnuplot after interacting with figure

Submitter:  Hartmut <hardy>
Submitted:  Thu 13 Feb 2014 07:35:13 PM UTC
   
 
Category:  Plotting with gnuplot Severity:  3 - Normal
Priority:  3 - Low Item Group:  Incorrect Result
Status:  Confirmed Assigned to:  None
Originator Name:  Open/Closed:  * Open
Release:  * dev Operating System:  * Any
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Jump to the original submission

Wed 04 Aug 2021 08:58:41 PM UTC, comment #13: 

as this seems to be a gnuplot issue that relates to there only being one way communication to gnuplot, and the following warning was added regarding gnuplot usage (https://hg.savannah.gnu.org/hgweb/octave/rev/a41c4b9ed64), recommend this bug be closed as 'won't fix'.


warning: using the gnuplot graphics toolkit is discouraged

The gnuplot graphics toolkit is not actively maintained and has a number of limitations that are ulikely to be fixed.  Communication with gnuplot uses a one-directional pipe and limited information is passed back to the Octave interpreter so most changes made interactively in the plot window will not be reflected in the graphics properties managed by Octave. For example, if the plot window is closed with a mouse click, Octave will not be notified and will not update it's internal list of open figure windows. We recommend using the qt toolkit instead.



Nicholas Jankowski <nrjank>
Group Member
Tue 18 Feb 2014 05:24:50 PM UTC, comment #12: 

This bug seems to have gotten severely off-topic. This is a reminder that this bug is about the view not being reported correctly when plotting with gnuplot and rotating the plot interactively. This has been marked as confirmed.

Can you please move any discussion about using FLTK, interaction with Windows, and video driver settings to the help mailing list for now? Or if you have determined that there are other bugs with FLTK and Windows, please report them separately.

Mike Miller <mtmiller>
Group Member
Tue 18 Feb 2014 01:35:23 PM UTC, comment #11: 

the root cause seems to be a buggy video driver:
<http://www.fltk.org/str.php?L2663>
fltk has implemented workarounds, which might not be available depending on the fltk version.
finally, the above url suggests some driver settings -- let us know if they help.

Felipe G. Nievinski <fgnievinski>
Tue 18 Feb 2014 01:09:54 PM UTC, comment #10: 

@ Felipe:
I've now updated my Octave installation to the version "octave-3.8.0-5-portable.zip" from the website you mentioned. (Before, I had the version "-4" from the very same website installed). And I have changed my Win7 settings to "Adjust for best appearance" like you described.

But the behavior in Win7 is still the same: As soon as the first fltk plot window opens, Windows disables Aero and falls back to some "basic window coloring scheme". And it only restarts Aero after the octave GUI process is finished.

Hartmut <hardy>
Sun 16 Feb 2014 10:25:55 PM UTC, comment #9: 

can someone pls rename this report to "FLTK causes Windows color scheme to change"
 
@Hardy: two suggestions:
1) try this build:
<http://mxeoctave.osuv.de/>
2) don't let Windows disable Aero automatically:
Go to Control Panel, then System, then Advanced System Settings. Select the "Advanced" tab then press the "Settings" button in the "Performance" section. Select the "Visual Effects" tab, then change this setting from "Let Windows Choose What's Best for my Computer" to "Adjust for best appearance".

Felipe G. Nievinski <fgnievinski>
Sun 16 Feb 2014 01:08:02 PM UTC, comment #8: 

@Rik:
I have attached an image that shows how your very simple plot example looks like in my octave-3.8.0 with fltk under Ubuntu linux. It still looks the same ("ugly").

@Felipe:
When I do this very simple plot in Win7, I do get the very same results as you do. So far so good.
I had nonetheless intuitivly judged the fltk plot to be "ugly". When I think about the reasons, it's because

  • The default font size in the fltk plot is too small. You said that's been taken care of in a different bug report.
  • Once the first figure window opens in my Win7 installation with fltk, the Windows color scheme falls back to some "basic" setup and makes ALL open windows (not only the octave ones) look different.
  • The fltk plot window has those four ugly gray buttons at the bottom that remind my of Unix stone age times...


@ Pantxo:
I don't feel comfortable to restart a 1.5 year old discussion on the developer's email list. I will instead open a new bug report with my funny (and now I know "unusual") behavior of fltk plots under linux.


Hartmut <hardy>
Sun 16 Feb 2014 11:08:06 AM UTC, comment #7: 

It's not related to this bug but anyway, here is the relevant discussion about linux video drivers and fltk:

http://octave.1599824.n4.nabble.com/fltk-rendering-problem-td4645232.html

Pantxo Diribarne <pantxo>
Group Member
Sun 16 Feb 2014 12:25:04 AM UTC, comment #6: 

I'm attaching the result of plot (1:10, "o-"); on Windows for each fltk and gnuplot; other than the fonts (which is addressed in bug #41308), could you tell me if it looks as good as in your install?


Felipe G. Nievinski <fgnievinski>
Sat 15 Feb 2014 10:34:26 PM UTC, comment #5: 

That's really strange.  I run Kubuntu 12.04 and the FLTK results are very good.  It has been so good that the default toolkit was switched in 3.8 over to FLTK from gnuplot.

I don't recall anyone having trouble with the FLTK toolkit on Linux so it may be something odd about your particular system.  Perhaps you don't have an OpenGL capable video card and are relying on a software implementation like Mesa instead.  I agree that the plot you made, fltk.png, is rather awful.  It appears that no OpenGL lines are being drawn.  This would account for why the axes are not shown and also why the sine plot shows each individual point rather than having smooth connecting lines between point.

You might try something simpler like


plot (1:10, "o-");


and see what it produces.

Rik <rik5>
Group administrator
Sat 15 Feb 2014 09:57:59 PM UTC, comment #4: 

No, I am running Octave 3.8.0 on Ubuntu Linux 12.04 as well as on Windows 7.

Is there an easy option that I can change so that fltk plots look reasonably nice on those platforms? (I have not found any hint anywhere else...)

Hartmut <hardy>
Sat 15 Feb 2014 08:49:43 PM UTC, comment #3: 

Are you running on Mac OS by any chance?  The FLTK backend has been much more reliable on Linux and Windows.  I happen to run Linux, but it's my perception that the Mac OS developers who contribute to Octave also frequently need to use gnuplot rather than FLTK.  I thought the situation had improved markedly for 3.8, but perhaps not.

Rik <rik5>
Group administrator
Sat 15 Feb 2014 07:35:03 PM UTC, comment #2: 

Thank you for the information.

I tend to stay with gnuplot normally, because I have not mananaged to get decent looking plots with fltk, yet. On neither Linux nor Windows. I'll attach two images with a very simple example. (Yes, they have nothing to do with this bug report.) Maybe I am just using fltk wrongly?






Hartmut <hardy>
Sat 15 Feb 2014 04:37:56 PM UTC, comment #1: 

The interface between Octave and gnuplot is mostly a one-way interface.  We send data and plotting commands down a pipe to the gnuplot program which then renders them.  It is very hard to get data back out.  For this reason all of the development has shifted internally to the OpenGL graphics toolkit.  I can confirm your bug report, but I doubt this will be fixed.  If you can, try using the fltk toolkit.

Rik <rik5>
Group administrator
Thu 13 Feb 2014 07:35:13 PM UTC, original submission:  

Here is a little m-script to demonstrate the behavior:


graphics_toolkit('gnuplot');
close all; clear all;
figure;
surf(sombrero);
input('Please rotate with mouse, done?');
[a,b]=view


You can rotate the resulting 3d plot with your mouse. But afterwards the view command will always return the values [-37.5,30], regardless of what viewpoint you rotated to.

With fltk as graphics_toolkit this behavior is absent. There you will get the the proper viewpoint results from the view command.

Hartmut <hardy>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #30571:  easyplot_ubuntu_fltk.png added by hardy (13KiB - image/png)
file #30566:  fltk-win.png added by fgnievinski (11KiB - image/png)
file #30567:  gnuplot-win.png added by fgnievinski (17KiB - image/png)
file #30559:  gnuplot.png added by hardy (20KiB - image/png)
file #30560:  fltk.png added by hardy (12KiB - image/png)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by nrjank (Posted a comment)
  • -email is unavailable- added by mtmiller (Posted a comment)
  • -email is unavailable- added by pantxo (Posted a comment)
  • -email is unavailable- added by fgnievinski (Updated the item)
  • -email is unavailable- added by hardy (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 10 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2018-04-27 mtmiller Priority5 - Normal 3 - Low
        Release3.8.0 dev
        Summary&quot;view&quot; gives incorrect viewpoint in gnuplot "view" gives incorrect viewpoint in gnuplot after interacting with figure
    2014-02-18 rik5 Carbon-CopyRemoved 72865 -
    2014-02-16 hardy Attached File- Added easyplot_ubuntu_fltk.png, #30571
    2014-02-16 fgnievinski Attached File- Added fltk-win.png, #30566
        Attached File- Added gnuplot-win.png, #30567
    2014-02-15 hardy Attached File- Added gnuplot.png, #30559
        Attached File- Added fltk.png, #30560
    2014-02-15 rik5 StatusNone Confirmed

    Back to the top

    Powered by Savane 3.13.
    Corresponding source code