Example #1
0
 public function import()
 {
     parent::import();
     $this->asset->filename = $this->asset->key . '.' . $this->data['_ext'];
     copy($this->source, $this->asset->assetPath . $this->asset->filename);
     $this->asset->commit();
 }
Example #2
0
 public function import()
 {
     if (empty($this->data['frames'])) {
         echo "Image sequence import: Counting frames...\n";
         $c = intval($this->data['_firstIndex']);
         $nframes = 0;
         while (true) {
             $testname = $this->data['_dir'] . '/' . $this->data['_base'] . sprintf($this->data['_printf'], $c) . '.' . $this->data['_ext'];
             if (!file_exists($testname)) {
                 break;
             }
             $nframes++;
             $c++;
         }
         $this->data['frames'] = $nframes;
         echo $nframes . " found.\n";
     }
     ImportMarshal::import();
 }