5
Media Computation Questions Barb Ericson Georgia Tech

Media Computation Questions

  • Upload
    khan

  • View
    33

  • Download
    1

Embed Size (px)

DESCRIPTION

Media Computation Questions. Barb Ericson Georgia Tech. Day 2 Questions. How to set the classpath to use Converter in Eclipse? I want to try making a jar and using that How do you save the pictures you have changed? use the write method Picture p = - PowerPoint PPT Presentation

Citation preview

Page 1: Media Computation Questions

Media Computation Questions

Barb EricsonGeorgia Tech

Page 2: Media Computation Questions

Day 2 Questions• How to set the classpath to use Converter in Eclipse?

– I want to try making a jar and using that• How do you save the pictures you have changed?

– use the write method Picture p = new Picture(FileChooser.getMediaPath("barbara.jpg");p.explore();p.decreaseRed();p.explore();p.write(FileChooser.getMediaPath("decRedBarb.jpg"));

• Why is this better than just using Photoshop?– If you just learn photoshop you are limited by what it can do

• If you learn to program you are not limited by your application

Page 3: Media Computation Questions

Precision Drawings

• How would you draw a stack of filled rectangles starting from the lightest one at the bottom right and the darkest one at the top left.– With 10 pixels between

each– Not easy with drawing

packages

Page 4: Media Computation Questions

Draw Filled Rectangles Methodpublic void drawFilledRectangles(){ Graphics g = this.getGraphics(); Color color = null; // loop 25 times for (int i = 25; i > 0; i--) { color = new Color(i * 10, i * 5, i); g.setColor(color); g.fillRect(0,0,i*10,i*10); }}

Page 5: Media Computation Questions

HW2: Create a collage, but must use turtles