Shop OBEX P1 Docs P2 Docs Learn Events
Propeller TV Vertical & Horizontal Switcher — Parallax Forums

Propeller TV Vertical & Horizontal Switcher

HumanoidoHumanoido Posts: 5,770
edited 2011-02-21 10:58 in Propeller 1
I have the small Parallax TV (3.5-inch, 320x240 pixels). It's mounted in an enclosure that is used in either a horizontal or vertical position. Is there a TV driver that can switch the rows of characters from horizontal to vertical? If it does not exist, what would it take to make one?

Comments

  • MagIO2MagIO2 Posts: 2,243
    edited 2011-02-21 00:27
    The main issue is that you still have to generate the video signal from left to right (320) and top down (240). So, if you want to rotate the content the character font in ROM will no longer support the video generator. Current drivers pick the content of the frame-buffer and then fetch the pixel data of the character to be displayed from ROM. Only a few operations for extracting and setting color and you have the data for the video generator.

    Changing the orientation means that you have to fetch 32 times from ROM to get the column of a character. You also need a lot of masking and shifting to put the bits at the right place. I think this will simply be much to slow.
    Solution: you have to convert the existing character-set to the new orientation beforehand, which needs some RAM or create a character set on your own with the right orientation.
  • RaymanRayman Posts: 14,886
    edited 2011-02-21 03:55
    Well, if you didn't mind using up 1/2 your RAM, you could embed or create at run time a rotated copy of the ROM font.

    Then, just change the Print routines to that base address...
  • wjsteelewjsteele Posts: 697
    edited 2011-02-21 06:06
    Rayman wrote: »
    Well, if you didn't mind using up 1/2 your RAM, you could embed or create at run time a rotated copy of the ROM font.

    Actually, I don't think this is much of an issue as the current Graphics.spin driver contains a vector font table. Using it instead, all you have to do is rotate each character. Now, you don't have the full font table, but all the important stuff, and you can easily add/remove items if you want to.

    Bill
  • RaymanRayman Posts: 14,886
    edited 2011-02-21 08:40
    That would probably work too. But, I think full screen graphics would use up even more RAM...
    Maybe not as single buffered though...
  • localrogerlocalroger Posts: 3,452
    edited 2011-02-21 10:58
    With such a small screen, duplicating the high definition ROM font in its entirety is overkill. You should be able to get serviceable results with an 8x8 font such as aiGeneric uses, with some horizontal and vertical expansion to reduce the screen resolution. Such a font will only eat 1K of your RAM for 128 characters instead of half of it. Then it's just a matter of reworking the tv_text object to insert characters bottom-to-top instead of left-to-right, which is fairly trivial.
Sign In or Register to comment.