Modules..

BlitzMax Forums/BlitzMax Programming/Modules..

ckob(Posted 2006) [#1]
ok lets say there is a existing 3d engine I would like to use in Blitzmax, what are the steps I would need to do in order to make a module or wrap it so I can use it with Blitzmax? I've never writting a module and I havent really found any detailed instructions. Could I do this without having an extensive knowledge on the 3d engine im wrapping?


Dreamora(Posted 2006) [#2]
1. Create a module server folder (like pub.mod, brl.mod etc), lets say test.mod
2. create the module folder (lets say 3dwrap.mod) within that folder
3. create a bmx file named 3dwrap.bmx which has the line module test.3dwrap at the top

4. write the code. If you want to wrap you will need to use extern to use the functionality of a DLL / C / CPP

To build the module you simply need to use build modules (which means that you need to have mingw installed and set the environment variables as described by MarkSilby in the thread on this topic)


ckob(Posted 2006) [#3]
yeah I knew that much thanks though.

talking with nowel now on msn..err was before msn went down


taxlerendiosk(Posted 2006) [#4]
You shouldn't need extensive knowledge of the 3D engine, just to know the expected inputs and outputs of the command set, and how to sensibly convert them to/from the BlitzMax equivalents.