Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

80
Views
Uint8Array stream buffer to video

I'm streaming video file from server to client. On the client side i receive Uint8Array and i don't know as use this array for streaming video. what data format to convert it to and how to send it as a video tag so that the file can be played ? The task is to stream an rtsp stream, but first I want to try streaming one video file

server

io.on('connection', socket => {
  console.log('conn')
  let stream = ss.createStream();
  ss(socket).emit('stream', stream);
  let readStream = fs.createReadStream(mp4Path);
  readStream.pipe(stream);

  socket.on('disconnect', () => {
    console.log('user disconnect')
  })
})

client

  const socket = io();

  ss(socket).on('stream', function(stream) {
    var binaryString = "";

    stream.on('data', function(data) {
      for(var i = 0; i < data.length; i++) {
        binaryString += String.fromCharCode(data[i]);
      }
    });

    stream.on('end', function(data) {
      binaryString = "";
    });
  });
about 4 years ago · Santiago Trujillo
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!