Amiga Video Programming
16 messages in this thread
Yes, but if I know how to write a single pixel ( fast ) then I'll know how to
do linedraws, bitblts, animation etc… Basically I'm trying to determine if I
can paint a screen with an Amiga 4000 faster than I can with a 486-66 PC.
Larry,
In the Amiga, knowing how to write a single pixel (fast) won't give you
ANY clue about how best to bltblt. There's a built in bit blitter.
Yep, that's what I found out. Guess I'm going to have to find some docs.
Larry,
The graphics/intuition libraries provides a whole bunch of functions to aid
drawing things, such as pixels, lines, rectangles, circles, ellipses, arbitrary
polygons, text, bitmaps, etc. There are even system calls to do animations,
although I've not used them myself. Most of these do clipping, so you do not
have to worry about going off the screen, although it is poss to disable the
clipping to gain some speed. I suspect that PCs have clipping code in the app
and that drawing off the screen is an unhealthy thing ?
Of these operations, writing pixels is probably one of the slowest, whereas
on the PC it is one of the fastest (largely due to the difference in the way
PCs and Amigas store their bitmaps). As you move to larger objects, the
pendulum swings the other way, as the Amigas bitplane architecture becomes more
efficient, and the Amiga can farm the requests off to the graphics hardware.
The multitasking nature of the machine means that the processor is free to be
calculating the coords of the next object *while the previous one is still
being drawn*. Of course, if the program calculates all the positions, *then*
draws them all, it will take less advantage of this ability.
Techies like argue incessantly over the difference between chunky (PC) arch,
and bitmap (Amiga) architecture. They both have advantages depending on what
you are trying to do.
Steve the G. [BEDFORDSHIRE, UK]
Also, since the screen address don't change on the PC, you can't double
buffer the whole screen since it's not going to draw it fast enough. To make
matters worse, you can't even check what scanline the video beam is currently
drawing! Well, you can sorta do it, but the code will break on some SVGA cards
(like IBM XGA and XGA-II… If you write directly to the hardware, your code
will break on these! In fact, you can't even write directly to the DAC's to
change the palette on these 2 beasts!).
There are some very cool ways to handle the bank switch's in SVGA using the
386 & 486 hardware. To make it short, you can use the 386 the same way they use
the 386 to do virtual memory! If the pixel you write to is not switched in, you
can have the hardware generate a exception. You handle the exception and do the
VESA bank switch. This eliminates all the checks you must do while drawing to a
SVGA screen! Very fast! However, you need to run in protected mode… You need
the FULL implementation of a DOS EXTENDER like Rational or Pharlap. The free
one (like Rational with Watcom 386) wont handle it! This will break your code
in a OS/2 DOS box though 😉 -Troy
What I'm trying to do is decide what platform I'm going to develop a VR idea I
have on. It'll be for my own amusement and a not for sale program. I have much
PC programming experience and keep noticing a lot of the VR systems use Amigas.
I have a TI 34020 board and it is very fast. But I'm wondering if an Amiga 4000
would give me equal or greater speed. Since I can guy a 4000 cheaper than a
486-66 with a 34020 board.
Larry, if you were going to buy a 486 with a 34020 board, wouldn't you get a
50mhz instead of a 66 since the chip doubled 66's bus only runs at 33mhz and
the 50mhz bus would be faster?
-Troy
Well no. I've tested 50DX machines compared to 66DX2's and for video the DX is
not much if any faster. The problem you face on a PC is the I/O bus channel and
not processor speed. When you go through the bus controller you run into the
bottle neck.
Larry, Thats what I said! The 50mhz DX has a faster bus than the 66mhz DX2's
33mhz bus speed! The chip doubled (DX2 chips) double the processor speed, the
bus runs at 1/2 the speed (DX2 @ 66mhz has a 33mhz bus, DX @ 50 mhz have a
50mhz bus)! I think were both on the same side 😉
-Troy
No, don't think we are. The 50DX has a 50 Mhz local memory bus. This talks
directly to the cache controller and the system ram. But, a video card plugs
into the expansion bus. Which has the Bus Controller chipset between the CPU
and the card. This is where you loose your speed. Unless you have a "local bus"
style design where the video card is addressed off of the local CPU memory bus
( which bypasses the bus controller ) devices in the expansion slots are
slower. I have done the tests with a 50DX LB system compared to a 486-66 DX2
EISA video card and the 66 wins overall.
I was assuming local bus video since it's just about standard on your high end
PC's. There are 34020 local bus cards! Real fast.
-Troy
Really? Gee, I didn't even know about the LB 020's. Haven't been keeping up
with LB I guess. Now I've got to get one of those! I love the 34020.
It's REAL FAST! There are some bugs in the Windows driver we have though.
Have you ever programmed a 34020? I haven't…
-Troy
Yes, I've programmed the 34020. Direct and via the Tiga interface.
I don't suppose there really is a definitive answer. I guess it would have to
come down to finding some people who already have these machines, and getting
some tests run.
Steve the G. [BEDFORDSHIRE, UK]