0

Unity 2019.1.9 and .12

I'm posting a WWWForm with several AddField text fields that get sent properly and also an AddBinaryField containing the bytes for an EncodeToPng image. The image arrives on the server always with missing bytes. This issue seems to only occur on iOS device and works fine in editor.

The image file bytes are saved to the iOS device photo album properly. The file size comparison for this "ground truth" image vs the one saved on server varies depending on which UnityWebRequest properties are marked explicitly as false.

  • With both .chunkedTransfer and .useHttpContinue set to false, the file uploaded is only 838 bytes smaller.

  • With no options like that set, 814 bytes smaller.

  • With .useHttpContinue set to false, 778 bytes smaller.

ina
  • 19,167
  • 39
  • 122
  • 201
  • Not sure if I should add AFNetworking https://stackoverflow.com/questions/14015167/uploading-image-to-web-service-leaves-the-image-corrupt – ina Jul 30 '19 at 13:02
  • current workaround is to just use BestHTTP assset – ina Jul 31 '19 at 00:47

0 Answers0