Unformatted text preview: plySmooth();
4 The first question: what class hierarchy?
x Question 1: what are the various objects the user needs to
x Question 2: what is common between those objects, i.e.,
Question what are common abstractions?
x Question 3: how to ensure the software will be extensible
Question for future use? (new algorithms, new image types)
x Question 4: are the algorithms specific to a 2D image, or
Question are they more generic?
are 1D image == a sound wave 3D image == a volume 5 The first question: what class hierarchy?
x Question 5: what are the image parameters that can be
Question changed by the user?
changed Image size? Color representation?
Color 6 Example of a design 7 Reminder: good programming habits
x Check the hierarchy complies with the “is a” and
Check “extends” tests
x Encapsulate all data, and provide accessors/mutators
x Provide default constructor/copy constructor/destructor
x Avoid multiple/diamond inheritance 8 Implementing the methods 9 The question of extensibility
x A smooth algorithm needs the notion of pixel neighbor A generic implementation for nD images is possible?
x An image is a collection of pixels, the pixel dimensionality
An determines the image dimensionality?
x Getting/setting a pixel: use a method More convenient writing using the operator [ ] possible? 10 Final design 11...
View Full Document
- Fall '00
- Computer Graphics, Computer program