Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Picture Frame
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
hotsnow




PostPosted: Thu Oct 16, 2008 12:20 pm   Post subject: Picture Frame

can any one help me make a picture frame using the "for-end for" loop to repeatedly draw lines,circles, etc. around the screen?

Thanx-
much appreciated
Sponsor
Sponsor
Sponsor
sponsor
Tony




PostPosted: Thu Oct 16, 2008 1:08 pm   Post subject: RE:Picture Frame

The Turing Walkthrough points for tutorials on how to use for-loops and drawing.
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
hotsnow




PostPosted: Thu Oct 16, 2008 9:47 pm   Post subject: RE:Picture Frame

Tony thanks for your help but I read the whole tut and it still doesnt help me...maybe you could pinpoint the solution? if you could it would be great
Tony




PostPosted: Fri Oct 17, 2008 9:30 am   Post subject: RE:Picture Frame

Turing:

for i: 1 .. maxx
   Draw.Oval(i, 100, 5, 5, red)
   delay(100)
end for
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
SNIPERDUDE




PostPosted: Fri Oct 17, 2008 3:04 pm   Post subject: RE:Picture Frame

You need to understand two things here:

For loops (try a few activities and try to understand how they work)
, and drawing (look in the turing help on how to use the drawing command for things like ovals, lines, etc).

If you need any more help (being more specific on your question about what your learned) - we're here to help.
hotsnow




PostPosted: Sun Oct 19, 2008 5:09 pm   Post subject: RE:Picture Frame

thanks for your help guys but what I am asking for is like some cool looking designs you could do on the frame, like something that'd look nice and cool around the border of the frame..
Tony




PostPosted: Sun Oct 19, 2008 5:21 pm   Post subject: RE:Picture Frame

That is not at all a specific question. What kind of a design would you consider cool? What kind of problems do you encounter in implementing the said design?
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
andrew.




PostPosted: Sun Oct 19, 2008 5:42 pm   Post subject: RE:Picture Frame

Try playing around with the drawing tools. Try drawing things in a straight line first to see of you like it. You could do things like have circles that go together to make a slinky looking border.
Sponsor
Sponsor
Sponsor
sponsor
hotsnow




PostPosted: Sun Oct 19, 2008 8:53 pm   Post subject: RE:Picture Frame

thanks andrew, could you give me an example perhaps?
Euphoracle




PostPosted: Mon Oct 20, 2008 2:55 pm   Post subject: RE:Picture Frame

Since no one else is going to say this, I will.

We're not here to give you code to copy and paste into your assignment. We're here to help you derive the code that you will write to aid your assignment.

After all, it's your assignment, not ours. Most of us have already done these in years past.

Now to make this post useful, I think this looks like a nice frame:

Posted Image, might have been reduced in size. Click Image to view fullscreen.
hotsnow




PostPosted: Mon Oct 20, 2008 6:50 pm   Post subject: RE:Picture Frame

Euphoracle, you're obviously missing the point here. I'm NOT asking for the code. I'm asking your guys' help so i can make the code myself. I've read the tut that Tony asked me to go read(and a few others) but they still don't help me which is why I made this thread. I need help in, for ex., how to make make a patterned design made of circles, boxes, etc. go across the screen from left to right, and bottom to top. Which commands should I use (because we haven't learned that many in class), How to choose different colours? (since they're numbered, and I don't know which number is which colour)
So do you understand what I'm trying to say??
I hope you do =(. But anyways, So...like I said I need your help to make the code, I dont need you to give it to me.

BTW, nice pic frame, it looks alright, but I prefer more colour.
The_Bean




PostPosted: Mon Oct 20, 2008 8:43 pm   Post subject: Re: Picture Frame

OK heres a colour picker, just hover the mouse over the colour you like and the corresponding number appears in the top left corner.
It's also an example of how to use a for statement and move something across the screen.

Turing:

View.Set ("graphics:755,120,offscreenonly")
var xm, ym, bm : int
for i : 1 .. 255
    Draw.ThickLine (i * 3 - 1, 0, i * 3 - 1, 100, 3, i)
end for
loop
    Mouse.Where (xm, ym, bm)
    locate (1, 1)
    put View.WhatDotColour (xm, ym)
    View.Update
    exit when hasch
end loop
hotsnow




PostPosted: Tue Oct 21, 2008 6:48 pm   Post subject: RE:Picture Frame

OMG thank you Bean, that was so much help! Its very cool how is shows the colour and it's number on the top, very, very helpful. Atleast now I know what colour to choose ratherthen choosing random numbers.THANX AGAIN =D
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 13 Posts ]
Jump to:   


Style:  
Search: