Class: Pageflow::VideoFile
Instance Method Summary
collapse
#retryable?
Methods included from HostedFile
#attachment, #attachment=, columns, #keep_on_filesystem_after_upload_to_s3?, #retryable?, #url
#usage_id
Instance Method Details
#attachment_s3_url ⇒ Object
39
40
41
|
# File 'app/models/pageflow/video_file.rb', line 39
def attachment_s3_url
"s3://#{File.join(attachment_on_s3.bucket_name, attachment_on_s3.path)}"
end
|
#hls_high ⇒ Object
74
75
76
|
# File 'app/models/pageflow/video_file.rb', line 74
def hls_high
ZencoderAttachment.new(self, "hls-high.m3u8")
end
|
#hls_low ⇒ Object
66
67
68
|
# File 'app/models/pageflow/video_file.rb', line 66
def hls_low
ZencoderAttachment.new(self, "hls-low.m3u8")
end
|
#hls_medium ⇒ Object
70
71
72
|
# File 'app/models/pageflow/video_file.rb', line 70
def hls_medium
ZencoderAttachment.new(self, "hls-medium.m3u8")
end
|
104
105
106
|
# File 'app/models/pageflow/video_file.rb', line 104
def meta_data_attributes=(attributes)
self.attributes = attributes.symbolize_keys.slice(:format, :duration_in_ms, :width, :height)
end
|
#mp4_high ⇒ Object
53
54
55
|
# File 'app/models/pageflow/video_file.rb', line 53
def mp4_high
ZencoderAttachment.new(self, "high.mp4")
end
|
#mp4_low ⇒ Object
61
62
63
|
# File 'app/models/pageflow/video_file.rb', line 61
def mp4_low
ZencoderAttachment.new(self, "low.mp4")
end
|
#mp4_medium ⇒ Object
57
58
59
|
# File 'app/models/pageflow/video_file.rb', line 57
def mp4_medium
ZencoderAttachment.new(self, "medium.mp4")
end
|
#output_definition ⇒ Object
#smil ⇒ Object
88
89
90
|
# File 'app/models/pageflow/video_file.rb', line 88
def smil
ZencoderAttachment.new(self, "hls-playlist.smil")
end
|
#thumbnail_url(*args) ⇒ Object
35
36
37
|
# File 'app/models/pageflow/video_file.rb', line 35
def thumbnail_url(*args)
poster.url(*args)
end
|
#webm_high ⇒ Object
44
45
46
|
# File 'app/models/pageflow/video_file.rb', line 44
def webm_high
ZencoderAttachment.new(self, "high.webm")
end
|
#webm_medium ⇒ Object
48
49
50
|
# File 'app/models/pageflow/video_file.rb', line 48
def webm_medium
ZencoderAttachment.new(self, "medium.webm")
end
|
#zencoder_poster ⇒ Object
96
97
98
|
# File 'app/models/pageflow/video_file.rb', line 96
def zencoder_poster
ZencoderAttachment.new(self, "poster-{{number}}", :format => 'jpg')
end
|
#zencoder_thumbnail ⇒ Object
92
93
94
|
# File 'app/models/pageflow/video_file.rb', line 92
def zencoder_thumbnail
ZencoderAttachment.new(self, "thumbnail-{{number}}", :format => 'jpg')
end
|