Commit Graph

36 Commits

Author SHA1 Message Date
Andreas Rheinhardt 1be3d8a0cb avcodec/avcodec: Stop including channel_layout.h in avcodec.h
Also include channel_layout.h directly wherever used.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2021-07-22 11:14:31 +02:00
Andreas Rheinhardt d92f38c179 avdevice: Constify all devices
This is possible now that the next-API is gone.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 11:48:05 -03:00
Jun Zhao 3aeb681f07 libavdevice: Update the class name as uniform style
Update the class name to uniform indev/outdev style.

Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Jun Zhao <barryjzhao@tencent.com>
2019-08-15 09:29:55 +08:00
Marton Balint 4bb0409820 avdevice: migrate to AVFormatContext->url
Signed-off-by: Marton Balint <cus@passwd.hu>
2018-01-28 23:06:43 +01:00
Muhammad Faiz 8103c59522 avdevice: do not use AVFrame accessor
Reviewed-by: wm4 <nfxjfg@googlemail.com>
Signed-off-by: Muhammad Faiz <mfcc64@gmail.com>
2017-04-23 14:35:08 +07:00
Derek Buitenhuis 6f69f7a8bf Merge commit '9200514ad8717c63f82101dc394f4378854325bf'
* commit '9200514ad8717c63f82101dc394f4378854325bf':
  lavf: replace AVStream.codec with AVStream.codecpar

This has been a HUGE effort from:
    - Derek Buitenhuis <derek.buitenhuis@gmail.com>
    - Hendrik Leppkes <h.leppkes@gmail.com>
    - wm4 <nfxjfg@googlemail.com>
    - Clément Bœsch <clement@stupeflix.com>
    - James Almer <jamrial@gmail.com>
    - Michael Niedermayer <michael@niedermayer.cc>
    - Rostislav Pehlivanov <atomnuker@gmail.com>

Merged-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
2016-04-10 20:59:55 +01:00
Ganesh Ajjanagadde 879b4a9d3e lavd/pulse_audio_enc: replace lround by lrint
Here it is mostly a cosmetic change, but there might be benefits in that
there are no compat hacks for lround, while there are for lrint.

Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
2015-12-21 08:25:30 -08:00
Michael Niedermayer 1e51af13c7 avdevice/pulse_audio_enc: use getter function for AVFrame.channels
This is required by the API/ABI for things outside libavutil

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2014-07-28 20:06:11 +02:00
Lukasz Marek 5bef4878d3 lavd/pulse_audio_enc: respect minreq while checking buffer fullness
Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
2014-04-30 00:36:14 +02:00
Lukasz Marek f817d55049 lavd/pulse_audio_enc: signal that buffer is still writable after write
Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
2014-04-30 00:36:06 +02:00
Lukasz Marek a1e5be5c1a lavd/pulse_audio_enc: add pointer checks
Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
2014-04-30 00:35:42 +02:00
Lukasz Marek 954a8f4483 lavd/pulse_audio_enc: add more buffer attributes
Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
2014-04-30 00:35:42 +02:00
Michael Niedermayer a614f892a6 Merge remote-tracking branch 'lukaszmluki/master'
* lukaszmluki/master:
  lavd/pulse_audio_enc: implement pause messages
  lavd/pulse_audio_enc: implement volume messages
  lavd/avdevice: add volume messages
  lavd/pulse_audio_enc: add buffer fullness messages
  lavd/pulse_audio_enc: add nonblocking mode
  lavd/pulse_audio_enc: replace simple API with async API
  lavd/pulse_audio_enc: cosmetics
  lavd/pulse_audio_common: add context helper functions
  lavd/pulse_audio_common: rename variables and enums

Merged-by: Michael Niedermayer <michaelni@gmx.at>
2014-04-18 04:57:23 +02:00
Lukasz Marek 35bf7a491e lavd/pulse_audio_enc: implement pause messages
Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
2014-04-18 02:15:56 +02:00
Lukasz Marek eb9136a7d6 lavd/pulse_audio_enc: implement volume messages
Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
2014-04-18 02:15:56 +02:00
Lukasz Marek cef1180329 lavd/pulse_audio_enc: add buffer fullness messages
Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
2014-04-18 02:15:50 +02:00
Lukasz Marek bc31a57902 lavd/pulse_audio_enc: add nonblocking mode
Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
2014-04-18 01:42:18 +02:00
Lukasz Marek eb9dee2d0d lavd/pulse_audio_enc: replace simple API with async API
Async API allows to use full capabilites of PulseAudio.

Signed-off-by: Lukasz Marek <lukasz.m.luki2@gmail.com>
2014-04-18 01:42:18 +02:00
Lukasz Marek 10627e7e10 lavd/pulse_audio_enc: cosmetics 2014-04-18 01:42:17 +02:00
Lukasz Marek 3937b40e87 lavd/pulse_audio_enc: implement get_device_list callback
Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
2014-03-29 09:54:16 +01:00
Lukasz Marek 27256e69ab lavd/pulse_audio_enc: implement write_uncoded_frame callback
Provided implementation doesn't support planar formats yet.

Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
2014-03-29 09:26:10 +01:00
Lukasz Marek f607767d93 lavd: add categories to device implementations
Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
2014-03-03 23:34:46 +01:00
Lukasz Marek 3aaa50a997 lavd/pulse_audio_enc: add buffer size control options
Add options to control the size of the PulseAudio buffer.

Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
Signed-off-by: Stefano Sabatini <stefasab@gmail.com>
2013-11-27 10:12:54 +01:00
Lukasz Marek babf20a215 lavd/pulse: add ff_ prefix and fix param type
Add ff_ prefix for internal API function.
Change type of param from int into enum AVCodecID as it is more specific.

Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
2013-11-04 00:47:00 +01:00
Lukasz Marek 398844f093 lavd/pulse_audio_enc: fix flush return code
Successful flushing is reported by returning 1 instead of 0.

Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
2013-11-04 00:23:39 +01:00
Michael Niedermayer d041f12513 avdevice/pulse_audio_enc: remove double ;
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-10-28 00:52:11 +01:00
Lukasz Marek 7f5e75eea9 lavd/pulse_audio_enc: more stream validation restrictive
So far pulse device picked up first audio stream and ignored others.
It is required to provide exactly one audio stream now.

Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
2013-10-27 21:45:32 +01:00
Lukasz Marek 4fb3aa491b lavd:pulse_audio_enc: fix array compared against 0
fixes CID 1113222

Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
2013-10-27 21:45:26 +01:00
Lukasz Marek e5b3b75669 lavd/pulse_audio_enc: fix timestamp calculation
Current implementation didn't include duration of
last processed packet.
Also remove access to st->cur_dts and replace with pkt->pts.

Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
2013-10-27 21:43:05 +01:00
Lukasz Marek c428170549 lavd/pulse_audio_enc: avoid vars in for()
Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
2013-10-26 01:58:18 +02:00
Lukasz Marek c6c70c2bf7 lavd/pulse_audio_enc: add another default to stream name
Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
2013-10-26 01:58:01 +02:00
Lukasz Marek d1f383341f lavd/pulse_audio_enc: add support for flushing
Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
Signed-off-by: Stefano Sabatini <stefasab@gmail.com>
2013-10-20 19:15:30 +02:00
Lukasz Marek f569592623 lavd/pulse_audio_enc: fix error check
Error check should be done by checking negative value, not non-zero.

Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
Signed-off-by: Stefano Sabatini <stefasab@gmail.com>
2013-10-18 23:59:27 +02:00
Lukasz Marek 7b1640c4a6 avdevice/pulse_audio_enc: fix stream index
Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
2013-10-12 13:52:26 +02:00
Lukasz Marek 60136345e6 lavd/pulse: move common code to separate file
Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
Reviewed-by: Stefano Sabatini <stefasab@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-10-08 23:02:47 +02:00
Lukasz Marek 361b56c379 lavd: pulse audio encoder
Signed-off-by: Lukasz Marek <lukasz.m.luki@gmail.com>
Reviewed-by: Stefano Sabatini <stefasab@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2013-10-08 14:31:50 +02:00