`","2024-08-21T10:29:21Z","https://github.com/Tresjs/tres/issues/418",0.7417888,{"description":2894,"labels":2895,"number":2896,"owner":2868,"repository":2888,"state":2870,"title":2897,"updated_at":2898,"url":2899,"score":2900},"### Description\n\nI defined a camera and a light and used the :position attribute, but the type error was displayed in vscode; so I changed :position=\"[3, 3,3]\" to:position=\"new THREE. Vector3(0, 3, 3)\" results in no type error;\r\n\r\nI don't know if it's a version problem or a package version problem.\n\n### Suggested solution\n\n``` vue\r\n\u003Cscript setup lang=\"ts\">\r\n\timport * as THREE from 'three'\r\n\timport { TresCanvas } from '@tresjs/core'\r\n\timport { OrbitControls, vLightHelper } from '@tresjs/cientos'\r\n\r\n\timport Texture_02 from '@/components/texture/texture_02/index.vue'\r\n\tdefineOptions({\r\n\t\tdir_name: 'stickers',\r\n\t})\r\n\u003C/script>\r\n\r\n\u003Ctemplate>\r\n\t\u003Cdiv class=\"container\">\r\n\t\t\u003CTresCanvas shadows clear-color=\"#82DBC5\" preset=\"realistic\" alpha power-preference=\"high-performance\">\r\n\t\t\t\u003COrbitControls />\r\n\r\n \u003C!-- There will be a type problem here -->\r\n\t\t\t\u003CTresPerspectiveCamera :position=\"[3, 3, 3]\" :look-at=\"[0, 0, 0]\" />\r\n\r\n\t\t\t\u003CSuspense>\r\n\t\t\t\t\u003CTexture_02 />\r\n\t\t\t\u003C/Suspense>\r\n\r\n \u003C!-- OK -->\r\n\t\t\t\u003CTresDirectionalLight :intensity=\"1\" :position=\"new THREE.Vector3(0, 3, 3)\" v-light-helper />\r\n\t\t\u003C/TresCanvas>\r\n\t\u003C/div>\r\n\u003C/template>\r\n\r\n\u003Cstyle lang=\"scss\" scoped>\r\n\t.container {\r\n\t\twidth: 100%;\r\n\t\theight: 100%;\r\n\t\tdisplay: flex;\r\n\t\talign-items: center;\r\n\t\tjustify-content: center;\r\n\t}\r\n\u003C/style>\r\n\r\n```\n\n### Alternative\n\nAt first I thought: position=\"new THREE.Vector3(0, 3, 3)\" is a better way to understand the original parameters of threejs, but after reading the documentation, I found: position=\"[0,3,3]\" is simpler ;But the recommended writing method in the document is: position=\"[0,3,3]\"\r\n\r\n\r\n\n\n### Additional context\n\n\r\n\r\n\n\n### Validations\n\n- [X] I agree to follow this project's [Code of Conduct](https://github.com/Tresjs/tres/blob/main/CODE_OF_CONDUCT.md)\n- [X] Read the [Contributing Guidelines](https://github.com/Tresjs/tres/blob/main/CONTRIBUTING.md).\n- [X] Read the [docs](https://tresjs.org/guide).\n- [X] Check that there isn't [already an issue](https://github.com/tresjs/tres/issues) that reports the same bug to avoid creating a duplicate.",[],696,"position type is incorrect","2024-05-27T03:45:05Z","https://github.com/Tresjs/tres/issues/696",0.75124115,{"description":2902,"labels":2903,"number":104,"owner":2868,"repository":2869,"state":2910,"title":2911,"updated_at":2912,"url":2913,"score":2914},"**Is your feature request related to a problem? Please describe.**\r\n`packages/cientos/core/OrbitControls.vue` offers limited props\r\n\r\n```ts\r\nexport interface OrbitControlsProps {\r\n /**\r\n * Whether to make this the default controls.\r\n *\r\n * @default false\r\n * @type {boolean}\r\n * @memberof OrbitControlsProps\r\n * @see https://threejs.org/docs/#examples/en/controls/OrbitControls\r\n */\r\n makeDefault?: boolean\r\n /**\r\n * The camera to control.\r\n *\r\n * @type {Camera}\r\n * @memberof OrbitControlsProps\r\n * @see https://threejs.org/docs/#examples/en/controls/OrbitControls\r\n */\r\n camera?: Camera\r\n /**\r\n * The dom element to listen to.\r\n *\r\n * @type {HTMLElement}\r\n * @memberof OrbitControlsProps\r\n * @see https://threejs.org/docs/#examples/en/controls/OrbitControls\r\n */\r\n domElement?: HTMLElement\r\n /**\r\n * The target to orbit around.\r\n *\r\n * @type {Ref\u003CVector3>}\r\n * @memberof OrbitControlsProps\r\n * @see https://threejs.org/docs/#examples/en/controls/OrbitControls\r\n */\r\n target?: Ref\u003CVector3>\r\n /**\r\n * Whether to enable damping.\r\n *\r\n * @default false\r\n * @type {boolean}\r\n * @memberof OrbitControlsProps\r\n * @see https://threejs.org/docs/#examples/en/controls/OrbitControls\r\n */\r\n enableDamping?: boolean\r\n}\r\n```\r\n\r\n\r\n**Describe the solution you'd like**\r\nThe ThreeJS [OrbitControls](https://threejs.org/docs/#examples/en/controls/OrbitControls) has way more features and properties we could support\r\n\r\n**Suggested solution**\r\nAdd rest of the properties to abstraction\r\n\r\n**Additional context**\r\nAdd any other context or screenshots about the feature request here.\r\n",[2904,2907],{"name":2905,"color":2906},"good first issue","7057ff",{"name":2908,"color":2909},"help wanted","008672","closed","Enhance OrbitControls cientos abstraction","2023-05-18T13:44:09Z","https://github.com/Tresjs/cientos/issues/3",0.45649067,{"description":2916,"labels":2917,"number":2918,"owner":2868,"repository":2888,"state":2910,"title":2919,"updated_at":2920,"url":2921,"score":2922},"# Goal\r\nGenerate three-shakeable components on build time to avoid the need for a catalog of global components. This will be probably a BREAKING CHANGE, especially for cientos.\r\n\r\n```vue\r\n\u003Cscript setup lang=\"ts\">\r\n\r\nimport { TresCanvas, TresPerspectiveCamera, TresScene, TresAmbienLight, useRenderLoop } from '@tresjs/core' \r\nimport { OrbitControls, TransformControls } from '@tresjs/cientos'\r\n\r\nconst sphereRef = ref()\r\n\r\nconst { onLoop } = useRenderLoop()\r\n\r\nonLoop(({ elapsed }) => {\r\n sphereRef.value.position.y += Math.sin(elapsed * 0.01) * 0.1\r\n})\r\n\u003C/script>\r\n\u003Ctemplate>\r\n \u003CTresCanvas v-bind=\"state\">\r\n \u003CTresPerspectiveCamera :position=\"[5, 5, 5]\" :fov=\"45\" :near=\"0.1\" :far=\"1000\" :look-at=\"[-8, 3, -3]\" />\r\n \u003COrbitControls make-default />\r\n \u003CTresScene>\r\n \u003CTresAmbientLight :intensity=\"0.5\" />\r\n \u003CTransformControls mode=\"scale\" :object=\"sphereRef\" />\r\n\r\n \u003CTresMesh ref=\"sphereRef\" :position=\"[0, 4, 0]\" cast-shadow>\r\n \u003CTresSphereGeometry />\r\n \u003CTresMeshToonMaterial color=\"#FBB03B\" />\r\n \u003C!-- \u003CTresMeshToonMaterial color=\"#FBB03B\" /> -->\r\n \u003C/TresMesh>\r\n \u003CTresDirectionalLight :position=\"[0, 8, 4]\" :intensity=\"0.7\" cast-shadow />\r\n \u003CTresMesh :rotation=\"[-Math.PI / 2, 0, 0]\" receive-shadow>\r\n \u003CTresPlaneGeometry :args=\"[10, 10, 10, 10]\" />\r\n \u003CTresMeshToonMaterial />\r\n \u003C/TresMesh>\r\n \u003CTresDirectionalLight :position=\"[0, 2, 4]\" :intensity=\"1\" cast-shadow />\r\n \u003C/TresScene>\r\n \u003C/TresCanvas>\r\n\u003C/template>\r\n\r\n```\r\n\r\n- [ ] Using a vite plugin to generate all the components from THREE instances (Except Scene)\r\n- [ ] Each component should locally register components on the slots (is possible?)\r\n- [ ] Typescript Definition for the components generated from the ThreeJS instance\r\n- [ ] Include them in the final bundle\r\n- [ ] Strategy for replacing catalog `extend` \r\n- [ ] Update the way `cientos` extends the catalog\r\n",[],104,"Generate instances on build-time rather than run-time","2023-03-13T14:26:46Z","https://github.com/Tresjs/tres/issues/104",0.7051123,{"description":2924,"labels":2925,"number":93,"owner":2868,"repository":2869,"state":2910,"title":2926,"updated_at":2927,"url":2928,"score":2929},"**Is your feature request related to a problem? Please describe.**\r\nWe should have a [CameraControls](https://github.com/yomotsu/camera-controls) component as it is a very handy tool.\r\n\r\n**Describe the solution you'd like**\r\nAbstraction in cientos.\r\n\r\n**Suggested solution**\r\nSee [drei](https://github.com/pmndrs/drei).\r\n",[],"CameraControls in cientos","2023-07-26T13:40:26Z","https://github.com/Tresjs/cientos/issues/1",0.71005154,{"description":2931,"labels":2932,"number":93,"owner":2868,"repository":2933,"state":2910,"title":2934,"updated_at":2935,"url":2936,"score":2929},"When i run 'pnpm dev' locally, i get this error:\r\n\r\n\r\n\r\nI guess maybe **node version** cause? I checked the node version, and It's **16.19.0**. Ok, I change it to **18.14.0**. Yes,it works! Then , I change it to **17.9.1**, the error again. \r\n\r\nAdd something about **node version** in README? ",[],"lab","'pnpm dev' failed","2024-09-01T16:08:35Z","https://github.com/Tresjs/lab/issues/1",{"description":2938,"labels":2939,"number":1660,"owner":2868,"repository":2943,"state":2910,"title":2944,"updated_at":2945,"url":2946,"score":2947},"**Is your feature request related to a problem? Please describe.**\r\nAs of now, effects are typescript `.ts` files with `defineComponent`.\r\n\r\n```ts\r\nexport const Glitch = defineComponent\u003CGlitchProps>({\r\n name: 'Glitch',\r\n props: [\r\n 'delay',\r\n 'duration',\r\n 'strength',\r\n 'mode',\r\n 'active',\r\n 'ratio',\r\n 'columns',\r\n 'chromaticAberrationOffset',\r\n 'peturbationMap',\r\n 'dtSize',\r\n ] as unknown as undefined,\r\n\r\n async setup(props, { expose }) {\r\n const { state } = useCore()\r\n const composer = inject\u003Cany>('effectComposer')\r\n const pass = ref\u003CEffectPass | null>(null)\r\n\r\n expose({ getPass: () => pass.value })\r\n\r\n watchEffect(() => {\r\n if (state.camera && composer && composer.value) {\r\n pass.value = new EffectPass(unref(state.camera), new GlitchEffect(props))\r\n composer.value?.addPass(toRaw(pass.value))\r\n }\r\n })\r\n\r\n watch(\r\n () => props.active,\r\n value => {\r\n if (pass.value) {\r\n pass.value.enabled = value as boolean\r\n }\r\n },\r\n )\r\n\r\n return () => {\r\n pass\r\n }\r\n },\r\n})\r\n\r\n```\r\n\r\n**Describe the solution you'd like**\r\n\r\nUse a similar approach as cientos and use vue SFC components \r\n\r\n",[2940],{"name":2941,"color":2942},"enhancement","a2eeef","post-processing","Refactor Effects to .vue files","2023-06-23T16:06:50Z","https://github.com/Tresjs/post-processing/issues/23",0.7191441,{"description":2949,"labels":2950,"number":1660,"owner":2868,"repository":2888,"state":2910,"title":2955,"updated_at":2956,"url":2957,"score":2947},"Atm HMR disposal is not working as expected. Meshes are duplicated and this could lead to performance issues on large scenes.\n\nAlso not nice for DX. User needs to reload everytime.\n\nThis one is pretty tricky.\n\n# Desired solution.\n\nRenderer, scene and object follow a disposal flow when HMR hits",[2951,2952],{"name":2908,"color":2909},{"name":2953,"color":2954},"discussion 💭","AE4C80","HMR disposal","2023-09-12T18:58:32Z","https://github.com/Tresjs/tres/issues/23",{"description":2959,"labels":2960,"number":2961,"owner":2868,"repository":2962,"state":2910,"title":2963,"updated_at":2964,"url":2965,"score":2966},"### Describe the bug\n\nI added OrbitControls, and when scrolling I get the following error\r\n\r\n```\r\nWARNING: OrbitControls.js encountered an unknown camera type - dolly/zoom disabled.\r\n```\r\n\r\nMake it impossible to scroll to zoom in/out. \r\n\r\n\r\n\n\n### Reproduction\n\nhttps://stackblitz.com/edit/nuxt-starter-3nnslu?file=package.json\n\n### Steps to reproduce\n\n_No response_\n\n### System Info\n\n```shell\nSee https://stackblitz.com/edit/nuxt-starter-3nnslu?file=package.json\n```\n\n\n### Used Package Manager\n\nnpm\n\n### Code of Conduct\n\n- [X] I agree to follow this project's [Code of Conduct](https://github.com/Tresjs/tres/blob/main/CODE_OF_CONDUCT.md)\n- [X] Read the [Contributing Guidelines](https://github.com/Tresjs/tres/blob/main/CONTRIBUTING.md).\n- [X] Read the [docs](https://tresjs.org/guide).\n- [X] Check that there isn't [already an issue](https://github.com/tresjs/tres/issues) that reports the same bug to avoid creating a duplicate.\n- [X] The provided reproduction is a [minimal reproducible example](https://stackoverflow.com/help/minimal-reproducible-example) of the bug.",[],49,"nuxt","Nuxtjs: OrbitControls.js encountered an unknown camera type","2023-11-08T09:28:32Z","https://github.com/Tresjs/nuxt/issues/49",0.7238578,["Reactive",2968],{},["Set"],["ShallowReactive",2971],{"$fTRc1wZytZ_XrK4EfJfei_Sz-An4H4Yy6syhVxH_PVJc":-1,"$f7W5y0b5_83IFO1QV-UowfnvEmj5fo3G4L0vZoVWfjZI":-1},"/Tresjs/lab/3"]