The big review

Post your FreeBASIC source, examples, tips and tricks here. Please don’t post code without including an explanation.
Post Reply
Tourist Trap
Posts: 2958
Joined: Jun 02, 2015 16:24

The big review

Post by Tourist Trap »

The big review
Tips&Tricks section snapshot at Aug.2016, sorted by author names. I think it can be useful here because tips and tricks are a source of enlightement even at page 65.

Note: Tool written in freebasic to get the whole list joined at the very bottom.

2
Hey,this is a really cool trick with negative powers of 2!
1000101
[3] Fast multi-threaded synchronization constructs
Runtime Code Generation or Just Some Hax
Win32\Dos\Linux (to come) Clipboard module
Pixel-Perfect Collision Detection
Detecting Windows NT/Wine from code.
Win32 ThreadControl function
Simple Rational Class (Warning: Code dump)
Preliminary graphics library benchmarking
Aligned allocation functions
CPUID Class - Final Release?
memrep - memset for non byte values
ExEvent - Extended ScreenEvent
Fun with the preproc (warning, contains explicit language)
Curious benchmark results
pseudo-oo
Approximate Equallity
Graphics Memory Manager
Bit Arrays
~~mic~~ASM: cast float to unsigned longint
~~mic~~DEF SEG + PEEK/POKE hack
~~mic~~Procedural infinite heightmap generator
~~mic~~Demostration of finding the angle of an arc
~~mic~~Put function that does simple transformations
~~mic~~Working with playing cards
~~mic~~String split function
~~mic~~BMP "Depalettiser"
~~mic~~Variant-like variables
~~mic~~SDLNet TCP Example
~~mic~~Uniscribe header & example
~~mic~~Associativity and commutativity
~~mic~~QB-like ASCII table
~~mic~~Simple code-simplifying helper for instr()
~~mic~~Find the signed/unsigned equivalent of an integer type
~~mic~~Averaging packed values in an integer
~~mic~~Basic ZLib usage
~~mic~~ASSERT with failure message
~~mic~~Work out how long statements take to perform
~~mic~~ASM Code
~~mic~~Yagl! - A demo
~~mic~~ON TIMER substitute
~~mic~~PNG SCREENshot function
~~mic~~Crack and getCracked string manipulation
~~mic~~100% QB-compatible rnd function
~~mic~~Importing C libraries to a namespace
~~mic~~Displaying a Double with arbitrary precision
~~mic~~FreeBASIC CRC32
~~mic~~Bin2Bas
~~mic~~Cool easy game trainer load screen
AaveOpenGL Skybox
abc123How to make your own SCREENSAVER!
acetoline
Antialiased Bezier Curves
Antialiased Circles
Complex Numbers
adhay
A general string sort enhancement
fb_poker
on randomness
Adigun A. Polack
Warning! Squadrons of pixel craft are heading towards FB!!
Detect the first 4 joystick buttons in GFXlib 2 clearly!
Aeras
I need help with my program with freebasic
I can't get my logo to move around.
aetherFox
Palette effect using Allegro
agamemnus
The Qsort To End All Qsorts!
Common "2nd-level" string manipulations
Snippet: average the RGBA values of two uintegers.
"Screensaver"
Enforced "type aliases"
Decimal places limit / limiter
Never segfault due to changing types again!: callocateFull
dimFull: a macro for when you aren't sure of the type.
getId function for sorted arrays
Converting concave polygons to triangles in Freebasic
Read-only variables discussion
Creating an fb.image pointer "array" dynamically.
Reverse RGBA / rgb
line / line segment intersection function
DIRS().. fills an array with file names.
AGS
Commandline handling
scintilla editing component/widget (new iup widget)
Deductive database (datalog)
Pseudo random number generator
Using Python as a database (in-memory and on disk) package
Replacing select case with binary search (many large ranges)
find character class of char using xlat (inline asm)
Tile-based scrolling (uses SDL library)
Setting up bi - directional communcation between processes
Level order traversal of binary search tree (queueless)
treap ('balanced' binary search tree)
Debugging using a widget instead of PRINT statements
FreeBASIC keyword recognizer (using trie nor hashtable)
Searching UTF-8 encoded text using fb port of instr
S expressions (recursion)
Displaying values of an array using a html table
Regular expression example (uses pcre library)
Using bsearch to search a sorted array
Using tree rotations to destroy a binary search tree
mathematical expression parser (operator precedence parser)
Simple declaration 'parser'
drag-n-drop demo (simple drawing program)
Computed Goto (using labels as values/inline assembler)
FB version mkd(byval number as double)
Creating/writing/reading python objects using freebasic
bitarray
UTF-8 encoded byte stream validation
Redirecting stdin/out/err of child process (uses WIN32 API)
bittree (a tree based implementation of a dictionary)
Comb sort (bubble sort on steroids)
File Buffering (user defined file buffer)
Hash table generator
Getting input from user using a simple GUI (IUP/LUA/FB)
Multi line comment without using /' ... '/
Red-black tree (self-balancing binary search tree)
Optimizing code using the gcc back end (-gen gcc -O 2)
Comparing strings four characters at a time
Word completion/string completion (using a dictionary)
Includer-->includee dependency analyser
WStrPtr
GUI example using JAPI (uses JAVA)
Geany (an IDE) scripting examples
Creating, saving and reloading an in-memory Sqlite database
A 4 MB function (built using 572 bytes of FB source code)
Command line handling (arguments can appear in any order)
UTF16 macros (usable with WString indexing)
Using a sqlite table as a hashtable (indexed/in-memory db)
Converting UTF8 (unicode) to UTF32
Hacking the Insight debugger (can be used for FB debugging)
Attempt at implementing inheritance in FreeBASIC
Using dylibsymbol instead of import libraries (.dll.a)
Case InSeNsItIvE version of Instr
Fast string searching
Dictionary (programmed using a trie datastructure)
Reserved keyword recognizer
FreeBASIC versus Python (speed of execution)
al1979
incany.bi
albert
4 bouncing balls
Fast Decimal Multiplier
my first drawing program
Floating point math
aleofjax
Processor Friendly Frame Limiter
alfakilo
game scripting
Simple OpenGL shader example
display text in opengl
simple chatbot
Simple Chat
AK tic-tac-toe with AI
OpenGl road
billiard style ball movement
RTS GAME
Midi pianoroll
aloberoger
vb form to fb
AMIBCT
Ultra-Fast Directory Search
Amundo
Traverse Windows Registry Keys
Andec
Change Windows cursor shape in console programs
Andrew Collins
CHR$() codes
AndT
Who can hack this? (Don't modify the code :p)
How i use RND for cool effects..
A simple Filepack / extract routine with a costum container
A debugging method for subs :)
Beatbox with windows messagebox
A simple Applicationprotector (Freebasic only)
A simple 3D render method
Simple grass textrure rendering
angros47
GLSL shader for post processing in FBGX
animated toroid in OpenB3D
Fire effect in pure FB
Infinite sprites in pure FreeBasic
Some fun with munching squares
Metaballs: blobs of goo
3d animated tunnel in pure FB
Convolution filter(smoothing, sharpening...) in OpenGL
Blur shadows with OpenB3D
Multiple graphic windows
Xforms GUI Toolkit
Toast Projection
Fast sine approxymation
Butterworth filter
Convolution high and low pass filters
Zelda - A link to the past map
2d sprites in OpenGL
Voxel sprites
Triple horizontal resolution with subpixels
Parallax scrolling in less than 100 lines
Neural net
Multi-lingual Chatbot
A little quiz (optimizing branches)
2d on 3d (in OpenB3d)
Road for a racing game
Drive a Lamborghini in FreeBasic
Visit Dystopia city
Procedural 3d tree
Alien insects!
Voronoi diagrams
PUT behind background
3d city
3D mouse pointer in 3d space
Fading and trail effects
Pseudo 3D by Mode 7 simulation
A very simple tile engine
Simplest Chess game
Transformation matrix on 2D images
Some sprites from a never-released QB game
Hopalong
Simple planet texture
Road drawing system, similar to SimCity
An alien face stares at you!
MikMod headers translated to FreeBasic
Unzip
Detect wheter FreeBasic or QBasic is used
Emulating the SHARED command in subroutines
WAV files by the speaker
FreeBasic interpreter?
Random maze generator: simplest way
Turtle Graphics
antarman
zx spectrum screen emulator
Antoni
Merge Sort
Play single midi notes
HSV Colorspace
REplace chars from a string
Mouse interface for console programs
Put and get n bits from a buffer
Message box for windows batch files
COM black magic (not mine)
Convex hull
Permutations
Delayed startup of applications
GFX_NULL driver in GFXLIB
Draw a Bounding box with the mouse
Build a html photo book
Write text to console while in Gfx mode.
BMP Palette organiser
Console size is not fixed...
Compiler version control
arenth
A long and contrived spawn process example.
Multiple windows with fbgfx... sort of
attacke
Polygon - farily fast way.
An oop Example.
axipher
Color Picker (Windows only)
Debug without a debugger
2D music oscilliscope
point follow + alpha fade
Line intersection using advanced types (CVS)
Crazy gfx effect
Basic 2x Stretch
Date converter
Mini Tile Scroller
routine for anguled line drawing
Quick encryption
Finished Custom font
nth square root of a number
html log writer
Bacioiu.Ciprian
Triangle moving in X, Y, Z
badidea
Playing with hexagon tiles
Physics example: Bouncing balls
Simple code profiler
Tic-tac-toe in 1 hour
Physics example: BiotûSavart law
Simple tool for making color palettes
Sprite rotation
banon
simple .obj parser
BasicCoder2
Plotting 3D points to 2D display doodle
Path finder demo
scanning 2D array world for objects
conversion between isometric and Cartesian coordinates
Koch snowflake
FreeBasic snowflake
Fern Leaf generator
retro text box array
vanishing disc
Line Segment Circle Intersection
analog clock
squid on drugs
Implementing Vector Fonts
Another simple text box
raster fill triangles
Retro vector fonts
isometric world experiment
rotating cube with texture
3d to 2D projection
edit tiles and their objects
Bezier Curve
meshing cogs
Polygon demo
Drawing shapes.
Convert Bitmap to Data statements
Fade an Image
TEXT BOX EDITOR
LINE EDITOR
rounded corners
Oil Paint Effect
pixel perfect sprite collision
single and double mouse click
Shape contour extraction
Resize and move rectangle using mouse
Grab multiple webcam images
BasicScience
Stand alone Gui Slider
[NEW FEATURES 11-2-2010] FB_TextBox with advanced editing.
Dashed Line Routine
dynamic custom mouse cursor, using simple sprite
Updates for Excel Disphelper
ListBox Drop_Down Menu GUI
Font Changes mid Text_String with xFont wrapper
GUI Data_Entry form
Nintendo DSi, waiting...
Avoid graph axis min/max & tic headaches
Command_Button in FB
BastetFurry
[snippet] Isometric drawing
Little DRAW based text routine
bcohio2001
Stuff the keyboard buffer (Windows)
Another directory walker
Modal Progress bar and "Wait" window objects
Playing and recording wav files
Getting values of a multiple select listbox
Another DIR replacement
Insertion of string into an array in alphabetical order
BeginnerST
Simple programs to start
Some functions for string manipulation
biskbart
Fake blobs
Particles
blahboybang
Quadratic Equation Solver
bluatigro
atari books site
E motions sim
fuzzy logic example
BMarley
Irrlicht 3D Engine & ODE Physic Engine with FreeBasic!
bobfresh
Add Popup Balloon Tooltip to Dlg Ctrls
bojan.dosen
Easy Windows API Tutorial
GDI+ icon stack animation
YouTube viewer
Writing TAR (Tape ARchive) files
Simple Unix time output
Glass GFX (Win Vista/7 only)
Resizable GFX window
Resizable GFX window!!!
bruno_di_roma
Font size in Console mode
font in console mode
brybry
Simulate Mouse Click (Windows Only)
Buck
Linux screensavers?
bulrush
Read text file into array
Calmatory
Simple encryption
Yet another small&simple FB game ^__^
Simple "particle stuff" a.k.a. waterworks.
Carlos Herrera
Savitzky-Golay smooth
cbruce
Slope Averaging
ceoceo
lock / unlock
cevpegge
OpenGL 4 Port Viewer Demo with antiAliasing
cha0s
Get the address of a class function pointer
Some code to load any image to a FB image (using FreeImage)
Send a POST request via HTTP
Dynamic arrays in types
An object to facilitate dynamic arrays in types
Flood Filler
ForEach
3D button effect
"True" Generic Linked Lists
File iteration class
Round to a specified number of digits after decimal
Human-readable Windows Error Function
Simple little generic qsort example using arrays
a vector implementation...
Find out if your buffers are new or old, get width/height
graphics buffer handling
Load/Save .gif using FreeImage
high precision randomize
Easy type management thanks to ctors
independent unrestricted bmp loader
Simple password generator
console graphics commands [get/put, mouse support]
Block comment trick =)
Binary Event Handler
Simple linked list implementation.
Option Explicit'er
Easy BMP handling.
Call different function at runtime by a string.
Nostalgia!
zLib example, encapsulated.
Treat memory or an array like it's a file
behold jofers
Find an angle using only 2 vectors.
more spontaneous cha0s code
simple XML parsing
use pointers instead of select case
functions and progs i made when bored
versatile linked lists...
crappy short-circuit attempts...
getting openal to work with multiple samples
explaining some scrolling collision detection
Fast uByte array to String routine
an optimized 2x blocky scale algo
Function Generate_Declares
32-bit bmp loader
useless funcc
ChallengeSpaceYard
Handy clear inkey with only five characters
ChangeV
Zero filled string (useful for score table)
checker put (for any color depth)
Cherry
[Win32] Exception handling using Try/Catch/Finally
[Windows] Setting envvars and curdir in other processes
For Each
[Library/Port/Win] DockWnd - Docking windows (e.g. toolbars)
File and timer objects
[WinAPI] Injecting a DLL into a process
[Win32] Entering Ring 0 (Kernel Mode)!
Some stuff
Fatal Exception Handling (Access Violations and that stuff)
chim
Faster LINE
chris319
Functional SQLite Demo
chrowle
TUTORIAL: Module-type systems
chung
summary but fast shadows in openGL
save data to wav file
how to put a icon in irrlicht's 3D engine window
CJPinder
Fast Portable Solid RND Generator
coderJeff
gzip / zlib example in freebasic
How to change fbc's default dialect to "-lang qb".
Basic stack data structure
Image Object (was Types as Objects Preview)
CVSROOT update util
Multiple Resetable Timer Objects
Pixel Perfect Print Placement
Inkey$, CVI(), and CHR$(0)
Conexion
Prime Numbers
Fake 3D
Small Speed Test (ASM vs FB)
Playing with background animations
RGB to HSL
cosmax2008
How can FreeBasic beturned to a true (old style) interpreter
creek23
CairoPut - Cairo edition of MultiPut
dynamic UDT inside dynamic UDT
Draw String wrapper (handles tab and newline)
BASIC on GameBoy Advance
csde_rats
Fast math for lua
Cyperium
Faster distance calculation (a*a instead of a^2)
D.J.Peters
TexturedTriangle()
GetKeycode() keycodes for Inkey.
MultiPut V2.0 :-)
Using Shadertoy.com shaders offline.
A good collection of some collision stuff.
a line :-)
PutResize(dst,src,x,y,w,h)
PutResize(dst,x,y,w,h,src,x,y,w,h)
OpenGL shader language math in FreeBASIC.
Terrain marching (unfinished)
PutResize(dst,src)
imple [N]etwork [C]onnection win and lin 32/64-bit.
RayTracing versus PhotonMapping
Circle from 3 points.
Cyclic redundancy check (CRC) 16/32 bit.
Base64 de/encoder the second edition :-)
MultiPut() for FreeBASIC >=1.0.4
Demo
Game Of Life on GPU via OpenCL
MIDI In AUDIO Out template (WINDOWS)
MiniLight 1.7 a minimal global illumination renderer.
JAVA class and virtual machine byte code viewer.
flow of fluid solver and volumen rendering
OnTimer proc's
Global Illumination rendering. (CPU killer)
Fast filled polygons in BASIC (all video modes + clipping)
TinyDialog a simple Windows and Linux user interface.
32 bit fixed point 16:16 VECTOR and MATRIX math.
WaitTimer
Misfit3D OpenGL editor (WIN and Linux) native file reader.
OpenGL vsync on/off (Windows and Linux)
Replacement for gluPerspective and gluLookAt.
another easy to understand EVAL() expression solver
Printing FBGFX screen or image on Windows.
How to use NaturalDocs with FreeBASIC.
Font8, Font14 and Font16 for FreeBASIC version >=0.24
Depending on program and user *.ini file Reader/Writer.
Edwin Catmull and Raphael Rom - Spline
little bit physics
glScreen.bi with VBO and Shader OpenGL extension's
Simplex noise in 2D
Load JPG, JPEG, JFIF, MJPG from file or memory.
Floyd Steinberg dithering
Fast clipping lines in BASIC.
Speak text and recording 59 languages styles (win32).
More accurate Sleep(ms) WIN32 and Linux x86
Get CPU Speed
Fast polygone and triangle BPP 8,15,16,24,32
DPM Scene (deepMesh 3D file format)
PF prefab file reader (deepMesh custom 3D primitives)
How many active instances of objects/classes/types.
2D Ray/Line Circle intersection
BASE64 En/Decoder
First Steinberg ASIO COM interface in pure FreeBASIC.
Back to the Road :lol:
Tiny C64 (old school)
Metatunnel demo JAVA to FreeBASIC port.
JAVA Class Stream Reader (quite useless)
Simple Mode 13 in fullscreen on all gfx cards.
Simple FBImage / Sprite scaling in Basic
Example to Evaluate Basic Numeric Expressions
Radiosity with jacobi matrix solver, only a test!
How to capture your OpenGL or FBGFX Screen as video. (win32)
very simple color picker
"Genetic Algorithm Tutorial" only the source code
Another view of prime numbers
Tip: How to handle virtual members of C++ classes
Win32 mixerclass
Image=ImageScale(SrcImage,width,height) (8,15,16,24,32 bpp)
Get your WAN IP Win and Lin (needs fbnet.bi)
Fast Ray/Line<->Plane intersection in BASIC
A RigidBody 3D class
Not a trick but C port of simple 2D fluid solver
Only for fun
Simple clipped 2D polygons in all modes bpp>=8.
Test for 4 and 8 way stepping FloodFill and RowByRowFill.
'Old School' voxels in FreeBASIC 0.16 (Lin,Win)
Simple PutPicture with zooming.
Springs as rubberbands in 2D
only an tip for threads under Windows 98,XP,2000
AVI File Creator in FreeBASIC for LINUX and WINDOWS
the old mandelbrot fractal
Recording sound with FB.
GFX PUT [destination], [xpos], [ypos], source, [scaling]
Get Windows Vectorfonts Data and calc the QSplines.
Play a litle bit with physic.
RGB Support in 256 Color Modes.
Make a break and play.
3D rotations over 3 aches without matrix's
ten times so fast with inline assembly
LINUX,WINDOWS Fast RGB to 8,16,24,32BPP with GDK
dabooda
Quick Sort Routine
Key Input Handler
---->
Tourist Trap
Posts: 2958
Joined: Jun 02, 2015 16:24

