UnleashedCreativity.net
Postings on Mondays, Wednesdays, and Fridays or When-I-Have-Time-days

Login

username:
password:

Last 10 entries


Tags

.net 3d art blog c# coding college computers editorial entertainment firefox food freeware gaming hardware hdtp hiking humor ide japan japan, javascript linux mac mailbox milestone misc. mods momoiwa, mono movie nintendo philosophy php politics rant rebun review science software technology time ucr wakkanai windows work wormholeftp


Affiliates

  • Narcissism Incorporated
  • Wolfram Studios
  • KaleNet Web Design
  • OffTopic Productions
  • Deus Ex: High Definition Texture Project
  • The Nameless Mod


Creative Commons License
This work is licensed under a Creative Commons Attribution-Noncommercial 3.0 United States License.
tag: 

TECHNOLOGY

Cocoa.Application.Run does not return

Posted on: Thu Jan 17, 2008 06:01 AM

An ominous title, for yet another, but this time rather technical, guest post by EER.

Today I'll talk a bit about some crazy stuff I have been developing for work lately. As you may or may not know, I primarily work with .Net. Our government in the Netherlands is slowly moving to 'alternative' software platforms such as Linux or Macintosh.

Now Linux is not much of a problem, it is a developers' platform, and being a developer, I feel right at home using Debian or Ubuntu. But a macintosh is a whole different story. Luckily, I found the terminal after about two hours fiddling and everything is semi-normal if you just use the terminal ;)

Armed with a terminal and the latest version of the Mono framework I went about and tried to run my app. Of course, this failed horribly and I considered various options to get it all running. My first experiments with Windows Forms interfaces on the mac weren't very successful (to say the least). After inquiring on the mono-winforms mailing list, I was told to use the native Mac OS X driver by exporting the following variables from the terminal:

export MONO_MWF_USE_QUARTZ_BACKEND=1
export MONO_MWF_USE_CARBON_BACKEND=1

That looked a bit better than the X11 version, but still the stability was crap. So I moved on to check out the native Mac OS X interface programming framework "Cocoa". There are bindings available for Mono: cocoa#. These bindings are distributed with mono on mac by default.

So I tried to use them, which did not work as I came to expect from .Net when programming Windows Forms. So finally I'm coming to a point: Mac programming is different. How different you ask? I'll give you some hints to get started more easily:

  • You must create the user interface with "Interface Builder" which comes with Mac OS X.
  • Save the interface as a .NIB file, then use Application.LoadNib() in the cocoa framework to connect your code with the UI.
  • In the Interface builder, you can create an object with predefined properties and actions. Your .Net class should be registered using attributes on your class.
  • The message loop (Cocoa.Application.Run) does NOT return after when quitting. This is the last statement that is executed in your main method.

Code samples can be found in the Cocoa# source code, but I'll explain some of the attributes you can use:
  [Register("ControllerClass")] // You can use the Register attribute on a class to register it with the Object you have defined in the Interface Builder.
    [Connect] // Use the Connect attribute to link the public class variable to one of the outlets defined on the registered object in the Interface builder. These outlets can also be linked in the Interface Builder to various components in your NIB. For this to work, your object needs to be delegate for the component you want to access here.
    public Cocoa.Panel aboutPanel;
    [Export("show_about:")] // You can use the Export attribute to link class functions to the functions defined on the registered object. These functions will then execute managed code when they are called from the UI.
    public void show_about(Cocoa.Object sender)
    [Export("applicationWillTerminate:")] // The last one, still an Export, but this is the one you will need for cleanup code. As the Messageloop does not return, this is the event handler if the application is terminated by pressing Quit in the dock. For this to work, the registered object should be delegate for the application.
    public void ApplicationWillTerminate(Cocoa.Notification not)

 


3D Mailbox - First impressions

Posted on: Fri Jul 20, 2007 07:18 PM

Today, a guest post from nobody else but me, EER :D

