excamera / alfalfa

Purely functional video codec, used for ExCamera and Salsify
GNU General Public License v2.0
1.2k stars 112 forks source link

salsify-sender immediately returns #77

Closed MathieuBordere closed 6 years ago

MathieuBordere commented 6 years ago

Fedora 28 with gcc 8.1.1

Have modified the source of salsify-sender.cc

diff --git a/src/salsify/salsify-sender.cc b/src/salsify/salsify-sender.cc
index b09ddef..ed16ae9 100644
--- a/src/salsify/salsify-sender.cc
+++ b/src/salsify/salsify-sender.cc
@@ -281,7 +281,7 @@ int main( int argc, char *argv[] )
   }

   /* camera device */
-  Camera camera { 1280, 720, PIXEL_FORMAT_STRS.at( pixel_format ), camera_device };
+  Camera camera { 640, 480, PIXEL_FORMAT_STRS.at( pixel_format ), camera_device };

   /* construct the encoder */
   Encoder base_encoder { camera.display_width(), camera.display_height(),

I first run salsify-receiver 3000 640 480

then salsify-sender --device /dev/video0 --pixfmt YUYV localhost 3000 1337

but salsify-sender immediately returns with exit code 0, with no logging or errors.

sadjad commented 6 years ago

It seems that there's a connection problem here (I fixed salsify-sender.cc to print an error message in those cases: 0061035bf247ec64d2f12dd92e991c17c6a6423c), and the receiver cannot be reached for some reason. Can you try connecting to 0.0.0.0 instead of localhost?

--Sadjad

MathieuBordere commented 6 years ago

Thanks, connecting to 0.0.0.0 works.