wangyu- / tinyfecVPN

A VPN Designed for Lossy Links, with Build-in Forward Error Correction(FEC) Support. Improves your Network Quality on a High-latency Lossy Link.
MIT License
2.28k stars 457 forks source link

Raptor Codes / RaptorQ support? #62

Open syadnom opened 5 years ago

syadnom commented 5 years ago

Are there any plans to switch from reed-solomon to raptor codes such as the raptorq library?

I'm really impressed with tinyfec, but in my testing when increasing the fec packets really shows the weakness in reed-solomon. Much more bandwidth and much more CPU usage. RaptorQ would be a big improvement here.

wangyu- commented 5 years ago

Hi, glad it works for you.

Are there any plans to switch from reed-solomon to raptor codes such as the raptorq library?

No plan. I had investigated several erasure codes(RS code/Raptor code/Tornado code/LT codes...) before writting UDPspeeder/tinyfecVPN, and found RS code maybe the best choice when CPU usage is not a bottleneck.

but in my testing when increasing the fec packets really shows the weakness in reed-solomon. Much more bandwidth and much more CPU usage. RaptorQ would be a big improvement here.

Raptor only improves CPU usage(the improve would be significant).

Raptor(fountain code) provides "a potentially limitless sequence of encoding symbols", it does improves bandwidth for bulk data transimission when lantency is not important, but its not the case here since UDPspeeder/tinyfecVPN aims at real-time general-purpose networking.

Actually since RaptorQ is not an optimal code(possibility of success is involved), it may cost a bit more bandwidth to get the same effect as RS code.

Correct me if I was wrong.