Author Topic: Rotating an Image with LUA  (Read 5488 times)

0 Members and 1 Guest are viewing this topic.

Offline Augs

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 306
  • Rating: +30/-29
    • View Profile
Rotating an Image with LUA
« on: February 09, 2013, 07:22:33 am »
Is there anyway to rotate an Image using OS 3.1

I know that in OS 3.2 you can use Image.rotate but that is not available in OS 3.1

Any way to do it?

Otherwise I could just make set images.

Thanks in advance

Offline Lionel Debroux

  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2135
  • Rating: +290/-45
    • View Profile
    • TI-Chess Team
Re: Rotating an Image with LUA
« Reply #1 on: February 09, 2013, 07:58:24 am »
For instance, using a Ndless Lua extension (to be written, of course, but the rotation algorithms are well-known would do the trick.
Member of the TI-Chess Team.
Co-maintainer of GCC4TI (GCC4TI online documentation), TILP and TIEmu.
Co-admin of TI-Planet.

Offline Augs

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 306
  • Rating: +30/-29
    • View Profile
Re: Rotating an Image with LUA
« Reply #2 on: February 09, 2013, 08:39:47 am »
More explanation please?

Offline Levak

  • LV9 Veteran (Next: 1337)
  • *********
  • Posts: 1002
  • Rating: +208/-39
    • View Profile
    • My website
Re: Rotating an Image with LUA
« Reply #3 on: February 09, 2013, 08:57:48 am »
More explanation please?
Ndless 3.1 has a feature, named Ndless Lua extensions, that enables anyone having the .luax file in the ext directory of Ndless to enhance Lua modules.
Extensions files (*.luax) are C compiled modules that uses the OS Lua API.
Since Ndless runs only on 3.1 for now, this means your script won't run on 3.2
As said Lionel, no real extension were written so far, so no extension were written to rotate a TI-Image.
« Last Edit: February 09, 2013, 08:59:43 am by Levak »
I do not get mad at people, I just want them to learn the way I learnt.
My website - TI-Planet - iNspired-Lua

Offline Lionel Debroux

  • LV11 Super Veteran (Next: 3000)
  • ***********
  • Posts: 2135
  • Rating: +290/-45
    • View Profile
    • TI-Chess Team
Re: Rotating an Image with LUA
« Reply #4 on: February 09, 2013, 10:40:02 am »
And the Internet is a better source of documentation than I am about image rotation algorithms, although I know the basics. The ExtGraph TI-68k library contains such a routine, written in 68000 ASM, but it was contributed to ExtGraph by someone else.
Member of the TI-Chess Team.
Co-maintainer of GCC4TI (GCC4TI online documentation), TILP and TIEmu.
Co-admin of TI-Planet.

Offline Augs

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 306
  • Rating: +30/-29
    • View Profile
Re: Rotating an Image with LUA
« Reply #5 on: February 09, 2013, 11:00:48 am »
I'll just go with set images. Thanks guys

Offline Jim Bauwens

  • Lua! Nspire! Linux!
  • Editor
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1881
  • Rating: +206/-7
  • Linux!
    • View Profile
    • nothing...
Re: Rotating an Image with LUA
« Reply #6 on: February 09, 2013, 05:46:45 pm »
Rotating an image in a rectangular way (90 degree, etc) wouldn't be so hard to code in pure lua. So if that's what you need it I could code it quickly.

Offline Augs

  • LV6 Super Member (Next: 500)
  • ******
  • Posts: 306
  • Rating: +30/-29
    • View Profile
Re: Rotating an Image with LUA
« Reply #7 on: February 10, 2013, 08:43:24 am »
Nah, I'll just do set Images