15 December 2017, 23:37 | #41 |
Registered User
Join Date: Jan 2014
Location: Belgrade / Serbia
Age: 41
Posts: 1,004
|
AGA Hi-res overscan and Color Cycling
Is flag $100 in initcoplist everything that is needed to open hi-res screen?
I get the black screen with the code beneath. If I leave out $100 half of the picture is displayed. And the color cycling cycles only through first 16? colors, it doesn't do the full cycle. Does CyclePalette supports AGA at all? And has anyone fiddled with this cycling. I did before and as I remember I had to use DPaint 3 cause as I noticed CycleColor reads only CCRT chunk and won't read CRNG. Code:
BitMap 0,720,282,8:LoadBitMap 0,"boot.iff",0 InitCopList 0,13,282,$10108,8,256,0 DisplayBitMap 0,0 BitMapOutput 0 VWait 50 BLITZ CreateDisplay 0 Repeat VWait DisplayPalette 0,0 CyclePalette 0 Until Joyb(0) End Hm.. I can open hi-res screen with 4 bitplanes. Everything above opens black screen. Last edited by Cobe; 16 December 2017 at 00:45. |
16 December 2017, 01:30 | #42 |
Registered User
Join Date: Jun 2009
Location: Dublin, then Glasgow
Posts: 6,343
|
4 bitplanes in high resolution is the limit of ECS... It looks like you're not using a high enough fetch mode. Try adding a $1000 flag to the InitCoplist line and see if it helps. There's something funky about initialising bitmaps in Blitz as they need to be 32-bit or 64-bit aligned for the higher fetch modes. See if it works anyway...
|
16 December 2017, 01:59 | #43 |
Registered User
Join Date: Jan 2014
Location: Belgrade / Serbia
Age: 41
Posts: 1,004
|
$1000 works! But if pic is not wider then 640.. If it is than its appropriately scrambled in all fetch modes. I guess now I have to use displayadjust... easier said than done...
But it still doesnt cycle all colors... |
16 December 2017, 19:05 | #44 |
Registered User
Join Date: Jan 2014
Location: Cambs / UK
Posts: 356
|
Does anyone know how to detect the available chipram in Blitz?
Last edited by gazj82; 16 December 2017 at 19:12. |
16 December 2017, 19:30 | #45 |
Gets there in the end...
Join Date: Sep 2005
Location: Wales
Posts: 863
|
|
16 December 2017, 21:05 | #46 |
Registered User
Join Date: Jan 2014
Location: Cambs / UK
Posts: 356
|
|
11 January 2018, 10:18 | #47 |
Registered User
Join Date: Dec 2017
Location: Poland
Age: 47
Posts: 282
|
Since the title says: Blitz Basic Questions so I'm sure mine fits in here.
I just decided to give it a try and installed BlitzBasic2 few days ago. Found some examples to learn faster but there are few (eg. BlitzAndPieces on Aminet) that do not run (I get: TYPE NOT FOUND error) For example: Code:
; jamesboyd@all-hail.freeserve.co.uk ; lists open public screens Dim scr$(500) ; just to be on the safe side ;) *scrs.List=LockPubScreenList_ () ; lock all screens *mynode.Node=*scrs\lh_Head ; list o' screens count.w=0 While *mynode\ln_Succ count+1 scr$(count)=Peek$(*mynode\ln_Name) ; screen name *mynode=*mynode\ln_Succ Wend UnlockPubScreenList_ ; unlock screens For a=1 To count ; list 'em NPrint scr$(a) Next a MouseWait End Thanks. |
11 January 2018, 12:57 | #48 |
Registered User
Join Date: Jun 2009
Location: Dublin, then Glasgow
Posts: 6,343
|
Type not found means there's a Newtype definition missing. These are essentially the same as structs in C, and are used extensively when using the OS directly, including the .List and .Node types that this example uses. The structs for most OS purposes are already defined and stored in an external "resident" file, which means you just have to add that file to your compiler settings and all those definitions will automatically be available. To do this:
- Open Compiler settings (or Compiler options, depending on your editor) - Enter a new line in the Residents list containing Blitzlibs:amigalibs.res Save your file, recompile and it should work. If it doesn't work, there may be some other definitions file that you're missing, but that should be documented in the readme for the source. |
11 January 2018, 13:19 | #49 |
Registered User
Join Date: Dec 2017
Location: Poland
Age: 47
Posts: 282
|
Thank you. That worked.
Is there a way to make the Resident List permanetnt? (I'm using blitzBasic2 <release 2.1> and everytime I open the program and enter Compiler Options, the Residents List is empty) EDIT OK, I have it Just need to save what is in editor as *.bb2 Thanks |
11 January 2018, 14:46 | #50 |
Registered User
Join Date: Jun 2009
Location: Dublin, then Glasgow
Posts: 6,343
|
Yep, the Residents list (and other things like Debugger settings etc.) are saved along with a project, where .bb2 is the source and .xtra is the settings. So if you're moving the source file, just remember to move the matching .xtra file too and it will keep the same settings.
|
11 January 2018, 21:03 | #51 |
Banana
Join Date: Jul 2016
Location: Darmstadt
Posts: 1,214
|
BlitColl - I thought it could be set for odd or even colours but I can't find anything about it in the user manual. Any hints? Am I better off creating a 1-bitplane bitmap of the colour I want to check and using that?
|
11 January 2018, 22:13 | #52 |
Registered User
Join Date: Jun 2009
Location: Dublin, then Glasgow
Posts: 6,343
|
Yep, that might be a better way of doing it alright, if you can afford the extra blitting time. As far as I'm aware it's only sprite collisions that can be set to trigger on odd colours.
|
12 January 2018, 18:39 | #53 |
Registered User
Join Date: Dec 2017
Location: Poland
Age: 47
Posts: 282
|
|
12 January 2018, 21:29 | #54 |
Registered User
Join Date: Dec 2017
Location: Poland
Age: 47
Posts: 282
|
Just another question:
is there a way to stop such program: Code:
Repeat WaitEvent Forever Pressing STOP in debugger window does nothing. Choosing QUIT from menu -> same as above Only PANIC button seems to work but then I just cannot close debugger window (and Blitz's CLI window on WB screen stays there forever) - and I get Guru after a moment |
13 January 2018, 14:16 | #55 |
Registered User
Join Date: Jun 2009
Location: Dublin, then Glasgow
Posts: 6,343
|
For your first question, the screens missing from the list probably aren't public - it wouldn't make sense to let other programs open their windows on screens that might need to be closed again soon, or where all the pens are used up, as in Multiview's case. Private screens won't show up on the public screens list.
And the second question - the program is stuck at the WaitEvent command and isn't actually running, which is why the debugger can't stop it. WaitEvent suspends the program and waits for an event from the OS, so if there's a window on your program, you can trigger an event by clicking a gadget, moving it, whatever, and then the Stop from the debugger will take effect. Without that however, it's a dead process and you can't do much about it. |
13 January 2018, 16:40 | #56 |
Registered User
Join Date: Sep 2007
Location: Stockholm
Posts: 4,334
|
It makes sense to use e=Event() instead of WaitEvent inside the loop until you've made sure your event handling actually works. Don't keep it that way, though, since it will eat up CPU cycles.
|
13 January 2018, 16:54 | #57 |
Registered User
Join Date: Dec 2017
Location: Poland
Age: 47
Posts: 282
|
Thank you for the explanation - I do appreciate it.
|
13 January 2018, 17:00 | #58 | |
Registered User
Join Date: Dec 2017
Location: Poland
Age: 47
Posts: 282
|
Quote:
Thanks |
|
13 January 2018, 17:10 | #59 |
Registered User
Join Date: Dec 2017
Location: Poland
Age: 47
Posts: 282
|
and.. me again.
Just checking some examples and again there is something I don't understand. I found something like this: Code:
... *IntuiBase = OpenLibrary_( ?INTUITION,36) .... .... .... Even INTUITION Dc.b "intuition.library",0,0 .... Could you explain to me what all that "magic" in original version means? Thanks. |
14 January 2018, 03:11 | #60 |
Registered User
Join Date: Sep 2007
Location: Stockholm
Posts: 4,334
|
The "magic" is an assembler directive that stores the string "intuition.library" followed by a terminating zero. The location is given the label "INTUITION".
In Blitz, the question mark operator gives the address of a label. Since it worked for you with a plain string literal instead, the only technical reason I can think of doing it this way is that earlier Blitz versions didn't terminate strings with a zero, which is expected by the OS calls. (Oh, and Even means that the label starts at an even address (on a 16-bit boundary). This is needed for a lot of 68000 instructions.) |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Blitz basic 2 Help | Havie | Coders. Blitz Basic | 30 | 08 September 2013 09:15 |
blitz basic | petza | request.Apps | 11 | 08 April 2007 01:49 |
Blitz Basic 2 anyone? | jobro | request.Apps | 12 | 28 November 2005 18:15 |
Blitz Basic StopCD32 | Tony Landais | Coders. General | 2 | 08 May 2003 22:51 |
Blitz Basic 2 | LaundroMat | Retrogaming General Discussion | 5 | 24 July 2001 08:10 |
|
|