From e6f17e50c43177fccb5091c75894627ae2fc2376 Mon Sep 17 00:00:00 2001 From: Luigi Rizzo Date: Sun, 29 Jun 2008 12:45:59 +0000 Subject: make this compile after ast_frame's data field changed to a union git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@126308 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- channels/vcodecs.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'channels/vcodecs.c') diff --git a/channels/vcodecs.c b/channels/vcodecs.c index ae3770920..90f7258b1 100644 --- a/channels/vcodecs.c +++ b/channels/vcodecs.c @@ -240,7 +240,7 @@ static struct ast_frame *create_video_frame(uint8_t *start, uint8_t *end, return NULL; } memcpy(data+head, start, len); - f->data = data; + f->data.ptr = data; f->mallocd = AST_MALLOCD_DATA | AST_MALLOCD_HDR; //f->has_timing_info = 1; //f->ts = ast_tvdiff_ms(ast_tvnow(), out->ts); @@ -393,7 +393,7 @@ static struct ast_frame *h263p_encap(struct fbuf_t *b, int mtu, if (!f) break; - data = f->data; + data = f->data.ptr; if (h == 0) { /* we start with a psc */ data[0] |= 0x04; // set P == 1, and we are done } else { /* no psc, create a header */ @@ -647,7 +647,7 @@ static struct ast_frame *h263_encap(struct fbuf_t *b, int mtu, if (!f) break; - bcopy(h, f->data, 4); /* copy the h263 header */ + bcopy(h, f->data.ptr, 4); /* copy the h263 header */ /* XXX to do: if not aligned, fix sbit and ebit, * then move i back by 1 for the next frame */ @@ -801,7 +801,7 @@ static struct ast_frame *h261_encap(struct fbuf_t *b, int mtu, break; /* recompute header with I=0, V=1 */ h[0] = ( (sbit & 7) << 5 ) | ( (ebit & 7) << 2 ) | 1; - bcopy(h, f->data, 4); /* copy the h261 header */ + bcopy(h, f->data.ptr, 4); /* copy the h261 header */ if (ebit) /* not aligned, restart from previous byte */ i--; sbit = (8 - ebit) & 7; @@ -1021,7 +1021,7 @@ static struct ast_frame *h264_encap(struct fbuf_t *b, int mtu, size -= frag_size; /* skip this data block */ start += frag_size; - data = f->data; + data = f->data.ptr; data[0] = hdr[0]; data[1] = hdr[1] | (size == 0 ? 0x40 : 0); /* end bit if we are done */ hdr[1] &= ~0x80; /* clear start bit for subsequent frames */ -- cgit v1.2.3