screenshot would be hard consideing its not done it since i saved and reopened pro
the actual code i was writing at the time was
function Release()
`{
local i as integer
for i=total to 0 step -1
next i
endfunction
`} void
the only other stuff there was just my standard basic framework i've used 100x before
remstart
/*
Developer: FMTau Labs LLC
Title: Fresnel Reflect & Refraction Demo
Version: 0.00.1 alpha (Build 0000)
Date: 21-05-2003
Additional Notes:
alot of newer cards support Vertex Shader 1.1 which is what i've
used for this demonstration. If you're unsure if you card supports this
then don't worry because i've setup a checker to make sure you can
so if it runs then you card does support them.
*/ ** FresnelRnR.src.dba ****
remend
`------------------------------
`// Constants & Globals
`------------------------------
#constant TRUE=(1=1)
#constant FALSE=(1=0)
type Vec3_t
x,y,z as float
endtype
global g_pObject as integer
`// perform a precheck to find out if your card supports the nessary effects
if CheckDisplay()=FALSE
`{
center text screen width()/2,screen height()/2,"Sorry, your card doesn't appear to support the nessary Shaders"
wait key
end :`// don't goto quit else it'll crash because it'll try to release things not initilised (^_^)
`}
endif
`==============================
`// Main Loop //
do
`{
if cMainApp()=TRUE then goto quit
loop
`}
`==============================
`// quit application
quit:
Release()
end
`/* -------------------------------------
` Name: cMainApp()
` Desc: Main Application class function
` ------------------------------------- */
function cMainApp()
`{
local result as boolean
if MainAppPrivate<>FALSE then goto Public
global MainAppPrivate as boolean
Private:
MainAppPrivate=TRUE
OneTimeInit()
RestoreScene()
Public:
FrameMove()
endfunction result
`} boolean
`/* ------------------------------------------------
` Name: FrameMove()
` Desc: per frame containment
` ------------------------------------------------ */
function FrameMove()
`{
endfunction
`} void
`/* ------------------------------------------------
` Name: OneTimeInit()
` Desc: Initilise the instances or values which
` only require to be made once
` ------------------------------------------------ */
function OneTimeInit()
`{
global m_pSphere as integer : m_pSphere=(g_pObject=g_pObject+1)
endfunction
`} void
`/* ------------------------------------------------------
` Name: RestoreScene()
` Desc: call to restore scene instance which are dropped
` when you resize or change the screen
` ------------------------------------------------------ */
function RestoreScene()
`{
make object sphere m_pSphere,100.0,16,32
endfunction
`} void
`/* ---------------------------------
` Name: CheckDisplay()
` Desc: any display checks put here
` --------------------------------- */
function CheckDisplay()
`{
local result as boolean
local vs as float
result=FALSE
vs=get maximum vertex shader version()
if vs=1.1 then result=TRUE
endfunction result
`} boolean
`/* ---------------------------------
` Name: Release()
` Desc: releases all used instances
` --------------------------------- */
function Release()
`{
local i as integer
for i=g_pObject to 0 step -1
if i<>0 then delete object i
next i
endfunction
`} void
remstart
/*
Credits:
-- Programming ----
Robert 'Raven' Lettan
Robert James
-- Beta Testers ----
Copyright© 2003 FMTau Labs, LLC. All Rights Reserved.
Version 0.00.r1.alpha.0000
*/
remend
that was the source in full at the time - i've not altered it since then either because i wanted to actually get a Shader Extention DLL working cause thats what bert asked for.
Within the Epic battle of the fates the Shadow and the Angel will meet. With it will harbinger the very fight of good vs evil!