--- octave-nurbs-1.0.2.orig/debian/compat +++ octave-nurbs-1.0.2/debian/compat @@ -0,0 +1 @@ +7 --- octave-nurbs-1.0.2.orig/debian/copyright +++ octave-nurbs-1.0.2/debian/copyright @@ -0,0 +1,56 @@ +Format-Specification: http://svn.debian.org/wsvn/dep/web/deps/dep5.mdwn?rev=48 +Upstream-Name: Collection of routines for the creation and manipulation of Non-Uniform Rational B-Splines (NURBS) +Upstream-Maintainer: Carlo de Falco +Upstream-Source: http://octave.sourceforge.net/nurbs/index.html + +Files: debian/* +Copyright: © 2009 Rafael Laboissiere +License: GPL-3+ + +Files: inst/basisfunder.m +Copyright: © 2009 Rafael Vazquez +License: GPL-2+ + +Files: inst/basisfun.m, inst/findspan.m +Copyright: © 2003 Mark Spink, 2007 Daniel Claxton, 2009 Carlo de Falco +License: GPL-2+ + +Files: inst/bspdegelev.m inst/bspderiv.m, inst/bspeval.m, inst/bspkntins.m +Copyright: © 2003 Mark Spink, 2007 Daniel Claxton +License: GPL-2+ + +Files: inst/__nrb_srf_basisfun_der__.m, inst/__nrb_srf_basisfun__.m, + inst/nrbsrfgradient.m, inst/numbasisfun.m +Copyright: © 2009 Carlo de Falco + +Files: inst/democurve.m, inst/demodercrv.m, inst/demotorus.m, inst/nrbdemo.m, + inst/nrbextrude.m, inst/nrbruled.m, inst/nrbplot.m, inst/nrbrevolve.m +Copyright: © 2003 Mark Spink +License: GPL-2+ + +Files: inst/nrbbasisfunder.m, inst/nrbbasisfungradient.m, inst/nrbbasisfun.m +Copyright: © 2009 Carlo de Falco +License: GPL-2+ + +Files: inst/vecscale.m +Copyright: © 2003 Mark Spink, 2007 Daniel Claxton +License: GPL-2+ + +Files: inst/*.m +Copyright: © 2000 Mark Spink +License: GPL-2+ + +Files: src/* +Copyright: © 2009 Carlo de Falco + © 2003 Mark Spink, 2007 Daniel Claxton +License: GPL-2+ + +License: GPL-2+ + On Debian systems, the complete text of the GNU General Public + License, version 2, can be found in the file + `/usr/share/common-licenses/GPL-2'. + +License: GPL-3+ + On Debian systems, the complete text of the GNU General Public + License, version 3, can be found in the file + `/usr/share/common-licenses/GPL-3'. --- octave-nurbs-1.0.2.orig/debian/changelog +++ octave-nurbs-1.0.2/debian/changelog @@ -0,0 +1,22 @@ +octave-nurbs (1.0.2-1) unstable; urgency=low + + [ Rafael Laboissiere ] + * debian/control: Build-depend on octave-pkg-dev >= 0.7.0, such that the + package is built against octave3.2 + + [ Thomas Weber ] + * New upstream release. + * Removed patches (applied upstream): + + basisfunder-succeed-test.diff + + numbasisfun-succeed-test.diff + * Upstream permissions for .m files are fixed, remove code from + debian/rules. + * New patch: fix-tests, fixes failing unit tests, taken from upstream SVN + + -- Thomas Weber Wed, 30 Dec 2009 09:53:41 +0100 + +octave-nurbs (1.0-1) unstable; urgency=low + + * Initial release (closes: #529483) + + -- Rafael Laboissiere Sun, 24 May 2009 15:33:19 +0200 --- octave-nurbs-1.0.2.orig/debian/README.source +++ octave-nurbs-1.0.2/debian/README.source @@ -0,0 +1,9 @@ +README.source for octave-nurbs +=============================== + +This package uses quilt to manage all modifications to the upstream sources. +See `/usr/share/doc/quilt/README.source' to get more information on how to +use it. + + -- Rafael Laboissiere Sat, 23 May 2009 01:45:01 +0200 + --- octave-nurbs-1.0.2.orig/debian/control +++ octave-nurbs-1.0.2/debian/control @@ -0,0 +1,23 @@ +Source: octave-nurbs +Section: math +Priority: optional +Maintainer: Debian Octave Group +Uploaders: Ólafur Jens Sigurðsson , + Rafael Laboissiere , + Thomas Weber +DM-Upload-Allowed: yes +Build-Depends: debhelper (>= 7.0.0), cdbs, octave-pkg-dev (>= 0.7.0), quilt +Standards-Version: 3.8.1 +Homepage: http://octave.sourceforge.net/nurbs +Vcs-Git: git://git.debian.org/git/pkg-octave/octave-nurbs.git +Vcs-Browser: http://git.debian.org/?p=pkg-octave/octave-nurbs.git + +Package: octave-nurbs +Architecture: any +Depends: ${misc:Depends}, ${shlibs:Depends}, ${octave:Depends} +Description: non-uniform rational B-splines for Octave + This package contains a collection of routines for the creation and + manipulation of Non-Uniform Rational B-Splines (NURBS) using Octave, + a scientific computation software. + . + This Octave add-on package is part of the Octave-Forge project. --- octave-nurbs-1.0.2.orig/debian/watch +++ octave-nurbs-1.0.2/debian/watch @@ -0,0 +1,3 @@ +version=3 +http://octave.sourceforge.net/packages.html \ + http://downloads\.sourceforge\.net/octave/nurbs-([\d.]+)\.tar\.gz\?download --- octave-nurbs-1.0.2.orig/debian/rules +++ octave-nurbs-1.0.2/debian/rules @@ -0,0 +1,6 @@ +#!/usr/bin/make -f +# -*- makefile -*- + +include /usr/share/cdbs/1/class/octave-pkg.mk +include /usr/share/cdbs/1/rules/patchsys-quilt.mk + --- octave-nurbs-1.0.2.orig/debian/patches/autoload-yes.diff +++ octave-nurbs-1.0.2/debian/patches/autoload-yes.diff @@ -0,0 +1,15 @@ +Autoload the package when starting Octave. + + -- Rafael Laboissiere Fri, 22 May 2009 21:08:51 +0200 + +--- a/DESCRIPTION ++++ b/DESCRIPTION +@@ -7,7 +7,7 @@ + Description: Collection of routines for the creation, and manipulation of Non-Uniform Rational B-Splines (NURBS). + Categories: splines + Depends: octave (>= 3.2) +-Autoload: no ++Autoload: yes + License: GPL version 2 or later + Url: http://octave.sf.net + SVNRelease: 6471 --- octave-nurbs-1.0.2.orig/debian/patches/series +++ octave-nurbs-1.0.2/debian/patches/series @@ -0,0 +1,2 @@ +fix-tests +autoload-yes.diff --- octave-nurbs-1.0.2.orig/debian/patches/fix-tests +++ octave-nurbs-1.0.2/debian/patches/fix-tests @@ -0,0 +1,201 @@ +SVN rev 6650, for fixing failing tests +--- a/inst/nrbnumbasisfun.m ++++ b/inst/nrbnumbasisfun.m +@@ -103,11 +103,11 @@ + %! knots = {[zeros(1,p), linspace(0,1,mcp-p+2), ones(1,p)], [zeros(1,q), linspace(0,1,ncp-q+2), ones(1,q)]}; + %! Lx = 1; Ly = 1; + %! [cntl(1,:,:), cntl(2,:,:)] = meshgrid(linspace(0, Lx, ncp+1), linspace(0, Ly, mcp+1) ); +-%! cntl(4,:,:) = 1:numel(cntl(1,:,:)); ++%! cntl(:,:,4) = reshape(1:numel(cntl(:,:,4)),size(cntl(:,:,4))); + %! nrb = nrbmak(cntl, knots); + %! u = rand (1, 30); v = rand (1, 10); + %! N = nrbnumbasisfun ({u, v}, nrb); + %! assert (all(all(N>0)), true) + %! assert (all(all(N<=(ncp+1)*(mcp+1))), true) + %! assert (max(max(N)),(ncp+1)*(mcp+1)) +-%! assert (min(min(N)),1) +\ No newline at end of file ++%! assert (min(min(N)),1) +--- a/inst/nrbbasisfungradient.m ++++ b/inst/nrbbasisfungradient.m +@@ -16,7 +16,7 @@ + + %% -*- texinfo -*- + %% @deftypefn {Function File} {[@var{dRdx}, @var{dRdy}]=} nrbbasisfungradient (@{@var{dzdu}, @var{dzdv}@}, @{@var{dxdu}, @var{dydu}, @var{dxdv}, @var{dydv}@}) +-%% @deftypefnx {Function File} {[@var{dRdx}]=} nrbbasisfungradient (@var{dzdu}, @var{dxdu}) ++%% @deftypefnx {Function File} {[@var{dRdx}]=} nrbbasisfungradient (@var{dzdu}, @var{dxdu}, @var{nrb}) + %% NRBBASISFUNGRADIENT Compute the gradient of the basis functions of a NURBS surface at the + %% specified parametric points. + %% +@@ -26,6 +26,7 @@ + %% to parameters @code{u} and @code{v} + %% @item @var{dxdu}, @var{dydu}, @var{dxdv}, + %% @var{dydv}: NURBS geometry map derivatives ++%% @var{nrb}: NURBS structure describing the surface + %% @end itemize + %% + %% OUTPUT: +@@ -87,7 +88,7 @@ + %! knots = {[zeros(1,p), linspace(0,1,mcp-p+2), ones(1,p)], [zeros(1,q), linspace(0,1,ncp-q+2), ones(1,q)]}; + %! Lx = 1; Ly = 1; + %! [cntl(2,:,:), cntl(1,:,:)] = meshgrid(linspace(0, Ly, ncp+1), linspace(0, Lx, mcp+1) ); +-%! cntl(4,:,:) = 1:numel(cntl(1,:,:)); ++%! cntl(:,:,4) = reshape(1:numel(cntl(:,:,4)),size(cntl(:,:,4))); + %! nrb = nrbmak(cntl, knots); + %! + %! [u(2,:,:), u(1,:,:)] = meshgrid(rand (1, 20), rand (1, 20)); +@@ -100,11 +101,6 @@ + %! nd = nrbderiv(nrb); + %! [ndp, dp] = nrbdeval(nrb, nd, uv); + %! +-%! dxdu = repmat (reshape (dp{1}(1,:,:), [], 1), 1, columns(dzdu)); +-%! dydu = repmat (reshape (dp{1}(2,:,:), [], 1), 1, columns(dzdu)); +-%! dxdv = repmat (reshape (dp{2}(1,:,:), [], 1), 1, columns(dzdu)); +-%! dydv = repmat (reshape (dp{2}(2,:,:), [], 1), 1, columns(dzdu)); +-%! +-%! [dzdx, dzdy]= nrbbasisfungradient ({dzdu, dzdv}, {dxdu, dydu, dxdv, dydv}); ++%! [dzdx, dzdy]= nrbbasisfungradient ({dzdu, dzdv}, connect, nrb); + %! assert(norm(sum(dzdx, 2), inf), 0, 1e-10) +-%! assert(norm(sum(dzdy, 2), inf), 0, 1e-10) +\ No newline at end of file ++%! assert(norm(sum(dzdy, 2), inf), 0, 1e-10) +--- a/inst/nrbbasisfunder.m ++++ b/inst/nrbbasisfunder.m +@@ -65,9 +65,7 @@ + + if (iscell(points)) + [v, u] = meshgrid(points{2}, points{1}); +- p(1,:,:) = u; +- p(2,:,:) = v; +- p = reshape(p, 2, []); ++ p = [u(:), v(:)]'; + else + p = points; + end +@@ -130,16 +128,13 @@ + %! assert (sum(Bu, 2), zeros(numel(u), 1), 1e-10) + + %!test +-%! p = 2; +-%! q = 3; +-%! mcp = 2; ncp = 3; +-%! knots = {[zeros(1,p), linspace(0,1,mcp-p+2), ones(1,p)], [zeros(1,q), linspace(0,1,ncp-q+2), ones(1,q)]}; +-%! Lx = 1; Ly = 1; +-%! [cntl(2,:,:), cntl(1,:,:)] = meshgrid(linspace(0, Ly, ncp+1), linspace(0, Lx, mcp+1) ); +-%! cntl(4,:,:) = 1:numel(cntl(1,:,:)); +-%! nrb = nrbmak(cntl, knots); +-%! [u(1,:,:), u(2,:,:)] = meshgrid(rand (1, 20), rand (1, 20)); +-%! tic(); [Bu, Bv, N] = nrbbasisfunder (u, nrb); toc() ++%! p = 2; q = 3; m = 4; n = 5; ++%! Lx = 1; Ly = 1; ++%! nrb = nrb4surf ([0 0], [1 0], [0 1], [1 1]); ++%! nrb = nrbdegelev (nrb, [p-1, q-1]); ++%! nrb = nrbkntins (nrb, {linspace(0,1,m)(2:end-1), linspace(0,1,n)(2:end-1)}); ++%! nrb.coefs (4,:,:) += rand (size (nrb.coefs (4,:,:))); ++%! tic(); [Bu, Bv, N] = nrbbasisfunder ({rand(1, 20), rand(1, 20)}, nrb); toc() + %! #plot3(squeeze(u(1,:,:)), squeeze(u(2,:,:)), reshape(Bu(:,10), 20, 20),'o') + %! assert (sum (Bu, 2), zeros(20^2, 1), 1e-10) + +--- a/inst/nrbbasisfun.m ++++ b/inst/nrbbasisfun.m +@@ -59,9 +59,7 @@ + + if (iscell(points)) + [v, u] = meshgrid(points{2}, points{1}); +- p(1,:,:) = u; +- p(2,:,:) = v; +- p = reshape(p, 2, []); ++ p = [u(:), v(:)]'; + else + p = points; + end +@@ -78,7 +76,7 @@ + U = nrb.knots; + w = nrb.coefs(4,:); + +- spu = findspan (n, p, u, U); ++ spu = findspan (n, p, u, U); + nbfu = numbasisfun (spu, u, p, U); + + N = w(nbfu+1) .* basisfun (spu, u, p, U); +@@ -118,20 +116,17 @@ + %! assert(B(:,4), w(4)*nrbeval(nrb2, u)(2,:).', 1e-6) + + %!test +-%! p = 2; +-%! q = 3; +-%! mcp = 2; ncp = 3; +-%! knots = {[zeros(1,p), linspace(0,1,mcp-p+2), ones(1,p)], [zeros(1,q), linspace(0,1,ncp-q+2), ones(1,q)]}; +-%! Lx = 1; Ly = 1; +-%! [cntl(2,:,:), cntl(1,:,:)] = meshgrid(linspace(0, Ly, mcp+1),linspace(0, Lx, ncp+1)); +-%! cntl(4,:,:) = reshape(1:numel(cntl(1,:,:)), size(cntl(1,:,:))); +-%! nrb = nrbmak(cntl, knots); ++%! p = 2; q = 3; m = 4; n = 5; ++%! Lx = 1; Ly = 1; ++%! nrb = nrb4surf ([0 0], [1 0], [0 1], [1 1]); ++%! nrb = nrbdegelev (nrb, [p-1, q-1]); ++%! nrb = nrbkntins (nrb, {linspace(0,1,m)(2:end-1), linspace(0,1,n)(2:end-1)}); + %! u = rand (1, 30); v = rand (1, 10); + %! [B, N] = nrbbasisfun ({u, v}, nrb); + %! assert (sum(B, 2), ones(300, 1), 1e-6) +-%! assert (all(all(B<=1)), true) +-%! assert (all(all(B>=0)), true) +-%! assert (all(all(N>0)), true) +-%! assert (all(all(N<=(ncp+1)*(mcp+1))), true) +-%! assert (max(max(N)),(ncp+1)*(mcp+1)) +-%! assert (min(min(N)),1) +\ No newline at end of file ++%! assert (all (all (B<=1)), true) ++%! assert (all (all (B>=0)), true) ++%! assert (all (all (N>0)), true) ++%! assert (all (all (N <= prod (nrb.number))), true) ++%! assert (max (max (N)),prod (nrb.number)) ++%! assert (min (min (N)),1) +\ No newline at end of file +--- a/inst/findspanc.m ++++ b/inst/findspanc.m +@@ -19,7 +19,7 @@ + % + % Calling Sequence: + % +-% s = findspanc(n,p,u,U) ++% s = findspanc(u, U) + % + % INPUT: + % +@@ -42,7 +42,7 @@ + %! U = [0 0 0 1/2 1 1 1]; + %! p = 2; + %! u = linspace(0, 1, 10)(2:end-1); +-%! s = findspanc (p, u, U); ++%! s = findspanc (u, U); + %! assert (s, [2*ones(1, 4) 3*ones(1, 4)]); + + %!test +@@ -50,4 +50,4 @@ + %! U = [zeros(1,p) linspace(0,1,m+1-2*p) ones(1,p)]; + %! u = [ 0.11880 0.55118 0.93141 0.40068 0.35492 0.44392 0.88360 0.35414 0.92186 0.83085 ]; + %! s = [2 3 4 3 3 3 4 3 4 4]; +-%! assert (findspanc (p, u, U), s, 1e-10); +\ No newline at end of file ++%! assert (findspanc (u, U), s, 1e-10); +\ No newline at end of file +--- a/inst/surfderiveval.m ++++ b/inst/surfderiveval.m +@@ -97,4 +97,4 @@ + %! srf.order(2)-1, + %! srf.knots{2}, + %! squeeze(srf.coefs(1,:,:)), .5, .5, 1) ; +-%! assert (skl, [.5 0; 1 0]) +\ No newline at end of file ++%! assert (skl, [.5 0; 1 0], 100*eps) +\ No newline at end of file +--- a/src/surfderiveval.cc ++++ b/src/surfderiveval.cc +@@ -86,5 +86,5 @@ + %! srf.order(2)-1, + %! srf.knots{2}, + %! squeeze(srf.coefs(1,:,:)), .5, .5, 1) ; +-%! assert (skl, [.5 0; 1 0]) ++%! assert (skl, [.5 0; 1 0], 100*eps) + */