author | francesco-ST <francesco.abbate@st.com> | 2010年07月26日 10:04:30 +0200 |
---|---|---|
committer | francesco-ST <francesco.abbate@st.com> | 2010年07月26日 10:04:30 +0200 |
commit | 4a55ed9a3a350d354eef6705408bd2ae3fec3b0b (patch) | |
tree | 5a3e07463cc9494435932b5c795b546621ba729f | |
parent | 45413a080db2d3d0dcc5af70833efad26db3c371 (diff) | |
download | gsl-shell-4a55ed9a3a350d354eef6705408bd2ae3fec3b0b.tar.gz |
-rw-r--r-- | contour.lua | 4 | ||||
-rw-r--r-- | hpcontour.lua | 12 |
diff --git a/contour.lua b/contour.lua index fc0e2b21..46a1279f 100644 --- a/contour.lua +++ b/contour.lua @@ -722,7 +722,7 @@ local function grid_create(f, left, right, nx, ny, nlevels_or_levels) for id = 1, #curves do curve_add_path(ln, id, 'cw') end - pl:addline(ln, col) + pl:add(ln, col, {{'stroke', width=1}}) end return { @@ -742,7 +742,7 @@ function contour(f, a, b, ngridx, ngridy, nlevels) local p = plot() g.draw_regions(p) - g.draw_lines(p, rgba(0,0,0,0.8)) + g.draw_lines(p, rgb(0.4, 0.4, 0.4, 0.8)) p:show() return p diff --git a/hpcontour.lua b/hpcontour.lua index 0c688195..9db97dcc 100644 --- a/hpcontour.lua +++ b/hpcontour.lua @@ -829,7 +829,7 @@ local function grid_create(f, left, right, nx, ny, nlevels_or_levels) for id = 1, #curves do curve_add_path(ln, id, 'cw') end - pl:addline(ln, col) + pl:add(ln, col, {{'stroke', width=1}}) end return { @@ -846,12 +846,12 @@ function hpcontour(f, a, b, ngridx, ngridy, nlevels) g.find_curves() - pl = plot() - g.draw_regions(pl) - g.draw_lines(pl, rgba(0,0,0,0.8)) - pl:show() + local p = plot() + g.draw_regions(p) + g.draw_lines(p, rgb(0.4, 0.4, 0.4, 0.8)) + p:show() - return pl + return p end return M |