Recherche avancée

Médias (9)

Mot : - Tags -/soundtrack

Autres articles (62)

  • Personnaliser en ajoutant son logo, sa bannière ou son image de fond

    5 septembre 2013, par

    Certains thèmes prennent en compte trois éléments de personnalisation : l’ajout d’un logo ; l’ajout d’une bannière l’ajout d’une image de fond ;

  • Ecrire une actualité

    21 juin 2013, par

    Présentez les changements dans votre MédiaSPIP ou les actualités de vos projets sur votre MédiaSPIP grâce à la rubrique actualités.
    Dans le thème par défaut spipeo de MédiaSPIP, les actualités sont affichées en bas de la page principale sous les éditoriaux.
    Vous pouvez personnaliser le formulaire de création d’une actualité.
    Formulaire de création d’une actualité Dans le cas d’un document de type actualité, les champs proposés par défaut sont : Date de publication ( personnaliser la date de publication ) (...)

  • Publier sur MédiaSpip

    13 juin 2013

    Puis-je poster des contenus à partir d’une tablette Ipad ?
    Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir

Sur d’autres sites (10110)

  • Sending Blobs from a Chrome Extension to a Node.js Process without WebSockets [closed]

    29 octobre 2023, par Matrix 404

    Question :
I have a Puppeteer script that runs a Chrome extension, which opens a webpage. The extension records that tab and sends the recorded blobs to the main Node.js process using WebSockets. The main process then streams these blobs to an RTMP server.

    


    I'm looking for an alternative method to send blobs to the main process without using WebSockets. Additionally, I want to know if it's possible to stream these blobs directly from the browser using FFmpeg wasm.

    


    Details :

    


      

    1. My current setup : Puppeteer script -> Chrome extension (recording) -> WebSockets -> Node.js process -> RTMP server.

      


    2. 


    3. I'm exploring options to eliminate the use of WebSockets while maintaining the ability to send recorded blobs from the Chrome extension to the Node.js process efficiently.

      


    4. 


    5. Is it possible to use FFmpeg wasm to stream blobs directly from the browser to an RTMP server ? If so, how can this be achieved ?

      


    6. 


    


    Additional Information :

    


      

    • The technology stack I'm using includes Puppeteer, Chrome extension, Node.js, and FFmpeg.
    • 


    • Any code snippets, examples, or recommended libraries are greatly appreciated.
    • 


    


    Constraints :

    


      

    • Compatibility with modern browsers and reasonable performance are essential.
    • 


    • Ideally, the solution should work in a headless Chrome instance.
    • 


    


    Thank you for your assistance in finding an efficient solution to this problem !

    


      

    • The technology stack I'm using includes Puppeteer, Chrome extension, Node.js, and FFmpeg.
    • 


    • Any code snippets, examples, or recommended libraries are greatly appreciated.
    • 


    


  • 400 Bad Request Error uploading paperclip videos

    5 mars 2017, par jalen201

    Im trying to upload videos with paperclip. When i hit the submit button i receive.

    RSolr::Error::Http - 400 Bad Request Error:

    this is the migration

    class AddAttachmentVideoToPins < ActiveRecord::Migration
     def self.up
       change_table :pins do |t|
         t.attachment :video
       end
     end

     def self.down
       remove_attachment :pins, :video
     end
    end

    Heres the model

    class Pin < ApplicationRecord
     acts_as_votable
     belongs_to :user
     has_many :comments

     searchable do
       text :title, :boost => 5
       text :description
     end

     has_attached_file :image, styles: {medium: "300x300>" }
     validates_attachment_content_type :image, content_type: /\Aimage\/.*\z/

     has_attached_file :video, styles: {
       :medium => {
         :geometry => "640x480",
         :format => 'mp4'
       },
       :thumb => {
         :geometry => "160x120", :format => 'jpeg', :time => 10
       }
     },
     :processors => [:transcoder]

     validates_attachment_content_type :video, content_type:  /\Avideo\/.*\Z/

    also i added these 4 gems, and installed ffmpeg with homebrew

       gem 'paperclip', '~> 5.1'

       gem 'aws-sdk', '~> 2.8'

       gem 'paperclip-av-transcoder', '~> 0.6.4'

       gem 'paperclip-ffmpeg', '~> 1.2'

    lastly this is my controller, i added :video as a strong parameter.

    class PinsController < ApplicationController

     before_action :find_pin, only: [:show,:edit,:update,:destroy, :upvote]
     before_action :authenticate_user!, except: [:index,:show]

     def index
       @search = Pin.search do
         fulltext params[:search]
       end
       @pins = @search.results
     end

     def new
       @pin = current_user.pins.build
     end

     def show
       @comments = Comment.where(pin_id: @pin).order('created_at DESC')
     end

     def edit
       @lookup = User.all
     end

     def profile
       @users = User.all
       if User.find_by_username(params[:id])
         @username = params[:id]
         @user = User.find_by_username(params[:id])
       else
         redirect_to root_path
       end
       @user_pin = Pin.all.where('user_id = ?',       User.find_by_username(params[:id]).id)
     end

     def update
       if @pin.update(pin_params)
         redirect_to @pin, notice: "Pin was succesfully updated"
       else
         render 'edit'
       end
     end

     def destroy
       @pin.destroy
       redirect_to root_path      
     end

     def upvote
       @pin.upvote_by current_user
       redirect_to :back
     end

     def create
       @pin = current_user.pins.build (pin_params)

       if @pin.save
         redirect_to @pin , notice: "Succesfully created new pin"
       else
         render 'new'
       end
     end

     private

     def pin_params
       params.require(:pin).permit(:title, :description, :image, :video)
     end

     def find_pin
       @pin = Pin.find(params[:id])
     end
    end

    i added this in the view

    <%= video_tag @pin.video.url(:medium), controls: true, style: "max-width: 100%;" %>

    If anyone could help that would be greatly appreciated

  • Build Live Audio Stream Player

    5 décembre 2011, par Kurt

    For an internship project i've been trying to develop a simple audio player for audio live stream.

    Currently i'm using a homemade three buffering (of 1/3 s each) solution played by QAudioOutput, which recall himself after finished his reading.

    void VideoServer::getBuf(QBuffer * p_buf)
    {
       audio_chunk*    ac = NULL;
       std::vector v;

       v.clear();
       for (int i = 0; i < 20;)
       {
           ac = _audioPreviewSharedData->deQueueAudio();
           if (ac)
           {
               v.insert(v.end(), ac->v_buf.begin(), ac->v_buf.end());
               i++;
               delete ac;
           }
           else
               usleep(50000);
       }
       p_buf->close();
       p_buf->setData((const char *)(&v[0]), v.size()*2);
       p_buf->open(QIODevice::ReadOnly);
    }

    -

    void VideoServer::slot_launchAudioPreviewBuffering()
    {
       getBuf(_buf1);
       getBuf(_buf2);
       _state = 2;
       connect(_audioPreviewTimer, SIGNAL(timeout()), this, SLOT(slot_audioPreviewBuffering()));
       _audioPreviewTimer->start(0);
       connect(_audioOut, SIGNAL(stateChanged(QAudio::State)), this, SLOT(finishedPlaying(QAudio::State)));
    }

    -

    void VideoServer::finishedPlaying(QAudio::State state)
    {
       if(state == QAudio::IdleState) {
           slot_audioPreviewBuffering();
       }
    }

    -

    void VideoServer::slot_audioPreviewBuffering()
    {
       switch (_state) {
       case 0:
           {
               _audioOut->start(_buf2);
               getBuf(_buf1);
               _state = 1;
               break;
           }
       case 1:
           {
               _audioOut->start(_buf3);
               getBuf(_buf2);
               _state = 2;
               break;
           }
       case 2:
           {
               _audioOut->start(_buf1);
               getBuf(_buf3);
               _state = 0;
               break;
           }
       }
    }

    But i'm suffering of choppy sound (little interruption between audio chunk).

    How to play this flux without interruption () and with a reasonable delay between audio and video (less 1s) ? Is there a best way ? Am i doing wrong ?

    Thank you !