Search found 18 matches
- Thu Dec 04, 2008 4:31 pm
- Forum: C++ Development
- Topic: Send/Receive wxImage by using wxSocketBase
- Replies: 6
- Views: 1062
- Thu Dec 04, 2008 3:38 pm
- Forum: C++ Development
- Topic: Send/Receive wxImage by using wxSocketBase
- Replies: 6
- Views: 1062
In fact, I get the image from an IP camera: wxString httpAddress= "http://..."; wxURL imageURL(httpAddress); wxInputStream *inputStream = imageURL.GetInputStream(); wxImage downloadedImage; if ((inputStream != NULL) && (downloadedImage.LoadFile(*inputStream, wxBITMAP_TYPE_JPEG))) { downloadedImage.S...
- Thu Dec 04, 2008 1:54 pm
- Forum: C++ Development
- Topic: Send/Receive wxImage by using wxSocketBase
- Replies: 6
- Views: 1062
Thanks for your answer. This code: unsigned char *memp; mySock->Read(memp,size); means that I must send an unsigned char pointer like: unsigned char *memp; ... mySock->Write(memp,size); So if I have a wxImage, how can I transform it into unsigned char* ; Or if I have a wxInputStream* , how can I tra...
- Thu Dec 04, 2008 11:28 am
- Forum: C++ Development
- Topic: Send/Receive wxImage by using wxSocketBase
- Replies: 6
- Views: 1062
Send/Receive wxImage by using wxSocketBase
Hi,
Is it possible to send and receive wxImage by using wxSocketBase::Write and wxSocketBase::Read functions?
Thx.
Is it possible to send and receive wxImage by using wxSocketBase::Write and wxSocketBase::Read functions?
Thx.
- Thu Nov 20, 2008 1:07 pm
- Forum: C++ Development
- Topic: How to surcharge wxApp::OnRun() ?
- Replies: 1
- Views: 463
How to surcharge wxApp::OnRun() ?
Hello! I have an application derived from wxApp. I use the OnInit() function in order to create sockets. I want to add a loop in the main function(OnRun). But if I surcharge this function, the socket events are not "handled". So how can I do it? To give a mark, I 've created a class derived from wxE...
- Tue Nov 11, 2008 4:34 pm
- Forum: C++ Development
- Topic: wxWidgets' sample ipc
- Replies: 3
- Views: 909
In fact I have a problem "wxYield called recursively" with an application like the sample ipc. I've seen in the book that it is "normal" and I've seen in the forums that I must launch the socket in a second thread. So I've read the tutorial "Sockets FAQ/Tutorial" and after that I've posted this topi...
- Mon Nov 10, 2008 1:23 pm
- Forum: C++ Development
- Topic: wxWidgets' sample ipc
- Replies: 3
- Views: 909
wxWidgets' sample ipc
Hello! I want to do an application client/server like the sample of the library wxWidgets on the repertory "ipc". But I want launch the socket in a second thread that is to say one thread per client. Could you help me please for the beginning ; I have the impression that it is necessary to modify th...
- Fri Nov 07, 2008 11:55 am
- Forum: C++ Development
- Topic: wxTCP... and recursive Yield
- Replies: 7
- Views: 1962
Look at http://wiki.wxwidgets.org/docbrowse.cgi/wxwin_wxapp.html#wxappyield "Calling Yield() recursively is normally an error and an assert failure is raised in debug build if such situation is detected. However if the onlyIfNeeded parameter is true, the method will just silently return false inste...
- Tue Nov 04, 2008 2:12 pm
- Forum: C++ Development
- Topic: wxSocket: wxYield called recursively
- Replies: 5
- Views: 2073
- Tue Nov 04, 2008 10:02 am
- Forum: C++ Development
- Topic: wxSocket: wxYield called recursively
- Replies: 5
- Views: 2073
I had to create the thread just after we have the event "wxSOCKET_CONNECTION" ? wxTCPServerThread is my thread class: #define TCPSERVERTHREAD #ifdef TCPSERVERTHREAD // -------------------------------------------------------------------------- // wxTCPEventHandler stuff (private class) // -----------...
- Tue Nov 04, 2008 8:47 am
- Forum: C++ Development
- Topic: wxSocket: wxYield called recursively
- Replies: 5
- Views: 2073
Sorry I have deleted all the code concerning the threads.. But I use the classes wxTCPServer, wxTCPClient, and wxTCPConnection, so the flag of the sockets is wxSOCKET_WAITALL. I have decided to modifiy theses classes and not my code. Because yestarday I've observed a private class named "wxTCPEventH...
- Mon Nov 03, 2008 9:45 am
- Forum: C++ Development
- Topic: IPC and wxYield -
- Replies: 2
- Views: 719
- Mon Nov 03, 2008 9:39 am
- Forum: C++ Development
- Topic: Question about using wxSocketBase::Peek()
- Replies: 5
- Views: 1696
wxYield called recursively
hi there, there was a good entry in the wxBook. wxSockets do have flags that define how they act (blocking GUI while they receive data, receive all data at once and so on). My problem was that i only used a single thread including GUI and sockets. You need now to imagine that without "blocking GUI"...
- Fri Oct 31, 2008 11:29 am
- Forum: C++ Development
- Topic: wxSocket: wxYield called recursively
- Replies: 5
- Views: 2073
- Thu Oct 30, 2008 9:53 am
- Forum: C++ Development
- Topic: wxSocket: wxYield called recursively
- Replies: 5
- Views: 2073
wxSocket: wxYield called recursively
Hi! I have a problem with the use of wxTCPServer and wxTCPConnection classes. At execution of the program, if 2 clients start each an event (for example the event OnDisonnect) at the same time, I have this error on server side: assert "wxAsserFailure" failed: wxYield called recursively In accordance...