@juen, post #121
; AGA copperbars by Coagulus (EAB) ; modified by Cylon (EAB) ; chg: added ecs support ( quick and dirty 😛 ) DEFTYPE.w InitPalette 0,256 BitMap 0,320,256,1 ;just 1 bplane needed! saves chipmem! Dim bar(32) ;saturation value (0-255) of bar y line Dim bary(3) ; 1-red 2-green 3-blue Dim baryt(3) Dim barydir(3) ;we create bars of 32pixl height: If CheckAGA Then fact.w=16 Else fact.w=1 For a=0 To 15 bar(a) = (a*fact) bar(a+15)= ((16-a)*fact) Next baryt(0)=-3 baryt(2)=3 barydir(0)=1 barydir(1)=1 barydir(2)=1 VWait 100 ;two seconds is enough before takin' the machine over BLITZ ;SpriteMode 2 ;not needed. ;1bitplane 24bit(256,256,256) aga coplist ;again: we use the copper only, so 1 bplane is enough. InitCopList 0,34,256,$10000|$01|$10|$400,8,1,-4 CreateDisplay 0 DisplayPalette 0,0 DisplayBitMap 0,0 Repeat VWait DisplayRainbow 0,0,0 InitPalette0,256 ;256 cols eq 256 lines vertical For a=0 To 2 bary(a) +baryt(a) baryt(a)+barydir(a) If QAbs(baryt(a)) = 13 Then barydir(a)=0-barydir(a) Next If CheckAGA For a=0 To 31 AGAPalRGB 0,32+a+bary(0),bar(a),0,0 AGAPalRGB 0,32+a+bary(1),0,bar(a),0 AGAPalRGB 0,32+a+bary(2),0,0,bar(a) Next Else For a=0 To 31 PalRGB 0,32+a+bary(0),bar(a),0,0 PalRGB 0,32+a+bary(1),0,bar(a),0 PalRGB 0,32+a+bary(2),0,0,bar(a) Next EndIf Until Joyb(0) OR Joyb(1) QAMIGA VWait50 End CloseEd ;eof
@tukinem, post #122
@juen, post #123
BitMap 0,320,256,1; tworzymy bitmape z jednym bitplanem InitPalette 0,1; tworzymy palete dla ekranu PalRGB 0,0,$0,$0,$0; przypisujemy kolor czarny dla koloru nr 0 InitCoplist 0,34,$1,8,1,-1; -1 to wiadomosc ze bedzie tworzony rainbow CreateDisplay 0 DisplayPalette 0,0 DisplayBitMap 0,0 PalRGB 1,100,15,15,15; będziesz mieć w 100 linii kolor biały DisplayRainbow 0,0,1; jako rainbow z paleta "linii ekranu" nr 1
@tukinem, post #124
@tukinem, post #130
@tukinem, post #132
@tukinem, post #132
The #agacolors flag must ALWAYS be set when more than 32 colours are in use or
when 24 bit color definition is required.
the new display library is also semi-compatible
with pre-AGA Amigas. CopLists can be created on ECS Amigas, however none of the AGA-specific flags
(i.e. super high-resolution or 128/256 colours), nor any of the AGA-specific commands may be used on
pre-AGA Amigas. You have been warned!
The INITCOPLIST statement can also be used to create non-AGA displays, however only low-resolution
sprites, single fetch mode, and a maximum of 64 colours are allowed:
@mastaszek, post #135
spróbuj próbnie ustawić taką malutką tęczę na 31 'kolorów' i zobacz czy pójdzie na 1.3 i czy to właśnie to jest problemem
@tukinem, post #122
#COP=0 #COLOR=0 WBStartup BitMap 0,320,256,1 InitPalette 0,2 BLITZ InitCopList #COP, 34,256,$1,8,2,-1 CreateDisplay 0 DisplayPalette 0,0 DisplayBitMap 0,0 Use BitMap 0 For a=0 To 254 DisplayRGB #COP, #COLOR, a, a/16, a/16 ,a/16 Next a DisplayRGB #COP, #COLOR, 254, 8,0,0 ; czerwone na koniec Repeat Until RawStatus($45) End
@c64portal, post #138
@c64portal, post #139
@pisklak, post #142
nie powinno być InitPalette #COLOR,2
#COP=0 #COLOR=0 WBStartup BLITZ InitCopList #COP, 34,256,$1,8,2,-1 CreateDisplay 0 Use BitMap 0 For a=0 To 254 DisplayRGB #COP, #COLOR, a, a/16, a/16 ,a/16 Next a DisplayRGB #COP, #COLOR, 254, 8,0,0 ; czerwone na koniec Repeat Until RawStatus($45) End
@c64portal, post #143
@tukinem, post #144
@tukinem, post #145
If CheckAGA aga=16 Else aga=1 Endif ... DisplayRGB 0,0,#NR_LINII,$F*aga,$C*aga,8*aga VWait
@c64portal, post #143