Giter Club home page Giter Club logo

audiostreamer's Introduction

audiostreamer's People

Contributors

rockerhx avatar syedhali avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

audiostreamer's Issues

Add Images

Hey guys,

Thanks so much for putting this together. It's super helpful!

I was wondering if the missing readme images could be replaced. Pictures help me (lots).

If there's a quick and easy way to plop them back in I'd love to see them!

If it's a big hassle to find or recreate them, close the issue and I'll understand!

Thanks!

Thread 1: Fatal error: Index out of range

I am getting error Thread 1: Fatal error: Index out of range on "Reader+Converter.swift" file on line 54 (let packet = packets[packetIndex]) even if there is packetIndex is less then packets.count.
Screenshot 2019-08-07 at 12 14 44 PM

Add buffering to StreamingState

Right now the StreamingState provides states for Playing, Paused and stopped. I think it would be great to extend those states to include buffering states (like on seeking).

Memory leaks caused by ReaderConverterCallback?

Hi, first I'd like to say how great this framework is. It saved me a lot of time, thank you.

I've noticed that once I called play() method on the Streamer class, the memory usage was growing rapidly in my app. To check whether it's a problem on my side I downloaded your example project and profiled it.
It seems there are memory leaks in ReaderConverterCallback caused by UnsafeMutablePointer that is never deallocated.

I tried to set the streamer's URL to a longer audio file (>1 hour) and the used memory was more than 500MB in about a minute even though the audio file was only about 50MB big.

Steps to reproduce

  1. Download the example project
  2. Run profiling on memory leaks
  3. Hit play before the audio file is downloaded

EDIT

I think I might understand the problem here. The memory usage is growing even though the audio was paused - the read() method is reading empty packets and allocating new memory for the buffer here and here

I'm not really sure how and when should I deallocate the pointers though.

ChatGPT

Cool this is used in ChatGPT iOS!

Deprecated ''withUnsafeMutableBytes' and 'withUnsafeBytes'

Hi,
Thank you for creating this framework, it has been exactly what I needed for my project.
Since the shift to swift 5 there are two warnings due to deprecation:

''withUnsafeMutableBytes' is deprecated: use withUnsafeMutableBytes<R>(_: (UnsafeMutableRawBufferPointer) throws -> R) rethrows -> R instead

'withUnsafeBytes' is deprecated: use withUnsafeBytes<R>(_: (UnsafeRawBufferPointer) throws -> R) rethrows -> R instead

I have not focused on fixing this yet but I thought of mentioning it already.

m4a not supported

I want to stream m4a file and when I pass m4a file url it's give me below error when I use AudioFileStreamParseBytes
"The file is malformed, or otherwise not a valid instance of an audio file of its type, or is not recognized as an audio file."

Streaming Radio ?

Trying to use this framework to stream internet radio. I am able to get some radio stations that stream in .mp3 formats to play, but only for a short period of time . Most stations stream for 30 seconds or so and then go 'silent'. The App does not crash, and there are no errors in the console .. it just seems to go ....silent for lack of a better description ?

The app continues to run and packets seem to still be processed..but no audio ?

The console logs as below, but no audio is heard . ..

2019-08-19 19:26:37.360708-0400 TimePitchStreamer[14105:1198796] [Parser.Packets] ParserPacketCallback(_:_:_:_:_:) - 17 [bytes: 1254, packets: 6, compressed: true]

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.