Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] View of /branches/charisee/ertest/vispaper/grad-magnitude2/grad-magnitude2.diderot
ViewVC logotype

View of /branches/charisee/ertest/vispaper/grad-magnitude2/grad-magnitude2.diderot

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2870 - (download) (annotate)
Wed Feb 25 21:47:43 2015 UTC (5 years ago) by cchiw
File size: 534 byte(s)
added sqrt,pow, and examples
field#3(2)[] s= load ("../../../data/parab/parab2-150.nrrd") ⊛ bspln5;
field#0(2)[2] f=∇|∇s|;

int imgSizeX = 10;
int imgSizeY = 10;

strand fieldTest (int xi, int yi) {
        real xx = lerp(0.3, 6.75, 0.0, real(xi), real(imgSizeX)-1.0);
        real yy = lerp(0.6, 3.69, 0.0, real(yi), real(imgSizeY)-1.0);
        vec2 pos = [xx,yy];

        output tensor [2] t=f(pos);
     
        update
        {
            stabilize;

        }
    }

initially [ fieldTest(xi, yi) |  yi in 0..(imgSizeY-1), xi in 0..(imgSizeX-1)];


root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0