From 4d042e5b7d31cc2ad5b4191f3a2d654228c4bf07 Mon Sep 17 00:00:00 2001 From: Johanna Vanhatapio Date: Thu, 7 Dec 2023 16:56:06 +0200 Subject: [PATCH] Doc: Update info on baking lights Fixes: QDS-11174 Change-Id: I8f92c3cca0faaa3f4b1db11caa8825677c80121e Reviewed-by: Miikka Heikkinen Reviewed-by: Mats Honkamaa Reviewed-by: Qt CI Patch Build Bot --- .../images/icons/bakelights.png | Bin 0 -> 502 bytes .../qtdesignstudio-3d-editor.qdoc | 7 ++ .../qtdesignstudio-3d-lights.qdoc | 62 ++++++++++-------- 3 files changed, 43 insertions(+), 26 deletions(-) create mode 100644 doc/qtdesignstudio/images/icons/bakelights.png diff --git a/doc/qtdesignstudio/images/icons/bakelights.png b/doc/qtdesignstudio/images/icons/bakelights.png new file mode 100644 index 0000000000000000000000000000000000000000..21ca61375669785d6c1b46540e92c85dc02633f4 GIT binary patch literal 502 zcmeAS@N?(olHy`uVBq!ia0y~yU=RRd4mJh`2Kmqb6B!s7I14-?iy0XBj({-ZRBb+K z1_lQ95>H=O_UAl2oRR_uuLfRVU|^i;>Eak-(OY|YZ+1wa0PBbQdeS0-TLicjy_)1* zn^Y1!q`5hxqB_FD#JVClnj+?&3KD4Qt#{B`9a840+|kPDxZ%PK4Gl9VgI3QoQEzfS z-Ed%gHurbhxjE*=?{}|NkuN+luhz?m+cQq&o_0+y_tEUc#Z#YHPy5Il?J1`cc_ed7 z_nzjhD#o7A3|fL`yb1Y~J?Zz?si|`gNZCy}A#qME($6Sx&vA+O3%Zjhue3FjZ%!87>V*f?@9-K}n9=Xp6XUpt z8B5IyWM_LW)4rBlc0ok);_WlhJHqOOtv%hOuf#U4yEoC~ZRNut%QL(MxBd$5`e8mn z=5X1h+gGo4?X|wJ{oFg}_uF%C#q+4nT>o7$hp*t;#aHpmzW-Qh{yS^Za?g7YQzq7{ z&h+}ka#&RQn9J@ddXKo$3U}U`cZf+WYi&{Z>Ej#!$$vQAJL6`Vpeh3c1B0ilpUXO@ GgeCw0KiJOz literal 0 HcmV?d00001 diff --git a/doc/qtdesignstudio/src/qtquick3d-editor/qtdesignstudio-3d-editor.qdoc b/doc/qtdesignstudio/src/qtquick3d-editor/qtdesignstudio-3d-editor.qdoc index 4c45f87ad8b..7111d2db90e 100644 --- a/doc/qtdesignstudio/src/qtquick3d-editor/qtdesignstudio-3d-editor.qdoc +++ b/doc/qtdesignstudio/src/qtquick3d-editor/qtdesignstudio-3d-editor.qdoc @@ -153,6 +153,13 @@ For more information about the available scene light types and their properties, see \l{Lights}. + \section1 Baking Lights + + Bake lights to light static elements in your scene. To bake lights, + select \inlineimage icons/bakelights.png to open the + \uicontrol {Lights Baking Setup} dialog. For more information, see + \l {Baking Lightmaps}. + \section1 Selecting Components To move, rotate, or scale components in the scene, you need to select them diff --git a/doc/qtdesignstudio/src/qtquick3d-editor/qtdesignstudio-3d-lights.qdoc b/doc/qtdesignstudio/src/qtquick3d-editor/qtdesignstudio-3d-lights.qdoc index ec1de943f2b..af994d58774 100644 --- a/doc/qtdesignstudio/src/qtquick3d-editor/qtdesignstudio-3d-lights.qdoc +++ b/doc/qtdesignstudio/src/qtquick3d-editor/qtdesignstudio-3d-lights.qdoc @@ -213,10 +213,11 @@ \note Lightmaps baking is released as technical preview in \QDS 4.1. - Baked lightmaps allow pre-generating the direct lighting from lights such as DirectionalLight, - PointLight, and SpotLight, including the shadows cast by the lights. At run time, instead of - performing the appropriate calculations in the fragment shader, and, in case of shadows, - generating the potentially costly shadow maps in real time, the pre-generated light map is + Baked lightmaps allow pre-generating the direct lighting from lights, + such as DirectionalLight, PointLight, and SpotLight, including the shadows + cast by the lights. At run time, instead of performing the appropriate + calculations in the fragment shader, and, in case of shadows, generating + the potentially costly shadow maps in real time, the pre-generated light map is sampled instead. \section2 Baking Lightmaps @@ -224,47 +225,56 @@ To bake lightmaps for models in your 3D scene: \list 1 - \li Right-click anywhere in the \uicontrol 3D view and select \uicontrol {Bake Lights}. - \li In the \uicontrol {Lights Baking Setup} dialog: + \li Select \inlineimage icons/bakelights.png in the \uicontrol 3D view + toolbar or right-click anywhere in the \uicontrol 3D view and select + \uicontrol {Bake Lights} to open the \uicontrol {Lights Baking Setup} + dialog to define settings for baking lights. + \li Set \uicontrol {Bake Mode} for each light source: \list - \li For every light you want to use to bake lightmaps, set \uicontrol {Bake Mode} to BakeModeAll. - \li For every 3D model you want to bake lightmaps, select \uicontrol {In Use} and - \uicontrol {Enabled}, and set the desired \uicontrol {Resolution}. + \li To bake both direct (diffuse and shadow) and indirect lighting, + select \uicontrol {Bake All}. + \li To bake only indirect lighting, select \uicontrol {Bake Indirect}. + \li To not include a light source in the baking of lights, select + \uicontrol {Baking Disabled}. \endlist - \li Optional. If you have components with unexposed models or lights (for example, imported - 3D models created in other software), select \uicontrol {Expose models and lights} to add the - models and light of that component to the \uicontrol Models and \uicontrol Lights sections of - the dialog. + \li For every 3D model you want to bake into a lightmap, select + \uicontrol {In Use} and \uicontrol {Enabled}, and set the desired + \uicontrol {Resolution}. + \li Optional. If you have components with unexposed models or lights + (for example, imported 3D models created in other software), select + \uicontrol {Expose models and lights} to add the models and light of + that component to the \uicontrol Models and \uicontrol Lights sections + of the dialog. \li Select \uicontrol Bake. \endlist \image bake-lights-dialog.png \section2 Manually Baking Lightmaps for a 3D Model - Baked lightmap components are not visible in the \uicontrol Navigator view by default. To make - them visible, select \inlineimage icons/visibilityon.png + \note Baked lightmap components are not visible in the \uicontrol Navigator view by + default. To make them visible, select \inlineimage icons/visibilityon.png in the \uicontrol Navigator view. To bake lightmaps for a 3D model: \list 1 - \li From \uicontrol Components, drag a \uicontrol {Baked Lightmap} component to - the 3D model in the \uicontrol Navigator view. + \li From \uicontrol Components, drag a \uicontrol {Baked Lightmap} component + to the 3D model in the \uicontrol Navigator view. \image baked-lightmaps-navigator.png - \li In the \uicontrol Navigator view, select \e bakedLightmap and in the \uicontrol Properties - view: + \li In the \uicontrol Navigator view, select \e bakedLightmap, and in the + \uicontrol Properties view: \list \li Select \uicontrol Enabled. - \li In \uicontrol Key, set the filename base for the generated light maps. This must be - a unique name. - \li In \uicontrol {Load Prefix}, set the relative path to the folder where the generated - light map files are saved. + \li In \uicontrol Key, set the filename base for the generated light maps. + This must be a unique name. + \li In \uicontrol {Load Prefix}, set the relative path to the folder where + the generated light map files are saved. \endlist \li In the \uicontrol Navigator view, select the 3D model and in the \uicontrol Properties - view, select \uicontrol {Used in Baked Lighting}. + view, select \uicontrol {Used in Baked Lighting}. \li Optional. Adjust \uicontrol Resolution to set the light map resoution. This effects how - accurate and time-consuming the lightmap baking is. + accurate and time-consuming the lightmap baking is. \li In the \uicontrol Navigator view, select the light component that you want to bake - lightmaps for, and in the \uicontrol Properties view, set \uicontrol {Bake Mode} to BakeModeAll. + lightmaps for, and in the \uicontrol Properties view, set \uicontrol {Bake Mode} to BakeModeAll. \li Right-click anywhere in the \uicontrol 3D view and select \uicontrol {Bake Lights}. \li Select \uicontrol {Setup baking manually}, and then select \uicontrol Bake. \endlist