Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs(app): Improve docs examples with code group to avoid confusion #463

Merged
merged 133 commits into from
Aug 29, 2024

Conversation

JaimeTorrealba
Copy link
Member

No description provided.

andretchen0 and others added 30 commits January 11, 2024 22:31
andretchen0 and others added 20 commits July 23, 2024 14:34
* chore(deps): update deps to latest

* chore: on demand invalidation composable with prop change detection

* feat: on-demand orbit-controls

* feat: on-demand camera controls

* feat: invalidate also on autoRotate

* feat: on-demand map controls and refactor

* feat: on-demand transform controls

* feat: on-demand keyboard controls

* feat: on-demand keybaord controls

* chore: added demo suffix to control pages to avoid confusions

* feat: on-demand pointer lock controls

* feat: on-demand scroll controls

* feat: on-demand levioso

* feat: correct orbit controls auto rotate invalidation

* feat: on-demand text3d

* feat: on-demand mouse-parallax

* feat: on-demand fbo and size watcher refactor

* chore(playground): refactor to use useLoop and sub components

* chore: remove unused import for lint fix

* chore(playground): refactor lensflare demo to use useLoop

* feat: on-demand sampler

* feat: on-demand invaldiation on reflector prop change

* chore: added render activity graph and try to make on-demand work on AnimatedSprite

* chore: renamed positional audio demo

* chore: on-demand smoke

* feat: on-demand precipitation

* feat: on-dermand stars

* feat: on-demand Environment

* feat: on-demand sky

* feat: on-demand Ocean component

* chore: testing on-demand on fit

* feat: on-demand Wobble Material

* feat: on-demand invalidation holographic material

* feat: on-demand reflection material

* feat: on-demand custom shader material

* chore: rename bakeshadows demo

* chore: misc route

* chore: ci, update action setup

* chore: update Tres core

* fix: reimplement ContactShadows for v4 core

* docs: change link name

* fix(ContactShadows): add invalidate to updates

---------

Co-authored-by: alvarosabu <alvaro.saburido@gmail.com>
* feat(Sparkles): invalidate on update

* chore: fix linter error

* refactor(Sparkles): remove renderMode predicate before invalidate
* chore: remove `useOnDemandInvalidation` on Levioso

* chore: remove composable `useOnDemandInvalidation`

* chore: remove composable from Ocean

* chore: remove composable on Precipitation

* chore: remove composable from sky

* chore: remove from Fit

* chore: remove from smoke

* chore: remove from orbit-controls

* chore: remove composable from Text3D

* chore: remove from mouse parallax

* chore: remove composable from Reflector

* chore: only needed fbo invalidation

* chore: remove composable from useSurfaceSampler

* chore: remove composable from all controls

* chore: add invalidation on loop

* chore: remove prop speed check on loop for Levioso

* chore: remove invalidateOnDemand on MapControls

* chore: remove `invalidateOnDemand` from Keyboard controls

* chore: add invalidate on fit method, remove watch props
This PR adds an `autoRender` flag to `FBOOptions`.

This flag allows consumers of `useFBO` who want to take control of when
and where to render the render target instead of always rendering it
with the default scene and camera.

Co-authored-by: Alvaro Saburido <alvaro.saburido@gmail.com>
Copy link

stackblitz bot commented Aug 7, 2024

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

Copy link
Member

@alvarosabu alvarosabu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great idea @JaimeTorrealba, hopefully this will educate community about async usage on cientos.

I just added minor suggestion on the naming of components.

Thanks for the PR

<script setup lang="ts">
import { TresCanvas } from '@tresjs/core'
import { OrbitControls } from '@tresjs/cientos'
import AsyncComponent from './AsyncComponent.vue'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
import AsyncComponent from './AsyncComponent.vue'
import TheModel from './TheModel.vue'

<TresPerspectiveCamera :position="[11, 11, 11]" />
<OrbitControls />
<Suspense>
<AsyncComponent />
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<AsyncComponent />
<TheModel />

</TresCanvas>
</template>
```
```vue{2,6} [AsyncComponent.vue]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
```vue{2,6} [AsyncComponent.vue]
```vue{2,6} [TheModel.vue]

<script setup lang="ts">
import { TresCanvas } from '@tresjs/core'
import { OrbitControls } from '@tresjs/cientos'
import AsyncComponent from './AsyncComponent.vue'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
import AsyncComponent from './AsyncComponent.vue'
import TheModel from './TheModel.vue'

<TresPerspectiveCamera :position="[3, 2, 5]" />
<OrbitControls />
<Suspense>
<AsyncComponent />
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<AsyncComponent />
<TheModel />

</TresCanvas>
</template>
```
```vue{2,6} [AsyncComponent.vue]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
```vue{2,6} [AsyncComponent.vue]
```vue{2,6} [TheModel.vue]

<script setup lang="ts">
import { TresCanvas } from '@tresjs/core'
import { OrbitControls } from '@tresjs/cientos'
import AsyncComponent from './AsyncComponent.vue'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
import AsyncComponent from './AsyncComponent.vue'
import TheVideoTexture from './TheVideoTexture.vue'

/>
<OrbitControls />
<Suspense>
<AsyncComponent />
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<AsyncComponent />
<TheVideoTexture />

</TresCanvas>
</template>
```
```vue{3,8,13} [AsyncComponent.vue]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
```vue{3,8,13} [AsyncComponent.vue]
```vue{3,8,13} [TheVideoTexture.vue]

@JaimeTorrealba JaimeTorrealba changed the base branch from v4 to main August 24, 2024 15:30
Copy link

netlify bot commented Aug 24, 2024

Deploy Preview for cientos-tresjs ready!

Name Link
🔨 Latest commit a217277
🔍 Latest deploy log https://app.netlify.com/sites/cientos-tresjs/deploys/66c9fe1e943d850008ad0936
😎 Deploy Preview https://deploy-preview-463--cientos-tresjs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@JaimeTorrealba
Copy link
Member Author

@alvarosabu I have fixed this one, please let me know if everything good

@alvarosabu alvarosabu merged commit 38213d7 into main Aug 29, 2024
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

4 participants