Subversion Repositories wimsdev

Rev

Rev 3837 | Rev 6790 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3837 Rev 6578
Line 741... Line 741...
741
    if(dd<3) dd=3; if(dd>MAX_SIZE) dd=MAX_SIZE;
741
    if(dd<3) dd=3; if(dd>MAX_SIZE) dd=MAX_SIZE;
742
    plotjump=dd;
742
    plotjump=dd;
743
}
743
}
744
 
744
 
745
        /* plot a curve, either parametric or explicit */
745
        /* plot a curve, either parametric or explicit */
746
void obj_plot(objparm *pm)
746
void _obj_plot(objparm *pm,int dash)
747
{
747
{
748
    int i,j,n,dist,xx,yy,varpos;
748
    int i,j,n,dist,xx,yy,varpos;
749
    char p1[MAX_LINELEN+1], p2[MAX_LINELEN+1];
749
    char p1[MAX_LINELEN+1], p2[MAX_LINELEN+1];
750
    char *varn, *pp;
750
    char *varn, *pp;
751
    double dc[2],t,v;
751
    double dc[2],t,v;
Line 791... Line 791...
791
            dist=sqrt(xx*xx+yy*yy);
791
            dist=sqrt(xx*xx+yy*yy);
792
            if(dist>0) {
792
            if(dist>0) {
793
                if(dist>plotjump || dist==1)
793
                if(dist>plotjump || dist==1)
794
                  gdImageSetPixel(image,ic[0],ic[1],pm->color[0]);
794
                  gdImageSetPixel(image,ic[0],ic[1],pm->color[0]);
795
                else
795
                else
-
 
796
                 if ( dash==1) {
-
 
797
                  gdImageDashedLine(image,oc[0],oc[1],ic[0],ic[1],pm->color[0]);
-
 
798
                  } else
796
                  gdImageLine(image,oc[0],oc[1],ic[0],ic[1],pm->color[0]);
799
                  {gdImageLine(image,oc[0],oc[1],ic[0],ic[1],pm->color[0]); }
797
               
800
               
798
            }
801
            }
799
        }
802
        }
800
        memmove(oc,ic,sizeof(oc));
803
        memmove(oc,ic,sizeof(oc));
801
    }
804
    }
802
    if(vimg_enable) vimg_plotend();
805
    if(vimg_enable) vimg_plotend();
803
}
806
}
-
 
807
 
-
 
808
void obj_plot(objparm *pm) { _obj_plot( pm,0) ;}
-
 
809
void obj_dplot(objparm *pm) { _obj_plot( pm,1) ; }
804
 
810
 
805
        /* set levelcurve granularity */
811
        /* set levelcurve granularity */
806
void obj_levelstep(objparm *pm)
812
void obj_levelstep(objparm *pm)
807
{
813
{
808
    int dd;
814
    int dd;