Search found 217 matches
- Fri 30 May, 2008 10:39 pm
- Forum: Programming Help
- Topic: [TI-ASM] Memory allocation and management
- Replies: 27
- Views: 20648
So then, allocate 1024+256 bytes, then have the Update routine just move the data, or should it just recalculate the data? I have it check where the memory was allocated and then it InsertMem's any required padding bytes. Moving/recalculating is trivial enough - this is not something which is time ...
- Fri 30 May, 2008 8:50 pm
- Forum: Programming Help
- Topic: [TI-ASM] Memory allocation and management
- Replies: 27
- Views: 20648
Unfortunately, yes - it needs to be contiguous. Actually, it also needs to be 256 byte aligned, so 255 times out of 256 I'll have to allocate even more than that :P I might just add a routine the user can call to valid the ram if they muck around with vars, and it can update its internal pointers as...
- Fri 30 May, 2008 9:07 am
- Forum: Programming Help
- Topic: [TI-ASM] Memory allocation and management
- Replies: 27
- Views: 20648
[TI-ASM] Memory allocation and management
I'm not too up to speed on the way TI-OS handles memory, so maybe one of the gurus can help me out with this one. I'm porting Aether to run as a flash library, and I'd like to be able to allocate the ~1kb I need for dynamically generated tables, etc, rather than forcing the program to do it to avoid...
- Fri 30 May, 2008 8:39 am
- Forum: Aether 3D
- Topic: Progress Thread - New demo - Cobra Mk III (18-May-08)
- Replies: 319
- Views: 367425
I've just had my first success running the library as a flash library. All it did was load the identity matrix, but it worked :) The loading code is pretty small - the program has to look-up the application using _FindApp and then set the ROM page by outputting to port 6. It's about 40 bytes of &quo...
- Thu 29 May, 2008 9:08 am
- Forum: Programming Help
- Topic: [TI ASM] Useful routines.
- Replies: 50
- Views: 59299
- Wed 28 May, 2008 10:36 am
- Forum: Programming Help
- Topic: [TI ASM] Useful routines.
- Replies: 50
- Views: 59299
- Wed 28 May, 2008 10:06 am
- Forum: Programming Help
- Topic: [TI ASM] Useful routines.
- Replies: 50
- Views: 59299
Here's a routine (well, a small set of routines) to perform a cross-fade between two images. It works by comparing the two images to see which bits need to be changed, and then randomly flips these bits until the image has been completed. It's not as fast as I would like - an image which needs every...
- Sun 25 May, 2008 9:57 am
- Forum: Programming Help
- Topic: [ASM] Compare 16-bit registers?
- Replies: 27
- Views: 36904
Is using IXH and IXL worth the huge overhead? I haven't timed it, but is pushing and popping other registers faster? Surprisingly, no. In my situation, I need to preserve all registers except A (otherwise I wouldn't be using IX to begin with!). First, my code: ld a, ixl ; [8] cpl ; [4] add a, c ; [...
- Sun 25 May, 2008 9:08 am
- Forum: Super Mario - and the Elemental Crystal
- Topic: Project Discussion
- Replies: 35
- Views: 85885
- Sun 25 May, 2008 7:04 am
- Forum: Aether 3D
- Topic: Progress Thread - New demo - Cobra Mk III (18-May-08)
- Replies: 319
- Views: 367425
This looks a lot more professional already than many old PC games. :) Screenshot - first half with stars on, second half with stars off How come stars cause such a performance hit? Partially because I'm lazy, and partially because there's still a lot work to do even just to display a point. There a...
- Sun 25 May, 2008 6:28 am
- Forum: Programming Help
- Topic: [ASM] Compare 16-bit registers?
- Replies: 27
- Views: 36904
Sorry for the necropost, but I've stumbled on a cool trick for doing comparisons byte-by-byte. It doesn't work exactly like CP, but is very useful when you are short on registers. I came up with this for comparing against IX (which has no SBC instruction), but it can modified easily enough. ld a, ix...
- Sun 25 May, 2008 2:29 am
- Forum: Aether 3D
- Topic: Progress Thread - New demo - Cobra Mk III (18-May-08)
- Replies: 319
- Views: 367425
- Sat 24 May, 2008 10:12 am
- Forum: Aether 3D
- Topic: Progress Thread - New demo - Cobra Mk III (18-May-08)
- Replies: 319
- Views: 367425
I was doing some work today and deleted some code I shouldn't have, but it did produce a pretty cool screenshot :) One of the techniques I am using to pick up some speed with sending data to the LCD is to keep two buffers - one for the current frame, and one for the last - and only send the bytes wh...
- Fri 23 May, 2008 7:50 am
- Forum: Aether 3D
- Topic: Progress Thread - New demo - Cobra Mk III (18-May-08)
- Replies: 319
- Views: 367425
I just rotate the value right one place and mask out the two lowest bits to give a byte offset into the pattern array. Does it look worse if you don’t mask out the last two bits? I can imagine that a clever dither pattern could allow achieving finer shades that way. That's not a bad idea! Wh...