I am trying to publish 360 ° photos on behalf of my application users, but I cannot figure out how to make it work.
I downloaded the Facebook Javascript Graph API, registered the user with the publish_actions scope, and used the following code to publish the image using an equiang projection:
FB.api( "/me/photos", "POST", { "url": "MY_PUBLIC_URL", "allow_spherical_photo": true, "spherical_metadata": { "ProjectionType": "equirectangular", "CroppedAreaImageWidthPixels": 240, "CroppedAreaImageHeightPixels": 240, "FullPanoWidthPixels": 1962, "FullPanoHeightPixels": 981, "CroppedAreaLeftPixels": 981, "CroppedAreaTopPixels": 490 } }, function (response) { console.log(response);
Correctly placed on the current user timeline, but displayed as a "normal" image, not a 360 ° panorama.
Does anyone implement a 360 ° pan panorama function that works?
My photograph must have the correct ratio (2: 1) and is the correct 360 ° photograph.
Thank you in advance for your help.
source share