title: Load sprite from a base64 string which came from a websocket
body: <p>I am trying to turn a base64 String into an Sprite in Unity 3D, but my sprite in scene remains blank.</p>
  
  <pre><code>public var cardPicture : Image;
  
  function ReceiveData(jsonReply : JSONObject) {
      var pictureBytes : byte[] = System.Convert.FromBase64String(jsonReply.GetString("picture"));
      var cardPictureTexture = new Texture2D( 720, 720);
      Debug.Log(cardPictureTexture.LoadImage(pictureBytes));
      var sprite : Sprite = new Sprite ();
      sprite = Sprite.Create (cardPictureTexture, new Rect (0,0,720,720), new Vector2 (0.5f, 0.5f));
      cardPicture.overrideSprite = sprite;
  }
  </code></pre>
  
  <p>This prints out true, but I am not sure if it is loading the image appropriately from the bytes or if something else is going wrong. I am not sure what to check in order to determine what is going wrong either. Assigning some picture to the cardPicture in scene displays correctly.</p>
  
  <p>I logged the jsonReply.picture and used an online base64 to image converter and it displayed the image correctly.</p>