Face count. Is there a limit

Blitz3D Forums/Blitz3D Beginners Area/Face count. Is there a limit

carpman(Posted 2003) [#1]
I'm having a problem loading a fairly large .b3d file into Blit3D. It's a model of a town built with 3DCANVAS, exported as a single object in .x format and converted to .b3d with Stickmans DX8 to B3D. Total faces= 1866. The problem is if take the number of faces above 1866 I get a MEMORY ACCESS VIOLATION when I try to convert to .b3d. I loaded the same .x file into GILE(S) and exported this to .b3d without a problem but when I try to get blitz to load the file guess what? MEMORY ACCESS VIOLATION!!!!
I havn't quite finished building the model yet so any help with this would be much appreciated.
Thanks
>CARPMAN


Tracer(Posted 2003) [#2]
1866 faces is nothing :)

Turn on debugging (in one of the menus) and run it again, see if you get an actual error message then..

Tracer


carpman(Posted 2003) [#3]
Tracer, thanks I've tried that but get the same message.

>Carpman


Tracer(Posted 2003) [#4]
Odd, make sure that ALL the files needed are being loaded.

In your code, after you load all your stuff.. put a "STOP" command.. make sure the debugger is on and run.. it'll halt the program.. check all the variables where you load stuff into are greater than 0 (zero) .. if one is zero.. whatever it is supposed to load into that variable, isn't there and will bomb out.

And if all else fails..post your code, that'll help the people trying to help you a lot.

Tracer


Ross C(Posted 2003) [#5]
Might be a bug in stickmans converter too. But yeah, post the code :)


carpman(Posted 2003) [#6]
OK. I've done some more tests as follows, I loaded the original .x file into Gile(s) and exported it as both a .b3d
file and an .x file. The .x format loads perfectly into Blitz but the .b3d file brings up the MEMORY ACCESS VIOLATION. Strange!
Code as follows:-

scene=LoadMesh("models/city1_Test.b3d");Debug stops here
PositionEntity scene,0,-66,50
ScaleEntity scene,1.25,1.25,1.25
EntityType scene,scene_col
EntityPickMode scene,2

Changing to .x instead of .b3d works fine!
Guess its a problem converting to .b3d or .b3d dosn't like
my models to be over a certain size. If I reduce the number of faces to 1866 or below the .b3d file works ok. I,ll just have to stay with .x till I work this one out

>Carpman


Ross C(Posted 2003) [#7]
So, the way Gile[s] exports it to .b3d is wrong also? Make sure about your textures to. .X may save the location of them differently.


TeraBit(Posted 2003) [#8]
@Carpman - Is your version of Blitz3D up to date?

The reason I ask is that I know several people were having problems with just the last version of Blitz with B3D files that contained lightmaps or blank textures.


carpman(Posted 2003) [#9]
Ross
>So, the way Gile[s] exports it to .b3d is wrong also?
I take the point, both exporting the same error, not likley.

Lee
I,ve had problems with V1.85 so went back to V1.83 about a month ago.
>Thanks Carpman


TeraBit(Posted 2003) [#10]
Hmmm. That's probably what is doing it then. Someone had exactly the same thing using levels written out from Decorator.

Try writing out a decorator level and seeing if you get the same thing.

If you want to give it a try, Decorator can be downloaded Here

Alternatively send me the B3D file that crashes along with a little view code (and any textures it needs), and I can test it here for you.


AbbaRue(Posted 2003) [#11]
In my experiance I find that X files render faster then
most other file formats, so why would you want to convert?
Try a speed test for yourself, I think you will find that
you get a higher frame rate using the X file version over
the b3d version. Let me know if you do.


carpman(Posted 2003) [#12]
lee,
Thanks, I've downloaded DECORATOR I'll give it a try and see what happens.If I can't sort it out I'll send you the files. Thanks a lot.

Abbarue,
I started using .b3d files because I coudn't get the .x format to work with boned animations in Blitz and thought I'd keep all the files the same, especially after purchasing GILES(S). Initally you could only export .b3d but now .x is included so I'll give it a try. I didn,t know thier was any speed differnce.
>Carpman


carpman(Posted 2003) [#13]
Lee,
The .b3d file that wouldn't load into Blitz happily loads into DECORATOR. If I then save it back out as the same .b3d file it loads ok into Blitz. So from this you could assume that both DX8 to B3D and GILE(S)are exporting the file differently to DECORATOR. However as a test I loaded the DECORATOR file into GILE(S) saved it again as .b3d and Blitz loaded it ok. Any ideas on what's happening?
So the procedure now is, export the model from 3DCANVAS in .x, load into DECORATOR and do whatever,save as .b3d, load into GILE(S) and do the lightmap,export as .b3d and load into Blitz.
>Carpman


TeraBit(Posted 2003) [#14]
Weird, since all I do in Decorator is LoadMesh()...

I would guess that if you upgrade to the latest blitz version, the problem will go away.


carpman(Posted 2003) [#15]
I've done the upgrade back to v1.85 and everthing's now working fine. DX8 to B3d still won't convert the file but I can use GILE(S) or Decorator instead.
Thanks.
>Carpman


TeraBit(Posted 2003) [#16]
Glad it worked out :)