IceCast with iPhone Header issue

二次信任 提交于 2019-12-08 05:39:29

I was sending request using GET method which was a wrong way. I used -

[requestURL setHTTPMethod:@"SOURCE /mountpoint ICE/1.0"];.

I am able to create mount at icecast server.

I also added mp3 file data to play the file like

    //get data from the file url so we can start recording with some file
    NSData *audioData = [NSData dataWithContentsOfURL:fileURL];

    //add audio to stream and add the stream to request for sending data
    NSInputStream *inputStream = [NSInputStream inputStreamWithData:audioData];
    [request setHTTPBodyStream:inputStream];

Its able to play the song data. But currently I don't know why its play only a single chunk of data. I am researching to add chunks of data to stream.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!