« August 2008 | Main | December 2008 »

September 2008 Archives

September 1, 2008

C# .NET 3D Frameworks - Part II

Axiom Multiverse is out of the picture as it failed the most simple compile test. I downloaded the package and tried to compile it with Visual Studio 2008, but Multiverse doesn't include all the necessary codes to compile it. So the last native candidate is gone.

MOGRE does compile with Visual Studio 2008. It's another win by default and not necessarily by technical merit.

So it's either MOGRE or nothing. Nothing meaning, that I don't do the 3D in C# but instead opt for a separate C++ app that I myself bridge into C# or that communicates with the C# App.

Blender 2.47 moan

So I want to create some simple 3D models and show them in a 3D viewer in my "enterprise" app. The easiest way would be to create the models with a 3D modelling studio, import them into the code and then modify them a little to taste before viewing. I figured the first stop for this is probably Blender.

Now the last time I touched a 3D modelling tool has been on an Atari ST... or so. I remember that creating models in a 3D view was a real pain, and that ultimately I was editing the models usually in a kind of spreadsheet list manually and seeing the changes in real time in the 3D view.

After about three hours with Blender it has become fairly clear, that there has been virtually no progress except that Blender can't even do the basics well. The very first very obvious bug (Mac OS X or Windows) is this: Start Blender and you get a default scene with three objects (lamp, camera, cube). Now go into the outline view and you see... nothing (or almost nothing), which is pretty perplexing. Actually it's a simple redrawing problem, when you switch the view to "Oops Schematic" and back then you get the contents.

Blender redraw bug

More hair pulling is the boneheaded way the selection works in Blender and how the inspector window isn't updated correctly. The thing is, if you say deselect all 'A', it's not really deselecting all. Your last object stays selected. So if you want to switch to another object by then selecting it with 'B', oh no, you have a multiple selection, because selecting is additive. If you are doing a multiple selection, the inspector can't really display it, so cleverly the old contents stay and are still editable. You don't even see, how many objects you have selected, unless you have the outline view open, which apparently is mandatory to have open all the time (see Atari ST times), and also the only(?) way to really select only one item.

But Blender can take gestures to initate rotations or translations and reorganize the panels with fluid animation, developer time surely well spent...

Now Blender may be otherwise a fine product, but I have my doubts...

A cursory glance at other free 3D Modellers

While looking for an alternative to Blender I checked out these alternatives...

NameCommentVerdict
Art Of Illusion 3DNeither the 2.5.1 nor the the 2.6.1 installer .exe worked on Windows.FAIL
GroIMP-0.9.7Java jar without accompanying .BAT, didn't look so promising/fitting in the first place.FAIL
OpenFX 2.0A nice looking editor, but I couldn't find a useful object list view.FAIL
Moonlight-0.2.0Java yet again. No .BAT file to start it. Screenshots didn't look too bad though.FAIL
Ayam 1.13Needs an obsolete render engine. Looked extremely poor.FAIL
AvoCADo-08.03Java :( but comes with a .BAT file! Which doesn't work :(FAIL
K-3D 0.7.9It looked very promising for exactly 45seconds and then crashed when I tried to move a sphere.FAIL

The last try will be trueSpace from Caligari a hefty -used to be commercial- package and then it's back to Blender (yuck).

September 21, 2008

Limiting Stacksize for recursion debugging

This can be handy in recursion crashers, where Xcode takes half an hour to resolve symbols.
   struct rlimit rlim;
   getrlimit(RLIMIT_STACK, &rlim);
   rlim.rlim_cur = 0x8000;
   setrlimit(RLIMIT_STACK, &rlim);

-[CFDictionary retain] bug

This is a strange one. I don't see anything illegal I am doing. NSMutableDictionary's real class is of course CFDictionary and that will be returned from class. But why is it going into recursion on retain ?

#import <Foundation/Foundation.h>


int main (int argc, const char * argv[]) 
{
   NSAutoreleasePool     *pool;
   NSMutableDictionary   *dict;
   NSMutableDictionary   *other;
   
   pool = [NSAutoreleasePool new];

   dict  = [NSMutableDictionary dictionary];
   other = [[[dict class] new] autorelease];
   
   NSLog( @"A");
   [other retain]; // Program received signal:  “EXC_BAD_ACCESS”.
   NSLog( @"B");
   
   [pool release];
   return( 0);
}

UPDATE: Thanks to Ken Ferry from the MacOSXDev mailing list, this piece of code can be made usable thusly:
   other = [[[dict classForCoder] new] autorelease];

About September 2008

This page contains all entries posted to Nat!'s Web Journal in September 2008. They are listed from oldest to newest.

August 2008 is the previous archive.

December 2008 is the next archive.

Many more can be found on the main index page or by looking through the archives.

Powered by
Movable Type 4.25