CodePudding user response:
In a window in the process is not recommended to do the UDP data reception, suggest more of a Shared memory, using a console to write data receiving applications, with a change to the next, and then the window procedure in order to read the Shared memory, also do a ready sign on each of the Shared memory, when the window procedure after reading the flag set to false, the console the receiving application write Shared memory is full, the flag set to true, and multiple threads access to a Shared memory overhead is very small,CodePudding user response:
Reply with sending and receiving process, each sending a package out after waiting for the other party under the receive reply whether success to send a packet of data, so as to preserve stabilityEvery packet data bring a frame number, every time after receiving the judgment on whether a packet of data packet of data
CodePudding user response:
Your traffic is not big ah, not more than 2 MB/s, you get a queue, a thread to the network data, a thread processing data, maintain good this queue, should be no problem