Last active
April 22, 2022 13:24
-
-
Save milesw/f386067fab2f50798b5c58d84226b6aa to your computer and use it in GitHub Desktop.
Specify environment image on Shopify 3D model
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% comment %} Before {% endcomment %} | |
{{ media | model_viewer_tag: image_size: '1024x', reveal: 'interaction', toggleable: true }} | |
{% comment %} After {% endcomment %} | |
{%- assign environment_image = settings.models_environment_image | default: 'neutral' -%} | |
{{ media | model_viewer_tag: image_size: '1024x', reveal: 'interaction', toggleable: true, environment-image: environment_image }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "3D Models", | |
"settings": [ | |
{ | |
"label": "Environment image URL", | |
"type": "url", | |
"id": "models_environment_image", | |
"info": "Provide an environment image to set the lighting in the 3D viewer. Image should be in HDR format. If no image URL is provided, the \"neutral\" setting will be used." | |
} | |
] | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment