=== 3D Scene Viewer ===
Contributors: wprj
Tags: 3D, 3D model, 3D scene, threejs, woocommerce
Requires at least: 6.6
Tested up to: 6.8.2
Requires PHP: 7.4
Stable tag: 1.1.1
License: GPLv3
License URI: https://www.gnu.org/licenses/gpl-3.0.en.html

Display a 3D model or an entire scene made of multiple 3D models onto your site.

== Description ==

3D scene viewer allows you to create a 3D scene from 3D model files. You can replace a product image with an interactive 3D scene on the product page, or just display a 3D model in a post or page. 3D scene viewer gives you total control on allowed camera movements and endless lighting conditions possibilities.

[View plugin demo](https://lalabe.io/3d-wp/).

= Supported file types =

* `glTF` v2: `.gltf`/`.glb`.
* `FBX` ASCII version 7.0 and newer, or binary version 6400 and newer.
* `STL`.
* `OBJ` with support for material file (`.mtl`).

= Scene customization =

You can add as many models as you want into a single scene and each model can be scaled and positioned individually into the scene to fit your goals.

Animated models are supported (`.glb`, `.gltf` and`.fbx`).

= Infinite light possibilities =

You can add as many light sources to simulate any desired lighting condition for your scene.

= Camera =

Camera position and movement are configurable. You can restrict the viewer from moving the camera beyond certain angles, restrict the zooming capability, place the camera wherever you want an point it at any point of the scene.

== Installation ==

= Uploading in WordPress Dashboard =

1. Navigate to the 'Add New' in the plugins dashboard
2. Navigate to the 'Upload' area
3. Select `3d-scene-viewer.zip` from your computer
4. Click 'Install Now'
5. Activate 3D Scene Viewer in the Plugin dashboard

= Using FTP =

1. Download `3d-scene-viewer.zip`
2. Extract the `3d-scene-viewer` directory to your computer
3. Upload the `3d-scene-viewer` directory to the `/wp-content/plugins/` directory
4. Activate 3D Scene Viewer in the Plugin dashboard

== Frequently Asked Questions ==

= What data will be imported from a file =

All data supported by the file format (glTF or FBX) specification will be imported, except for cameras. There will be only one camera on the scene, and it's the one created by the plugin.

Multiple animated objects can be imported all at once in one single file, but this might lead to problems when there are animations with different lengths.

= I imported a FBX file but I don't see it on the preview and there is no error message =

Most of the FBX files available on the web (or at least a lot of them) need to be scaled down to a factor of 0.01 to fit the scale of three.js. After adding your FBX model to the scene, apply a scale of 0.01 on all the axes.

== Screenshots ==

1. Dashboard menu
2. Backend preview
3. Visual helper on the preview
4. Product image replacement

== Changelog ==

= 1.1.1 =

- Updated Three.js version to r180

= 1.1 =

- Add support for OBJ/MTL files
- Add support for STL files
- Add model size information in the backend
- Fix some bugs with 3d model shadow settings
- Fix spotlights custom target position not working
- Fix directional light custom shadow camera not working
- Add more visual indication about the scene axes on the backend preview
- Updated Three.js version to r174
- Updated .pot template

= 1.0.2 =

- Add a clearer notification when copying into clipboard
- Improve code readability

= 1.0.1 =

- Added WooCommerce image/gallery replacement.
- Fix a bug making FBX models never cast nor receive shadows on the frontend

= 1.0 =

Initial release
