Использование gst-launch-1.0 для записи звука с камеры в аудиофайлLinux

Ответить Пред. темаСлед. тема
Anonymous
 Использование gst-launch-1.0 для записи звука с камеры в аудиофайл

Сообщение Anonymous »


I'm trying to record my camera's audio into an audio file, i tired wav or mp3 with lame and twolame but the results are the same, so lets stick to wav file for now.

so running st-device-monitor-1.0 Audio/Source shows:

Device found: name : HD Pro Webcam C920 Analog Stereo class : Audio/Source caps : audio/x-raw, layout=interleaved, format=S16LE, rate=[ 16000, 32000 ], channels=2 properties: alsa.card = 1 alsa.card_name = HD Pro Webcam C920 alsa.class = generic alsa.device = 0 alsa.driver_name = snd_usb_audio alsa.id = USB Audio alsa.long_card_name = HD Pro Webcam C920 at usb-0000:00:14.0-10.2, high speed alsa.name = USB Audio alsa.resolution_bits = 16 alsa.subclass = generic-mix alsa.subdevice = 0 alsa.subdevice_name = subdevice #0 api.alsa.card.longname = HD Pro Webcam C920 at usb-0000:00:14.0-10.2, high speed api.alsa.card.name = HD Pro Webcam C920 api.alsa.path = front:1 api.alsa.pcm.card = 1 api.alsa.pcm.stream = capture audio.channels = 2 audio.position = FL,FR card.profile.device = 0 device.api = alsa device.class = sound device.id = 55 device.profile.description = Analog Stereo device.profile.name = analog-stereo device.routes = 1 factory.name = api.alsa.pcm.source media.class = Audio/Source node.description = HD Pro Webcam C920 Analog Stereo node.name = alsa_input.usb-046d_HD_Pro_Webcam_C920_B71E5BFF-02.analog-stereo node.nick = HD Pro Webcam C920 node.pause-on-idle = false object.path = alsa:pcm:1:front:1:capture priority.driver = 2009 priority.session = 2009 factory.id = 18 clock.quantum-limit = 8192 client.id = 32 node.driver = true factory.mode = split audio.adapt.follower = library.name = audioconvert/libspa-audioconvert object.id = 63 object.serial = 67 gst-launch-1.0 pipewiresrc target-object=67 ! ... now.. running gst-launch-1.0 pipewiresrc target-object=67 ! autoaudiosink does work, i can hear the sound from my camera

now i'm trying to record it to a wav file (i added debug output):

gst-launch-1.0 --gst-debug-level=3 pipewiresrc target-object=67 ! audioconvert ! audioresample ! wavenc ! filesink location=output.wav I get:

Setting pipeline to PAUSED ... 0:00:00.011095507 110033 0x7fe5e4000b70 FIXME default gstutils.c:4036:gst_pad_create_stream_id_internal: Creating random stream-id, consider implementing a deterministic way of creating a stream-id 0:00:00.017102534 110033 0x7fe5dc002500 ERROR video-info video-info.c:540:gst_video_info_from_caps: wrong name 'audio/x-raw', expected video/ or image/ Pipeline is live and does not need PREROLL ... Pipeline is PREROLLED ... Setting pipeline to PLAYING ... New clock: pipewireclock0 Redistribute latency... 0:00:00.0 / 99:99:99.

Источник: https://stackoverflow.com/questions/780 ... audio-file
Реклама
Ответить Пред. темаСлед. тема

Быстрый ответ

Изменение регистра текста: 
Смайлики
:) :( :oops: :roll: :wink: :muza: :clever: :sorry: :angel: :read: *x)
Ещё смайлики…
   
К этому ответу прикреплено по крайней мере одно вложение.

Если вы не хотите добавлять вложения, оставьте поля пустыми.

Максимально разрешённый размер вложения: 15 МБ.

  • Похожие темы
    Ответы
    Просмотры
    Последнее сообщение

Вернуться в «Linux»