Rethink the API entirely.

- Use composition instead of inheritance for some classes.
- Extend the concept of filters.