[gameprogrammer] Re: Odometer

  • From: jorgefm@xxxxxxxxx
  • To: gameprogrammer@xxxxxxxxxxxxx
  • Date: Fri, 30 Sep 2005 17:25:50 +0200

Well, the openGL code is no problem. I've yet all the source
to load texture, draw it, and so on working. I was thinking in
a component with the odometer behaviour, to know how the
'acumulative' scroll could be done. For every digit position
you can draw a textured number and translate it for an amount
at every constant time. How to calculate this messurements are
my question.



gameprogrammer-bounce@xxxxxxxxxxxxx escribió el 30/09/2005 16:58:52:

> On 30 Sep, 2005, at 8:01 AM, jorgefm@xxxxxxxxx wrote:
>
> > Hi all,
> >
> > Anybody knows how implement a graphical odometer with SDL, openGL,
> > etc ?
> > Or knows a link to a odometer component in C/C++ ?
> >
> > Thanks
> > Jorge
>
> I've not done it myself, but I imagine that it's probably a simply
> matter of determining a set of textures for the numbers, then the
> space you want them to go, and finally keeping track of the distance
> traveled, and cutting off the floating-point value, and then parsing
> the integer into a string of numbers, and drawing those into their
> appropriate locations using the appropriate number-texture.  So, I
> guess it comes down to how much OpenGL code do you know?  (ie: can
> you load textures and keep track of them?)
>
> So IF you understand what I just rambled about (I'm REALLY bad at
> explaining things to people), then maybe you can clarify at what
> point you can no longer figure this out the rest of the way, and I
> can try to give you some code. ^_^  I just don't want to teach/
> exemplify stuff that you already know.
>
> --Ben
>
>
> ---------------------
> To unsubscribe go to http://gameprogrammer.com/mailinglist.html
>
>

Other related posts: