Send raw pixels over the network and visualise them with generic software
Hi,
I am doing a project where I read frames from the camera of an Android device, render them on a plane in Unity and send them over the network (UDP) to a server with a C++ software. The C++ software reads the stream of bytes and saves each frame.
At the moment every captured frame is converted to a jpg array of bytes (e.g. tex.EncodeToJpg ()). I noticed that this operation on a mobile device takes long time and I measured a max of 12fps for frames of size 720x480x3. I would like to try to send the raw frames directly, without going through any conversion on the mobile, and do the conversion on the server.
So I would like to send the bytes obtained with tex.GetRawTextureData (). The only thing is that I don't know how to deal with the received data at the server side. How do I convert these bytes to something readable, e.g. a Jpg files, on the server? Let's say that on the server there are no Unity libraries.
Thank you in advance.
Your answer
Follow this Question
Related Questions
Resolution of Interactive Map,Resolution for Interactive Map Game 0 Answers
Camera raw data into file 0 Answers
Game Development For Different Screen Resolutions 0 Answers
In-game asset creation resolution 1 Answer
Fit Canvas in camera on editors screen 0 Answers