Shop OBEX P1 Docs P2 Docs Learn Events
hippy, could you assist with this? — Parallax Forums

hippy, could you assist with this?

Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
edited 2008-10-14 23:08 in Propeller 1
hippy,

would you mind helping adjust this code to properly support 22x13 character size allowing
Aigeneric access to larger custom fonts on screen. It's based on your AiChip video driver
from a while back.

Thanks
OBC

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
New to the Propeller?

Getting started with a Propeller Protoboard?
Check out: Introduction to the Proboard & Propeller Cookbook 1.4
Updates to the Cookbook are now posted to: Propeller.warrantyvoid.us
Got an SD card connected? - PropDOS

Comments

  • hippyhippy Posts: 1,981
    edited 2008-10-13 00:46
    I'd love to say yes, but (1) I'm a bit tied up at present and (2) It would take me a while to get back into it ( haven't done any TV since back then ), so I'm afraid it's a - sorry but no - at present :-(
  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2008-10-13 12:14
    Don't sweat it.. I'll either pick my way through it and learn something new, or another kind soul
    will see the obvious that I'm missing. Thanks for all you do here.

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    New to the Propeller?

    Getting started with a Propeller Protoboard?
    Check out: Introduction to the Proboard & Propeller Cookbook 1.4
    Updates to the Cookbook are now posted to: Propeller.warrantyvoid.us
    Got an SD card connected? - PropDOS
  • BaggersBaggers Posts: 3,019
    edited 2008-10-13 13:14
    OBC, is the font 22 pixes by 13? is that you're wanting to display? if so, why such a strange number? why not 24x16? also is the larger number the Y size or X size?
    what is it exactly your after? and would it be set to that size or would you want it to be changeable on the fly?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    http://www.propgfx.co.uk/forum/·home of the PropGFX Lite

    ·
  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2008-10-13 13:18
    I'm thinking that the redefine will look much nicer for creating games
    if the font is twice as large. The exact size really isn't a big deal.

    The size I specified was a combination I found by playing with the row/cols settings.

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    New to the Propeller?

    Getting started with a Propeller Protoboard?
    Check out: Introduction to the Proboard & Propeller Cookbook 1.4
    Updates to the Cookbook are now posted to: Propeller.warrantyvoid.us
    Got an SD card connected? - PropDOS
  • BaggersBaggers Posts: 3,019
    edited 2008-10-13 13:29
    ah, so what you're now after is 16x16 tiles? say for background in games?
    but surely that would eat memory more than 8x8 tiles with 2x2 or 4x4 bigtiles, then the MAP so to speak?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    http://www.propgfx.co.uk/forum/·home of the PropGFX Lite

    ·
  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2008-10-13 13:44
    Nah, eight by eight is fine.. only larger display for clarity.

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    New to the Propeller?

    Getting started with a Propeller Protoboard?
    Check out: Introduction to the Proboard & Propeller Cookbook 1.4
    Updates to the Cookbook are now posted to: Propeller.warrantyvoid.us
    Got an SD card connected? - PropDOS
  • trodosstrodoss Posts: 577
    edited 2008-10-13 13:50
    @OBC
    Are you planning on using the font characters for 'tiles' in the game? If so, you could accomplish the same thing by putting 4 8x8 characters together to make one 16x16 'block' on the screen (a lot of tile engines do that). You could even make 'larger' letters the same way without affecting the code. It would save from adding complexity into AIGeneric.

    I would think that if you were truly wanting a 22x13 font you would have to use a method similar to Graphics.spin instead of what is in AIGeneric. That way you could scale/rotate/etc. on the text.

    [noparse][[/noparse]Edit:] If you are going after a 'larger' display have you thought about just reducing the resolution (maybe 192X160 like the Hydra HEL engine)?· That would give you 'bigger' 8x8 characters, and it would be fairly fast to implement.· In 8x8 characters/tiles that would give you a 24 x 20 area to work with.·

    Post Edited (trodoss) : 10/13/2008 2:00:13 PM GMT
  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2008-10-13 14:04
    Reducing resolution should be the obvious answer, but I haven't located all the
    correct adjustments to make it work correctly.

    Using redefine in AiGeneric, this text driver becomes a nearly perfect platform
    for an easy game design.

    I'm thinking that something simple like this might promote a little more game
    creation around here. [noparse]:)[/noparse]

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    New to the Propeller?

    Getting started with a Propeller Protoboard?
    Check out: Introduction to the Proboard & Propeller Cookbook 1.4
    Updates to the Cookbook are now posted to: Propeller.warrantyvoid.us
    Got an SD card connected? - PropDOS
  • trodosstrodoss Posts: 577
    edited 2008-10-13 14:05
    @OBC

    I don't know if you will find it useful or not, but I put together a 'quick and dirty' program that can generate AIGeneric fonts from a bitmap.· I have been using it in a little game project I have been working on myself.· [noparse][[/noparse]Edit:] It might help someone if they wanted to define the tiles upfront (as an alternative to using 'redefine' in code).

    Usage:

    FontMaker.exe [noparse][[/noparse]input_bitmap_filename] [noparse][[/noparse]output_filename]
  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2008-10-13 14:06
    trodoss said...
    @OBC

    I don't know if you will find it useful or not, but I put together a 'quick and dirty' program that can generate AIGeneric fonts from a bitmap. I have been using it in a little game project I have been working on myself.

    Usage:

    FontMaker.exe [noparse][[/noparse]input_bitmap_filename] [noparse][[/noparse]output_filename]

    NICE! I will try this later today. [noparse]:)[/noparse]

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    New to the Propeller?

    Getting started with a Propeller Protoboard?
    Check out: Introduction to the Proboard & Propeller Cookbook 1.4
    Updates to the Cookbook are now posted to: Propeller.warrantyvoid.us
    Got an SD card connected? - PropDOS
  • trodosstrodoss Posts: 577
    edited 2008-10-13 14:16
    @OBC
    As far as adjusting the resolution, I might expirament with AiGeneric_Driver_TV to see what can be done by adjusting the timing, etc. I am sure someone more familiar with the code could accomplish it much faster/better, but it might be a good excuse for me to get my 'feet wet' and/or do some research in the Hydra book.

    Also, I highly agree that AIGeneric would be a great platform for learning about game programming.· Working with·the Prop·brings back fond memories of the TI-994A, and pouring over books like David Ahl's "BASIC Computer Games" (the "Creative Computing" magazine book).·[noparse][[/noparse]Edit:]·http://www.moorecad.com/classicbasic/index.html· <sigh!> Yep, I am officially "old" [noparse];)[/noparse]

    --Tro

    Post Edited (trodoss) : 10/13/2008 2:56:32 PM GMT
  • BaggersBaggers Posts: 3,019
    edited 2008-10-13 15:02
    OBC, my only concern about you using aigeneric for doing games is the face it doesn't do sprites, it might be better to get someone ( or me if you can wait til end of month as I have a demo for work to finish by end of month ) to do a C64 style display ( which is a mode I'm also doing on PropGFX, but the GFX Lite will have a lot more sprites [noparse]:D[/noparse] ) that has 256 chars + 4 colours each and 4x8 fat pixels ( to keep memory usage down ) and 8 * 12x21 4 colour sprites? ( or 24x21 2 colour )
    then people could redo C64 style games [noparse]:)[/noparse]

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    http://www.propgfx.co.uk/forum/·home of the PropGFX Lite

    ·
  • trodosstrodoss Posts: 577
    edited 2008-10-13 15:10
    @OBC
    I forgot to mention in my posting of the code that I was working with a 96 character font, instead of 128.· If you were going to 'test' it you would have to use all caps for the characters.· In order to do the full 128 just increase the size of the bitmap by 8 pixels, and add in the lower case letters.

    Just in case I sound like I am speaking jibberish, here is an edited .bmp that would work with both capital/lower case letters.
  • trodosstrodoss Posts: 577
    edited 2008-10-13 15:36
    @Baggers
    It sounds like you are creating similar (or an improvement on) the "DK" engine, used in Dodgy Kong, only with a lower resolution(?) and higher performance. Sounds like a great enginge though.· I was always a big fan of C64·games.··The GFX Lite·looks like it will come with a·wealth of code to show off what it can do. So would US buyers be able to order these in November?

    As far as sprites/collision detection/etc., those are great, but not always absolutely necessary (especially in 'simple' tile-based games). I would think a 'double buffered' display or page-swapping (to avoid 'flickering') would be about the extent that would be needed, but a sprite engine is certianly a "nice to have" when the user understands the concepts of sprites, collision detection, etc.· [noparse][[/noparse]Edit:] I will certianly be the first to admit my own ignorance of game programming.· I write the 'necessary evil' (business apps) for a living tongue.gif --oh, and "Post Icons" ... Silly things.· Took me forever to figure out how got get rid of the 'thumbs down' on it.· Definatly was my own ignorance, and not some sort of statement.

    Post Edited (trodoss) : 10/13/2008 4:28:56 PM GMT
  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2008-10-13 16:51
    Ultimate cool would be to grab sprites from sites like this
    and incorporate them easily into Propeller games.

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    New to the Propeller?

    Getting started with a Propeller Protoboard?
    Check out: Introduction to the Proboard & Propeller Cookbook 1.4
    Updates to the Cookbook are now posted to: Propeller.warrantyvoid.us
    Got an SD card connected? - PropDOS
  • trodosstrodoss Posts: 577
    edited 2008-10-13 17:22
    @OBC
    You could probably use some of the other tools that came with the Hydra book/CD and convert those to 'usable' sprites for a game, depending on what engine you use and tile size. Re: NES sprites - I think the NES pattern table was a series of 4-color 8x8 tiles that were 'constructed' in the games into 16x16, 16x32, etc. More 'space concious' than easy to work with. Wth the right coding both in spin/asm and PC-based (either with an existing NES tool like YY-Chr, or one you/someone creates for editing the pattern table(s)) you could probably take the existing Dodgy Kong engine and make a generic NES engine.· [noparse][[/noparse]Edit:] Or, as Baggers said, maybe wait for his C64 engine.· Sprites, scrolling, etc. are all possible if you can·execute 3D rendering [noparse];)[/noparse]

    Post Edited (trodoss) : 10/13/2008 9:32:02 PM GMT
  • Oldbitcollector (Jeff)Oldbitcollector (Jeff) Posts: 8,091
    edited 2008-10-14 20:23
    Proof again that enough monkeys with computers can generate working code...

    Attached is a version (AIGENERICcf) which is adjusted to 24x22. It is reasonably close for the purpose
    I have in mind. I figure someone might find it useful as well.

    OBC

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    New to the Propeller?

    Getting started with a Propeller Protoboard?
    Check out: Introduction to the Proboard & Propeller Cookbook 1.4
    Updates to the Cookbook are now posted to: Propeller.warrantyvoid.us
    Got an SD card connected? - PropDOS
  • trodosstrodoss Posts: 577
    edited 2008-10-14 21:14
    @OBC
    Very cool.· I would be one·such monkey who would find it useful [noparse];)[/noparse]
    ·
  • hippyhippy Posts: 1,981
    edited 2008-10-14 23:08
    @ OBC : Glad you got somewhere suitable and I'm sure it's been a lot quicker than I'd have managed ! Thanks to Baggers and trodoss for stepping up to the table.
Sign In or Register to comment.