English Amiga Board


Go Back   English Amiga Board > Coders > Coders. General

 
 
Thread Tools
Old 17 May 2009, 23:29   #1
Franz Bazarov
Resident Mad Scientist
 
Franz Bazarov's Avatar
 
Join Date: Apr 2009
Location: Land of Thomas Edison's Tortured Ghost, NJ
Posts: 24
Hardware Lines or a Tiled Bitmap? - Which Method is the Fastest When Making a Grid?

On AmigaOS 3.x, with original hardware, is it faster (at the machine level) to draw the actual lines themselves, or is it faster to tile a bitmap of a suitably pixel-stroked square, if one wanted to make a full-screen grid very quickly?

Reasons for both methods would be helpful.

Alternately, would it just be faster to load & display a full background image of a previously prepared full grid image?

Thanks!
Franz Bazarov is offline  
Old 18 May 2009, 00:55   #2
Zetr0
Ya' like it Retr0?
 
Zetr0's Avatar
 
Join Date: Jul 2005
Location: United Kingdom
Age: 49
Posts: 9,768
I would say that using a small 2 bitplane tile for the grid would be the best, keeping the size divisible by 8 and use the blitter to slap (thats BlitBitMask) it to the background bitmap.

I would sugest this for a basic unexpanded 020 or lower (even with fast ram), however with an 030 CPU it would probably quicker to write the whole lot to a Screen Bitmap in fast ram and then just blast it to the current screen rasta bitmap.
Zetr0 is offline  
Old 18 May 2009, 02:48   #3
Leffmann
 
Join Date: Jul 2008
Location: Sweden
Posts: 2,269
You can get a grid on the screen virtually free as far as processing time goes, but it requires some hardware poking and is less flexible, and I'm assuming you will want to show some bitmap graphics on top of the grid as well.

Typically you will clear the whole bitmap when you redraw the graphics, and since copying with the blitter is just as fast as clearing alone you can just copy a prepared full screen grid in one go into the bitmap every time you want to change the graphics. This is flexible and straight forward, but it requires that your other graphics is drawn with respect to the grid, which can be slower than drawing with the assumption that the bitmap is clear.

You can also allocate 1 bitplane for the grid alone and use the other bitplanes for the graphics, and you won't need to redraw the grid or consider it when drawing the graphics.

What the fastest method is depends on what you want to show on top of the grid really.
Leffmann is offline  
Old 18 May 2009, 04:06   #4
Franz Bazarov
Resident Mad Scientist
 
Franz Bazarov's Avatar
 
Join Date: Apr 2009
Location: Land of Thomas Edison's Tortured Ghost, NJ
Posts: 24
Thanks!

Basically, I want to prepare a number of monochromatic vector grids.

The background being a straight 2D grid, and the foreground being comprised of multiple perspective-shifted grids going off to a point on the horizon.

I want to set it up so that you can see through the grids with transparency, to give an illusion of huge depth. I'm planing on using dual playfields.

None of this will be texture mapped, it will appear like old school vector graphics (Tempest, Batttlezone, etc), meaning just lines in a 2D space (but projected to give an illusion of 3D space). Should perform well.

Other than that, alpha-numeric data & sprites will be in the foreground.

Once this display is setup, I want to be able to control small areas of the screen with borderless terrain generated polygonal or line-oriented mountains as seen on the Fairlight CMI Page D & Joy Division "Unknown Pleasures" album.

I want to maintain a very retro vector feel to the whole thing, but use various LED styled fonts in conjunction with a vector style engineering font that I've created.

As of now the fonts are Truetype, I'm going to look into a converter if needed, or else some static ones will be represented with bitmaps & the dynamic ones will be native Amiga.

There will be movement on some perspective grids, similar to the game "Ballblazer" on the Atari 8-bit, but it will be vector-style, not checkered.

That's about it. I'm thinking that I might do a combination of the three methods, when animation is necessary.

I'm doing some testing of prepared grid squares following the powers of two, from 4x4 through 1024x1024 to test fixed stepping zooms. Looks pretty cool!
Franz Bazarov is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
3 button alfa data optical grid mouse athiga Hardware mods 16 23 March 2016 03:42
Hardware Idea: Making use of microcode to improve 68k emulation performance HenryCase Amiga scene 5 24 December 2011 11:11
Grid Start 3 s2325 HOL contributions 0 18 March 2010 03:39
[Found: Simulcra] A 3D game with a triangle spaceship in a black grid world Wuigi Looking for a game name ? 3 27 December 2009 22:58
Best capture method DJ_OXyGeNe_9 project.Amiga Demo DVD 16 11 May 2009 23:28

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 11:53.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.07035 seconds with 15 queries