Something with OpenGL

  The aim of this article is simply ,just recording my path on the way towards OpenGL.

  Actually,OpenGL now is not as popular as last century.however,It still contains great power,to say the least, which

 can arm myself to earn a life in such complex society.

  Right now, I will note down the first  tip.

 

 1. <Coordinate transformation >

       Remember the glRotate() is surrounding the Vecteur from the origine,default at (0,0,0),to the parameter accepted

in the function . Eg:

                      glRotate(50,0.0,2.0,1.0);    // default origine at (0,0,0),so the vecteur is (0.0,2.0,1.0).

      The important point is that the order with  the function of glTranslate() will arise different  display.Must make clear!

 

 

2. About gluOrtho

    This type function is used to create a Orthogonal  parallel-to-viewport Vector. At the begin ,I just made a simply mistake.As the Red programming guide book stated, if you don't rule accurate view vector and you will  never view

the figure or scene.Normally, gluOrtho2D should correspond to the origine window size(defined by glutInitWindowSize)

,and the rate can be any scale.For erxample:

           glutInitWindowSize(500,500);

           gluOrtho2D(0,200,0,200);

   The display will be scaled by 5/2 times.So if you define 2 point 20mils,actually the points will be away from 50mils now.

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值