Sign in to follow this  

One quick question

This topic is 4813 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Use the line function to draw 4 lines between the 4 corners of the rectangle. Then use DispG (or whatever it is for a Ti-83) to display the graph. Probably insert a pause statement in there after that or something - depends what you want to do.

Share this post


Link to post
Share on other sites
Quote:
rather than go each step individually

What do you mean by this? You can have the 4 lines drawn simultaneously, so you won't even be able to notice that they're all drawn separately.

Do it within a program. Have the user input the 4 points. Draw the lines. Display the graph. Done.

Share this post


Link to post
Share on other sites
:Line(X1,Y1,X2,Y1):Line(X2,Y1,X2,Y2):Line(X2,Y2,X1,Y2):Line(X1,Y2,X1,Y1)

^^^ All on one line (not that it would make a difference if it were on four lines).

All of this material is definitely covered in the manual.

Share this post


Link to post
Share on other sites
When it comes down to it a computer can only perform one instruction at a time. Thus, if you want to draw a box, you tell it to draw each line according to the coordinates you give them. It usually happens so fast that you don't notice it. So your code would do this:

Draw line 1;
Draw line 2;
Draw line 3;
Draw line 4;
Calculate the area;
Fill in the area;

All those steps would happen so fast that you'd just see the end result.

Share this post


Link to post
Share on other sites
To fill you need to use the shade function, which sadly only takes two function values as parameters. Since a rectangle is defined by 3 4 functions, I don't know if you'll be able to shade it without altering the pixel data... which is really slow unless you're using ASM, and I gather you're not...

EDIT: what was I thinking? A rectangle is defined by 4 functions... not 3. Pardon the error!

[Edited by - Mushu on October 7, 2004 8:09:32 PM]

Share this post


Link to post
Share on other sites

This topic is 4813 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this