Changeset 21599
- Timestamp:
- 2010-01-25T13:57:54+13:00 (13 years ago)
- Location:
- gs2-extensions/video/trunk/perllib/plugins
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
gs2-extensions/video/trunk/perllib/plugins/MultimediaPlugin.pm
r20345 r21599 208 208 209 209 $self->add_OID($doc_obj); 210 211 $self->post_process_doc_obj($pluginfo, $base_dir, $file, $metadata, $doc_obj, $gli); 210 212 211 213 return (1,$doc_obj); -
gs2-extensions/video/trunk/perllib/plugins/VideoConverter.pm
r21335 r21599 793 793 my ($self) = shift(@_); 794 794 795 my ($doc_obj,$ section,$timeline) = @_;795 my ($doc_obj,$topsection,$timeline) = @_; 796 796 797 797 my $output_dir = $self->{'cached_dir'}; 798 798 799 799 my $count = 1; 800 801 my $endchild = $doc_obj->get_end_child($topsection); 800 802 801 803 foreach my $t (sort { $timeline->{$a}->{'keyframeindex'} <=> $timeline->{$b}->{'keyframeindex'} } keys %$timeline) … … 804 806 my $timestamp = $timeline->{$t}->{'timestamp'}; 805 807 808 # create next sub-section to video "document" 809 $endchild = $doc_obj->insert_section($endchild); 810 $doc_obj->add_utf8_metadata($endchild,"Title","Timestamp $timestamp"); 811 $doc_obj->add_utf8_metadata($endchild,"FrameNum",$t); 812 806 813 my $kframe_filename = &util::filename_cat($output_dir,$kframe_file); 807 $doc_obj->associate_file($kframe_filename,"keyframe$count.jpg","image/jpeg", 808 $section); 809 $doc_obj->add_utf8_metadata($section,"KeyframeTimestamp",$timestamp); 810 $doc_obj->add_utf8_metadata($section,"KeyframeFrameNum",$t); 814 $doc_obj->associate_file($kframe_filename,"keyframe$count.jpg", 815 "image/jpeg", 816 $endchild); 817 818 $doc_obj->add_utf8_metadata($endchild,"assockeyframe","keyframe$count.jpg"); 819 820 $doc_obj->add_utf8_metadata($topsection,"KeyframeTimestamp",$timestamp); 821 $doc_obj->add_utf8_metadata($topsection,"KeyframeFrameNum",$t); 822 823 811 824 812 825 $count++; 813 826 } 814 827 815 #### $doc_obj->add_utf8_metadata($ section,"NumKeyframes",scalar(@{$self->{'keyframe_fnames'}}));816 817 $doc_obj->add_utf8_metadata($ section,"NumKeyframes",scalar(keys %$timeline));828 #### $doc_obj->add_utf8_metadata($topsection,"NumKeyframes",scalar(@{$self->{'keyframe_fnames'}})); 829 830 $doc_obj->add_utf8_metadata($topsection,"NumKeyframes",scalar(keys %$timeline)); 818 831 819 832 820 833 # ***** 821 # $doc_obj->add_metadata ($ section, "thumblist", $self->{'flowplayer_thumblist'});834 # $doc_obj->add_metadata ($topsection, "thumblist", $self->{'flowplayer_thumblist'}); 822 835 } 823 836
Note:
See TracChangeset
for help on using the changeset viewer.