Re: The big review

Post by Tourist Trap »

(2)
dafhi
anim / physics fps class
image info udt
Pythagorean Triples list generator
analysis: indexing with rnd
kaleidoscopic plotter
tHSV
aa dots
ShowBits32
Lil' ASM tutes
fractal exploration framework
2d rotation demystified
tex warp
fps limiter
sine fractals
terminal velocity sim
accurate alpha blend
mandelbrot
gfx pointer arithmetic
line & floodfill
ASM Mul and Div
particle system
ShowBits32
DamageXbasic JPEG decoder- and encoder
dani.user
Super Fast Split String Function
Wildcard matching
darkblacklife
screen13 font on screen17
darkhog
Template Makefile
Dav
Binary file to .BAS code
DaveUnit
polygons and rotation stuff
DCrawshawJr
Rotating Sprites on the Pixel Level
Check whether a point is outside a circle
DeadCat
Wave interference animation
Demo: Metaballs!
A Blobby World
Messing around with translucent 3D objects
Deleter
Interesting Graphics
Bezier Curves
List for any type
delyall
FBIDE: How to do multi-module projects under v4.6
DeNivra
Synthesis of vowels in human speech
Need Help [Streaming Audio in Windows 7]
Destructosoft
Custom Fonts With Foreground/Background Colors
Switches!
deveah!
Find your blind spot!
DNAarray
gui code 0.2, fileselection, imagerollover, and vectorfont
vector fonts idea for auto-antialiasing
gui code 0.1 getting better
gui code - menu, checkbox, and button
dodicat
Polynomial Interpolation.
Desktop Colour Picker
Colour Finder
Sudoku Solver (re-done)
Simultaneous congruences by Chinese Remainder
Short Linear equation solver
Some Fonts by Draw String
Vampire numbers
Slack halyard
Opengl clock ~ screensaver - Windows
3D surface plot
polynomial interpolating curve
OpenGL experiment
Visual sorts
Fake fonts
THE DETERMINANT, plain and simple
Polynomial Plotter
Polynomium Roots by Eigenvalue
One minute Sudoku solver
HARRY BELAFONTE
Determinant and inverse of real or complex matrix
GAUSS-JORDAN method for real or complex linear equations.
One minute geometry
CHARACTERS THAT COUNT Part 1
PSEUDO single type font, sized, angled
Toad Hill
Rotator -- a genuine Turner
CHARACTERS THAT COUNT Part 2
THE MATRIX INVERSE - no frills
The old GAUSS-JORDAN made easy
Array extensions and sorts
A Brown Ale down at the old Foo
THE SERGEANT MAJOR
dontfixme
XMSDSK as ramdisk.
DOS
Get Windows Runtime!
DOS386
INCREDIBLE INCREMENTER - finally solved the "file exist
UTF-8 encoder
UDIRX - enhanced directory listing (Win32/HX) with bloat
MD5 Calculator
BUOB , number input and output conversion, digits bunching
Anyone dares beat this ? SINE 66 bytes only 8080-compatibe
Target switching
dpixel
Simple Color Chart
Dr_D
Another A* test program
Old line/circle collision and response code
2d shadow idea updated...
Windows '98 screen saver clone.
Here's another glsl demo...
Here's a little fmod spectrum thing...
Here's a shader demo...
I don't know what to call this. :p
Here's another glsl experiment...
Normal mapping fun.
cpu model skinning
Here's a program that uses freeimage
Fun with gfxlib...
OpenGL multi-texturing for terrains...
OpenGL Framebuffer objects...
Here's a GLSL metablob demo.
DrV
(FBMLD) FreeBASIC Memory Leak Detector
Hex dump of file
Reentrant Dir replacement
Kinetic ScreenSaver
dstein
Syntax highligher for Notepad++ (FB0.91)
Duke49
FB - How to activate Intellisense ?
Win32 help on Vista
duke4e
Procedural 2D City
STL Vector-alike via macros
OSX Dock
Easing Equations
Painting App
Really Fancy Clock
SuperShapes
MouseObject - Complete mouse manipulation routine
Sexy Procedural Universe
Ultra-Fast Software Blur
480000 Particles in realtime
Golden Ratio Rects
Procedural World Generator
Mandelbrot/Julia
2D Fourier Transform On Images
[Ultra Fast, Tileable] Improved 2D Perlin Noise
Most Awful Image Compression
Gradient Rect
Hand drawn graphics
L-Systems (+Awesome 3D update)
Adobe Color Wheel
28 Blend Modes
Curve Plotter
Spiral Clock
Old trick
dumbledore
sdl_net example
a* pathfinding
text mode buffering
dw
Trying to figure out how to read and write to a text file
E.K.Virtanen
Crypting text.
ASCII snowfall with spread "effect".
ASCII end text scroller (what ever)
Useless ASCII star trek (something)
Eclipzer
Thick Sub-Pixel Drawing Primitives (Circle)
Global Operator Overload Template Source Generator
Target Class
Determine If Program Running From FBIDE
Bit-Stream Class
Character Insert Routine
RGBA Class
Drawing Rings
Angle Between Two Points
Dereferenced WITH Statement
Game Clock Code
Useful Rectangle Class
Linked List Library/Class
Game Clock Routines
QBE Tutorial Submission C&C
egocks
FB programming in Eclipse (without a plugin)
ejc.cryptography
Creating an uncompressed archive
Key Generator From Password
WordCount function (text statistics)
elulis
TB(TerribleBASIC) Interpreter
enform
MD5 Calculator and comparator,copy to clipboard ,GUI
MiniDebug 2 , displays variables , + a little more features
MyMemory , a word search tool ; multifiles ; ini file .
eodor
String (or file) parsing and..
Collection class
shape test
Eponasoft
A quick-and-dirty win32-only AVI player using only mmsystem
Eternal_Pain
FB-Splashscreen with OpenGL
24bit to 16bit
fabrizio
This saves some typing
fatman2021
Introduction to Thoughtful Programming
fbfan
just a little game
population simulation
just a little game
AutoRPG
read your long numbers better with dots
FBUser52
FBGFX files???
ffweb
Italian Tombola
Heat transfert
Fragmeister
Compile helper
Frank Dodd
SDL UDP Example
fswRQ Coding Style in FB 0.17b
funkheld
Irrlicht with two screens.
FXG861
TSNE - FTP Access
HTTP - PHP - SQL example
TSNE - Send email from freebasic
fxm
UDT Screen_Event_Thread (methods and event pointers)
UDT_timer_thread (public methods and private thread-sub)
Replace any recursion by unlimited iteration with own stack
UDT: Dynamic Queue/Stack for data-type (numeric/string/user)
UDT Decimal (decimal digits + prefix/suffix formatting)
UDT: Static Member Variable (numeric/string) Emulation
UDT: Dynamic Member Array (numeric/string 1D/2D) Emulation
gbos
Random Password Generator
Constructing a dll for Excel (tutorial for newbies like me)
Simple Stopwatch
SD DataGrid
Small GUI Maker
RMChart Control Example
gel
Mersenne Twister
Gonzo
Voronoi cellspaced
gothon
Recursive Macros!
greenink
Forest of Tree Neurons
Hacking on Tcl/Tk a bit
Decision tree experiments
Single layer neural net with 2 way nonlinearity
Random Number
Analog hash table
Neural net comparison (64 bit Linux)
Symbols (64 bit Linux only)
RP Bloom filter
Hashtable
h4tt3n
Rigid Ropes using Sequential Impulses and Warm Starting
Harmonic oscillator class
particle based interactive fluid
h4tt3n's spring physics simulation tutorial
Soft bodys with shape matching
Kepler orbit
Very fast ellipse drawing
ghost net toy thingy ;-)
Particle based slime simulation
real-time verlet physics
Soft body simulation toy ^^
advanced spring simulation - tutorial warmup
Image rotation trick
haegartheroot
Internationalization: How to Culture-Specific Formatting
Lunar Phase Visualizer
Internationalization made easy
HalfByte
Static version of Zlib 1.23
Hard
[WINDOWS] GDI+
Hexadecimal Dude!
Preprocessor Tree Implementation
Crazy drawing effects in MS Paint (/any windows paint prog!)
Hezad
3D things
Yet another controls code [Fader, Push button]
Reflections
Easy Menu Handler
Strings handled Database
ASCII and low-res Cube :)
A simple rotating fractal shape (fixed :) )
A little shape interpolation snippet
WIP 3D Engine (Update : Modularization+Materials)
Procedural 2D Landscape Scrolling
48 seconds in space (some kind of a demo)
Blur, Treshold, GreyScale, and Color Filter in a .bi
The FreeBasic Graphics Showcase :D
A nice clouds generator :D
Port of a CHIP8 Emulator to FB :D
Yet Another Mouse alpha Trail
Quick Drag and drop FTP Sender
Character recognition :)
Graphs
WireWorld
MyTerminal
Not "Turing machine" in FB
one more Conway's game Of life
Particules
My first steps with open GL
A little Life Game
a little thing with rnd :)
hogue
Complex Numbers
I3I2UI/I0
PI from FPU
FB Version 0.14b 0r 0.15?
ike
LUA
sqlite - create db,table and insert some rec
Today my boss was not here, so I play with GTK
ikkejw
Radar Effect
Simple .ini reader
Imortis
Rounded Rectangles
The Amazing Bounded Variables!
FB OOP Tutorial
Horray For Buttons!
Horray For TextBoxes!
Sine waves
inded005
CheckOverlap
integer
CONTINUE -- I did not know how to CONTINUE
Inutilis
Send mail via SMTP (Windows only)
Ivan, Zagreb
Ellipse
Pendulum waves
Periodic Table of Elements
Alignment draw string
j_milton
Fletcher's Checksum
sort without compare: the count sort
The comb sort
JaDogg
print hello world by hooking exitprocess (win)
Calculating Sin the hard way + e^x
draw on desktop
Calling exports in an EXE from a dll loaded by (exe)it self
Adding a Section to an .EXE file
Create a wav file(funny sound)
EXE Overlay
Windows User access control tool for XP
what my processor is
uuencoder,advance shell,antidebug
jdebord
Mandelbrot Mix
Mandelbrot Dazibao program revival
Quaternion library
Differential equations
Fast Fourier Transform
Complex number library
Hypercomplex number library
Jerry Fielden
Home grown Bsave/Bload for win console mode 0
jevans4949
Yet Another Linked List Implementation
jiri
bezier curves
flame
bloodrain
my wheel
gfx text
JJ2005
Transparent window
Joakim_ar
Reverse Polish Notation stack calculator
Heh, interesting child of my boredom
joco
Write string directly to the screen memory
jofers
Use menus with GfxLib in Windows
Associative arrays that actually look like arrays
Using TTF fonts in GfxLib
Trap the console output of another program
Win32 Open Hooks example (Open "Resource: ID, Type&quot
Use "AND" for combining flags instead of "OR&
Get a transparent image from photoshop to GfxLib
Mix GDI and GFXLIB routines
Package any file into a windows resource file
JohnB
glgetversion
MipMap OpenGL
A Simple (?) Multi-Texture OpenGL Example
source code generator fo OBJ
By pixel text scrolling using gfxlib
Jojo
Getting the system language (cross-platform)
Jokse
A MID for binary extraction
judemo
Simple dialog in DLL using IUP
Juiced
FB Quine
Julcar
CGI - How to process HTML forms!
KaraK
Windows Service installer class
Themida/WinLicense SDK Protection Macros
VB's Split Replacement
Macro to convert Hex view of a float to float view
Using Freebasic to extend Python
Keal
BASICA/GW-BASIC/Qbasic Graphical GET/PUT & BLOAD
Keeling
Numbers to words (US English)
The eyes have it
Least-squares linear regression
FB can compile itself, it should be able to draw itself
keithpickering
GSL example usage
kidersx
Evolution/Mutation Simulation, Anyone Want To Make One?
kiyotewolf
Tiny Typewriter Implementation
WRITECLIP.EXE
Filesize Calculator
Selective JPG [UserDefinedType image file format]
Funny Rotation
32BIT VS 64BIT Program Files directories
LINE (foo,bar)-(bar,foo), B(rounded edges)
Sprite Sheet fast sprite grabbing
Generic Math A Refresher
Global Variables for cheaters
Hue Sat Lum color wheel
Easy Breezy Menu
Full RGB 24bit graph paper
Fast SVGA save-load
Digital Project Storyboarding
Snow
Windowed WAV player code
KLBear
Basic Sound for FreeBasic
FB Lotto Gui Demo
krcko
PHP-like associative arrays
Exception Handling in FreeBASIC
Mixed datatype
Simple Expression Evaluator
GetToken function...
Just Another Linked List...
KristopherWindsor
Speak Text from the Clipboard!! (Windows Only)
Tiny Stack Implementation
Bouncing Balls, Line-circle Collision Detection
Send an Arbitrary HTTP Request (Windows only)
Maze Solver
Weighted Randoms
Square Roots: Babylonian Style!!
A wrapper for fbc: new command line arguments, build numbers
IP address -> Hostname (Windows only)
Screen scaling with OpenGL
A faster way to loop through arrays of objects
Ranged data type (limits values to some range)
Faking Static UDT Members with Properties
Determine if the FBGFX window is fullscreen (WinAPI)
Simulating keyboard strokes / presses with WinAPI
Windows API: Open Dialog to Browse for a File
Projectile stepping through grid
Images, Bitmaps (BMPs), Loading, and Saving (How To)
Zooming in on a Map
10 Helpful Snippets from my Game
Recursive Sierpinski Triangle
Divisibility Tree!
Image Scaler (Resizer) with Pixel Blending
Infix / Postfix conversion and evaluation
Very Easy-to-use (Animated) Sprite Engine (Beta??)
A Console Screen Object (Flicker-Free!)
Simple Matrix RRef Method
Some WinAPI to probably burn your harddrive / CPU out fast!!
Anti-aliased Pixelation!
Simulated 3D Cube in 2D, or a Distortion Formula
Level Loading Screen / Bar
Show and Hide the Console with the WinAPI (ShowWindow)
Fast Put() Alternative with Horizontal / Vertical Flipping
Magnification Tool (2 Methods)
Function to Draw a Circle (Port from FBGFX)
3D Torus in OpenGL
Coding from a formula: Quadratic BÚzier Curves
Demo: 3D Graphing in OpenGL!
Map Walking Demo (Scrolling a Tiled Map One Pixel at a Time)
Start with a Camouflaged Window / Capture Desktop Screenshot
Tool to Generate a Road from a Set of Points
Custom File Input # Clone
Demo: Custom Paint Function
Spirograph Art + Alpha Blending: Art Gallery!! :-)
Demo: Calculate the Area of a Polygon!
Sound (Microphone) in Games Demo (URL)
Demo: Stickman in a Platform Game
Demo: How to Load the Default 8x8 Font from the Data File
Linked List Demo (Integrated within a UDT Object)
BasicText - Small Library to Print with Pixel-based Coords
Automatic Sub Declarer
Twilight Cylinder - Explained
Gravity + Real-time text mode display without flickering
Alpha Codes Demo
Line to Line and Line to Circle Collision Detection Demo
Pi, Arctangent, Sine, Cosine, and Pythagorean Distance Demo
Lightning and Fire Works (Explosions / Particle Trails)
kwhitefoot
Maze solver without recursion, objects or lists
L_O_J
PPConv - Pixel Plus 256 To BMP Converter.
Binary Search Tree and AVL tree
...
Lachie Dazdarian
Change PNG sprite hue and saturation, or change to grayscale
Chipmunk ultra-commented toy
A Simple (but flexible) Magnifier Effect
Twinkling star routine
Polygon and star drawing routines
Chain-like animation tutorial I wrote for QB Express
Landeel
Joystick Rumble (Force Feedback). Linux only.
Using FbEdit as Linux IDE with wine
OpenGL VSYNC - multiplatform
FLC / FLI Animation Player
lassar
Cosine Interpolation
Direct Way to Find Quadratic & Cubic Equations
SuperFast Png viewer
Mouse & Vesa routines: shows mouse without flicker
Dos Keyboard handler
Simple way to flip a bmp upside down
Vertical RLE Bmp Compressor
Pcx2Bmp: A 8 bit Rle Bmp Compressor
Faster 8 bit Pcx Viewer
8 bit RLE BMP viewer
MidCompare% function
Instring assembly function.
Extract$ using Assembly InstrAnySpace%
32 bit resolution pcx viewer
PB2FB Translator
Graphics Routines for faster dos freebasic
Show 640 by 480 PCX
WorkAround for FullScreen Alt-Enter
Graphic drivers checker, and check for screen resolution
Splash Screen
Ultra Fast Trans PCX drawer
8 by 16 font routines. 640 by 480 (8bit and 32 bit)
lemontree
Continuous Gray code numerical optimisation
Compressive Sensing
Numerical Optimizer - Find the minimum of a function
A Bloom filter, for the forgetful.
leodescal
Neat Debugging with detailed Bug handling
Vote
leopardpm
Obsessed with Pathfinding...
3 Shear Rotation - rotates without any aliasing(holes)
Does anyone have a HQx scaling routine?
Something Fun: Morton Code Routines
Splitting a Full Sprite Sheet Into Usable Individual Images
lillo
Starcontrol like melee AI aiming
Lithium
Interpolating between two polygons
Loe
Speech Recognizer
LinkedList Class - My attempt in FB OO
Some string and listview wrapper
Playing with ActiveX in FB
loking1235
maze code
Lothar Schirm
Simple GUI
Yet another play: Iteratative solution of z^n = 1
Some string functions
lp0cua0
Windows registry reader function, handles most value types.
lrcvs
A simple Clip
Show only prime factors
Ulam spiral
Conjecture of Goldbach (simulation)
Greater distance between consecutive primes.
Ying Yang
The table rotatory
Simulation tailgate lift truck
Telescopic Cilinder
Test >>> Turtle7.bi
Robot_1
Train
Bottle on the sea
Safety Lock
Trajectory of an egg
Garden Machine
PROGRAM EUCLIDES TO CALCULATE THE GCM & LCM
Curiosity of "For" and a counter
Randomize's timer's
Multiplication
Lster
Twirly 2D star thing
LukeL
Reverse Line Input
FBgfx buffer to jpeg using FreeImage
Luxan
Ubuntu dislin freebasic install
mambazo
Simple Script Interpreter
Capture input from the Mic with FMOD
FreeBASIC with artistic licence!
Inspired by the Falling Sand Game!
Super Simple Encryption
Oscilliscope with FMOD
Record & Playback with FMOD
Mandelbrot Fractal Explorer
DivX subtitles out of sync?
Manpcnin
Support for old commands in XP/2000
mARCO
Improved 3D Rotation Formulas
mark bower
Menu, Simple
Cartesian Plot
marpon
SendKeys sub
Enumerate Process and functions to work with
Advanced Search StringInStr
Enumerate windows and functions to work with
mathwizard44
Color Codes in Text Mode (Screen 0)
matwachich
MySock - Simple Sockets Library
fb-rc4 - Small & Simple RC4 implementation
[Type] Particle Emitter
mdsy
BATCH (to freeBASIC, then) to EXE !
Mentat
Making grass on the run
Debugging using shell's msg
A simple working 3d triangle graphics line
Merick
Examples and Tricks?
simple screen mode select
lua tables
swig auto-runner
gampad setup udt (fbext)
special effects (was fullscreen filters)
Lua neural network
Merri
Metaeffect: DirectX + Metaballs + creative ideas
mg
Boundary checking for "allocated" arrays
---->
Tourist Trap
Posts: 2958
Joined: Jun 02, 2015 16:24

