Jump to content
  • entries
    943
  • comments
    5,899
  • views
    923,763

iWerks


Josh

4,841 views

 Share

When I saw specs for the graphics card they are using in the new iMacs, I knew it was time for Leadwerks to come to Mac. Steam for Mac also recently came out, so the time seems right for Mac gaming. Of course, some guy blew up the Roseville Galleria, so the Apple store was closed. I ordered the 27" iMac with a 3.2 ghz dual core processor and upgraded the graphics card to an ATI 5750. Here's what they sent me:

blogentry-1-060547000 1288598652_thumb.jpg

The computer case/monitor (it's all one piece) is a solid piece of aluminum that doesn't bend or crackle when you pick it up, like most PC equipment. It's very nice to have a solid geometric shape with such stability.

 

The keyboard looks weird at first, but I got used to typing on the low flat keys very quickly. The mouse has a touch surface instead of a mouse wheel, which works well for scrolling pages, but doesn't work at all for switching weapons in a game. The shape of the mouse is not very ergonomic, and I don't think I will be able to use it for extended periods of time unless I figure out a better way to hold it. The mouse and keyboard are both wireless. In fact, I have a computer with speakers, mouse, keyboard, camera, and internet, and only one cord is coming out of it, for power. It definitely cuts down on space and mess.

 

The monitor is the most beautiful I have ever seen. It's 27 inches with a native resolution of 2560x1440. At that resolution, you can't even see the individual pixels. The desktop background looks like a photograph because you can't see pixels. I have a black and white photo in the background and I can see individual grains of sand on a beach. It's really incredible. Unfortunately, the OS has not adjusted to this fine resolution. There is no way to adjust the font size for the whole interface, so if you have the monitor set at its native resolution you will be looking at text that would be about a size 6 or 7 on a 1920x1080 monitor of the same physical size. You can lower the resolution, but then text gets slightly blurred. A few programs like Xcode and Safari let you adjust some of the text sizes, so that is what I am getting by with for now. This giant image is squeezed onto a 27" monitor:

blogentry-1-031570000 1288598657_thumb.png

The speakers embedded in the monitor (that I didn't even know existed) are surprisingly good. I sort of got used to my bass-heavy Altec Lansing speakers with bad shielding and a constant buzz. It's nice to have good clear speakers and no subwoofer to trip over.

 

The ATI 5750 has 720 stream processors (equivalent to about 144 NVidia stream processors) but I was apprehensive about performance because it is a mobile card. Source engine games ran great with max settings at the monitor's native resolution of 2560x1440. Remember, this is running in native OSX, not Windows with boot camp:

blogentry-1-094472900 1288598659_thumb.jpg

I wanted to see how a more demanding engine would do, so I installed Windows 7 on a separate partition and ran Crysis. I was surprised to see the game running with max settings at about 18 frames per second, at the monitor's massive resolution. Of course, lowering the screen resolution improved performance. So that was not bad at all.

blogentry-1-020689300 1288599033_thumb.jpg

I spent some time with the Mac developer tool Xcode. It's about the same as Visual Studio. It uses GCC to compile, which cuts the ten minute build time in Visual Studio down to about a minute. I could get the same results on Windows using Code::Blocks so that's not really a Mac thing, but it's nice to work with. I am pleased to say that Leadwerks Engine 3 is now compiling for Windows and MacOS. The Mac version has no graphics or GUI yet, but it compiles without any errors, and that is a big achievement. Linux should be easy now, since it's a lot more like Mac than Mac is like Windows. I also tried out the iPhone SDK and was pleased to see the iPhone emulator starts up almost instantly. By contrast, the Android SDK took me about 45 minutes to install the first time, and it took ten minutes for the emulator to start.

 

So my conclusion on Mac is that I am very pleased with just about every aspect of them. You could reasonably get away with only having an iMac for development, because it allows you to make games for Windows, Mac, Linux, Android, and iPhone. I may make MacOS my main operating system, although I have to keep some other machines around for compatibility testing. It's taking some extra time to get the cross-platform support for Leadwerks Engine 3 in from the beginning, but I think a couple extra weeks spent now will be well worth it in the long run. Soon enough the code will be platform-agnostic, meaning I can just work with my own code, instead of trying to figure out somebody's else's designs.

 

I picked up Left 4 Dead 1 and 2 last week in a Steam Halloween sale. I'm starting with the first one, and I absolutely love it. I've always liked co-op play since Duke Nukem, and there hasn't been nearly enough of it available. I also love zombie movies, so Left 4 Dead is right up my alley.

 Share

17 Comments


Recommended Comments

You could also install Debian as multi-boot on the iMac.

I would also buy a Mac if they had Motorola or PowerPC CPUs, but with Intel it's just the same as a PC.

Link to comment

Microsoft keyboard (and mouse) on the last picture :lol: (native mac keyboard in the background). You should upload the picture to mac websites... They'd like it...

 

Does the keyboard say "Keyboard" on the under side? We had Mac Pros at uni those ones did. They also had the word "Mouse" on the under side of the mouse. Did they really think no one would recognise what they were?

Link to comment

Great post! I use a dual OSX/Windows 7 Mac Pro at work, and it's a great machine. My only advice is to toss the Mac mouse - everyone hates them!

Link to comment

Microsoft keyboard (and mouse) on the last picture :lol: (native mac keyboard in the background). You should upload the picture to mac websites... They'd like it...

 

Does the keyboard say "Keyboard" on the under side? We had Mac Pros at uni those ones did. They also had the word "Mouse" on the under side of the mouse. Did they really think no one would recognise what they were?

It just has an apple on the back side. So does the mouse, so they match now.

 

The green light is my Android phone plugged into it.

Link to comment

Cool progress Josh. Mac is indeed a nice platform to work on. The transition to mac from pc is a bit less painful if you've worked with Linux before. :lol:

This shall benefit us all!

Link to comment

Yes, first thing I did was to toss the mouse.

 

Those iMacs are expensive, this summer my kids went to do an animation workshop ran by the local city council. Their media room was like a modern class room, desks around the walls, each of which had a 27" iMac. My jaw fell when I thought how much all that stuff cost.

 

I remembered, one of my former clients used to be in charge of local education spending. He's now an Apple dealer, the swine. Our tax dollars at work.

 

Great machines though. Got to love a keyboard you can use for etching bathroom tiles. As hunks of metal go, it's almost as good as the long forgotten Memotech MTX 512. Almost solid alu chassis.

 

I'm quite eager to get to work on a Mac port of some games, I have Unity licenses for that and the iPhone but I'd much rather use LE tbh as I'm much more comfortable using it. If you want someone to help playing with Mac builds to iron things out then count me in. I'm happy to do some testing and trials for the sake of getting in some early familiarisation.

 

Can't stand iTunes though. How not to design a music library, it's a spreadsheet gone mad.

Link to comment

Hey if those kids didn't gain access to 27" Imacs we'd have to spend that money on teachers' salaries and policemen :lol:

 

I think the good guys won in our current situation

Link to comment

It's taking some extra time to get the cross-platform support for Leadwerks Engine 3 in from the beginning, but I think a couple extra weeks spent now will be well worth it in the long run. Soon enough the code will be platform-agnostic, meaning I can just work with my own code, instead of trying to figure out somebody's else's designs.

You are right, early design is very important and can make your life easyer later.

If LE3 code is platform-agnostic it's mainly because of the new driver architecture for opengl, directx, ... right ? This provides flexibility, it's a good thing, so why not do the same for physics and have a 'driver' abstration layer that would allow to implement both newton and bullet ? I know you did not reach physics stage in LE3 roadmap, but i wanted to know if 'physics driver architecture' is somewhere on the LE3 roadmap ? Many people request bullet now, but someday newton 2 may catch up. And this way, if the Newton controller is better for FPS, fps coders would use newton; if the car physics is better on bullet, car race coders would use bullet; and we would have the best of both.

Link to comment

I'm not so sure about interchangeable physics engines. Because whilst the graphics rendering all appears the same (in a black box view), physics engines deep down can be very different. Not all support buoyancy, not all support cloth effects, etc.

 

Most physics engines are designed to be hooked up to a graphics rendering system. The example from newton that I know is that for every rigid body that was moved, a user defined callback is called. Newton gives you the body that was moved and the 4x4 matrix to represent its position, rotation and scale. Newton bodies also store a single pointer for your own use. Usually that's the graphical object which visually represents that body.

 

So for the Leadwerks, when the callback is called:

  • Read the pointer stored with the rigid body. (When you created rigid body, you should have saved the pointer to the TModel which represents the body):
  • Transpose the matrix (Because newton gives the matrix in "row-major" by default, probably because there are more DirectX games out there)
  • Call SetEntityMatrix on the model pointed to by the pointer, with the transposed matrix.
  • Voila!

 

Newton and Bullet probably have very different structs and classes deep down and trying to incorporate them both into the engine would be wasteful. All physics engines are designed to easily interface with any graphics renderer, because without the graphics, you simply have no idea if the physics calculations are working accurately or not. Bullet probably relies on a very similar way of getting it's positional information to a graphics renderer. If it is that simple to interface with, I would say that physics should not be integrated into LE 3 at all.

 

Imagine the prospective companies interested in LE 3. They might have decided on a physics engine already (Or even written their own). To suddenly be told, "you've got to use one of these physics libraries - In the way that I've wrapped them up", might just turn them away.

Link to comment

If it is that simple to interface with, I would say that physics should not be integrated into LE 3 at all.

 

If no physics were in LE3 it would turn me away. I think there should always be a default even if it's "easy" to integrate others.

Link to comment

Imagine the prospective companies interested in LE 3. They might have decided on a physics engine already (Or even written their own). To suddenly be told, "you've got to use one of these physics libraries - In the way that I've wrapped them up", might just turn them away.

Well then he just has to add a command allowing to disable integrated physics engine. This will probably be easy for Josh.

On the other side, many people buy the engine for it's reputation of ease of use, so they don't want to go deep into newton or bullet API, they just want controllers, collisions and cars to work out of the box in LE.

Link to comment

Well then he just has to add a command allowing to disable integrated physics engine. This will probably be easy for Josh.

 

Would you believe, an idea as simple as that never even occured to me... (Actually, I'm sure you would)

Link to comment

You are right, early design is very important and can make your life easyer later.

If LE3 code is platform-agnostic it's mainly because of the new driver architecture for opengl, directx, ... right ? This provides flexibility, it's a good thing, so why not do the same for physics and have a 'driver' abstration layer that would allow to implement both newton and bullet ?

The physics is being implemented as an abstract physics driver class as well. I have worked in great depth with Newton, and have done some work with PhysX. I do not know how feasible it is to implement an abstract command set because of fundamental difference in the way the different libraries work. I'm sure it would work well for rigid bodies and simple things, but I won't know how comparable more complex things are until I start working with them. I only want to provide official support for one physics library. If other people want to do their own, that's an option.

 

Bullet has good features and seems to have better cross-platform support than PhysX. PhysX has GPU acceleration on NVidia cards right now, and brand recognition. Newton is the best for basic rigid bodies, but it seems like progress in its development has stopped. I'll have to research them more before I make a decision.

Link to comment

Bullet is nice, but still a bit slow. I think it will get faster when it develops more, and it's being developed quite often.

PhysX is quite fast, but Havok is faster.

PhysX is again faster than Havok with GPU Physics.

 

PhysX has a nice cloth simulation and concave bodies.

Havok has also concave bodies which work very well, but Havok Cloth is a seperate product which I don't like, because it's like the Torque style of marketing.

Havok has the best fluid and massive amount simulation though.

PhysX is also not bad even without GPU support, but I heard the code has all SSE2 commands disabled deliberately, so it could be much better if they would fix that.

 

The speed of Newton is a joke compared to all other physics engines (about 4 times slower than Bullet, about 8 times slower than PhysX), and it's not even accurate since it often keeps bodies standing on one edge.

 

Overall, I tend to prefer Havok at the moment, but maybe in future Bullet will be the best.

Link to comment

Damn, I want one (or two) of those :blink:.

 

One day you'll hate XCode, objective C and would wish you could use Visual Studio. If I develop for mac, I code in Visual studio, commit to svn, and update on mac, just because XCode misses all basic development actions and a good window layout. I think I must not say there are no good graphical svn clients (free) for mac, so command line is the way to go... You can customize everything in visual studio, from compiler and linkers, to revision handling etc. Combined with Visual Assist for C++ and Resharper for C# no other IDE can compete. I think it's (little) mistake to say Mac is more like Linux than Windows is. Mac has objective C, one of a kind.

 

Maybe good to know is that steam mac sales are below charts. I know 3 indie companies who ported for mac, and launched at the release date, and still now they haven't got sufficient revenue to cover the port. Everyone is going to think I'm a mac hater, and in a way I am. I love it for graphical work, but for daily use and development it's really not my preference.

 

Good to hear you're making progress! I have some spare time soon, and I'm thinking to make a test case for performance, to see if we can actually create a game with good looking graphics and gameplay.

 

@Lumooja: About Havok. I've talked with Steve Ewart from Havok at GDC 2010, and have seen crazy progress and things yet to come. Now that intel is in charge they really have very high goals!

Link to comment
Guest
Add a comment...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...