I just added a method named CActiveRecord::instantiate().
You can override this method in Media. The method should create either a Video or a Photo object depending on the 'class' value given in the method parameter.
Now, if you do Media::model()->findAll(), the returned array will contain video and photo objects, according the 'class' column value.