
Recherche avancée
Médias (5)
-
ED-ME-5 1-DVD
11 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Audio
-
Revolution of Open-source and film making towards open film making
6 octobre 2011, par
Mis à jour : Juillet 2013
Langue : English
Type : Texte
-
Valkaama DVD Cover Outside
4 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Image
-
Valkaama DVD Label
4 octobre 2011, par
Mis à jour : Février 2013
Langue : English
Type : Image
-
Valkaama DVD Cover Inside
4 octobre 2011, par
Mis à jour : Octobre 2011
Langue : English
Type : Image
Autres articles (71)
-
MediaSPIP Player : les contrôles
26 mai 2010, parLes contrôles à la souris du lecteur
En plus des actions au click sur les boutons visibles de l’interface du lecteur, il est également possible d’effectuer d’autres actions grâce à la souris : Click : en cliquant sur la vidéo ou sur le logo du son, celui ci se mettra en lecture ou en pause en fonction de son état actuel ; Molette (roulement) : en plaçant la souris sur l’espace utilisé par le média (hover), la molette de la souris n’exerce plus l’effet habituel de scroll de la page, mais diminue ou (...) -
Amélioration de la version de base
13 septembre 2013Jolie sélection multiple
Le plugin Chosen permet d’améliorer l’ergonomie des champs de sélection multiple. Voir les deux images suivantes pour comparer.
Il suffit pour cela d’activer le plugin Chosen (Configuration générale du site > Gestion des plugins), puis de configurer le plugin (Les squelettes > Chosen) en activant l’utilisation de Chosen dans le site public et en spécifiant les éléments de formulaires à améliorer, par exemple select[multiple] pour les listes à sélection multiple (...) -
Création définitive du canal
12 mars 2010, parLorsque votre demande est validée, vous pouvez alors procéder à la création proprement dite du canal. Chaque canal est un site à part entière placé sous votre responsabilité. Les administrateurs de la plateforme n’y ont aucun accès.
A la validation, vous recevez un email vous invitant donc à créer votre canal.
Pour ce faire il vous suffit de vous rendre à son adresse, dans notre exemple "http://votre_sous_domaine.mediaspip.net".
A ce moment là un mot de passe vous est demandé, il vous suffit d’y (...)
Sur d’autres sites (10246)
-
ruby on rails carrierwave-video ffmpeg AWS
11 mars 2015, par Joseph Han Nim JangI am trying to create an academic site where users can upload lecture videos and other users can view them - similar to a site like Udemy.
I am using Carrierwave, Carrierwave-video (for encoding videos), AWS to make this happen. AWS configuration has been done, and it’s working.
However, I am getting this error. (By the way, I am testing this video feature in a Yelpdemo site, so I am trying to have users upload videos to restaurants for now.)
rails points the error to @restaurant = Restaurant.new(restaurant_params)
Errno::ENOENT in RestaurantsController#create
No such file or directory - ffmpeg
# POST /restaurants.json
def create
@restaurant = Restaurant.new(restaurant_params)respond_to do |format|
if @restaurant.saveThis is my video_uploader.rb
# encoding: utf-8
class VideoUploader < CarrierWave::Uploader::Base
include CarrierWave::Video
include CarrierWave::Video::Thumbnailer
process encode_video: [:mp4]
include CarrierWave::MiniMagick
storage :fog
def store_dir
"uploads/#{model.class.to_s.underscore}/#{mounted_as}/#{model.id}"
end
version :thumb do
process thumbnail: [{format: 'png', quality: 10, size: 192, strip: true, logger: Rails.logger}]
def full_filename for_file
png_name for_file, version_name
end
end
def png_name for_file, version_name
%Q{#{version_name}_#{for_file.chomp(File.extname(for_file))}.png}
end
endI have manually (added a file to the model) created video.rb in the model - not sure if this is the right way to do it..
class Video < ActiveRecord::Base
attr_accessor :user_id, :video,, :type, :filename, :path, :filesize, :width, :height, :duration, :bit_rate
belongs_to :restaurant
belongs_to :user
mount_uploader :video, VideoUploader
endin app/views/restaurants/show.html.erb for showing the video. Right now, without the encoding done, I can see like an image of the video. When I right lick and copy the code - it gives me the AWS URL which means AWS configuration is in place
<p>
<strong>Video:</strong>
<%= video_tag @restaurant.video_url %>
</p>I am trying to show videos like this.
I have downloaded FFMPEG (both ffmpeg-2.6 and SnowLeopard_Lion_Mountain_Yosemite_17) - not sure which one’s the right one.. And I have read somewhere that you need to place FFMPEG in your usr/local/bin -> So do you have to physically place ffmpeg exec file in your respective folder ?
Need your expert help please.
Thank you in advance !
-
Error with IO.popen and ffmepg
6 mars 2015, par Florian Dano ClementI received files in mp3 (2 minutes/files) I want to concatenate together and create a bigger file. So I created my model a function to do this using ffmpeg and IO.popen
FileUtils.mkdir_p "#{Rails.root}/tmp/files"
imported_dir = "#{Rails.root}/tmp/files/#{SecureRandom.uuid}"
links.each_with_index do |link, index|
file_path = "#{imported_dir}_#{index}#{File.extname(link)}"
File.open(file_path, 'wb') do |file|
file.write open(link).read
end
concat_list << "file '#{file_path}'\n"
end
File.open("#{imported_dir}.txt", 'w'){ |f| f.write(concat_list)}
io = IO.popen("#{Rails.root}/lib/ffmpeg/ffmpeg -f concat -i #{imported_dir}.txt -c copy #{imported_dir}.mp3").readlines
if sound = Sound.create(user_id: user.id, file: File.open("#{imported_dir}.mp3"), lang: lang, title: title)
audio = FFMPEG::Movie.new("#{imported_dir}.mp3")
if !audio.valid?
puts "//_!_\\\\ Failed reading with ffmpeg (#{sound.id})#{sound.title} //_!_\\\\"
return false
end
endthe problem is that my .txt file containing the file path
file '/home/test/apps/example/releases/20150305224026/tmp/files/4dbe9707-cfef-467b-ab2c-a5e1e1165953_0.mp3'
created files as well but the final file is not created and i got the error message :
No such file or directory @ rb_sysopen - /home/test/apps/example/releases/20150305224026/tmp/files/4dbe9707-cfef-467b-ab2c-a5e1e1165953.mp3
If anyone could help me
-
Processing files and then re-uploading with fog and carrierwave fails on production
2 mars 2015, par LaurieSo I’m trying to get use carrierwave and fog to upload a file to my server, processing that file using ffmpeg to cut it into multiple small files, then upload those to s3.
This works locally (no fog, just file storage), but breaks on production with this error :
NoMethodError: undefined method 'to_file' for #CarrierWave::Storage::Fog::File:0x0000000639a458>
And this trace :
/var/deploy/webapp/web_head/shared/bundle/ruby/2.2.0/gems/carrierwave-0.10.0/lib/carrierwave/storage/fog.rb 259:in `store'
…gems/carrierwave-0.10.0/lib/carrierwave/storage/fog.rb: 80:in `store!'
…s/carrierwave-0.10.0/lib/carrierwave/uploader/store.rb: 59:in `block in store!'
…rrierwave-0.10.0/lib/carrierwave/uploader/callbacks.rb: 17:in `with_callbacks'
…s/carrierwave-0.10.0/lib/carrierwave/uploader/store.rb: 58:in `store!'
…2.2.0/gems/carrierwave-0.10.0/lib/carrierwave/mount.rb: 375:in `store!'
…2.2.0/gems/carrierwave-0.10.0/lib/carrierwave/mount.rb: 207:in `store_audio!'
…/20150227144932/app/controllers/podcasts_controller.rb: 60:in `update'
…2.0/gems/actionview-4.2.0/lib/action_view/rendering.rb: 30:in `process'
…_language-2.0.5/lib/http_accept_language/middleware.rb: 14:in `call'
…red/bundle/ruby/2.2.0/gems/rack-1.6.0/lib/rack/etag.rb: 24:in `call'
…/ruby/2.2.0/gems/rack-1.6.0/lib/rack/conditionalget.rb: 38:in `call'
…red/bundle/ruby/2.2.0/gems/rack-1.6.0/lib/rack/head.rb: 13:in `call'
…/2.2.0/gems/rack-1.6.0/lib/rack/session/abstract/id.rb: 225:in `context'
…/2.2.0/gems/rack-1.6.0/lib/rack/session/abstract/id.rb: 220:in `call'So, I have two uploaders. The uploader for the small chopped up audio files just sets the storage to fog, that’s it.
After uploading the big audio file I run this processing function in the uploader (though the error doesn’t seem to come from here) :
def split
directory = File.dirname(current_path)
tmpfile = File.join(directory,'tmpfile.mp3')
File.rename(current_path,tmpfile)
File.chmod(0644,tmpfile)
sound = FFMPEG::Movie.new(tmpfile)
@model.length = Mp3Info.open(tmpfile).length.round
i=0
number_of_lines= @model.ordered_lines.length
lines = @model.ordered_lines
while icode>Any ideas ?