Skip to content

Commit

Permalink
update props and constructor
Browse files Browse the repository at this point in the history
  • Loading branch information
damienmontastier committed Jan 7, 2025
1 parent 56daa5b commit 5c8b1a7
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion playground/src/pages/postprocessing/barrel-blur.vue
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ const { blendFunction, amount, offsetX, offsetY } = useControls({
blendFunction: {
options: Object.keys(BlendFunction).map(key => ({
text: key,
value: BlendFunction[key],
value: BlendFunction[key as keyof typeof BlendFunction],
})),
value: BlendFunction.OVERLAY,
},
Expand Down
10 changes: 5 additions & 5 deletions src/core/pmndrs/BarrelBlurPmndrs.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@ export interface BarrelBlurPmndrsProps {
offset?: Vector2 | [number, number]
}
const props = withDefaults(defineProps<BarrelBlurPmndrsProps>(), {
amount: 0.15,
offset: () => new Vector2(0.5, 0.5),
})
const props = defineProps<BarrelBlurPmndrsProps>()
const { pass, effect } = useEffectPmndrs(
() => new BarrelBlurEffect({ ...props, offset: Array.isArray(props.offset) ? new Vector2(...props.offset) : props.offset }),
() => new BarrelBlurEffect({
...props,
offset: Array.isArray(props.offset) ? new Vector2(...props.offset) : props.offset,
}),
props,
)
Expand Down

0 comments on commit 5c8b1a7

Please sign in to comment.