Permalink #1 
Neha's Avatar
Join Date: Mar 2009
Posts: 2
Junior Member
    Thanks: 0
    Thanked 0 Times in 0 Posts

    Smile 3D Car


    My teacher have given me an assignment to build a 3D car in C language using Turbo C compiler only....
    I'm very confused how to start making it....
    kindly help me!!!!
    how to start?
    please help me

    I am allowed to use only basic functions of C (like line(), polygon(), putpixel(), floodfill())

    Last edited by Neha; 03-22-2009 at 02:53 PM.
      Permalink #2 
    fongmingyun's Avatar
    Join Date: Aug 2008
    Posts: 318
    Senior Member
      My Mood: Cheerful
      Thanks: 0
      Thanked 16 Times in 16 Posts

      I thinjk we would need more specific information to help you. Are you using a linear algebra package? What about for graphics - OpenGL?
        Permalink #3 
      Neha's Avatar
      Join Date: Mar 2009
      Posts: 2
      Junior Member
        Thanks: 0
        Thanked 0 Times in 0 Posts

        Hey I've given all information needed..
        kindly help me now!!!!
          Permalink #4 
        fongmingyun's Avatar
        Join Date: Aug 2008
        Posts: 318
        Senior Member
          My Mood: Cheerful
          Thanks: 0
          Thanked 16 Times in 16 Posts

          I'm afraid I am mainly knowledgeable in C++, but what I would do is take some graph paper and plot out the points on a car.

          For example, to make a box, I'd have points at:

          (0,0,0)
          (1,0,0)
          (0,1,0)
          (1,1,0)
          (0,0,1)
          (1,0,1)
          (0,1,1)
          (1,1,1)

          Once you have your car-on-paper, you can begin translating it into code.

          I would draw a polygon between each of those points. This totals to six polygons. Also, make sure the normals are facing outwards. So, if you're doing the bottom of the box - do (0,0,0) then (0,1,0) then (1, 1, 0) then (1, 0, 0). Notice, this traverses the points in a clockwise manner - so the normal points downwards. The "outside" part of the plane that forms the box bottom faces down.

          Repeat this process for all items.
            Permalink #5 
          feed_me's Avatar
          Join Date: Oct 2012
          Posts: 2
          Junior Member
            Thanks: 0
            Thanked 0 Times in 0 Posts

            Quote:
            Originally Posted by Neha View Post
            My teacher have given me an assignment to build a 3D car in C language using Turbo C compiler only....
            I'm very confused how to start making it....
            kindly help me!!!!
            how to start?
            please help me

            I am allowed to use only basic functions of C (like line(), polygon(), putpixel(), floodfill())
            Ahhh.. turbo C


            Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
             

            Posting Rules
            Smilies are On
            [IMG] code is On
            HTML code is Off