[Live-devel] Form hang when running live555MediaServer

steven choong lovestoryhouse at gmail.com
Mon Mar 22 18:30:28 PDT 2010


Dear Ross,

I am trying to use live555MediaServer.cpp as a server , I was successfully
compiled the code in VS2008. I use a main form to present the
live555MediaServer, there has a button which triggered the below functions:

public:
        void startServer(){

            TaskScheduler* scheduler = BasicTaskScheduler::createNew();
            UsageEnvironment* env =
BasicUsageEnvironment::createNew(*scheduler);
            UserAuthenticationDatabase* authDB = NULL;
            RTSPServer* rtspServer;
            portNumBits rtspServerPortNum = 554;
            rtspServer = DynamicRTSPServer::createNew(*env,
rtspServerPortNum, authDB);
            if (rtspServer == NULL) {
                rtspServerPortNum = 8554;
                rtspServer = DynamicRTSPServer::createNew(*env,
rtspServerPortNum, authDB);
            }

            env->taskScheduler().doEventLoop();

        }

When the form is running, user click on the button in order to start the
server, it hangs. My question is, Is that a way to prevent the form being
hang while the server is running ?

Thanks in advance,
Steven Choong
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.live555.com/pipermail/live-devel/attachments/20100323/a6e3e313/attachment-0001.html>


More information about the live-devel mailing list