diff options
Diffstat (limited to 'src/liana')
| -rw-r--r-- | src/liana/client.c | 7 | ||||
| -rw-r--r-- | src/liana/handlers/codec_client.c | 2 | ||||
| -rw-r--r-- | src/liana/handlers/codec_server.c | 12 | ||||
| -rw-r--r-- | src/liana/list.c | 2 |
4 files changed, 14 insertions, 9 deletions
diff --git a/src/liana/client.c b/src/liana/client.c index 5e33086..5d770c0 100644 --- a/src/liana/client.c +++ b/src/liana/client.c @@ -39,9 +39,10 @@ static void parse_info_packet(struct lia_client *client, struct aki_packet *pack av_channel_layout_default(&fmt->channel_layout, fmt->channel_count); #endif } else if (type == CAMU_STREAM_VIDEO) { - track->stream.video.width = aki_packet_read_s32(packet); - track->stream.video.height = aki_packet_read_s32(packet); - track->stream.video.format = aki_packet_read_s32(packet); + struct camu_video_format *fmt = &track->stream.video.fmt; + fmt->width = aki_packet_read_s32(packet); + fmt->height = aki_packet_read_s32(packet); + fmt->format = aki_packet_read_s32(packet); } track->index = 0; break; diff --git a/src/liana/handlers/codec_client.c b/src/liana/handlers/codec_client.c index 050cc6f..d420c59 100644 --- a/src/liana/handlers/codec_client.c +++ b/src/liana/handlers/codec_client.c @@ -1,6 +1,8 @@ #include "../../codec/codec.h" +#ifdef CAMU_HAVE_FFMPEG #include "../../codec/ffmpeg/decoder.h" #include "../../codec/ffmpeg/packet_ext.h" +#endif #include "../../codec/stb_image/decoder.h" #include "../../codec/spng/decoder.h" #include "../../codec/wuffs/decoder.h" diff --git a/src/liana/handlers/codec_server.c b/src/liana/handlers/codec_server.c index 07fafdf..58da2e6 100644 --- a/src/liana/handlers/codec_server.c +++ b/src/liana/handlers/codec_server.c @@ -1,6 +1,8 @@ #include "../../codec/codec.h" +#ifdef CAMU_HAVE_FFMPEG #include "../../codec/ffmpeg/demuxer.h" #include "../../codec/ffmpeg/packet_ext.h" +#endif #include "../../codec/stb_image/demuxer.h" #include "../../codec/spng/demuxer.h" #include "../../codec/wuffs/demuxer.h" @@ -41,12 +43,14 @@ static void codec_server_write_info(struct lia_server_handler *handler, struct a al_array_foreach_ptr(codec->demux->streams, i, stream) { aki_packet_write_u8(packet, stream->mode); switch (stream->mode) { - case CAMU_NORMAL: + case CAMU_NORMAL: { aki_packet_write_u8(packet, stream->type); - aki_packet_write_s32(packet, stream->video.width); - aki_packet_write_s32(packet, stream->video.height); - aki_packet_write_s32(packet, stream->video.format); + struct camu_video_format *fmt = &stream->video.fmt; + aki_packet_write_s32(packet, fmt->width); + aki_packet_write_s32(packet, fmt->height); + aki_packet_write_s32(packet, fmt->format); break; + } #ifdef CAMU_HAVE_FFMPEG case CAMU_FFMPEG_COMPAT: aki_packet_write_av_codec_id(packet, stream->av.stream->codecpar->codec_id); diff --git a/src/liana/list.c b/src/liana/list.c index 9698497..970d247 100644 --- a/src/liana/list.c +++ b/src/liana/list.c @@ -3,8 +3,6 @@ #include <al/lib.h> #include <al/log.h> -#include "../libsink/common.h" - #include "list.h" #include "list_cmp.h" |