The occasion? Kale showed me this digg, which is about an e-mail client named "3D Mailbox". As the name suggest, it's a three dimensional representation of your mailbox. Strangely enough by default all your e-mail is represented as women in bikini's. Nothing wrong with that obviously :P

I directly saw the potential, after all, with Mii's, PS Home and Second Life, 3D Email was only the next logical step. So hereby a small rundown of my experiences using 3D Mailbox.

First of all, the download was 72 MB(!). So that sounded promising. To use it, you need to register for some code, which I tried several times. Only after three times I found out the thing was case-sensitive and showed only uppercase while expecting lowercase input. The fact that the registration website was excruciatingly slow didn't help much to give a good first impression :X

After installing, registering and making account settings, the first thing I tried was walking around. Well. That didn't work, not using WASD, not using the arrow keys. What good is a first person interface when you can't walk around but have fixed camera positions?

The 3D action was taking place windowed, which isn't a bad idea for a mail client, however, 3D graphics in a window hardly ever perform as well as full screen. And 3D Mailbox was no exception, even when graphics are lower than low, it still doesn't perform adequate if there are multiple e-mails swimming around in the pool. There is also virtually no control over your e-mail folk, they just swim around until you can click them (if you can click them, they swim bloody fast).

There is also a regular e-mail display you can use to read your e-mail from, with spam filter and everything. But if you prefer that, you could simply use Thunderbird or Outlook Express.

All in all it has been a frustrating experience, however, I do think it has potential and I may try it again someday if they implement the following features:

  • Free roaming, I want to walk around, without being in some fixed position.
  • Better 3D performance, I don't want my PC to crash when there are more than 50 unread mails in the pool. In fact, I don't even want it to slow down.
  • More control of my mail, I'd like something like the Sims, where I can tell my mailpeople exactly what to do
  • Faster load times, booting the app took me 2 minutes, Doom 3 loads faster than that!

Back from hiatus

Posted on: Wed Jan 17, 2007 04:10 PM
After a short reprieve, I've decided to get back into posting. I'll do a brief "whats going on" write-up tomorrow, but for now, check some of this stuff out:

Feinstein Speaks out on U.S. Atty Firings - http://www.tpmmuckraker.com/archives/002349.php
Senator Feinstein speaks out against the unwarranted firing of several US Attorneys across the US. The firings are not based on misconduct, but instead utilize a clause introduced into the PATRIOT Act when it was reinstated last year...now, the president can instate his cronies to preside over several upcoming cases dealing with corruption at a politician-level. Firing US Attorneys is within the power of the president, but what has changed is the time limit that interim attorneys are allowed to remain in their position; before the PATRIOT Act, interim attorneys were allowed to serve for a maximum period of 120 days, but recent changes to that policy give interims an infinite amount of time in their position.

Keith Olbermann's response to Bush's new plan for Iraq - http://www.msnbc.msn.com/id/16583889/
Keith Olbermann tears into Bush, chastising him for being a complete and utterly incompetent president. Words can't do justice, so just click on the link to see Olbermann's response.

-----And on a technical note-----

Why upgrading to Microsoft Vista may be a smarter choice than purchasing new - http://www.extremetech.com/article2/0,1697,2082979,00.asp
Here's an interesting article about Windows Vista and its upgrade procedure. Apparently, the installer for Windows Vista is leagues ahead of the installer that Windows XP is based off of, so upgrading from an existing install of XP appears to be a feasible option. After reading this article, I've reconsidered my stance on Vista and am now considering saving $150 by purchasing the upgrade to Windows Vista Ultimate...there's still a bit of time until Vista's release, and even more time until I make the jump to Vista, so I think I'll wait and see how other people to this new OS.

That should keep you guys and gals busy until I get to tomorrow's post. A hint for tomorrow, I've tested VirtualBox's now-open-source virtualization software, so look out for my review!

EVERYTHING on this site is © Matthew Miller, 2005-2008, so don't friggin' touch