Results 1 to 5 of 5

Thread: Memory Leak

  1. #1

    Memory Leak

    Hello.

    I am having a serious memory leak problem, and my media player is sucking up lots of memory over time.

    Does BASS have an OnStop event or anything like that?

    Because I don't know how to tell programmatically when it has stopped playing the song.

    Could someone please help me?
    Nicholas.
    <br />
    <br />Please join: http://holzstukka.proboards81.com

  2. #2

    Memory Leak

    If you were so wise to keep your code compiler independant: compile it with FPC, and use -gh, at program exit, all memory leaks will be printed, along with their locations in source code.

  3. #3
    PGD Community Manager AthenaOfDelphi's Avatar
    Join Date
    Dec 2004
    Location
    South Wales, UK
    Posts
    1,245
    Blog Entries
    2

    Memory Leak

    Nicholas,

    You can find a suggestion on the BASS forums (A quick google got me to the site of the company that makes BASS and a quick search of their forums found the suggestion).

    Admittedly, the code isn't Pascal, but it should give you the way of doing it.

    This has been said before.. please try and search for the answers on-line. You seem to hit a problem and just post on here, which whilst the whole point of a developers community is to get the input of others, I'm sure I'm not the only person who will tell you that you will learn so much more by doing your own research and testing rather than simply posting a request for assistance.

    I'll typically spend hours and hours tinkering around, reading, coding, cursing ;-) Literally, I will exhaust every possibility I can think of before I ask for help. Some may consider that a waste of time if I could get an answer without having to do anything, but I've learned so much this way.

    A pointer to the answer is here.

    In essence, what that post says is that you link a callback to a stream once you've created it using the method BASS_ChannelSetSync.
    :: AthenaOfDelphi :: My Blog :: My Software ::

  4. #4

    Memory Leak

    When I clicked that link it went to the un4seen home page, so I can't see the post.

    What do I do after the SetSync thing to figure out if its still plying?
    Nicholas.
    <br />
    <br />Please join: http://holzstukka.proboards81.com

  5. #5

    Memory Leak

    AthenaOfDelphi, I don’t think your wise suggestion passed..
    Voltrox, in un4seen forum look for the topic "Event for playback stopped". you can also read in the API/Help for the BASS_ChannelSetSync method.
    [size=9px]BEGIN GEEK CODE BLOCK
    <br />d s-- : a24 GB GCS GTW GE C++ P L+ W++ N+ K- w++++ M- PS+ PE+ Y- t+ 5+++ X+ R*
    <br />tv b+ DI++ D+ e++ h+ G-
    <br />END GEEK CODE BLOCK[/size]
    <br />Create your own GeekCode block at: <a href="">...</a>

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •