[FFmpeg-soc] [soc]: r5755 - mms/mmst.c
zhentan feng
spyfeng at gmail.com
Mon Apr 19 18:56:46 CEST 2010
Hi
On Mon, Apr 19, 2010 at 11:58 PM, Ronald S. Bultje <rsbultje at gmail.com>wrote:
> Hi,
>
> On Sun, Apr 18, 2010 at 5:06 AM, spyfeng <subversion at mplayerhq.hu> wrote:
> > /** Send a prepared MMST command packet. */
> > static int send_command_packet(MMSContext *mms)
> > {
> > - ByteIOContext *context= &mms->outgoing_packet_data;
> > - uint8_t *p = mms->outgoing_packet_buffer;
> > - int exact_length= url_ftell(context);
> > + unsigned char *p = mms->outgoing_packet_buffer;
> > + int exact_length= mms->write_ptr - p;
> > int first_length= exact_length - 16;
> > int len8= first_length/8;
> > int write_result;
>
> p is unused here, you can remove it.
>
> removed.
> > +static void mms_put_utf16(MMSContext *mms, uint8_t *src)
> > +{
> > + ByteIOContext bic;
> > + int size = mms->write_ptr - mms->outgoing_packet_buffer;
> > + int len;
> > + init_put_byte(&bic, mms->write_ptr,
> > + sizeof(mms->outgoing_packet_buffer) - size, 1, NULL, NULL,
> NULL, NULL);
> > +
> > + len = ff_put_str16_nolen(&bic, src);
> > + mms->write_ptr += len;
> > +}
>
> Hmm... Is it possible to change ff_put_str16_nolen() prototype?
>
>
most code in asfenc.c use put_le*() functions and write value into
ByteIOContext.
it's a little complicated to modify it.
IMHO, this solution should be ok:)
zhentan
--
Best wishes~
More information about the FFmpeg-soc
mailing list