Image Map Image Map
View RSS Feed

All Blog Entries

  1. CGA Text Blit

    I went back and forth over whether or not to write my own text rendering routine in assembler. DOS supplies a decent print string function [1] but it turned out to be insufficient to my needs. My requirements include the ability to change color mid-stream as well as repeat lines of pixel data twice to create a "large" font. Here's a screenshot from a test of the C functions I created back in January:

    Click image for larger version. 

Name:	fonts-testcga.jpg 
Views:	25 
Size:	30.4 KB 
ID:	39886

    There were three functions ...
    Tags: bios, cga, x86 Add / Edit Tags
  2. PICKUPS 13: Video Games + Stuff | It's a Pixel THING - Ep. 122

    Let's take a look at 20 video games + related stuff that I managed to grab during the last 2 months! There's stuff for the PlayStation 4, PC, PlayStation 3, Xbox 360, PlayStation 2 and the original Xbox!

    PICKUPS 13: Video Games + Stuff | It's a Pixel THING - Ep. 122
  3. Variable FPS Animation with DDA

    I just finished writing some code to animate movement and turning. When initially planning to tackled this task I was going to make a lot of assumptions and fix the framerate regardless of the computer speed. This would mean that on fast-enough computers the animation would run as expected but on slower computers it would slow down. Of course, once I started down this path I immediately didn't like it and decided to delve into writing something that would adjust the FPS [1] depending on how much ...
    Tags: bresenham, math Add / Edit Tags
  4. IDIV and IMUL do not set Sign Flag

    Or more specifically:

    The CF, OF, SF, ZF, AF, and PF flags are undefined.
    What it comes down to is that you cannot safely jump (JS / JNS) based on a signed multiply or divide.

    MOV AX, FF00	;
    CWD		; DX:AX = -256
    MOV BX, 0012	; BX = +18
    IDIV	BX	;
    JNS	$+4	; WRONG!
    NEG	AX	; AX = ABS(DX:AX / BX)
    The fix is to re-test the highest byte of the result (DH, AH or AL depending ...):

    MOV AX, FF00	;

    Updated July 11th, 2017 at 08:15 AM by neilobremski (Corrected mistakes identified by Krille)

  5. My Top 10 AMIGA EXCLUSIVES | It's a Pixel THING - Ep. 121

    The Amiga was home of many mind-blowing exclusives, in so many different genres! Here’s my Top 10 choices that all gamers should try at least once in their lives!

    My Top 10 AMIGA EXCLUSIVES | It's a Pixel THING - Ep. 121
Page 4 of 101 FirstFirst 123456781454 ... LastLast