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

Username:   Password: 
 RegisterRegister   
 I need some help with the rotation
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
jd




PostPosted: Tue Feb 19, 2008 10:43 pm   Post subject: I need some help with the rotation

Hi there, I'm a first year student who started learning turing to make program. I have a question on how to rotate my 3-d box, I try to make it just as similar as the screen saver that we usually have on our computer. I had look through all the posts about rotation, but I still have no clue how to do it. Can anyone help me with this? I'll be very appreciate with that.
My program is on the following:


Quote:
% Jacklyn

View.Set ("offscreenonly")

setscreen ("screen:max;max")

% background colour
colourback (7)
cls

% variables
var x, y : int := 10
var c : int := 25
var x2, y2 : int := 3

loop

% draw 3D-box
drawbox (x, y, x + 50, y + 50, c)
drawline (x, y + 50, x + 30, y + 80, c)
drawline (x + 30, y + 80, x + 80, y + 80, c)
drawline (x + 80, y + 80, x + 50, y + 50, c)
drawline (x + 80, y + 80, x + 80, y + 30, c)
drawline (x + 80, y + 30, x + 50, y, c)
drawfill (x + 60, y + 70, c, 7)
drawfill (x + 70, y + 65, c, 7)

% show output
View.Update

% no exit statement in this program

% delay
delay (40)

% erase
cls

% moving position
x += x2
y += y2
if x < 10 or x > maxx - 90 then
x2 := -x2
c := c + 2
end if
if y < 10 or y > maxy - 90 then
y2 := -y2
c := c + 2
end if

end loop
Sponsor
Sponsor
Sponsor
sponsor
Sean




PostPosted: Wed Feb 20, 2008 7:24 am   Post subject: Re: I need some help with the rotation

Read up on Pic.Rotate.
ericfourfour




PostPosted: Wed Feb 20, 2008 3:41 pm   Post subject: Re: I need some help with the rotation

Vilament wrote:

Read up on 3D geometry.

Fixed.
CodeMonkey2000




PostPosted: Wed Feb 20, 2008 6:08 pm   Post subject: RE:I need some help with the rotation

That's not what he need help with, he wants to know about rotating 3D shapes.
EDIT: What the? did some one post again about Pic.rotate?
jd




PostPosted: Wed Feb 20, 2008 8:00 pm   Post subject: Re: RE:I need some help with the rotation

CodeMonkey2000 @ Wed Feb 20, 2008 6:08 pm wrote:
That's not what he need help with, he wants to know about rotating 3D shapes.
EDIT: What the? did some one post again about Pic.rotate?


I'm very sorry of keep asking the same question over and over again, but I'm a very beginner of turing, I haven't get a chance to learn Pic.Rotate yet. I was trying to do some extra things in my program, which is rotate the 3D box/shapes. I've tried to look on the Turing Tutorials; although I read the postes, but the main problem is I don't really understand about it. Could you help me with this?
Clayton




PostPosted: Wed Feb 20, 2008 9:11 pm   Post subject: RE:I need some help with the rotation

Hold on there partner, take it one step at a time. If you haven't even talked about Pic.Rotate() and it's friends, then you're definitely not ready for 3D. Learn 2D first, then go for 3D.
jd




PostPosted: Wed Feb 20, 2008 9:24 pm   Post subject: Re: RE:I need some help with the rotation

Clayton @ Wed Feb 20, 2008 9:11 pm wrote:
Hold on there partner, take it one step at a time. If you haven't even talked about Pic.Rotate() and it's friends, then you're definitely not ready for 3D. Learn 2D first, then go for 3D.

are there any post about the rotation of 2D shapes?
this is so confusing for me..
Clayton




PostPosted: Wed Feb 20, 2008 9:27 pm   Post subject: RE:I need some help with the rotation

Use the search function at the top of the page, there's been tons of posts about rotating a 2D shape.
Sponsor
Sponsor
Sponsor
sponsor
jd




PostPosted: Wed Feb 20, 2008 9:28 pm   Post subject: Re: RE:I need some help with the rotation

Clayton @ Wed Feb 20, 2008 9:27 pm wrote:
Use the search function at the top of the page, there's been tons of posts about rotating a 2D shape.

okok, thank you so much.
But if I still don't understand about it, can I ask you about that?
ericfourfour




PostPosted: Wed Feb 20, 2008 10:16 pm   Post subject: Re: RE:I need some help with the rotation

jd @ Wed Feb 20, 2008 9:28 pm wrote:
But if I still don't understand about it, can I ask you about that?


Did you just ask permission to ask for help on a help forum?
Clayton




PostPosted: Wed Feb 20, 2008 10:36 pm   Post subject: RE:I need some help with the rotation

jd wrote:
But if I still don't understand about it, can I ask you about that?


No, I'm afraid we don't do that here.
jd




PostPosted: Thu Feb 21, 2008 12:09 am   Post subject: Re: RE:I need some help with the rotation

ericfourfour @ Wed Feb 20, 2008 10:16 pm wrote:
jd @ Wed Feb 20, 2008 9:28 pm wrote:
But if I still don't understand about it, can I ask you about that?


Did you just ask permission to ask for help on a help forum?

I'm sorry, I didn't noticed about that.
jd




PostPosted: Thu Feb 21, 2008 12:11 am   Post subject: Re: RE:I need some help with the rotation

Clayton @ Wed Feb 20, 2008 10:36 pm wrote:
jd wrote:
But if I still don't understand about it, can I ask you about that?


No, I'm afraid we don't do that here.

It's ok, I am going to use another way to do it.
Clayton




PostPosted: Thu Feb 21, 2008 8:45 am   Post subject: RE:I need some help with the rotation

I think I broke my own sacasmeter with that remark...
CodeMonkey2000




PostPosted: Thu Feb 21, 2008 4:12 pm   Post subject: RE:I need some help with the rotation

Clayton you sucks at sarcasm. jd, google 3d rotation.
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  [ 15 Posts ]
Jump to:   


Style:  
Search: