SpecularGlossyMaterialSection.qml 45 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345
  1. // Copyright (C) 2022 The Qt Company Ltd.
  2. // SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only
  3. import QtQuick 2.15
  4. import QtQuick.Layouts 1.15
  5. import HelperWidgets 2.0
  6. import StudioTheme 1.0 as StudioTheme
  7. Column {
  8. width: parent.width
  9. Section {
  10. caption: qsTr("Specular Glossy Material")
  11. width: parent.width
  12. SectionLayout {
  13. id: baseSectionLayout
  14. property bool isAlphaMaskMode: alphaModeComboBox.currentIndex === 1
  15. PropertyLabel {
  16. text: qsTr("Alpha Mode")
  17. tooltip: qsTr("Sets the mode for how the alpha channel of material color is used.")
  18. }
  19. SecondColumnLayout {
  20. ComboBox {
  21. id: alphaModeComboBox
  22. scope: "SpecularGlossyMaterial"
  23. model: ["Default", "Mask", "Blend", "Opaque"]
  24. backendValue: backendValues.alphaMode
  25. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  26. + StudioTheme.Values.actionIndicatorWidth
  27. }
  28. ExpandingSpacer {}
  29. }
  30. PropertyLabel {
  31. visible: baseSectionLayout.isAlphaMaskMode
  32. text: qsTr("Alpha Cutoff")
  33. tooltip: qsTr("Sets the cutoff value when using the Mask alphaMode.")
  34. }
  35. SecondColumnLayout {
  36. visible: baseSectionLayout.isAlphaMaskMode
  37. SpinBox {
  38. minimumValue: 0
  39. maximumValue: 1
  40. decimals: 2
  41. stepSize: 0.1
  42. sliderIndicatorVisible: true
  43. backendValue: backendValues.alphaCutoff
  44. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  45. + StudioTheme.Values.actionIndicatorWidth
  46. }
  47. ExpandingSpacer {}
  48. }
  49. PropertyLabel {
  50. text: qsTr("Blend Mode")
  51. tooltip: qsTr("Sets how the colors of the model rendered blend with those behind it.")
  52. }
  53. SecondColumnLayout {
  54. ComboBox {
  55. scope: "SpecularGlossyMaterial"
  56. model: ["SourceOver", "Screen", "Multiply"]
  57. backendValue: backendValues.blendMode
  58. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  59. + StudioTheme.Values.actionIndicatorWidth
  60. }
  61. ExpandingSpacer {}
  62. }
  63. PropertyLabel {
  64. text: qsTr("Lighting")
  65. tooltip: qsTr("Sets which lighting method is used when generating this material.")
  66. }
  67. SecondColumnLayout {
  68. ComboBox {
  69. scope: "SpecularGlossyMaterial"
  70. model: ["NoLighting", "FragmentLighting"]
  71. backendValue: backendValues.lighting
  72. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  73. + StudioTheme.Values.actionIndicatorWidth
  74. }
  75. ExpandingSpacer {}
  76. }
  77. }
  78. }
  79. Section {
  80. caption: qsTr("Albedo")
  81. width: parent.width
  82. SectionLayout {
  83. PropertyLabel {
  84. text: qsTr("Color")
  85. tooltip: qsTr("Sets the albedo color of the material.")
  86. }
  87. ColorEditor {
  88. backendValue: backendValues.albedoColor
  89. supportGradient: false
  90. }
  91. PropertyLabel {
  92. text: qsTr("Map")
  93. tooltip: qsTr("Sets a texture used to set the albedo color of the material.")
  94. }
  95. SecondColumnLayout {
  96. ItemFilterComboBox {
  97. typeFilter: "QtQuick3D.Texture"
  98. backendValue: backendValues.albedoMap
  99. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  100. + StudioTheme.Values.actionIndicatorWidth
  101. }
  102. ExpandingSpacer {}
  103. }
  104. PropertyLabel {
  105. text: qsTr("Use Single Channel")
  106. tooltip: qsTr("Use only a single channel from albedoMap.")
  107. }
  108. SecondColumnLayout {
  109. CheckBox {
  110. id: albedoSingleChannelCheckBox
  111. text: checked ? qsTr("Enabled") : qsTr("Disabled")
  112. backendValue: backendValues.albedoSingleChannelEnabled
  113. implicitWidth: StudioTheme.Values.twoControlColumnWidth
  114. + StudioTheme.Values.actionIndicatorWidth
  115. }
  116. ExpandingSpacer {}
  117. }
  118. PropertyLabel {
  119. text: qsTr("Channel")
  120. tooltip: qsTr("Sets the texture channel used to read the albedo value from albedoMap.")
  121. }
  122. SecondColumnLayout {
  123. ComboBox {
  124. enabled: albedoSingleChannelCheckBox.checked
  125. scope: "Material"
  126. model: ["R", "G", "B", "A"]
  127. backendValue: backendValues.albedoChannel
  128. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  129. + StudioTheme.Values.actionIndicatorWidth
  130. }
  131. ExpandingSpacer {}
  132. }
  133. }
  134. }
  135. Section {
  136. caption: qsTr("Specular")
  137. width: parent.width
  138. SectionLayout {
  139. PropertyLabel {
  140. text: qsTr("Color")
  141. tooltip: qsTr("Sets the specular color of the material.")
  142. }
  143. ColorEditor {
  144. backendValue: backendValues.specularColor
  145. supportGradient: false
  146. }
  147. PropertyLabel {
  148. text: qsTr("Map")
  149. tooltip: qsTr("Sets a texture used to set the specular color of the material.")
  150. }
  151. SecondColumnLayout {
  152. ItemFilterComboBox {
  153. typeFilter: "QtQuick3D.Texture"
  154. backendValue: backendValues.specularMap
  155. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  156. + StudioTheme.Values.actionIndicatorWidth
  157. }
  158. ExpandingSpacer {}
  159. }
  160. PropertyLabel {
  161. text: qsTr("Use Single Channel")
  162. tooltip: qsTr("Use only a single channel from specularMap.")
  163. }
  164. SecondColumnLayout {
  165. CheckBox {
  166. id: specularSingleChannelCheckBox
  167. text: checked ? qsTr("Enabled") : qsTr("Disabled")
  168. backendValue: backendValues.specularSingleChannelEnabled
  169. implicitWidth: StudioTheme.Values.twoControlColumnWidth
  170. + StudioTheme.Values.actionIndicatorWidth
  171. }
  172. ExpandingSpacer {}
  173. }
  174. PropertyLabel {
  175. text: qsTr("Channel")
  176. tooltip: qsTr("Sets the texture channel used to read the specular value from specularMap.")
  177. }
  178. SecondColumnLayout {
  179. ComboBox {
  180. enabled: specularSingleChannelCheckBox.checked
  181. scope: "Material"
  182. model: ["R", "G", "B", "A"]
  183. backendValue: backendValues.specularChannel
  184. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  185. + StudioTheme.Values.actionIndicatorWidth
  186. }
  187. ExpandingSpacer {}
  188. }
  189. }
  190. }
  191. Section {
  192. caption: qsTr("Glossiness")
  193. width: parent.width
  194. SectionLayout {
  195. PropertyLabel {
  196. text: qsTr("Amount")
  197. tooltip: qsTr("Sets the size of the specular highlight generated from lights, and the clarity of reflections in general.")
  198. }
  199. SecondColumnLayout {
  200. SpinBox {
  201. minimumValue: 0
  202. maximumValue: 1
  203. decimals: 2
  204. stepSize: 0.1
  205. sliderIndicatorVisible: true
  206. backendValue: backendValues.glossiness
  207. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  208. + StudioTheme.Values.actionIndicatorWidth
  209. }
  210. ExpandingSpacer {}
  211. }
  212. PropertyLabel {
  213. text: qsTr("Map")
  214. tooltip: qsTr("Sets a texture to control the glossiness of the material.")
  215. }
  216. SecondColumnLayout {
  217. ItemFilterComboBox {
  218. typeFilter: "QtQuick3D.Texture"
  219. backendValue: backendValues.glossinessMap
  220. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  221. + StudioTheme.Values.actionIndicatorWidth
  222. }
  223. ExpandingSpacer {}
  224. }
  225. PropertyLabel {
  226. text: qsTr("Channel")
  227. tooltip: qsTr("Sets the texture channel used to read the glossiness value from glossinessMap.")
  228. }
  229. SecondColumnLayout {
  230. ComboBox {
  231. scope: "Material"
  232. model: ["R", "G", "B", "A"]
  233. backendValue: backendValues.glossinessChannel
  234. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  235. + StudioTheme.Values.actionIndicatorWidth
  236. }
  237. ExpandingSpacer {}
  238. }
  239. }
  240. }
  241. Section {
  242. caption: qsTr("Normal")
  243. width: parent.width
  244. SectionLayout {
  245. PropertyLabel {
  246. text: qsTr("Map")
  247. tooltip: qsTr("Sets an RGB image used to simulate fine geometry displacement across the surface of the material.")
  248. }
  249. SecondColumnLayout {
  250. ItemFilterComboBox {
  251. typeFilter: "QtQuick3D.Texture"
  252. backendValue: backendValues.normalMap
  253. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  254. + StudioTheme.Values.actionIndicatorWidth
  255. }
  256. ExpandingSpacer {}
  257. }
  258. PropertyLabel {
  259. text: qsTr("Strength")
  260. tooltip: qsTr("Sets the amount of simulated displacement for the normalMap.")
  261. }
  262. SecondColumnLayout {
  263. SpinBox {
  264. minimumValue: 0
  265. maximumValue: 1
  266. decimals: 2
  267. stepSize: 0.1
  268. sliderIndicatorVisible: true
  269. backendValue: backendValues.normalStrength
  270. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  271. + StudioTheme.Values.actionIndicatorWidth
  272. }
  273. ExpandingSpacer {}
  274. }
  275. }
  276. }
  277. Section {
  278. caption: qsTr("Occlusion")
  279. width: parent.width
  280. SectionLayout {
  281. PropertyLabel {
  282. text: qsTr("Amount")
  283. tooltip: qsTr("Sets the factor used to modify the values from the occlusionMap texture.")
  284. }
  285. SecondColumnLayout {
  286. SpinBox {
  287. minimumValue: 0
  288. maximumValue: 1
  289. decimals: 2
  290. stepSize: 0.1
  291. sliderIndicatorVisible: true
  292. backendValue: backendValues.occlusionAmount
  293. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  294. + StudioTheme.Values.actionIndicatorWidth
  295. }
  296. ExpandingSpacer {}
  297. }
  298. PropertyLabel {
  299. text: qsTr("Map")
  300. tooltip: qsTr("Sets a texture used to determine how much indirect light the different areas of the material should receive.")
  301. }
  302. SecondColumnLayout {
  303. ItemFilterComboBox {
  304. typeFilter: "QtQuick3D.Texture"
  305. backendValue: backendValues.occlusionMap
  306. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  307. + StudioTheme.Values.actionIndicatorWidth
  308. }
  309. ExpandingSpacer {}
  310. }
  311. PropertyLabel {
  312. text: qsTr("Channel")
  313. tooltip: qsTr("Sets the texture channel used to read the occlusion value from occlusionMap.")
  314. }
  315. SecondColumnLayout {
  316. ComboBox {
  317. scope: "Material"
  318. model: ["R", "G", "B", "A"]
  319. backendValue: backendValues.occlusionChannel
  320. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  321. + StudioTheme.Values.actionIndicatorWidth
  322. }
  323. ExpandingSpacer {}
  324. }
  325. }
  326. }
  327. Section {
  328. caption: qsTr("Opacity")
  329. width: parent.width
  330. SectionLayout {
  331. PropertyLabel {
  332. text: qsTr("Amount")
  333. tooltip: qsTr("Sets the opacity of just this material, separate from the model.")
  334. }
  335. SecondColumnLayout {
  336. SpinBox {
  337. minimumValue: 0
  338. maximumValue: 1
  339. decimals: 2
  340. stepSize: 0.1
  341. sliderIndicatorVisible: true
  342. backendValue: backendValues.opacity
  343. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  344. + StudioTheme.Values.actionIndicatorWidth
  345. }
  346. ExpandingSpacer {}
  347. }
  348. PropertyLabel {
  349. text: qsTr("Map")
  350. tooltip: qsTr("Sets a texture used to control the opacity differently for different parts of the material.")
  351. }
  352. SecondColumnLayout {
  353. ItemFilterComboBox {
  354. typeFilter: "QtQuick3D.Texture"
  355. backendValue: backendValues.opacityMap
  356. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  357. + StudioTheme.Values.actionIndicatorWidth
  358. }
  359. ExpandingSpacer {}
  360. }
  361. PropertyLabel {
  362. text: qsTr("Channel")
  363. tooltip: qsTr("Sets the texture channel used to read the opacity value from opacityMap.")
  364. }
  365. SecondColumnLayout {
  366. ComboBox {
  367. scope: "Material"
  368. model: ["R", "G", "B", "A"]
  369. backendValue: backendValues.opacityChannel
  370. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  371. + StudioTheme.Values.actionIndicatorWidth
  372. }
  373. ExpandingSpacer {}
  374. }
  375. PropertyLabel {
  376. text: qsTr("Invert Channel")
  377. tooltip: qsTr("Invert the values of the opacity map.")
  378. }
  379. SecondColumnLayout {
  380. CheckBox {
  381. text: checked ? qsTr("Enabled") : qsTr("Disabled")
  382. backendValue: backendValues.invertOpacityMapValue
  383. implicitWidth: StudioTheme.Values.twoControlColumnWidth
  384. + StudioTheme.Values.actionIndicatorWidth
  385. }
  386. ExpandingSpacer {}
  387. }
  388. }
  389. }
  390. Section {
  391. caption: qsTr("Emissive Color")
  392. width: parent.width
  393. SectionLayout {
  394. PropertyLabel {
  395. text: qsTr("Map")
  396. tooltip: qsTr("Sets a texture to be used to set the emissive factor for different parts of the material.")
  397. }
  398. SecondColumnLayout {
  399. ItemFilterComboBox {
  400. typeFilter: "QtQuick3D.Texture"
  401. backendValue: backendValues.emissiveMap
  402. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  403. + StudioTheme.Values.actionIndicatorWidth
  404. }
  405. ExpandingSpacer {}
  406. }
  407. PropertyLabel {
  408. text: qsTr("Factor")
  409. tooltip: qsTr("Sets the color of self-illumination for this material.")
  410. }
  411. SecondColumnLayout {
  412. SpinBox {
  413. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  414. + StudioTheme.Values.actionIndicatorWidth
  415. minimumValue: -9999999
  416. maximumValue: 9999999
  417. decimals: 2
  418. stepSize: 0.01
  419. backendValue: backendValues.emissiveFactor_x
  420. }
  421. Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
  422. ControlLabel {
  423. text: "R"
  424. color: StudioTheme.Values.theme3DAxisXColor
  425. }
  426. ExpandingSpacer {}
  427. }
  428. PropertyLabel {}
  429. SecondColumnLayout {
  430. SpinBox {
  431. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  432. + StudioTheme.Values.actionIndicatorWidth
  433. minimumValue: -9999999
  434. maximumValue: 9999999
  435. decimals: 2
  436. stepSize: 0.01
  437. backendValue: backendValues.emissiveFactor_y
  438. }
  439. Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
  440. ControlLabel {
  441. text: "G"
  442. color: StudioTheme.Values.theme3DAxisYColor
  443. }
  444. ExpandingSpacer {}
  445. }
  446. PropertyLabel {}
  447. SecondColumnLayout {
  448. SpinBox {
  449. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  450. + StudioTheme.Values.actionIndicatorWidth
  451. minimumValue: -9999999
  452. maximumValue: 9999999
  453. decimals: 2
  454. stepSize: 0.01
  455. backendValue: backendValues.emissiveFactor_z
  456. }
  457. Spacer { implicitWidth: StudioTheme.Values.controlLabelGap }
  458. ControlLabel {
  459. text: "B"
  460. color: StudioTheme.Values.theme3DAxisZColor
  461. }
  462. ExpandingSpacer {}
  463. }
  464. PropertyLabel {
  465. text: qsTr("Use Single Channel")
  466. tooltip: qsTr("Use only a single channel from emissiveMap.")
  467. }
  468. SecondColumnLayout {
  469. CheckBox {
  470. id: emissiveSingleChannelCheckBox
  471. text: checked ? qsTr("Enabled") : qsTr("Disabled")
  472. backendValue: backendValues.emissiveSingleChannelEnabled
  473. implicitWidth: StudioTheme.Values.twoControlColumnWidth
  474. + StudioTheme.Values.actionIndicatorWidth
  475. }
  476. ExpandingSpacer {}
  477. }
  478. PropertyLabel {
  479. text: qsTr("Channel")
  480. tooltip: qsTr("Sets the texture channel used to read the emissive value from emissiveMap.")
  481. }
  482. SecondColumnLayout {
  483. ComboBox {
  484. enabled: emissiveSingleChannelCheckBox.checked
  485. scope: "Material"
  486. model: ["R", "G", "B", "A"]
  487. backendValue: backendValues.emissiveChannel
  488. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  489. + StudioTheme.Values.actionIndicatorWidth
  490. }
  491. ExpandingSpacer {}
  492. }
  493. }
  494. }
  495. Section {
  496. caption: qsTr("Height")
  497. width: parent.width
  498. SectionLayout {
  499. PropertyLabel {
  500. text: qsTr("Amount")
  501. tooltip: qsTr("Sets the factor used to modify the values from the heightMap texture.")
  502. }
  503. SecondColumnLayout {
  504. SpinBox {
  505. minimumValue: 0
  506. maximumValue: 1
  507. decimals: 2
  508. stepSize: 0.1
  509. sliderIndicatorVisible: true
  510. backendValue: backendValues.heightAmount
  511. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  512. + StudioTheme.Values.actionIndicatorWidth
  513. }
  514. ExpandingSpacer {}
  515. }
  516. PropertyLabel {
  517. text: qsTr("Map")
  518. tooltip: qsTr("Sets a texture used to determine the height the texture will be displaced when rendered through the use of Parallax Mapping.")
  519. }
  520. SecondColumnLayout {
  521. ItemFilterComboBox {
  522. typeFilter: "QtQuick3D.Texture"
  523. backendValue: backendValues.heightMap
  524. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  525. + StudioTheme.Values.actionIndicatorWidth
  526. }
  527. ExpandingSpacer {}
  528. }
  529. PropertyLabel {
  530. text: qsTr("Channel")
  531. tooltip: qsTr("Sets the texture channel used to read the height value from heightMap.")
  532. }
  533. SecondColumnLayout {
  534. ComboBox {
  535. scope: "Material"
  536. model: ["R", "G", "B", "A"]
  537. backendValue: backendValues.heightChannel
  538. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  539. + StudioTheme.Values.actionIndicatorWidth
  540. }
  541. ExpandingSpacer {}
  542. }
  543. PropertyLabel {
  544. text: qsTr("Min Map Samples")
  545. tooltip: qsTr("Sets the minimum number of samples used for performing Parallax Occlusion Mapping using the heightMap.")
  546. }
  547. SecondColumnLayout {
  548. SpinBox {
  549. minimumValue: 1
  550. maximumValue: 128
  551. decimals: 0
  552. sliderIndicatorVisible: true
  553. backendValue: backendValues.minHeightMapSamples
  554. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  555. + StudioTheme.Values.actionIndicatorWidth
  556. }
  557. ExpandingSpacer {}
  558. }
  559. PropertyLabel {
  560. text: qsTr("Max Map Samples")
  561. tooltip: qsTr("Sets the maximum number of samples used for performing Parallax Occlusion Mapping using the heightMap.")
  562. }
  563. SecondColumnLayout {
  564. SpinBox {
  565. minimumValue: 1
  566. maximumValue: 256
  567. decimals: 0
  568. sliderIndicatorVisible: true
  569. backendValue: backendValues.maxHeightMapSamples
  570. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  571. + StudioTheme.Values.actionIndicatorWidth
  572. }
  573. ExpandingSpacer {}
  574. }
  575. }
  576. }
  577. Section {
  578. caption: qsTr("Clearcoat")
  579. width: parent.width
  580. SectionLayout {
  581. PropertyLabel {
  582. text: qsTr("Amount")
  583. tooltip: qsTr("Sets the intensity of the clearcoat layer.")
  584. }
  585. SecondColumnLayout {
  586. SpinBox {
  587. minimumValue: 0
  588. maximumValue: 1
  589. decimals: 2
  590. stepSize: 0.1
  591. sliderIndicatorVisible: true
  592. backendValue: backendValues.clearcoatAmount
  593. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  594. + StudioTheme.Values.actionIndicatorWidth
  595. }
  596. ExpandingSpacer {}
  597. }
  598. PropertyLabel {
  599. text: qsTr("Map")
  600. tooltip: qsTr("Sets a texture used to determine the intensity of the clearcoat layer.")
  601. }
  602. SecondColumnLayout {
  603. ItemFilterComboBox {
  604. typeFilter: "QtQuick3D.Texture"
  605. backendValue: backendValues.clearcoatMap
  606. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  607. + StudioTheme.Values.actionIndicatorWidth
  608. }
  609. ExpandingSpacer {}
  610. }
  611. PropertyLabel {
  612. text: qsTr("Channel")
  613. tooltip: qsTr("Sets the texture channel used to read the intensity from clearcoatMap.")
  614. }
  615. SecondColumnLayout {
  616. ComboBox {
  617. scope: "Material"
  618. model: ["R", "G", "B", "A"]
  619. backendValue: backendValues.clearcoatChannel
  620. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  621. + StudioTheme.Values.actionIndicatorWidth
  622. }
  623. ExpandingSpacer {}
  624. }
  625. PropertyLabel {
  626. text: qsTr("Roughness Amount")
  627. tooltip: qsTr("Sets the roughness of the clearcoat layer.")
  628. }
  629. SecondColumnLayout {
  630. SpinBox {
  631. minimumValue: 0
  632. maximumValue: 1
  633. decimals: 2
  634. stepSize: 0.1
  635. sliderIndicatorVisible: true
  636. backendValue: backendValues.clearcoatRoughnessAmount
  637. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  638. + StudioTheme.Values.actionIndicatorWidth
  639. }
  640. ExpandingSpacer {}
  641. }
  642. PropertyLabel {
  643. text: qsTr("Roughness Map")
  644. tooltip: qsTr("Sets a texture used to determine the roughness of the clearcoat layer.")
  645. }
  646. SecondColumnLayout {
  647. ItemFilterComboBox {
  648. typeFilter: "QtQuick3D.Texture"
  649. backendValue: backendValues.clearcoatRoughnessMap
  650. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  651. + StudioTheme.Values.actionIndicatorWidth
  652. }
  653. ExpandingSpacer {}
  654. }
  655. PropertyLabel {
  656. text: qsTr("Roughness Channel")
  657. tooltip: qsTr("Sets the texture channel used to read the roughness from clearcoatRoughnessMap.")
  658. }
  659. SecondColumnLayout {
  660. ComboBox {
  661. scope: "Material"
  662. model: ["R", "G", "B", "A"]
  663. backendValue: backendValues.clearcoatRoughnessChannel
  664. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  665. + StudioTheme.Values.actionIndicatorWidth
  666. }
  667. ExpandingSpacer {}
  668. }
  669. PropertyLabel {
  670. text: qsTr("Normal Map")
  671. tooltip: qsTr("Sets a texture used as a normalMap for the clearcoat layer.")
  672. }
  673. SecondColumnLayout {
  674. ItemFilterComboBox {
  675. typeFilter: "QtQuick3D.Texture"
  676. backendValue: backendValues.clearcoatNormalMap
  677. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  678. + StudioTheme.Values.actionIndicatorWidth
  679. }
  680. ExpandingSpacer {}
  681. }
  682. PropertyLabel {
  683. text: qsTr("Normal Strength")
  684. tooltip: qsTr("Sets the Normal Strength of the clearcoat layer.")
  685. }
  686. SecondColumnLayout {
  687. SpinBox {
  688. minimumValue: 0
  689. maximumValue: 1
  690. decimals: 2
  691. stepSize: 0.1
  692. sliderIndicatorVisible: true
  693. backendValue: backendValues.clearcoatNormalStrength
  694. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  695. + StudioTheme.Values.actionIndicatorWidth
  696. }
  697. ExpandingSpacer {}
  698. }
  699. PropertyLabel {
  700. text: qsTr("Fresnel Power")
  701. tooltip: qsTr("Sets the fresnel power.")
  702. }
  703. SecondColumnLayout {
  704. SpinBox {
  705. minimumValue: 0
  706. maximumValue: 1000
  707. stepSize: 0.1
  708. decimals: 2
  709. backendValue: backendValues.clearcoatFresnelPower
  710. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  711. + StudioTheme.Values.actionIndicatorWidth
  712. }
  713. ExpandingSpacer {}
  714. }
  715. PropertyLabel {
  716. text: qsTr("Enable scale and bias")
  717. tooltip: qsTr("Sets whether fresnel scale and bias are enabled.")
  718. }
  719. SecondColumnLayout {
  720. CheckBox {
  721. text: checked ? qsTr("Enabled") : qsTr("Disabled")
  722. backendValue: backendValues.clearcoatFresnelScaleBiasEnabled
  723. implicitWidth: StudioTheme.Values.twoControlColumnWidth
  724. + StudioTheme.Values.actionIndicatorWidth
  725. }
  726. ExpandingSpacer {}
  727. }
  728. PropertyLabel {
  729. text: qsTr("Fresnel Scale")
  730. tooltip: qsTr("Sets the fresnel scale.")
  731. }
  732. SecondColumnLayout {
  733. SpinBox {
  734. minimumValue: 0
  735. maximumValue: 5
  736. stepSize: 0.1
  737. decimals: 2
  738. backendValue: backendValues.clearcoatFresnelScale
  739. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  740. + StudioTheme.Values.actionIndicatorWidth
  741. }
  742. ExpandingSpacer {}
  743. }
  744. PropertyLabel {
  745. text: qsTr("Fresnel Bias")
  746. tooltip: qsTr("Sets the fresnel bias.")
  747. }
  748. SecondColumnLayout {
  749. SpinBox {
  750. minimumValue: -1
  751. maximumValue: 1
  752. stepSize: 0.1
  753. decimals: 2
  754. backendValue: backendValues.clearcoatFresnelBias
  755. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  756. + StudioTheme.Values.actionIndicatorWidth
  757. }
  758. ExpandingSpacer {}
  759. }
  760. }
  761. }
  762. Section {
  763. caption: qsTr("Refraction")
  764. width: parent.width
  765. SectionLayout {
  766. PropertyLabel {
  767. text: qsTr("Transmission Factor")
  768. tooltip: qsTr("Sets the base percentage of light that is transmitted through the surface.")
  769. }
  770. SecondColumnLayout {
  771. SpinBox {
  772. minimumValue: 0
  773. maximumValue: 1
  774. decimals: 2
  775. stepSize: 0.1
  776. sliderIndicatorVisible: true
  777. backendValue: backendValues.transmissionFactor
  778. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  779. + StudioTheme.Values.actionIndicatorWidth
  780. }
  781. ExpandingSpacer {}
  782. }
  783. PropertyLabel {
  784. text: qsTr("Transmission Map")
  785. tooltip: qsTr("Sets a texture that contains the transmission percentage of a the surface.")
  786. }
  787. SecondColumnLayout {
  788. ItemFilterComboBox {
  789. typeFilter: "QtQuick3D.Texture"
  790. backendValue: backendValues.transmissionMap
  791. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  792. + StudioTheme.Values.actionIndicatorWidth
  793. }
  794. ExpandingSpacer {}
  795. }
  796. PropertyLabel {
  797. text: qsTr("Transmission Channel")
  798. tooltip: qsTr("Sets the texture channel used to read the transmission percentage from transmissionMap.")
  799. }
  800. SecondColumnLayout {
  801. ComboBox {
  802. scope: "Material"
  803. model: ["R", "G", "B", "A"]
  804. backendValue: backendValues.transmissionChannel
  805. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  806. + StudioTheme.Values.actionIndicatorWidth
  807. }
  808. ExpandingSpacer {}
  809. }
  810. PropertyLabel {
  811. text: qsTr("Thickness Factor")
  812. tooltip: qsTr("Sets the thickness of the volume beneath the surface in model coordinate space.")
  813. }
  814. SecondColumnLayout {
  815. SpinBox {
  816. minimumValue: 0
  817. maximumValue: Infinity
  818. decimals: 2
  819. backendValue: backendValues.thicknessFactor
  820. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  821. + StudioTheme.Values.actionIndicatorWidth
  822. }
  823. ExpandingSpacer {}
  824. }
  825. PropertyLabel {
  826. text: qsTr("Thickness Map")
  827. tooltip: qsTr("Sets a texture that contains the thickness of a the material volume.")
  828. }
  829. SecondColumnLayout {
  830. ItemFilterComboBox {
  831. typeFilter: "QtQuick3D.Texture"
  832. backendValue: backendValues.thicknessMap
  833. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  834. + StudioTheme.Values.actionIndicatorWidth
  835. }
  836. ExpandingSpacer {}
  837. }
  838. PropertyLabel {
  839. text: qsTr("Thickness Channel")
  840. tooltip: qsTr("Sets the texture channel used to read the thickness amount from thicknessMap.")
  841. }
  842. SecondColumnLayout {
  843. ComboBox {
  844. scope: "Material"
  845. model: ["R", "G", "B", "A"]
  846. backendValue: backendValues.thicknessChannel
  847. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  848. + StudioTheme.Values.actionIndicatorWidth
  849. }
  850. ExpandingSpacer {}
  851. }
  852. PropertyLabel {
  853. text: qsTr("Attenuation Color")
  854. tooltip: qsTr("Sets the color that white lights turn into due to absorption when reaching the attenuation distance.")
  855. }
  856. ColorEditor {
  857. backendValue: backendValues.attenuationColor
  858. supportGradient: false
  859. }
  860. PropertyLabel {
  861. text: qsTr("Attenuation Distance")
  862. tooltip: qsTr("Sets the average distance in world space that light travels in the medium before interacting with a particle.")
  863. }
  864. SecondColumnLayout {
  865. SpinBox {
  866. minimumValue: 0
  867. maximumValue: Infinity
  868. decimals: 2
  869. backendValue: backendValues.attenuationDistance
  870. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  871. + StudioTheme.Values.actionIndicatorWidth
  872. }
  873. ExpandingSpacer {}
  874. }
  875. }
  876. }
  877. Section {
  878. caption: qsTr("Fresnel")
  879. width: parent.width
  880. SectionLayout {
  881. PropertyLabel {
  882. text: qsTr("Fresnel Power")
  883. tooltip: qsTr("Sets the fresnel power.")
  884. }
  885. SecondColumnLayout {
  886. SpinBox {
  887. minimumValue: 0
  888. maximumValue: 1000
  889. stepSize: 0.1
  890. decimals: 2
  891. backendValue: backendValues.fresnelPower
  892. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  893. + StudioTheme.Values.actionIndicatorWidth
  894. }
  895. ExpandingSpacer {}
  896. }
  897. PropertyLabel {
  898. text: qsTr("Enable scale and bias")
  899. tooltip: qsTr("Sets whether fresnel scale and bias are enabled.")
  900. }
  901. SecondColumnLayout {
  902. CheckBox {
  903. text: checked ? qsTr("Enabled") : qsTr("Disabled")
  904. backendValue: backendValues.fresnelScaleBiasEnabled
  905. implicitWidth: StudioTheme.Values.twoControlColumnWidth
  906. + StudioTheme.Values.actionIndicatorWidth
  907. }
  908. ExpandingSpacer {}
  909. }
  910. PropertyLabel {
  911. text: qsTr("Fresnel Scale")
  912. tooltip: qsTr("Sets the fresnel scale.")
  913. }
  914. SecondColumnLayout {
  915. SpinBox {
  916. minimumValue: 0
  917. maximumValue: 5
  918. stepSize: 0.1
  919. decimals: 2
  920. backendValue: backendValues.fresnelScale
  921. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  922. + StudioTheme.Values.actionIndicatorWidth
  923. }
  924. ExpandingSpacer {}
  925. }
  926. PropertyLabel {
  927. text: qsTr("Fresnel Bias")
  928. tooltip: qsTr("Sets the fresnel bias.")
  929. }
  930. SecondColumnLayout {
  931. SpinBox {
  932. minimumValue: -1
  933. maximumValue: 1
  934. stepSize: 0.1
  935. decimals: 2
  936. backendValue: backendValues.fresnelBias
  937. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  938. + StudioTheme.Values.actionIndicatorWidth
  939. }
  940. ExpandingSpacer {}
  941. }
  942. }
  943. }
  944. Section {
  945. caption: qsTr("Vertex Color")
  946. width: parent.width
  947. SectionLayout {
  948. PropertyLabel {
  949. text: qsTr("Show Colors")
  950. tooltip: qsTr("Sets whether vertex colors are used to modulate the base color.")
  951. }
  952. SecondColumnLayout {
  953. CheckBox {
  954. text: checked ? qsTr("Enabled") : qsTr("Disabled")
  955. backendValue: backendValues.vertexColorsEnabled
  956. implicitWidth: StudioTheme.Values.twoControlColumnWidth
  957. + StudioTheme.Values.actionIndicatorWidth
  958. }
  959. ExpandingSpacer {}
  960. }
  961. PropertyLabel {
  962. text: qsTr("Enable Masks")
  963. tooltip: qsTr("Sets whether vertex colors mask are used.")
  964. }
  965. SecondColumnLayout {
  966. CheckBox {
  967. text: checked ? qsTr("Enabled") : qsTr("Disabled")
  968. backendValue: backendValues.vertexColorsMaskEnabled
  969. implicitWidth: StudioTheme.Values.twoControlColumnWidth
  970. + StudioTheme.Values.actionIndicatorWidth
  971. }
  972. ExpandingSpacer {}
  973. }
  974. ListModel {
  975. id: colorMaskModel
  976. ListElement {
  977. name: "Glossiness"
  978. flag: "GlossinessMask"
  979. }
  980. ListElement {
  981. name: "Normal Strength"
  982. flag: "NormalStrengthMask"
  983. }
  984. ListElement {
  985. name: "Clearcoat Amount"
  986. flag: "ClearcoatAmountMask"
  987. }
  988. ListElement {
  989. name: "Clearcoat Roughness Amount"
  990. flag: "ClearcoatRoughnessAmountMask"
  991. }
  992. ListElement {
  993. name: "Clearcoat Normal Strength"
  994. flag: "ClearcoatNormalStrengthMask"
  995. }
  996. ListElement {
  997. name: "Height Amount"
  998. flag: "HeightAmountMask"
  999. }
  1000. ListElement {
  1001. name: "Occlusion Amount"
  1002. flag: "OcclusionAmountMask"
  1003. }
  1004. ListElement {
  1005. name: "Thickness Factor"
  1006. flag: "ThicknessFactorMask"
  1007. }
  1008. ListElement {
  1009. name: "Transmission Factor"
  1010. flag: "TransmissionFactorMask"
  1011. }
  1012. }
  1013. PropertyLabel {
  1014. text: qsTr("Mask R")
  1015. tooltip: qsTr("Sets the properties masked by the vertex color red channel.")
  1016. }
  1017. SecondColumnLayout {
  1018. FlagsComboBox {
  1019. backendValue: backendValues.vertexColorRedMask
  1020. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  1021. + StudioTheme.Values.actionIndicatorWidth
  1022. itemsModel: colorMaskModel
  1023. scope: "SpecularGlossyMaterial"
  1024. zeroFlag: "NoMask"
  1025. }
  1026. ExpandingSpacer {}
  1027. }
  1028. PropertyLabel {
  1029. text: qsTr("Mask G")
  1030. tooltip: qsTr("Sets the properties masked by the vertex color green channel.")
  1031. }
  1032. SecondColumnLayout {
  1033. FlagsComboBox {
  1034. backendValue: backendValues.vertexColorGreenMask
  1035. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  1036. + StudioTheme.Values.actionIndicatorWidth
  1037. itemsModel: colorMaskModel
  1038. scope: "SpecularGlossyMaterial"
  1039. zeroFlag: "NoMask"
  1040. }
  1041. ExpandingSpacer {}
  1042. }
  1043. PropertyLabel {
  1044. text: qsTr("Mask B")
  1045. tooltip: qsTr("Sets the properties masked by the vertex color blue channel.")
  1046. }
  1047. SecondColumnLayout {
  1048. FlagsComboBox {
  1049. backendValue: backendValues.vertexColorBlueMask
  1050. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  1051. + StudioTheme.Values.actionIndicatorWidth
  1052. itemsModel: colorMaskModel
  1053. scope: "SpecularGlossyMaterial"
  1054. zeroFlag: "NoMask"
  1055. }
  1056. ExpandingSpacer {}
  1057. }
  1058. PropertyLabel {
  1059. text: qsTr("Mask A")
  1060. tooltip: qsTr("Sets the properties masked by the vertex color alpha channel.")
  1061. }
  1062. SecondColumnLayout {
  1063. FlagsComboBox {
  1064. backendValue: backendValues.vertexColorAlphaMask
  1065. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  1066. + StudioTheme.Values.actionIndicatorWidth
  1067. itemsModel: colorMaskModel
  1068. scope: "SpecularGlossyMaterial"
  1069. zeroFlag: "NoMask"
  1070. }
  1071. ExpandingSpacer {}
  1072. }
  1073. }
  1074. }
  1075. Section {
  1076. caption: qsTr("Advanced")
  1077. width: parent.width
  1078. SectionLayout {
  1079. PropertyLabel {
  1080. text: qsTr("Point Size")
  1081. tooltip: qsTr("Sets the size of the points rendered, when the geometry is using a primitive type of points.")
  1082. }
  1083. SecondColumnLayout {
  1084. SpinBox {
  1085. minimumValue: 0
  1086. maximumValue: 1024
  1087. decimals: 0
  1088. backendValue: backendValues.pointSize
  1089. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  1090. + StudioTheme.Values.actionIndicatorWidth
  1091. }
  1092. ExpandingSpacer {}
  1093. }
  1094. PropertyLabel {
  1095. text: qsTr("Line Width")
  1096. tooltip: qsTr("Sets the width of the lines rendered, when the geometry is using a primitive type of lines or line strips.")
  1097. }
  1098. SecondColumnLayout {
  1099. SpinBox {
  1100. minimumValue: 0
  1101. maximumValue: 1024
  1102. decimals: 0
  1103. backendValue: backendValues.lineWidth
  1104. implicitWidth: StudioTheme.Values.singleControlColumnWidth
  1105. + StudioTheme.Values.actionIndicatorWidth
  1106. }
  1107. ExpandingSpacer {}
  1108. }
  1109. }
  1110. }
  1111. }