bugGNU Octave - Bugs: bug #41294, FLTK does not draw linewidths...

 
 

bug #41294: FLTK does not draw linewidths >= 6 correctly

Submitted by:  Rik <rik5>
Submitted on:  Tue 21 Jan 2014 10:56:25 PM UTC  
 
Category: Plotting with OpenGLSeverity: 3 - Normal
Priority: 5 - NormalItem Group: Incorrect Result
Status: InvalidAssigned to: None
Originator Name: Open/Closed: Closed
Release: devOperating System: GNU/Linux

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Sun 20 Apr 2014 12:48:11 PM UTC, comment #4:

One possible solution would be to render lines as quad when the linewidth is above a given value.

Michael Goffioul <goffioul>
Project Member
Sun 20 Apr 2014 02:23:30 AM UTC, comment #3:

I found the problem. The issue is that OpenGL itself only supports a limited range of line widths. It has a range both for aliased (jagged) and anti-aliased (smooth) lines.

I've attached code which will print out these ranges. Unfortunately it's in C so you need to have the development packages for GL, GLU, and GLUT installed. On Linux it compiles with

In my case, the range of smooth lines is 1.0-5.0 and the granularity is 0.5 so I can really have lines from 0.5-5.5 which explains the issue.

I don't think there's much to be done about this so I'm closing the report.

(file #31215)

Rik <rik5>
Project Administrator
Tue 18 Feb 2014 04:16:49 PM UTC, comment #2:

Anti-aliasing neither helps nor hurts, but the lines are still not drawn correctly above 5.

Rik <rik5>
Project Administrator
Sun 16 Feb 2014 09:30:57 PM UTC, comment #1:

does this help:

http://hg.savannah.gnu.org/hgweb/octave/rev/c6e5466d74fe

Felipe G. Nievinski <fgnievinski>
Tue 21 Jan 2014 10:56:25 PM UTC, original submission:

Run the attached script mk_linewidths to generate a table of lines where the linewidth is equal to the y-value. For linewidths greater than 5, Octave just draws a width=5 line. See the attached pictures made with the FLTK and gnuplot toolkit. gnuplot correctly keeps growing the line as the linewidth is increased. Also, note that this is only an on-screen drawing issue. Printing the plot to a file, which uses gl2ps, correctly scales the line.

Rik <rik5>
Project Administrator

 

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

Attach File(s):
   
   
Comment:
   

Attached Files
file #31215:  rpt_lwidth.c added by rik5 (907B - text/x-c)
file #30330:  mk_linewidths.m added by rik5 (169B - d2l/unknowntype)
file #30331:  gnuplot_linewidths.png added by rik5 (8KiB - image/png)
file #30332:  fltk_linewidths.png added by rik5 (12KiB - image/png)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by goffioul (Posted a comment)
  • -unavailable- added by fgnievinski (Posted a comment)
  • -unavailable- added by rik5 (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 6 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Sun 20 Apr 2014 02:23:30 AM UTCrik5Attached File-=>Added rpt_lwidth.c, #31215
      StatusConfirmed=>Invalid
      Open/ClosedOpen=>Closed
    Tue 21 Jan 2014 10:56:25 PM UTCrik5Attached File-=>Added mk_linewidths.m, #30330
      Attached File-=>Added gnuplot_linewidths.png, #30331
      Attached File-=>Added fltk_linewidths.png, #30332

    Back to the top


    Powered by Savane 3.1-cleanup1