1. 03 3月, 2019 15 次提交
    • R
      Add option to mirror in read-only · 8655ba71
      Romain Vimont 提交于
      Add an option to disable device control: -n/--no-control.
      8655ba71
    • R
      Rename -n/--no-window to -N/--no-display · 163cd36c
      Romain Vimont 提交于
      The description of scrcpy is "Display and control your Android device".
      We want an option to disable display, another one to disable control.
      
      For naming consistency, name it --no-display.
      
      Also change the shortname to -N, so that we can use -n for --no-control
      later.
      163cd36c
    • R
      Add missing no_window initialization · db6644f1
      Romain Vimont 提交于
      Initialize the field no_window in "struct args"
      db6644f1
    • R
      Avoid unnecessary call if display is disabled · 36191b7e
      Romain Vimont 提交于
      If --no-window is passed, there is no need to register an event watcher.
      36191b7e
    • R
      Extract event processing out of event_loop() · 33ccb136
      Romain Vimont 提交于
      To avoid too many levels of nested blocks, move the event handling logic
      in a separate function.
      33ccb136
    • R
      Update code style · aeda583a
      Romain Vimont 提交于
      Limit source code to 80 chars, and declare functions return type and
      modifiers on a separate line.
      
      This allows to avoid very long lines, and all function names are
      aligned.
      
      (We do this on VLC, and I like it.)
      aeda583a
    • R
      Replace uint64_t by Uint64 for consistency · b2fe0054
      Romain Vimont 提交于
      The field pts is declared Uint64 in struct frame_meta.
      b2fe0054
    • R
      Describe the --no-window feature in README · ef118cc6
      Romain Vimont 提交于
      ef118cc6
    • R
      Implement the --no-window flag · 89812e4e
      Romain Vimont 提交于
      Disable decoder, screen (display), file_handler and controller when
      --no-window is requested.
      
      <https://github.com/Genymobile/scrcpy/pull/418>
      89812e4e
    • C
      Add a new option: -n/--no-window · 421a1141
      CapsLock 提交于
      This option will allow scrcpy to record the stream without display.
      Signed-off-by: NRomain Vimont <rom@rom1v.com>
      421a1141
    • R
      Add stream layer · e6e011ba
      Romain Vimont 提交于
      The decoder initially read from the socket, decoded the video and sent
      the decoded frames to the screen:
      
                    +---------+      +----------+
        socket ---> | decoder | ---> |  screen  |
                    +---------+      +----------+
      
      The design was simple, but the decoder had several responsabilities.
      
      Then we added the recording feature, so we added a recorder, which
      reused the packets received from the socket managed by the decoder:
      
                                          +----------+
                                     ---> |  screen  |
                    +---------+     /     +----------+
        socket ---> | decoder | ----
                    +---------+     \     +----------+
                                     ---> | recorder |
                                          +----------+
      
      This lack of separation of concerns now have concrete implications: we
      could not (properly) disable the decoder/display to only record the
      video.
      
      Therefore, split the decoder to extract the stream:
      
                                          +----------+      +----------+
                                     ---> | decoder  | ---> |  screen  |
                    +---------+     /     +----------+      +----------+
        socket ---> | stream  | ----
                    +---------+     \     +----------+
                                     ---> | recorder |
                                          +----------+
      
      This will allow to record the stream without decoding the video.
      e6e011ba
    • R
      Store the recording request in a local bool · e7b7b083
      Romain Vimont 提交于
      This avoids to test explicitly whether options->record_filename is NULL.
      e7b7b083
    • R
      Fix cleanup order · 8aeb5c0e
      Romain Vimont 提交于
      The order of cleanup was not the reverse as the initialization order. As
      a consequence, recorder_destroy() could theoretically be called even if
      recorder_init() failed.
      8aeb5c0e
    • R
      Fix recording with old decoding/encoding API · bcd4090d
      Romain Vimont 提交于
      The deprecated avcodec_decode_video2() should always the whole packet,
      so there is no need to loop (cf doc/examples/demuxing_decoding.c in
      FFmpeg).
      
      This hack changed the packet size and data pointer. This broke recording
      which used the same packet.
      bcd4090d
    • R
      Rename "stop" to "interrupt" · 84270e2d
      Romain Vimont 提交于
      The purpose of video_buffer_stop() is to interrupt any blocking call, so
      rename it to video_buffer_interrupt().
      84270e2d
  2. 02 3月, 2019 2 次提交
  3. 27 2月, 2019 1 次提交
  4. 16 2月, 2019 5 次提交
  5. 10 2月, 2019 4 次提交
  6. 09 2月, 2019 6 次提交
  7. 27 1月, 2019 2 次提交
  8. 26 1月, 2019 3 次提交
  9. 22 1月, 2019 2 次提交