Blogs
What is CrystalUI
by Mark B. | Mon, 03/30/2009 - 01:18Crystal is a Abstract Graphical User Interface. The goal of this project is experiment in the areas of GUI (concurrent/multithreading), advanced input devices camera based hand detection.
The Crystal API is divided into the public API, which is mainly a collection of interfaces and classes that act as glue code and various implementations of the public API.
Adding concurrent async API
by Mark B. | Sun, 01/10/2010 - 17:53I'm adding async method support to nodes. Something like this:
PixmapChannel pix = new PixmapChannel();
pix.setBrightness(0.5);
pix.setContrast(0.5);
pix.setEnableCache(true);
pix.setFile(new File("img1.jpg"));
final RGBToPixmap adapter = new RGBToPixmap(pix);
Future<int[]> asyncPixels = pix.async().getPixels(0, 0, 100, 100,
new int[1024], 0);
Future<int[]> asyncRed = adapter.async().getRed(0, 0, 100, 100,
new int[1024], 0);
int[] red = asyncRed.get();
int[] pixels = asyncPixels.get();
Channels ver. 21
by Mark B. | Thu, 01/07/2010 - 14:24Here is some more work on Channels.
Image:Channel Concept
I am actually quiet surprised how much complexity there is with trying to define 2 concepts. First a generic hierarchal network "graph" model and a concept of a data channel.
Redefining channels
by Mark B. | Thu, 12/24/2009 - 23:55I've recently spent a bit more time on channels and once again redefined what they are and how they are used. This is one benefit of not releasing software too quickly, which allows ample amount of time on proof of concept and that the original design is on the right track.
I started with Channels as a stand-alone library that is composed of nodes and channels. Channels are a collection of channel segments that interconnect into a communication channel. I've spent a great deal of time on defining how channels process data, interconnect with channel segments and how they signal each other.
Tracking movement
by Mark B. | Sun, 05/03/2009 - 02:20I can track movement using camera. I haven't had much time to work on crystal MT lately, but made some progress none the less.
Image processing library
by Mark B. | Mon, 04/20/2009 - 00:32I've made significant progress on image processing library needed for hand detection. Here is a little application that using a static image sets up a scene graph with 3 branches that does different type of processing on the source image. The post processed image results of each graph branch are displayed in a swing frame. Below is an sample code in its entirety. When run, it brings up 3 windows with 3 different type of images displayed in them. The code is broken up into smaller sections with images inserted when they are brought up.
Started work on MultiTouch detection using webcam
by Mark B. | Wed, 04/08/2009 - 10:13MultiTouch is a term used to describe UI controls through a touch screen or projection device that can detect multiple touches at the same time. Perfect example is iPhone that allows multiple fingers to interact with the screen such as 2 fingers sliding away from each other causing a picture to be zoomed in.
I started some preliminary work on MT detection. There are many techniques, the most common one and cheapest/easiest to implement is a webcamera that can view the backside of a piece of paper or laminent that tracks shadows cast when you fingers slide on the other side.
Discovered jSeamless
by Mark B. | Tue, 03/31/2009 - 13:18I discovered jSeamless today and talk to the project leader. Its almost identical to what I wanted to develop. Its basically a UI abstraction layer that provides a common set of widgets that can be used to build GUIs on numerous GUI platforms, especially web based. The project has an amazing "flex" implementation (flash).
I have to take a look a bit more to see if this is something that is what I wanted to design. My ultimate motive for designing such a beast is to try and design new way of interfacing with an application. Very futuristic, 3d, yet down to earth.
Designing the view
by Mark B. | Mon, 03/30/2009 - 02:14The view is where all the real magic takes place. The view is responsible for interfacing with the underlying display medium, input controls and provides the behavior for each component.
A quick look at the class hierarchy. This is currently preliminary and will most likely change after further design review.
Component
+-o Model
+-o View
+-o Geometry - keeps information about the shape of the component
+-o Behavior - interaction with the user and the environment.
| Yes, components can bounce of each other, users can spin
| labels, etc..
Designing the model
by Mark B. | Mon, 03/30/2009 - 01:43The one thing that all crystal implementations are going to have the same, is the Controller and the data Model. I started design on the data model first. After careful design, review and several rewrites I came up with 3 simple models.
-
FlatModel<? extends Model.Data>- holds a single piece of model data -
ListModel<? extends Model.Data>- holds model data as a list. The list can be arranged and changed at runtime -
TreeModel<Model.Data>- a hierarchical tree of nodes which hold model data