You are here

public function video_preset::getSettings in Video 6.5

File

./video.lib.inc, line 130
File containing Video module interfaces and classes

Class

video_preset

Code

public function getSettings() {
  if ($this->settings == NULL) {
    $transcoder = variable_get('vid_convertor', 'video_localcommand');
    $settings = db_result(db_query('SELECT data FROM {video_preset_settings} WHERE presetid = %d AND transcoder = "%s"', $this->id, $transcoder));
    if ($settings) {
      $this->settings = unserialize($settings);
    }
    else {
      $this->settings = array();
    }
  }
  return $this->settings;
}