MiniB3d for FreeBasic
-
- Posts: 8586
- Joined: May 28, 2005 3:28
- Contact:
Re: MiniB3d for FreeBasic
@Gunslinger you never posted the problem of .3ds loading with my build of the lib.
The right forum section is libOpenB3D-1.25 not MiniB3d !
How ever I will look for the problem on weekend, but I self never changed or used the 3ds loader before.
Joshy
The right forum section is libOpenB3D-1.25 not MiniB3d !
How ever I will look for the problem on weekend, but I self never changed or used the 3ds loader before.
Joshy
-
- Posts: 8586
- Joined: May 28, 2005 3:28
- Contact:
Re: MiniB3d for FreeBasic
It works with libOpenB3D-1.25 from 2019 tested on Windows and Linux both 32 and 64-bit !
I upload "fighter.3ds" in the zip file see LoadMesh.bas.
By the way your code is "2018" you have to read the notes about changes in the "openb3d.bi" file.
Again "MiniB3d or OpenB3d" and "libOpenB3D" isn't the same !
Both use the C++ library but the interface are different.
For example in my build RGBA colors are in range of 0.0 - 1.0 each
while the other or original interface use 0-255 for RGB but 0.0-1.0 for A.
Use MiniB3d/OpenB3d if it the right for you
but if you use "libOpenB3D-1.25" use the right forum section for any questions or problems.
Happy 3D coding.
Joshy
I upload "fighter.3ds" in the zip file see LoadMesh.bas.
By the way your code is "2018" you have to read the notes about changes in the "openb3d.bi" file.
Again "MiniB3d or OpenB3d" and "libOpenB3D" isn't the same !
Both use the C++ library but the interface are different.
For example in my build RGBA colors are in range of 0.0 - 1.0 each
while the other or original interface use 0-255 for RGB but 0.0-1.0 for A.
Use MiniB3d/OpenB3d if it the right for you
but if you use "libOpenB3D-1.25" use the right forum section for any questions or problems.
Happy 3D coding.
Joshy
Re: MiniB3d for FreeBasic
First attempt to add sound support to OpenB3D
https://sourceforge.net/projects/minib3 ... p/download
https://sourceforge.net/projects/minib3 ... p/download
-
- Posts: 44
- Joined: Nov 07, 2019 21:57
Re: MiniB3d for FreeBasic
How do I install a Library to FBIDE?
Re: MiniB3d for FreeBasic
Sorry, but the question is 'all wrong'.IvanisIvan wrote:How do I install a Library to FBIDE?
Libraries are installed into the Compiler-Tree (FBC's file structure) and not any IDE.
E.g.: you have FBC (64 bit) in C:\FreeBASIC\fbc.exe (and more files) then
Libraries go to C:\FreeBASIC\lib\win64\ (..\win32\ for 32 bit FBC)
(just a example for a Windows installation)
Important: the bitness of compiler and libraries must be the same (mandatory).
Re: MiniB3d for FreeBasic
Put the library file (.a or .dll) into the same folder as your code calling it.
It will work perfectly well this way.
If you really like the library (static .a), then do as Mr Swiss advises.
Any .dll you like you can put into your system folder (system32 windows) and put the .dll.a file into the lib folder as Mr Swiss advises.
FB will always produce a .dll.a file if you create a .dll with fb.
Otherwise you will have to create your own with dlltool.exe and gendef.exe.
It will work perfectly well this way.
If you really like the library (static .a), then do as Mr Swiss advises.
Any .dll you like you can put into your system folder (system32 windows) and put the .dll.a file into the lib folder as Mr Swiss advises.
FB will always produce a .dll.a file if you create a .dll with fb.
Otherwise you will have to create your own with dlltool.exe and gendef.exe.
Re: MiniB3d for FreeBasic
Hi Ivan,IvanisIvan wrote:How do I install a Library to FBIDE?
As an example, the Cairo library would sit in two locations:
C:\MyBasics\FreeBasic\lib\win32\Cairo\*.dll
C:\MyBasics\FreeBasic\inc\Cairo\*.bi
Once the necessary files sit there, you can compile e.g. C:\MyBasics\FreeBasic\lib\win32\Cairo\line.bas (if you do it from other locations, it will not find the necessary includes, unless you manually set the PATH variables).
P.S.:
Ignore him ;-)MrSwiss wrote:Sorry, but the question is 'all wrong'.
-
- Posts: 44
- Joined: Nov 07, 2019 21:57
Re: MiniB3d for FreeBasic
Thank you! If I could upvote this, I would. :Djj2007 wrote:Hi Ivan,IvanisIvan wrote:How do I install a Library to FBIDE?
As an example, the Cairo library would sit in two locations:
C:\MyBasics\FreeBasic\lib\win32\Cairo\*.dll
C:\MyBasics\FreeBasic\inc\Cairo\*.bi
Once the necessary files sit there, you can compile e.g. C:\MyBasics\FreeBasic\lib\win32\Cairo\line.bas (if you do it from other locations, it will not find the necessary includes, unless you manually set the PATH variables).
P.S.:Ignore him ;-)MrSwiss wrote:Sorry, but the question is 'all wrong'.
-
- Posts: 44
- Joined: Nov 07, 2019 21:57
Re: MiniB3d for FreeBasic
I'm going to sound real stupid but I can't seem to find minib3d.bi. I downloaded the zip file from https://sourceforge.net/projects/minib3d/. Please tell me what I am doing wrong.
Re: MiniB3d for FreeBasic
Try this post: viewtopic.php?f=14&t=27233
-
- Posts: 44
- Joined: Nov 07, 2019 21:57
Re: MiniB3d for FreeBasic
thank you, that was very helpful!jj2007 wrote:Try this post: viewtopic.php?f=14&t=27233
Re: MiniB3d for FreeBasic
In the later version it's called openb3d.biIvanisIvan wrote:I can't seem to find minib3d.bi
Re: MiniB3d for FreeBasic
@D.J.Peters
In the past you complained that in 64 bit mode the words "near" and "far" used in octree.h and octree.cpp prevent compilation, and I replied that I was able to compile in 64 bit with no issues. I realized now that the issue occurs only under some compilers in windows, and it doesn't depend on the fact that near and far are reserved words, but on the fact that they are defined to nothing in the file minwindef.h (so the variable names are removed by the preprocessor). That happens to help compiling old, 16 bit source codes still designed for Windows 3.1
So, the simplest fix is to #undef near and far in the file octree.h
In the past you complained that in 64 bit mode the words "near" and "far" used in octree.h and octree.cpp prevent compilation, and I replied that I was able to compile in 64 bit with no issues. I realized now that the issue occurs only under some compilers in windows, and it doesn't depend on the fact that near and far are reserved words, but on the fact that they are defined to nothing in the file minwindef.h (so the variable names are removed by the preprocessor). That happens to help compiling old, 16 bit source codes still designed for Windows 3.1
So, the simplest fix is to #undef near and far in the file octree.h
Re: MiniB3d for FreeBasic
New version is online. Some minor fixes, no new features added, besides the fact that now it should be usable with FreeBasic Emscripten branch
Also, with make is now possible to use "make static" to compile a version for static linking (under Linux, it works well, under Windows, it requires you to have the same version of mingw for the C++ compiler and for FreeBasic: since FreeBasic carries its own version of Mingw, this is not always true)
Also, with make is now possible to use "make static" to compile a version for static linking (under Linux, it works well, under Windows, it requires you to have the same version of mingw for the C++ compiler and for FreeBasic: since FreeBasic carries its own version of Mingw, this is not always true)
Re: MiniB3d for FreeBasic
Hello!
I have a problem with MiniB3d:
first, I create a texture:
then, after I create an entity and scale it to bigger, I add this texture to this entity:
The borderwall will be enough width, and the texture stretching on it and I don't want this, because I would like a repeating texture on this width wall, not a coloured, long strip.
I tried solve this with using flag 16 in the loadtexture, but the result is the same. I don't know, what's wrong: my technique or the version of MiniB3d doesn't be able to this yet? Version of my MiniB3d is 1.1.
I have a problem with MiniB3d:
first, I create a texture:
Code: Select all
walltexture=loadtexture("pics\brickwall.jpg")
Code: Select all
borderwalls(0).image=CreateCube()
ScaleEntity borderwalls(0).image,wallwidth*pixels,1,1
EntityTexture borderwalls(0).image,walltexture
I tried solve this with using flag 16 in the loadtexture, but the result is the same. I don't know, what's wrong: my technique or the version of MiniB3d doesn't be able to this yet? Version of my MiniB3d is 1.1.