Adding Jar files to OS X apps

Link: http://www.cs-ed.org/blogs/mjadud/archives/programming/

I was trying to package a jar file based application up for OS X in XCode, and it seems to be less than happily documented (though I don't know my way round XCode as I use armed bear J as my main editor). After doing what the blog said, I found I needed to move the jar into J.app/Contents/Resources/Java, and alter the classpath in info.plist. But I guess that XCode is s'posed to be used for the project, not just to mac-ify a Java app. Ho Hum.

[eta: developer.apple.com does actually give the info on what is in the package contents of an application, so you can build one yourself in Ant if you want, rather than messing around with XCode.]



Link: http://www.lambda-foo.net/

Began a new website project.

Tasteful beige with a hint of mystery meat.


Ship of Fools: Google-whacking

Link: http://forum.ship-of-fools.com/cgi-bin/ultimatebb.cgi?ubb=get_topic&f=28&t=000456#000038

Ship of Fools: Google-whacking

I quite like the phrase ‘transistorised symbiont’.

Today I got iLife and messed around with GarageBand making a trip-funk loop.

"Then," said Gwalchmai, "it is not fitting that any should disturb an honourable knight from his thought unadvisedly; for either he is pondering some damage that he has sustained, or he is thinking of the lady whom best he loves.”

But I don’t think tilting people when they disturb your cognitive flow is socially acceptable nowadays.

I really do need to get out more.


Just another day

Check out my Morality! 67% liberal, 33% conservative
now, there's a surprise.

Quite why I keep on doing these things that tell me I'm a easy-going ingenious introvert I don't know.


Compound Model Pages

Been working (at work) on compound docs- for simple probs, we now have a single page doc for describing a system (ad-hoc document vocabulary), the maths (MathML), a data model (UML, with own namespace attributes to tie to the maths), and bits of svg for diagrams. Currently there's output to pdf using FOP; tomorrow I'll start to make html forms for a web app.

At home, I'm using something similar- XSLT on the OMG's XMI cmof model- to generate some classes for a MOF implementation so I've something more to bring to the table for the JMI update.


Compound documents and XMI

Am currently thinking about compound docs and XMI. XMI 2 is very much geared for interchange between tools by mapping UML's Meta Object Facility (MOF) to W3 XML Schema (WXS). Systems engineering UML (SysML) a profile of UML for systems engineering, suggests the use of MathML for constraints. The UML Diagram Interchange Format (UML:DIF) uses Scalable Vector Graphics (SVG) as part of the presentation format.

Queue a compound document, with elements from several namespaces- interior to XMI are the xmi and uml namespaces, also some type information from wxs. Nested inside, you should have SVG and MathML.

Constraints in UML may either be opaque strings, or part of the object model.

If they are part of the object model, the body of the constraint is serialised as the expression tree in XMI.

Any language can be used an opaque expression. Unfortunantly, the type of the body of the expression is string, so you would have to escape the MathML markup as text, losing the compound document nature and complicating processing.

XMI does have an extension mechanism for vendor-specific XML data- and this may be used to package the SVG or MathML, but without the relevence of the extension data being available to the general tool. So you can have a parsed constraint that you know is the same abstract syntax tree and a MathML expression, but isn't MathML, you can have the characters that make up a MathML element as an opaque string expression, or you can embed real MathML in a extension, but it won't be recognised as being the value specification of the constraint.

I'm not sure what the vendor support for XMI2.1 is like yet, but it would be nice to get XML literals as valid content in XMI constraints and comments.


Currently Convolving

I'm trying to find a fast way of doing nice convolution in Java on OS X, as in this SVG, for an interactive diagram editor.

The java.awt.image convolution is far, far slower than any native code I've seen on OS X, and the OpenGL accumulation buffer isn't accelerated either, so can't use that and be able to drag the image around (other than caching the part of the image of the image being dragged for movement, though that doesn't apply for resize). Using a filter pipeline (see SoftShadow.java takes about 600ms to convolve a 400x400 area, about 100ms or 40ms for drop-shadow specific hacks, about as slow a convolve on the non-accelerated OpenGL accumulate buffer.

I suppose you could also turn drop shadow off during drag or resize then up the render quality later, but it would be nice if it allowed full quality motion; a layers approach of sizing the solid blocks then another thread to add the convolve ops would also work, but you'ld have to pause the motion for long enough for it to catch up to get the quality one.


All in the wrist

I'm currently injured, having done something bad to my mouse wrist, so am limited as to what I can do online. It means I'm off of development at the moment, and at work I've been given training time to read- I'm doing a pure math course from the OU, and re-reading knuth as I've forgotten too much fundemental stuff having to work with Java cruft.