Drawing Commands: TI Nspire CX II
07-19-2019, 06:08 PM
Post: #2
 toml_12953 Senior Member Posts: 2,044 Joined: Dec 2013
RE: Drawing Commands: TI Nspire CX II
(07-19-2019 04:17 PM)Eddie W. Shore Wrote:  Blog post: http://edspi31415.blogspot.com/2019/07/t...i-cas.html

The CX II adds drawing commands to the TI Nspire programming language which includes:

I posted a CX II program to draw a hat some time back. I do like the CX II but I still wish it had a method to grab a section of the screen and put it down somewhere else (BitBlit) Maybe in a future OS version...

Code:
Define hat()= Prgm :SetWindow 0,319,0,199 :FillRect 0,0,319,199 :p:=160: q:=100 :xp:=144: xr:=1.5*3.1415927 :yp:=56: yr:=1: zp:=64 :xf:=((xr)/(xp)): yf:=((yp)/(yr)): zf:=((xr)/(zp)) :For zi,−q,q-1 :  If zi≥−zp and zi≤zp Then :    zt:=((zi*xp)/(zp)): zz:=zi :    xl:=int(0.5+√(xp*xp-zt*zt)) :    For xi,−xl,xl :      xt:=√(xi*xi+zt*zt)*xf: xx:=xi :      yy:=(sin(xt)+0.4*sin(3*xt))*yf :      x1:=xx+zz+p :      y1:=yy-zz+q :      SetColor 0,255,0 :      PlotXY x1,y1,7 :      If y1≠0 Then :        SetColor 0,0,0 :        DrawLine x1,y1-1,x1,0 :      EndIf :    EndFor :  EndIf :EndFor :EndPrgm

Tom L
Cui bono?
 « Next Oldest | Next Newest »

 Messages In This Thread Drawing Commands: TI Nspire CX II - Eddie W. Shore - 07-19-2019, 04:17 PM RE: Drawing Commands: TI Nspire CX II - toml_12953 - 07-19-2019 06:08 PM

User(s) browsing this thread: 1 Guest(s)