- if ((prop = child->property ("quality"))) {
- _src_quality = (SRCQuality) string_2_enum (prop->value(), SRCQuality);
+ child->get_property ("quality", _src_quality);
+ }
+
+ if ((child = root.child ("CodecQuality"))) {
+ child->get_property ("quality", _codec_quality);
+ _has_codec_quality = true;
+ } else {
+ _has_codec_quality = false;
+ }
+
+ /* fixup codec quality for old states */
+ if (!_has_codec_quality) {
+ /* We'd need an instance of ExportFormatManager to look up
+ * defaults for a given type -- in the future there may even be
+ * difference qualities depending on sub-type, so we just
+ * hardcode them here for the time being.
+ */
+ if (format_id() == F_FFMPEG) {
+ _codec_quality = -2; // ExportFormatOggVorbis::default_codec_quality();
+ }
+ else if (format_id() == F_Ogg) {
+ _codec_quality = 40; // ExportFormatFFMPEG::default_codec_quality();