Re: The big review

Post by Tourist Trap »

(3)
MichaelW
High-precision CPU clock speed routine, 64-bit Windows only
Test of X64 Calling Convention
Cycle count macros for 32 and 64-bit code
Simple binary semaphore based on the CMPXCHG instruction
Simple "Try" macros based on VEH (Windows only)
Stack allocations
Pi to 1000000 digits with Brent-Salamin and GMP
New cycle-count macros (Windows only)
Mouse Hook Demo (Windows only)
Clock Cycle Count Macros
CPU Identification
D-R conversion timings
Reasons to avoid 8 and 16-bit iterators
WinIo-based Peek functions
Windows API popup menu over fbgfx
WinIo
Fast Hex-Ascii dump generator
GET with allocated buffer
Faster RND
Optimization
CPU Clock Speed (Windows only)
Exception Handling Macros (Windows only)
System Error String (Windows only)
Code Timer Macros
Mihail_B
Boolean/math expression parser with "cached" variables
Parabolic Mirror/Shape
How to read ATAPI CD/DVD sectors and related stuff (for DOS)
MilesAhead
Glass Prompt for Vista and Windows Seven
Mindless
simple, dirty huffman coding example
strip id3v2
tiger hash
another linked list implementation
SHA1 code ported
MiniMICROSOFT
DirectDraw Blt-ing into Notepad's window.
App that displays shuttery message on top of DirectX fullscr
An DoEvents subroutine
mjs
OPEN "TICKER:" implementation


mrminecrafttnt
Example of using textfiles for OBS :)
Developing of an bytecode interpreter in freeBASIC
Challenge: An uncheatable Value (i think)
Some anticheating stuff :)
Simplest costum CPU emulator ever
A costum VM (44 Opcodes)
Retro Videocard Emulation
A very simple VM
MrSwiss
Code "optimizing" - in practice
Library Tutorial - Step by Step - DateTimeHelper
ExDate() Function
File "open" UDT
Sub getScrInfo(), replaces ScreenInfo() Integer ret. with Lo
Concatenating String with Boolean FBC 1.04 only
using Boolean variables in FBC 1.04.0 DEV version
cPrt() Sub, for Console Printing
mrToad
Dynamic String Testing (Text adventures or other input)
MusicianKool
Double Linked List
Muttonhead
a very very basic contour finder :)
a simple image filter
rnd
Yet Another Color Mixer
axle model
MVXA
simple signal type
Mysoft
QB like PLAY plus more...
Palette Animation (Canvas Animation)
"cassete upload" for dinossaurs only!
800x600x24 bitmap fun...
Fast HighQuality Resizer
Extended ConsoleClass Functions
FBGFX font render
OpenGL fbgfx render...
Aquarium of fishes
Capture a Window (or the screen) example
Snake Saver =]
Hanoi DEMO
Hq2x filter
Alternative Keyboard
Sphere World Demo
n00b
3d collision with 6th grade math
Nicky
Time programs
nimdays
Tiny SDGL
HTML To Image
Another Memory Dialog
7zip Example
String Cutter
Native Way
String To Byte Array
Toy Interpreter
Simple Pratt Parser
Dynamic Vector
Very simple Assembler
noop
Downscaler/Upscale image
Naked function: An observation (x86,x86-64)
notthecheatr
A stack object
Swarm
Simultaneous Random Number Generation
GRA
Pragma Preprocessor
Probability Machine
A Double-linked list
Another linked list
Soundex routine
Forum post converter
ScaleHalf
Special FX Objects
Lines of code
Simple Lighting Object (updated 12-26-07 11:14am)
Parsing 101
Not modifying strings in functions
An Error Reporting Object
Alpha <-> Trans
Speed
Novice
Newbie Needs Help Compiling Old Program
oog
The heart of a virtual machine / CPU emulator
Vector Graphics Engine
Ophelius
Hack Challenge
Plasma Effect
Buttons
Oz
Input box using fbgfx
Multimonitors manager for Windows
Thread friendly INPUT
Line Intersection Algo.
Sine and Cosine square
PAEz
[Win32] SetWinEventHook
Paragon
Using This with func ptrs
Easy unions.
Var funcs, w/ var arg lists and var returns.
parakeet
30k simple web server
The Active Belt
PacMan !
tHE ReD U.F.O.
parkovski
Compiling under x86_64 linux
PaulSquires
SQLite3 database class (32-bit)
String functions (32/64 bit ANSI only)
FTP class (Windows 32-bit and 64-bit)
Keyed Linked List / Hash Table (32-bit and 64 bit)
FireImage custom control (WinAPI GDI Plus)
pestery
OpenGL shader examples
petan
Countries flags (free) - all in one image
routine "Screen Extended Last Cursor Position - sExLCP
Geany - color schemes - Dark background
Create today's folder under shortname, e.g. Apr-24 .Win+Lin
'Last Checkpoint' function
'CSV file list' via DIR() + terminal + console hidden
FB version indicator in windowtitle
Lib's check (Win+Lin)
Time asymetrically visible - line XOR
Drawing nice 2D histogram
1-2-3;) - voices in your program !
Easy to troubles - block comments.
Finding correct crashpoint
Using StrReplace function nerveless
Indexed color variables with color constants
peterbenwar
another mandelbrot browser
phishguy
Faster text file parsing
ADO Query of Excel file (and CSV format) Now with SQL
Example to display all the available fonts in Word
Spell check
Create Excel spreadsheet without Excel
Using .Net classes
Desktop draw
Custom input function
console mode app icon
Different way to do buttons
phycowelder
Little Matrix manipulation Lib
piccaso
Loading a dll from memory
Pitto
Bitmap to SVG converter (grid mode)
pr0gger
Simple OpenGL Bitmap fonts
Automatically create function prototypes (DECLARE SUB, etc)
FBGFX Buffer to OpenGl Texture, and BMP to GL texture
Prime Productions
Simple Assembler
anonymous1337
Extra Crappy Observable macro +Two-Way Binding Configuration
My own FPS control - Yellow, Magma, Clay
Quick, Clean Mouse Grid-locking
FPS Independence: Call timer() only sometimes
Make screen fade in and out to white (variable frame rates)
N-Dimensional Equilateral Array
>.>;; Use the arrow keys.
FreeBASIC "Cartesian Tree Merge" sort (JavaScript port)
(Very) Simple Global Stack using FreeBASIC Arrays (Macro'd)
Recursive Spiral - OpenGL Version
The Fancy 2.5D Tutorial v.1 - Tips & Code for 2.5D
Factorial without Recursion
Demonstrating BBCode to users
Custom Trans in PUT
Rudimentary Boolean Type
Easings/Tweens - Sequencing them using callbacks
Formatted input/output using CRT
str_iif(c, t, f) + a failed dyn_iif
Simple (Arbitrarily Weighted) Probability Machine
Thread Management Class [UPDATED]
Another XML Parser ^_^;;=b
Lazy Man's Test for Non-Integer Values (Never Mind)
Inkey - Press a Key Once
Lazy Benchmark: Toggling GFX_ALPHA_PRIMITIVES
Recursive Vector Revolutions [Screenshots]
"Algebraically" Plot Circumference of Circle
Simple FBgfx scancode compatible input loop
Objects with individual FPS, same Pixels Per Second
Second-Based FPS Timer (Macro)
Set a Default Drawing Buffer for "Circle"
Ring Segment/Circle Collision Detection
"Difficulty Adjuster Formula"; amnt of (min-max)
Non-Trigonometry 2D Hill Collision in < 120LOC
Convert Number to Spelled Number
Nested Withs w/ the preprocessor
Easy MP3 loading with FSound (Uses FMod)
Recursive Spiral - FBgfx Version
Render an Image Horizontally Flipped with CUSTOM.
My (VERY PARTIAL) Solution to FB's Quirky Syntax.
Floating Point to Fractional Value
Safely resize a list of NEW'd Ptrs
Like MOD, but for Doubles. Keep Double In Range.
(SIMPLE) Select Case without Auto-Breaking
"Plugin" example using DLLs and Proc Ptrs.
Simple FB AI with Lua Scripting Example
New "Virtual Mouse" - Move, Keep Mouse In Window
Travel Around the Circumference of a Circle
Changing Behaviors w/ Preprocessor & Includes. Hackish.
ON TIMER type behavior using threads...
Simple Redraw Region Example
Really simple star rendering... Like, oldsch00l stars.
mai multikeyz ting!!!
Object Ownership in FB, The BASICs.
Generate a Random Number within a Multiplier Range.
Guarded Blocks with Thread CONDitionals.
Really Basic Long Division . . .
Simple File List Object. . .
High Precision Single/Double Equality w/ Reasonable Defaults
So I was bored....
pritch.Sprite - Wait for Inheritance, you'll like this ;p
Prime Factorization (Updated: LCM and GCF added)
Da most simple n' eaziedst n' koolezt resizing algoridm evar
Alphanumericalism - Speak in Alpha-Speak, be Hax0r.
Simple + More Advanced Ellipse Renderer
UDT's for Properties.
Basic Animation Stuff . . . ^_^;;
Demonstrating Properties of Real Numbers in FB.
Simple Circle->Rect collision using priVect2D
pristd - priVect2D: A simple 2D Vector Class
For you lazy people out there who want a container
Testing FBgfx at Your Monitor's Resolution
Keep Mouse On Screen When It Moves (FB .17 intermediate)
Demonstration: Some FB Objects, . . . I was bored ^_^;;
Lock the mouse to a grid.
NewKey, multikey defines and a Getkey method great for ASCII
Most Simplistic "Static" Effect I could think of
2D Camera Rotation Compensation - Move & Rotate camera
^_^;; Danger: Le Deadly Weapon Ahead - Or something!
Just another simple key up/down/active/changed checker :P
Clear Inkey...Whooo.
Decryptographer Helper
Windows API Testing: Move mouse with Image Drawing
Macro to turn off Scientific Notation
Wheel Creator Thingy. . . Perfectly Spaced lines! XD
Image to Data Statements by anonymous1337 (upgrade by Axipher)
Tile Creator and Loader! ~Large images to Tiles~
Advanced FPS Manipulation Tutorial! The Perfect Solution!
qbasic
files
Quadrescence
Fast GCD algorithm
Quark
The spooky recursive backtracker
Animated Birds
Humble DRAW not so humble after all
Klingons weep
Little puzzle for fun
Mass-Processing of Files
The mighty DIR
Rock 'N Roll
Simple file selector
Magenta Dreams
Scaling A Toucan
Dancing FB
Mini Image Scaler Demo
Demo of dodicat's fps contol
Endless Highway
Encoding Files For Forum Upload
Scrolling Color Boxes
Talking to the User
Creating mosaic tiled images from bmp files

Raddel
Win32 - Seaching File Method
Simple Sniffer
Rattrapmax6
Morphing....
Playing around.. (Triple Buffer Display)
Pixel Per Second advancing...
Locking FPS....
Racing Lap Timer...
FreeBasic RGB to HTML RGB....
RayBritton
Draw String Input Thing
Chisock demo
String drawing function
ShellExec (ShellExecuteEx and Exec replacement)
Key Defs
QB timer code
rdc
Yet Another Raycaster
Using the MK* and CV* Functions
Image Grid Object
Inheritance via Pointers
Simple Hash Table Object
GRFont
FB Data Structures: Data Object
1D Dynamic Array in Type Def
StringList Object
Screen Object
Simple Noise Texture Generator
Map Interaction Using Action Objects
Node Generation
Drop Shadow
Little Menu Class Experiment
Ascii Chart and Box Styles
Bidirectional Ascii Ticker
Illusion
Island Generator
Ascii World Ascii Fire
Reflections of Ascii World
Decentralized Group Behavior (Emergence) Programming
Plastic Chladni
Bump Map Chladni
Spherical Strangeness
Red
Grid drawing function
red_Marvin
Long time no code...
A shattered gradient...
Updated: random animated n-branch ifs fractals
New and improved! (Now with triangles)
a quite nice gfx thingy
redcrab
Fade test : Remanance test of old green CRT monitor
Multi directional gravity bouncing ball : or 70s fx
Fun : The Shaped Maze Generator... animated
Nested Cycloid ? What's that ? ;)
Thick Alpha Colored Lines without Open GL
Vectorial Text Drawing with polar coordinate font definition
Let's Play With The Dust : particule algo
Gaz Iso Pressure : see gaz moving with an atomic microscope!
Weird Atomic Chamber
Pseudo biological flood filling progression...
GOSUB in SUB
DELTAMULTIKEY ... key state change tracking
print integer value in all direction and size
Refine
Mergesort is fast and stable
Shell-sort that's competitive with CRT's quicksort
relsoft
FBGFX to OpenGL (Use FBGFX along with OpenGL)
Using Framebased movement with Delta-timing
Hashed/Linked Arrays (A very fast Particle Manager)
Interpolated Delta Timing
The easiest way to code a 3d Platformer.
Matrix 2D Crap
Time constant Bezier Splines
Reparametizing the spline...
SAT based Polygon Collision
Table sort. Fastest sort algo I've ever come to know...
Easy Joystick and keyboard handlers...
Glass Tunnel Source...
Realtime glow
Quadtree based renderer
Curved but Linear path traversal using Catmull-rom splines..
Beziers versus catmull-rom splines
Bullet Hell ala Strikers 1945
128 metaballs and counting....
Line cube. The easy and fast way. :*)
Supa_shape Morpher.
My neck and leg throbs but here's linecube++
Software GFX phun!!!!
Con-fusion
Radial displaced lensmapping....
Before I go....
The "Flower Tunnel"
Since everybody is playing with trig....
Combining olskool 2d effects and native opengl geometry....
3 Camera types
Rens
Blocks moving on a sine wave
Rev5
RNG using predetermined sequence
FOV range casting
Frame Rate Controller using precalculated array
Richard
List files contained in a folder
Modulo 10^9 floating point arithmetic.
Solstices and Equinoxes.
Wire Gauge Tables. AWG, B&S, SWG.
Arbitrarily Big Integer Routines.
Saving Line Art .BMP files.
Engineering Notation
Rate Multipliers generate straight lines.
Bernoulli Numbers.
Fast Function Approximations by Lookup Table.
Engineering notation, SI suffix input routine.
Smith Chart, RF Impedance Diagram with Mouse Interface.
Engineering Notation with SI Prefixes
RNBW
Numeric entry into a textbox
Roe5685
windows message & dialog boxes
Roland Chastain
Catholic feasts whose date is relative to Easter date
Julian Day Number
Tic-Tac-Toe using Minimax algorithm
Recursive Sierpinski Triangle using Cairo
Cairo snowflake
Cairo FB Horse
Josephus problem - Linked list example
Skeleton of an fb-doc tutorial
Animated lines
Simple labyrinth demo
Combinations of a character set
Simple algorithm for a "Four-in-a-row"
Date of Easter
rolliebollocks
JSON Parser
Generates Generic HTML from JSON
Bubble Sort Alphabetize
Generic Vector Using array(any)
Neural Nets
midStr (Parsing function)
Cairo Based GUI widgets [Update 2.20]
Texture Map AVI to OpenGL Object
Yet another 3d Starfield
Various String Editing Routines for Text Manip
Yet Another String Splitter (Over many delimiters tough)
Mathematician's Slider
Return Multiple values (of same kind) with function
Intersecting Line Algorithm, returns Point of Intersection
Lissajous Texture Generator
Auto-scaling 3d Sprite class with 3d Rotations [8.11.10]
3d Point Class with Tutorial
Translates A 2d Sprite Into a 3d Image of Vibrating Lines
Cut an FB Image into Vertical or Horizontal Slice Array
Unoptimized Rotator/Dilator (Any thoughts on Speeding Up?)
Groovy v1.01
Knuth Morris Pratt vs. Boyer Moore
Easy to use High Scores Table for Games W/ Display
Crappy Text-based Button in 100 Lines (or less)
IsInStr, faster than INSTR? Challenge anyone? Beat this...
Scramble Characters in String
Super Simple FMOD sound Macro
Full Feature isInStr
Super IsInStr : Update! Full Commentary.
Split string into array of strings...
Zstring functions which return FB strings...
File Based Sprite Engine [With Tutorial]
Quick and simple function to remove any character from a str
Dialog Engine
Animate Sprites on Delay
Expression Splicer-> Meant to emulate LISP's CAR/CDR
Draw on desktop background - Cross Platform...
An interesting mistake?
Read path/processor info from "glitch" in string b
Fb Quine
GFX_SHAPED_WINDOW trick
Consin/Consout/ConsLoc => Input/Output/Locate for Console
Using MULTIKEY to return a single key press...
Basic usage of Tuples & Sequences using fb ext
roook_ph
bresenham line algorithm for those who want it
ryan_the_jedi_knight
Parametric -> Standard Forms of Lines?
SamLemke
learning openGL for noobs
sancho2
Slightly Faster Line Drawing (?)
Sandstorm
Line Segments Intersect Point
sasho
Some string and array tools
Escape/binary strings
A Levenstein's distance function
sblank
OpenGL NBody code
sean_vn
Robin Hood Hashtable
Fingerprint Bloom filter
More approximate counting
Same little machine learning code as before
Count-min sketch
The Hawkins Ahmad neuron
Statistics code
Quadrature Oscillator
Liquid State Computing
Evolve a minimum spanning tree
Chebyshev
atan2 of two Gaussians
indexed heap sort
Union Find algorithm
RNG Linux AMD64
Artistic license
Random number generator
Nerd, Half Nerd and Geek
Optimization (Rehash)
Heap macros
Numerical optimizer
segin
Program that simulates Windows 3.1 look-and-feel
Gradient Demo
seph
recode Windows INI functions?
keyCode() as a quicker solution
ShawnLG
A very simple self contained FPS counter program
The IF statement and speed
How does FreeBASIC looks like when compiled...
Blitting more faster...
Testing Various blitting modes
ShelledGhost
LCD clock, timer (or LED? i'm not sure...)
---->
Tourist Trap
Posts: 2958
Joined: Jun 02, 2015 16:24

Re: The big review

Post by Tourist Trap »

(4)
shiftlynx
TUTORIAL: Using FMOD for In-Game Music
Playing a Self-Composed Sound Buffer
shockwave
Asm based triangle routine
Electricity Simulation
Amiga Style Sine Intro!
Bezier curve routine.
ASCII 3D Starfield.
Fast flatshaded circle routine
Another tunnel
Bob tunnel +scroll using Tinyptc
Sigord
Line numbering
Identify the OS
sir_mud
Syntax Highlighting for Notepad++
FME - FreeBASIC Macro Expander Deluxe
Converting C Headers with swig
FBGFX from C
Start to a .lnk file reader (type code atm only)
Fast Inverse Square Root
explode function like php
I was really bored or one thing i miss about QB
Levenshtein Distance Algorithm
Input function with blinking cursor
Color List for FreeBASIC
Windows Count Files
A couple little handy functions
Loading a BMP without knowing it's Dimensions
Tiny speed increase parsing commandline options
InStrRev from VB6
siskinedge
How Not to Multi-thread
Merge Sort Algorythm
Useful Newton Subroutines
skystrick
Controlling user INPUT - Linux/Mac and Windows/DOS versions!
smagin
Using OPL3 emulator with FB
spaz_man
Color text scrolling
spodhaje
UUID generator (windows only)
squall4226
Simple lightning bolt algo
Color constants
Simple music visualizer
FSOUND_Stream_GetLengthMs() and VBR -Use FSOUND_MPEGACCURATE
square1
Process Googler for XP
srvaldez
decQuad lib and example
gamma function
Riemann zeta function
cool command line tools reference
Pi Chudnovsky
computing the coefficients for the Lanczos Gamma approx.
FreePascal DLL/FreeBasic example
using soft-float 128-bit floating point
ioldouble
using newLISP in FreeBasic
compute logarithm the hard way
floor and ceil
Quad Precision
I will guess your number
BCD floating point math
SSC
Simple OpenGL Scroller
stef
Fireworks (particle-test-demo)
Superellipses / Supershapes on the fly
Stefan Schnell
How to use SAP with FreeBASIC via CGI
How to use SAP with FreeBASIC
steven522
PARSE funtion for character separated value strings
Random file access and search
Make large "master sheet" bitmap from smaller tile
stevie1401
Easy printing on linux
Stonemonkey
Triangles
floor and ceil
gfx mode text
Stormy
Spectrum Visualisation (fmod,opengl)
Playing around with Polygons
[OpenGL] Rotation & Blur
FadeIn and FadeOut for 16Bit-screens
ColourArea
FadeScreen-Func
stranger
Text File to .csv conversion
StringEpsilon
FastMid - string cutting
stylin
Using Natural Docs with FreeBASIC source code
Type alias class members
Automatic bit flag declaration
Type-safe variadic MIN/MAX
Inferring fixed-length array size from initializer count
Constructing/destroying objects in existing memory
Safe string type
C++ virtual functions in FreeBASIC
Boolean type
A simple generic stack container
A simple generic queue container
Progress bar
Roman numeral to integer conversion
FreeBASIC run-time headers
Smart pointers: exclusive resource ownership
Con/De/struction of dynamic objects
Returning UDTs
Effective Conditionals
ASSERT and ASSERTWARN fix
Cast to boolean macro
String Reversal
pre- and post- increment and decrement
super_castle
Draw (Grafik) plays
opengl, texture with imagecreate and version 0.17
Sven_V
Simple Scripting engine
syn9
checking for window close using glfw
sys49152
scale graphics
t3rt3l
Smooth and Smoother Step Interpolation
Tafoid
ReadBDF - BDF Font Reader
taijinantangXX
Can anyone kindly translate this GTK program?
TbbW
2cent debug logging.
Custom window + FMOD ( like winamp )
Sqlite2 example
TESLACOIL
Eye detection,recognition and distance guestimate
simple CPU Benchmark with comparisons + 5%FB speed boost tip
Transparent window
Readable font in widescreen
Freebasic Mini Clock in a console window
Disable the users computer with setmouse
new KEYWORD for layzee people who like tidy print statements
You Talk , Freebasic types
Simple 8 line prog to play wav files using sndrec32.exe
The Second
Bmp to colormap converrter
themaetsnake
An interesting piece of code
thesanman112
collision basics....
rotation of bitmap
explotion of bitmap
directfb hehehe *rotation of bitmap*
variable multikey
Open gl virtual world layout for those looking...
TheWeirdMusician
Macro Inheritance
Thorham
Very simple random generator (VERY simple).
Fast Floyd-Steinberg based dithering.
Thrawn89
Resourcing PNGs
Dynamic Screenres
Tigra
Windows listbox with checkboxes
Get Windows application Version info
Windows resource .rc version incrementer
'callstack' macro
tinram
Perlin noise field
Quick color number reference
TJF
walking a directory tree (here remove all files)
Fast Fourier Transformation (FFT)
Using LibTcod (Example)
GTK window, updated by GLib threads
Read numbers from a STRING
Drag & Drop
Dynamic arrays in UDTs (once again)
command plugin for Pidgin (libpurple)
Polynomial regression curve (linear regression)
Drawing a graph (libgoocanvas / GTK / Cairo)
FB_Calc, an example for a small GTK application
Fast text search (hash table / GLib)
Cairo: colored text/vector grafic for screen/printer/files
Internationalisation (I18N) in FB code
BitArray, a large number off booleans refered by an index
Legendre polynomials
X / Y regression analysis
[GTK] How to find the GTK+ version, installed on the system
t'lon nanaki
preventing a .bi file from being called multiple times
toneboy
Strange idea
Tourist Trap
Another button UDT with drag and drop
Code enrichment based on #define
Little dialog-box to exhibit a string array content
A graphical file browser
Concepts for making a gui object
Clean ending
Cell based textbox
Trick to access a static property
Basic object to vizualize binary tree
A Filereset function
Tiny directory reader with possibilities of extension
Christopher Heulin 3D tutorial
Simple yet standalone draggable circle
ANGLE udt: add, substract, compare, convert, draw all in one
Error log object similar to LasterrorGet in winapi
Change .bas extension to allow deeper windows search
Simple yet standalone button
Data block compression/un-compression
How to make tea by side-effect in freebasic
Simple yet standalone slidebar
2 cents gui maker
Image color component shift
Screen pixel ruler
A grid and some segment antialiasing demo
Hide the console
Bitmap image to Data File & Data to Screen
Dummy Block design. Re-implementing ASM blocks ..
Time Ellapsed Displayer UDT and function
tresoldi
Split strings
Turd
text scaler
Ubuntu logo
Tusike
L-Systems
TuxForAll
littel compiler benchmark (Just For Fun!)
VANYA
Shell extension for Windows (Explorer context menu)
Sort Array
Allegro examples
GDI+ Examples
stack of unidirectional linked list
Find (At the assembler inserts)
vbmrupp
Split Sub
VB Replace function
winuser header
vdecampo
Antialias Line Drawing
Read/Write Registry (Win)
DriveList Object (Win32)
Multi-DataType QuickSort
Source Code Counter
Checking for Illegal Float Operations
NeuroScape (Its Pretty! I'm Bored!)
Debug Output for Windows Dev
Big Number Adder/Multiply
Star Castle Source Code Released!
Berzerk 2.0 Source Code Released
IEEE Fast Square Root Approximation
Using FBEdit with KwikBASIC
Creating NEW Var Len String Pointers
Multikey Single Key Press
SString:OOP String Object
Creating Huge Files Quickly
Drawing Rounded Rectangles
Self-Destructing Images
Day of the Week
ALT+ENTER (From Code) - Win32
Hybrid FBImage/GDI Image Object (EXAMPLE)
Hybrid FBImage/GDI Image Object
Gfx Window Control (Windows Only)
Unoptimized YUV(YUY2)->RGB Conversion
Star Castle (Code Snip!)
Custom Font Parser/Display
32-Bit / 16-Bit RGB Converter
Printing using Win32 API
Direct Image Buffer Access Macros
CPU independent code timing
Veggiet
snowfall
Reinventing the "PRINT"
Velatus
(x)ini parser
linked list snippet
Vendan
SDL Rotated Blit Function
VirusEcks
Easy Split Function
Easy Replace Function
vladimir777
LATITUDE LONGITUDE and UTM projections CONVERTING
GTK MENU - TOOLBAR - examples
Voltage
You're a sphere cow.
Big scroller
OpenGL Lighting Basics
Particle fire engine
Fog of war (Warcraft style)
VonGodric
Define value ranges
safe enum ... sorta
for VM dev's. function calls with virtal stack
FHC - FreeBasic Helper Classes
callback list
Container list
OOP simulation in FB
voodooattack
IncFile() and IncArray() macros [Updated 22-1-2009]
Calling a member function in a new thread
Pseudo Exception Handling (Try/Catch and Throw) In FB
pseudo-oo using operator overloading
Random Encryption Algorithm
Hooking DLL imports -- aka wrapping..
Westbeam
2D shadows
very basic GUI(Buttons,unmovable windows and TextBoxs)
Very basic 3D-RTS game
OpenWIZ-GUI [Version 2.1] *Update*
[OpenB3D]Skyengine
Concept of an Gameboy(Advance) emulator and other Handhelds
[Linux]CPU and RAM informations
My filebrowser
TileEngine
GBA Header Viewer
Wolfbas
tinyptc for java
Funny 3D
wolfman775
Create a file assosiation (Windows only!)
Realy small TGA loader
CLS not fast enugh?
xbgtc
Text Scrambling
Xcoder
Zip_Quick - Zip Lib
Xecronix
Create and use static libraries
cast an Any ptr to one of a desired type
'default value for a function argument
xoutys
Http Proxy
Port Redirection
xroot
VB SendKeys For FB
Lock Window To Screen
FB To VB Fun
Polygons
Simple Way to PopUp DeskTop Menu
Splash Screen by MessageBox
Simple LED Clock
Real Fonts
Simple Melt with BitBlt
Hook MessageBox
yetifoot
Big number wrapper (using GMP int)
LZW example
Quick and dirty self hosting BASICish compiler
Screen Capture code for Windows
Floyd-Steinberg dither
SHBrowseForFolder example
My first OpenGL program - Sierpinski tetrahedron
Fractal Leaf
MD4
using qsort from crt to speed up sorts
Operator Precedence Parsing (Expression Parser)
Split arguments without having to split Command$
PE Info Viewer
Using the insight debugger.
How to screencapture to a jpeg using freeimage
A Sha256 dll with FB example
yuri
Fun effect
Zamaster
PerPixel Shadows Updated
The Ultimate FB HashMap
The Ultimate 2D Shape Intersection Suite
Electric Arcs
more triangles... (updated)
AI Platformer Pathfinding
Warp Speed screen scaling!
DES/LUCIFER Encryption/Decryption
SeqFile, like bload+ for text files
Hardware like triangles
Parallax Occlusion Mapping w/ Shadows
Neat Bumpmapping Trick
CPU HDR Bloom, at 100 fps
Public Key Cryptography
Sphere Routine
Speedy little Physics thing
ASM FSAA 16x
An artistic fire effect
Micro Demos Round 2
Faster Cubic Interpolation
Fluid Contour WIP
Fast 2D Light Casting
Eigenvalues of a 4x4 Matrix
FAST Plasma
AES Encryption/Decryption Algorithm
Wizard Balls
Really (potentially) awesome discovery.
Spider Walk!
AweXome Flaymz n' Kurves!í!í
Beautiful Tree Generator
Fast Plasma... again
Traveling Salesman Demonstration
A Turing Machine
Simple Fast Pixel Collision
Wave Of Waves
Weird Triple Wave
Super Memory Efficent Flood Fill = FINISHED
Zap!
Green Gloop!
MetaBalls!
Fraction Library
MARS Encrytion Algorithm
Radial Dot Fractal Generator
Some Animated Cloud Action, Improved Again!
Orbital Simulation
Spline Curve
Point In Triangle
zcbenz
Vista-style window
zerospeed
Unit Testing with FreeBASIC -> Now without memory leaking
Zippy
Win: Use arbitrary fonts & load GIF/JPG/PNG to gfx, API only
Windows print to console, with GFX screen
Windows console resize (and move OR center)
"OnTop" for Windows
99 bottles of beer on the wall.
Using getmouse(), input(), and inkey() in polling loops
Get program path from exe name or file extension
multikey/inkey/getkey variant for fbgfx screens on Windows
Create Windows shortcuts shortcut .lnk .url
CaSe-InSensitive InStr using extended regexp
Get Integer Array Descriptor
"On Timer" in console & fb gfx [Windoze-only]
"On Mouse" in fb gfx [on Windoze-only]
"On Key" in fb gfx [on Windoze-only]
"On Timer" in fb gfx [on Windoze-only]
zzo38
Converting QBASIC program into FreeBASIC
><


Oups, that's even bigger than I thought....
Ok now what made all this possible:

Code: Select all

'search for a string in a text used as a start marker         
'then extract a string from this marker to the next end marker

#define _textfile	"G:/textfile.txt"
#define _resultfile	"G:/posttreatmentfile.txt"

#macro _P(id)
	? #id, id :
#endMacro
#macro _DYNARRAYINCREASE(array)
    redim preserve (array)(lBound(array) to uBound(array) + 1)
#endMacro
#macro _DYNARRAYDECREASE(array)
    if uBound(array)>lBound(array) then
        redim preserve (array)(lBound(array) to uBound(array) - 1)
    elseIf uBound(array)=lBound(array) then
        erase (array)
    end if
#endMacro
#macro _DYNARRAYINCREASEBYRANGE(array, range)
    redim preserve (array)(lBound(array) to uBound(array) + range)
#endMacro
#macro _DYNARRAYDECREASEBYRANGE(array, range)
    if range<(uBound(array) - lBound(array) + 1) then
        redim preserve (array)(lBound(array) to uBound(array) - range)
    elseIf range=(uBound(array)-lBound(array)+1) then
        erase (array)
    end if
#endMacro
#macro _ARRAYFIRSTITEM(array)
    array(lBound(array))
#endMacro
#macro _ARRAYLASTITEM(array)
    array(uBound(array))
#endMacro
#macro _ARRAYRANGE(array)
    (uBound(array) - lBound(array) + 1)
#endMacro

#macro _POPULATESTARTMARKERARRAY(arr...)
        dim as string starterArray(...) = { arr }
#endmacro
#macro _POPULATEENDMARKERARRAY(arr...)
        dim as string enderArray(...) = { arr }
#endmacro

#macro _STARTERFOUNDAT(position)
	starterFoundAt = position :
#endMacro
#macro _ENDERFOUNDAT(position)
	enderFoundAt = position :
#endMacro

function EndOfLine(byref TextLine as string) as boolean
	if len(TextLine)=0 then 
		'---->
		return TRUE
	else
		TextLine = right(TextLine, len(TextLine) - 1)
		'---->
		return FALSE
	end if
end function


'---------------------------------------------------INITIALIZE
'width 100
dim as integer	starterFoundAt
dim as integer	enderFoundAt
dim as string	tokenArray(any)

'create the text markers
_POPULATESTARTMARKERARRAY("class=""topictitle"">", "username"">",  "href="""               )
_POPULATEENDMARKERARRAY(  "</a>",                  "</a> &raquo;", """ class=""topictitle" )


dim as boolean	starterOverflow => FALSE
dim as boolean	enderOverflow => FALSE
dim as integer	overflowRange
if uBound(starterArray)<>uBound(enderArray) then
	color 12
	? "be aware that the marker arrays are not equally sized!"
	color 7
	sleep 1000, 1
	if uBound(starterArray)<uBound(enderArray) then
		starterOverflow = TRUE
	elseIf uBound(starterArray)<uBound(enderArray) then
		enderOverflow = TRUE
	end if
	overflowRange = abs(uBound(starterArray) - uBound(enderArray))
end if

'---------------------------------------------------------MAIN
dim as integer	fileNum => freeFile()
open _textfile for input as #fileNum


'read the text line after line, seek for token within each lines:
'for each textline..
dim as string	textline
dim as integer	lineCounter
while not eof(fileNum)
	'count line
	lineCounter += 1
	'read textline
	line input #fileNum, textline
	'store textline
	dim as string	initialTextLineCopy => textLine
	'
	'for each starter..
	dim as integer	starterPosArray(any)
	for starterIndex as integer = 0 to uBound(starterArray)
		'make the starter string a char array
		redim as string	starterChar(len(starterArray(starterIndex)))
		'fill the char array
		for charIndex as integer = 0 to len(starterArray(starterIndex)) - 1
			starterChar(charIndex) = mid(starterArray(starterIndex), charIndex + 1, 1)
		next charIndex
		'
		'for each linepos..
		dim as integer	linepos
		dim as string*1 carret
		while not EndOfLine(textline)
			'count linepos
			linepos += 1
			'char read at linepos
			carret = mid(initialTextLineCopy, linepos, 1)
			'compare with starterChar(0)
			if carret=starterChar(0) then
				'test if the current starter is found
				if starterArray(starterIndex)=mid( initialTextLineCopy, _ 
												   linepos, _ 
												   len(starterArray(starterIndex)) ) then
					_STARTERFOUNDAT(linepos)
					'
					'make the char array of corresponding ender
					redim as string	enderChar(len(enderArray(starterIndex)))
					for charIndex as integer = 0 to len(enderArray(starterIndex)) - 1
						enderChar(charIndex) = mid(enderArray(starterIndex), charIndex + 1, 1)
					next charIndex
					'for each deeperlinepos..
					dim as string	deepSearchTextLine = _ 
									right(textline, len(textline) - len(starterArray(starterIndex)) + 1)
					textline = deepSearchTextLine
					dim as integer	deeperlinepos
					while not EndOfLine(deepSearchTextLine)
						'count deeperlinepos
						deeperlinepos += 1
						'char read at linepos
						carret = mid(textline, deeperlinepos, 1)						
						'compare with enderChar(0)
						if carret=enderChar(0) then
							'test if the current ender is found
							if enderArray(starterIndex)=mid( textline, _ 
															 deeperlinepos, _ 
															 len(enderArray(starterIndex)) ) then
								_ENDERFOUNDAT(deeperlinepos)
								if starterIndex=0 then
									_DYNARRAYINCREASE(tokenArray)
									_ARRAYLASTITEM(tokenArray) = "<newuser>"
								end if
								'
								'grab the information token
								_DYNARRAYINCREASE(tokenArray)
								_ARRAYLASTITEM(tokenArray) = mid( textline, _
																  1, _ 
																  enderFoundAt - 1)
								'
								'go backward until (last) (reverse-)starter is reached
								'build reverse starter
								dim as string	reverseStarter
								for i as integer = _ 
								(len(starterArray(starterIndex)) + 1) to 1 step -1
									reverseStarter &= mid(starterArray(starterIndex), i - 1, 1) 
								next
								''detect reverse starter
								for index as integer = 0 to (len(_ARRAYLASTITEM(tokenArray)) - 1)
								'	'backward traversal
									carret = mid( _ARRAYLASTITEM(tokenArray), _ 
											 len(_ARRAYLASTITEM(tokenArray)) - index, _ 
											 1 )
									if carret=string(1, reverseStarter) then
										if starterArray(starterIndex)= _ 
										mid( _ARRAYLASTITEM(tokenArray), _ 
										len(_ARRAYLASTITEM(tokenArray)) - index - len(reverseStarter) + 1, _ 
										len(reverseStarter) ) then
											'_ARRAYLASTITEM(tokenArray) = ""
											_ARRAYLASTITEM(tokenArray) = _
														right( _ARRAYLASTITEM(tokenArray), _ 
														index)
											exit for
										end if
									end if
								next index
								'exit loop
								exit while
							end if
						end if
					wend
					'
				end if
			end if
		wend
	'
	'reset to initial state
	textline = initialTextLineCopy
	next starterIndex
wend
'
close #fileNum

'-----------------------------------------------POST-TREATMENT
color 10
? uBound(tokenArray)
for i as integer = 0 to uBound(tokenArray)
	if tokenArray(i)="<newuser>" then
		color 10
	else
		color 11
	end if
    ? i, tokenArray(i)
next i

dim as integer	startIndex	=> -1
dim as integer	endIndex	=> -1
dim as integer	resfileNum =freeFile()
open _resultfile for output as #resfileNum
	for index as integer = 0 to uBound(tokenArray)
		if tokenArray(index)="<newuser>" andAlso startIndex=-1 then
			startIndex	= index
			endIndex	= -1
			do
				index 		+= 1
			loop until tokenArray(index)="<newuser>" orElse index=uBound(tokenArray)
			if index=uBound(tokenArray) then exit for
			endIndex	= index - 1
			/'
			color 15
			?  tokenArray(endIndex)
			color 9 
			? tokenArray(startIndex + 1)
			? tokenArray(startIndex + 2)
			color 7
			? "......................."
			'/
			print #resfileNum, _ 
			tokenArray(endIndex) &"|"& "[url="& tokenArray(startIndex + 2) &"]"& tokenArray(startIndex + 1) &"[/url]"
		end if
		'
		startIndex = -1
		index = endIndex
	next index
close #resfileNum

'----------------------------------------------------TERMINATE

getKey()
'(eof)
The principle was to parse the html sources of the pages, and to make a table. I've sorted it externally because it's not that easy to do word sorting. At least I still don't see how.

To get the pages needed [SNC] is a very smart choice:

Code: Select all

'     [S]imple [N]etwork [C]onnection
'credits go to the author(*) for the library
'http://www.freebasic.net/forum/viewtopic.php?f=7&t=23421

'(*) well known author, you should find easily!

#include once "snc.bi"
#include once "snc_utility.bi"

'client connection to freebasic to get interesting pages_______
'______________________________________________________________

const as string ServerName  = "freebasic.net"
dim as string ServerPath    = "/forum/viewforum.php?f=7"
const as string ServerFile  = ""
const as string FileType    = MIME_HTM &";"& MIME_TXT


for page as integer = 1 to 65
    ' connect to web server at port 80...
    dim as NetworkClient client=type(ServerName,80)
    ' get a connection from ConnectionFactory...
    var connection = client.GetConnection()
    ' build an HTTP GET request...
    dim as string request = HTTPGet(ServerName, _ 
                                    ServerPath & ServerFile, _ 
                                    FileType)    
    ' ready to send ?
    while connection->CanPut()<>1
      sleep 100
    wend
    ' put data on the connection
    connection->PutData(strptr(request), len(request))
    ' ready to receive ?
    while connection->CanGet()<>1
      sleep 100
    wend
    
    dim as zstring ptr buffer
    var nBytes = connection->GetData(buffer)
    print "number of received bytes " & nBytes
    ' get last char position of the HTTP asci header
    var LastChar    = instr(*buffer,HeaderEnd) - 1
    var Header      = left(*buffer,LastChar)
    ' is it a OK answer ?
    if instr(Header,"200 OK")<1 then
        print *buffer
        print "can't get " & ServerName & ServerPath & ServerFile & " !"
        beep : sleep : end
    end if
    ' get first byte behind the HTTP asci header
    var DataStart = LastChar + 4
    
    ' save it
    dim as string pagename = "page"& str(page) &".txt"
    open pagename for binary access write as #1
        dim as ubyte ptr FileBuffer = @buffer[DataStart]
        nBytes -= DataStart
        put #1, , *FileBuffer, nBytes
    close #1
    print "file "& page &" saved ..."
    
    ' free the buffer (allocated by snc.bi)
    deallocate buffer
    
    'http://www.freebasic.net/forum/viewforum.php?f=7&start=30
    ServerPath = "/forum/viewforum.php?f=7"&"&start="& str(page*30)
next page

'______________________________________________________________

? "end"
sleep
'(eof)
This all certainly generalizes to any other web page that provide some data to parse. At least this way a good amount of the work can be automated, scheduled, and so on. ..


For the list of topics, it's very clear that some of them have been lost on the operation. Where? That's a good question... Sorry for the injuried authors!
BasicCoder2
Posts: 3906
Joined: Jan 01, 2009 7:03
Location: Australia

Re: The big review

Post by BasicCoder2 »

Thanks Tourist Trap for an interesting attempt at collating all that code.
Usually if I want to find code on a certain topic I would use the Search facitility of the forum.
The problem of course is finding a keyword.
Also listing according to topic would be more useful than by author which is possible with the forum's Search facility if you can find the right keyword.
I have the same problem when searching for some code I know I have written but can't find it with the file search facility of the File Explorer.
It is important to give the programs a name that corresponds to what is does. I guess some programmers are better at grouping their code in a meaningful way than others. I have attempted to collect and label programs that I thought I would find useful in the future into their own folder which in turn I placed into a folder called GoodStuff :) What I find useful is of course a personal bias to the subjects that interest me and where the source code is also readable and understandable to me which is usually only stuff I write myself.
.
dafhi
Posts: 1641
Joined: Jun 04, 2005 9:51

Re: The big review

Post by dafhi »

I'm not sure how your code works, as I am new to some of what you've posted,
but right out of the gate I found some very cool posts.

useful and rather unprecedented. Thanks!
Dr_D
Posts: 2451
Joined: May 27, 2005 4:59
Contact:

Re: The big review

Post by Dr_D »

Does anyone know what happened to 1000101?
Tourist Trap
Posts: 2958
Joined: Jun 02, 2015 16:24

Re: The big review

Post by Tourist Trap »

Dr_D wrote:Does anyone know what happened to 1000101?
Didn't know him, but hope it has not been shift-left. Maybe it has been simply incremented? ;-)
dafhi wrote:I'm not sure how your code works, as I am new to some of what you've posted, but right out of the gate I found some very cool posts.
It's ideal for the hollydays, it all can be read more or less like a magazine.

About the program, it's quite simple. It's possible to read and parse the rendered html page, but it lacks markers to make the whole thing easy (the context, or the formatting are often the only markers and require some analysis that I find difficult). In another hand, it's not readable for the human to get the html code, but it's plenty of markers to enclose content.
The code here just define a list of couple of markers, starting marker, and ending marker. Then it reads the html page (without any optimisation at all here), seek for data enclosed within the 2 markers, and stores it in an array. This is all done linearly, and without taking too much care of special issues. Unfortunately code for parsing things is as usual unreadable.
The [SNC], simple connexion tool by D.J. Peters allows one to get the html code in an automated way, so this is also less work for the human. Thanks for this.
It could be improved a lot (not SNC, this all process I mean) . But proof is shown here that it's a very affordable task in FB.
BasicCoder2 wrote: Also listing according to topic would be more useful than by author which is possible with the forum's Search facility if you can find the right keyword.
Yes I've tried at first but it was too hard. Or I'll need something like I'm playing with at ATOZ dummy project that I've posted recently. This is a project that I'm doing to try to really get a full project completed once! What the program does there is to count word frequency in a text file. On this basis, I think we could automate a sorting by topic, at least by keyword relative frequency.
BasicCoder2 wrote: It is important to give the programs a name that corresponds to what is does. I guess some programmers are better at grouping their code in a meaningful way than others. I have attempted to collect and label programs that I thought I would find useful in the future into their own folder which in turn I placed into a folder called GoodStuff :)
If really I had to go further (a matter of time!) I would try to do things such that one could gather topics of its own interest locally in its hard-disk, making it possible to use any stuff and database to seek for the information with all the customization.
For a reader that uses the forum, the ability to manage accurately at any time the valuable discussions would probably be a boost for his learning curve.
integer
Posts: 408
Joined: Feb 01, 2007 16:54
Location: usa

Re: The big review

Post by integer »

Tourist Trap wrote:The big review
Tips&Tricks section snapshot at Aug.2016, sorted by author names. I think it can be useful here because tips and tricks are a source of enlightement even at page 65.

Note: Tool written in freebasic to get the whole list joined at the very bottom.
...
This is VERY useful.
Thank you.
Provoni
Posts: 513
Joined: Jan 05, 2014 12:33
Location: Belgium

Re: The big review

Post by Provoni »

Thank you!
PeterHu
Posts: 148
Joined: Jul 24, 2022 4:57

Re: The big review

Post by PeterHu »

This is a treasure! Thank you so much!
Post Reply