ejurgensen
1fbb4b0d59
[transcode] Fix problem for file types where ffmpeg decode returns 0
...
It seems ffmpeg/libav reads a file type like Monkey's audio in large
chunks, so that each packet must be passed to the decoder multiple
times. The decoder will return 0 until the packet is completed. This
change makes forked-daapd able to deal with a return value of 0.
2016-05-06 00:23:07 +02:00
ejurgensen
42e68311eb
[transcode] Increase read timeout slightly
2016-03-25 20:56:08 +01:00
ejurgensen
7d1d52e8f0
[transcode] Fix missing channel number for newer ffmpeg ( closes #241 )
2016-03-20 19:22:16 +01:00
ejurgensen
73cddbb9de
[transcode] Fix type of stream_index so the tests make sense
2016-02-06 19:51:13 +01:00
ejurgensen
0d55e055c0
[ffmpeg] Update most deprecated functions
2016-01-05 23:22:01 +01:00
ejurgensen
7caf8cc66a
[artwork] Add ability to rescale Spotify (should improve caching so we don't save too large images)
2016-01-05 21:44:44 +01:00
ejurgensen
93a6765c8c
[transcode] Fix freeze problem where av_read_frame would block on broken connections
2015-12-09 20:00:09 +01:00
ejurgensen
7894a4d85f
[transcode] Don't push NULL frames to filtergraph when flushing, can lead to segfault
2015-10-25 19:59:06 +01:00
ejurgensen
3e80e5c517
[transcode] Don't pass error to player on eof + some comments and cleaning
2015-10-22 22:09:19 +02:00
ejurgensen
e20d2c544d
[transcode] Comments and raise MAX_BAD_PACKETS to 5
2015-10-22 21:01:43 +02:00
ejurgensen
058b2fb0d6
[transcode] Improve decoding to allow for decoder special cases, like decoders not processing
...
entire packets, rejecting packets and not returning frames. Should fix issue with network
streams not opening.
2015-10-21 23:53:21 +02:00
ejurgensen
2a610812a5
Refactor transcode.c so it can actually transcode + use new capability to support mp3 streaming.
...
Also includes the skeleton for perhaps supporting video in the future. Adds more fine-grained
ffmpeg/libav compability checks. Dependency on libavresample/libswresample exchanged with
dependency on libavfilter, which seems more versatile.
2015-10-09 23:58:27 +02:00
chme
e1147c00a1
[player] Refactor player to better fit the queue refactor
2015-10-04 07:59:58 +02:00
ejurgensen
68912efa1f
Enable resuming playback from saved position for certain media kinds (eg audiobooks)
2015-08-04 22:33:32 +02:00
chme
659f9c09bb
Use enum values for data_kind and media_kind
2015-04-23 11:34:44 +02:00
ejurgensen
99cda05dab
Remove player metadata event timer (use the existing instead)
2015-04-11 20:30:31 +02:00
ejurgensen
e72447954a
Some cleaning up of ICY artwork retrieval
2015-04-09 22:22:42 +02:00
ejurgensen
56ece92209
Remember to actually request ICY metadata in transcode.c
2015-04-02 00:09:12 +02:00
ejurgensen
e49c941a00
Add a worker thread to support async tasks from the player thread
...
(and maybe others later)
2015-03-31 23:05:24 +02:00
ejurgensen
a529d78880
Don't crash on no metadata...
2015-03-29 20:16:56 +02:00
ejurgensen
b8d8df132b
Support for remote m3u playlists (ref pr #79 )
2015-03-20 23:40:42 +01:00
ejurgensen
6221e24f1b
Support for live ICY metadata for streams (incl. artwork)
2015-03-14 21:42:53 +01:00
ejurgensen
2879458e98
Fix for issue #62 (slow internet streams), credit @chme
2015-01-02 23:24:44 +01:00
ejurgensen
a69619a5a7
Implement is_remote() and change how transcode_needed() is used
...
transcode_needed() was getting called needlessly in http_daapd.c,
because 1) once it is determined that a given codec needs transcoding
for a given client there is no reason to call and check again, 2)
transcoding is irrelevant for remotes. Also some cleaning up of
user_agent_filter().
2014-12-28 23:37:12 +01:00
chme
7889d92a81
Identify "android" user-agent as a remote client in transcode_needed()
...
(similar to the check in user_agent_filter())
2014-12-28 09:37:19 +01:00
ejurgensen
88fcfa061d
Add compability with ffmpeg's libswresample
2014-10-02 22:48:50 +02:00
ejurgensen
cf091e8d8b
Adjust daapcache so it serves User-Agent to httpd_daap's reply handlers
2014-08-23 00:02:01 +02:00
ejurgensen
17ffdc56ad
Fix bug where streams with sample rate < 44100 stop too early (with libav 10+)
...
- avresample_convert should be passed max samples to convert, not
number of samples in input (which for low sample rates is lower
than output)
2014-07-06 23:31:20 +02:00
ejurgensen
2247fadbfa
Some preprocessor conditions for compability on OpenWrt
2014-06-16 23:31:44 +02:00
ejurgensen
687f349927
Let configure check libevent version and include according to version
2014-03-13 23:33:35 +01:00
ejurgensen
7ed6cc98c3
Add support for Spotify (squashed commit), and:
...
- Try to not return items which a client can't play
- Remove inotify subscription to IN_MODIFY and IN_CREATE
- Fix crash on unknown codec type in transcode.c
- Probably added some new bugs...
2014-03-11 23:20:29 +01:00
ejurgensen
7997377deb
Adjust for libav 10 API
...
With libav 10 the API is (again...) changed, adjust for that and
add the appropriate version conditions
2014-02-17 23:05:24 +01:00
Justin Maggard
f9a76aeb1a
Add User-Agent detection for iTunes video playback on OSX
...
iTunes on OSX has a different User-Agent when playing back video
files. Detect this so we can deterimine his codec support.
2014-02-05 17:34:27 -08:00
ejurgensen
785383861b
ffmpeg/libav conditions for CodecID and AVCODEC_MAX_AUDIO_FRAME_SIZE (thanks @freultwah)
2014-01-27 21:24:08 +01:00
ejurgensen
5d6d7c7f82
Only allocate transcode resample buffer once, but make it large
2014-01-19 23:27:39 +01:00
ejurgensen
c2c072eb58
Plug bad mem leak if using libavcodec 54.35 (libav9) or above
2014-01-19 23:09:40 +01:00
ejurgensen
efd4d56de5
Fix a few missing libav conditions
2014-01-06 21:41:30 +01:00
ejurgensen
edaa8fe4f2
Add libav version conditions
2014-01-02 22:49:18 +01:00
ejurgensen
21584fa1ff
Minor adjustment of log message in transcode.c
2013-12-30 23:47:41 +01:00
ejurgensen
8663641e84
Account for no channel_layout (resample) + add free decode frame
2013-12-30 23:16:30 +01:00
ejurgensen
3a8936cd26
Change to libav 9 resampling (avresample)
...
Some of the previous libav stuff removed, re-add later
2013-12-30 13:03:53 +01:00
ejurgensen
73b2d08400
Rework of transcode.c for libav 9. Resampling is broken in this commit.
2013-12-30 00:40:16 +01:00
ejurgensen
0fd65b285d
Fix some ffmpeg/libav compiler conditions
2013-11-25 19:43:17 +01:00
ejurgensen
dea8d02c76
Downgrade log message severity
2013-11-23 11:04:10 +01:00
ejurgensen
3471b6c147
Cleaning up deprecated ffmpeg/libav
2013-09-07 23:39:22 +02:00
ejurgensen
c1c171e21f
Include for av_rescale_q was missing
...
- and has been for a while, it seems
2013-09-04 22:33:47 +02:00
ejurgensen
fa965dee75
Changed SAMPLE_FMT_S16 for ffmpeg 0.11
2013-05-24 20:33:26 +02:00
Julien BLACHE
ed20d3f7de
libav 0.7: use av_get_bytes_per_sample() instead of av_get_bits_per_sample_fmt()
2011-09-10 12:48:14 +02:00
Julien BLACHE
dbe22c2c02
libav 0.7: use avformat_open_input() instead of av_open_input_file()
2011-09-10 12:48:14 +02:00
Julien BLACHE
b1d31feb53
libav 0.7: Switch from av_get_bits_per_sample_format() to ..._fmt()
2011-06-02 22:16:52 +02:00