[MPlayer-dev-eng] Re: MMS support in mplayer begun

Derek J Witt djw at flinthills.com
Thu Dec 6 10:27:46 CET 2001


I have forgotten a header file that did not make it into the patch file. 

Derek J Witt wrote:
> 
> Hi, all. I have started on MMS support in mplayer.  I have it at least
> connecting to TCP MMS streams.  I have included the patch. For some
> reason, if I try using "cvs rdiff 120601 main", I keep getting a whole
> messful of parsed_root_directory errors. So,  I  was only able to run
> "cvs diff -NR" to get a file. I had to edit the file to get a proper
> patch file. But, it didn't include the new file I put in.
> 
> So, I have included both the patch and the new file.  I do have my test
> mms stream being connected.  I do send it the correct header. I have yet
> to get it to start the actual data packets. But, it should not affect
> anything else in mplayer. Let me know what you think.
> 
> Thanks.
> 
> --
> **  Derek J Witt                                              **
> *   Email: mailto:djw at flinthills.com                           *
> *   Home Page: http://www.flinthills.com/~djw/                 *
> *** "...and on the eighth day, God met Bill Gates." - Unknown **
> 

-- 
**  Derek J Witt                                              **
*   Email: mailto:djw at flinthills.com                           *
*   Home Page: http://www.flinthills.com/~djw/                 *
*** "...and on the eighth day, God met Bill Gates." - Unknown **
-------------- next part --------------
/*
 * MMS-tcp/ip protocol commands for MPlayer.
 * Originally written by an anonymous author (http://yaan2.linux.net.cn/) for
 * "ASFRecorder +". 
 * Adapted for MPlayer by Derek J Witt <djw at flinthills.com>,
 * 5 December 2001.
 *
 * Multimedia Services Protocol orignally designed by Microsoft Corporation.
 * I must give credit to Microsoft for this protocol, or someone will have
 * my hide. ;-)
 */

#ifndef __MMST_H
#define __MMST_H

#define MMST_DEFAULT_PORT 1755

#define MMSC_POS_SIZE			0x08
#define MMSC_POS_SEQ			0x14
#define MMSC_POS_FLAG			0x24
#define MMSC_POS_SUBFLAG1		0x26
#define MMSC_POS_REQCHUNKSEQ	0x3c
#define MMSC_POS_CHUNKLENGTH	0x5c
#define MMSC_POS_SUBFLAG2		0x28

#define MMSD_POS_TYPE			0x04
#define MMSD_POS_SUBTYPE		0x05
#define MMSD_POS_SIZE			0x06

/* MMSD Chunk types */
#define MMSD_HEADER_CHUNK 		0x02
#define MMSD_DATA_CHUNK   		0x04

unsigned char MMSC_HEADER[] = {
	0x01,0x00,0x00,0x00,0xCE,0xFA,0x0B,0xB0, 0x00,0x00,0x00,0x00,0x4D,0x4D,0x53,0x20};

unsigned char MMSC_REQUEST_INIT[] = {
	0x14,0x00,0x00,0x00,0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
	0x12,0x00,0x00,0x00,0x01,0x00,0x03,0x00, 0xF0,0xF0,0xF0,0xF0,0x0B,0x00,0x04,0x00,
	0x1C,0x00,0x03,0x00};

unsigned char MMSC_REQUEST_CONNPORT[] = {
	0x0B,0x00,0x00,0x00,0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,0x00,0x00,0xE0,0x3F,
	0x09,0x00,0x00,0x00,0x02,0x00,0x03,0x00, 0xF0,0xF0,0xF0,0xF0,0xFF,0xFF,0xFF,0xFF,
    0x00,0x00,0x00,0x00,0x00,0x00,0xA0,0x00, 0x02,0x00,0x00,0x00};

unsigned char MMSC_REQUEST_FILE[] = {
	0x08,0x00,0x00,0x00,0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,0x00,0x00,0xE0,0x3F,
	0x06,0x00,0x00,0x00,0x05,0x00,0x03,0x00, 0x01,0x00,0x00,0x00,0xFF,0xFF,0xFF,0xFF,
	0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00};

unsigned char MMSC_REQUEST_RECVHEADER[] = {
	0x09,0x00,0x00,0x00,0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,0x00,0x00,0xE0,0x3F,
	0x07,0x00,0x00,0x00,0x15,0x00,0x03,0x00, 0x01,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
	0x00,0x00,0x00,0x00,0x00,0x80,0x00,0x00, 0xFF,0xFF,0xFF,0xFF,0x64,0x00,0x79,0x00,
	0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,0x00,0x20,0xAC,0x40,
	0x02,0x00,0x00,0x00,0x00,0x00,0x00,0x00};

unsigned char MMSC_REQUEST_RECVBODY[] = {
	0x07,0x00,0x00,0x00,0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,0x00,0x00,0xE0,0x3F,
	0x05,0x00,0x00,0x00,0x07,0x00,0x03,0x00, 0x01,0x00,0x00,0x00,0xFF,0xFF,0x01,0x00,
	0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
	0xFF,0xFF,0xFF,0x80,0x04,0x00,0x00,0x00};

unsigned char MMSC_REPLY[] = {
	0x04,0x00,0x00,0x00,0x00,0x00,0x00,0x00, 0x00,0x00,0x00,0x00,0x00,0x00,0xE0,0x3F,
	0x02,0x00,0x00,0x00,0x1B,0x00,0x03,0x00, 0x01,0x00,0x00,0x00,0xFF,0xFF,0x01,0x00};

#endif


More information about the MPlayer-dev-eng mailing list