Skip to content

JazzCoder1/tb_Mode7

Repository files navigation

twinBASIC implementation of Mode7

What is Mode7

Mode 7 is a graphics mode introduced with the Super Nintendo Entertainment System (SNES). It allows a single background layer to be rotated and scaled on a scanline-by-scanline basis, creating effects like perspective and depth. This technique simulates a 3D environment on a 2D platform, making it revolutionary for its time. It was widely used in games like Super Mario Kart and Final Fantasy VI to create immersive and dynamic visuals.

twinBASIC implementation

Years ago I saw the code for how to achieve Mode7 graphics effects in a c programming language tutorial.
I have since ported that code to just about every flavor of BASIC.
This is the twinBASIC port.

screenshot

There are 2 methods used in this repository.

The first uses good old DIBits.
There are both 32 and 64 bit source files.

Next, in the DX folder, is a DirectX9 version.
The DX version runs slightly faster than the DIBits version.

Neither DIBits nor DX, 32-bit or 64-bit, run fast enough to be practical when compiled with the Beta builds of twinBASIC.
Once twinBASIC gets the LLVM running, I hope for an increase of 15x in speed from what it is doing today (BETA build 744).
That would put twinBASIC on par with other BASICs that compile to optimized native machine code.
The folks writing business applications do not need this type of speed, but other genres (like games) do ;-).

License

This twinBASIC implementation uses the UnLicense.

What is twinBASIC

twinBASIC is a new BASIC language compiler that strives to be 100% compatible with Visual Basic 6 (and VBA).
Check it out here: https://twinbasic.com/ and here: https://github.com/twinbasic/

About

twinBASIC implementation of the graphics technique Mode7

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors