Seth intro Lab intro, on actual slides How do we load an image and display it in Java? We find a tutorial and steal it I'm not going to use Eclipse or Windows Making some sense of our tutorial: frames, javax, awt, stuff you can do on the JVM - We could spend forever on this, but we won't Cross-platform UI The methods in here: main: Make and display a JFrame Paint, ChangeImageApp, Dimension: - These are expected methods of a Component Paint: Called when drawing the frame - I can show you how often later ChangeImageApp: - The constructor, sets up the image - We'll put our code here Dimension: Figures out the dimensions for the window What can we do with a BufferedImage? It's a Java object, so the methods and such are all documented /* What IS an Image, anyway? * It's a collection of pixels * They've got x and y coordinates and a value * RGB values, 24-bit color, how many colors can you have? * - Enough for a big box of crayons! * Editing values in hex, web people have tools for this. * Convert to red, green, blue and back, then assume it works */ Actually editing the BufferedImage: Let's make a red square! How about turning the red strawberry green? - Is white high in red? Mice picture time! Can we find the outline of a neuron? #1: Just look for dark areas #2: Look for dark areas with light neighbors How would we find the entire inside? ExpandArea algorithm, frontier, sets and such Putting it all together, with demonstration and TrakEM2