こんなアプリが欲しい
こういう「現実の背景をバックにアバターが踊ってる」動画を iPhoneとMocopiだけで指、表情込みで撮影できる アプリ
どんなアプリを作れば良いの?
アバターの読み込み
- VRoid Hubと連携してVRMモデルが読み込めると良い
トラッキング
- 顔はARKitFaceのBlendShape
- 指はMediaPipeのHand(後述の通りmocopiが無い場合はMediaPipeのBlazePoseでも良い)
/* | |
MIT License | |
Copyright (c) 2023 Jiayin Cao | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights | |
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
copies of the Software, and to permit persons to whom the Software is |
// Copyright (c) 2023 Tomasz Stachowiak | |
// | |
// This contribution is dual licensed under EITHER OF | |
// | |
// Apache License, Version 2.0, (http://www.apache.org/licenses/LICENSE-2.0) | |
// MIT license (http://opensource.org/licenses/MIT) | |
// | |
// at your option. | |
#include "/inc/frame_constants.hlsl" |
こういう「現実の背景をバックにアバターが踊ってる」動画を iPhoneとMocopiだけで指、表情込みで撮影できる アプリ
// code updates are now there: | |
// https://github.com/Bleuje/processing-animations-code/blob/main/code/spherewave/spherewave.pde | |
// Processing code by Etienne JACOB | |
// motion blur template by beesandbombs | |
// opensimplexnoise code (by Kurt Spencer) in another tab is necessary | |
// --> code here : https://gist.github.com/Bleuje/fce86ef35b66c4a2b6a469b27163591e | |
// See the license information at the end of this file. | |
// View the rendered result at: https://bleuje.com/gifanimationsite/single/spherewave/ |
# the scripting-addition must be loaded manually if | |
# you are running yabai on macOS Big Sur. Uncomment | |
# the following line to have the injection performed | |
# when the config is executed during startup. | |
# | |
# for this to work you must configure sudo such that | |
# it will be able to run the command without password | |
sudo yabai --load-sa | |
yabai -m signal --add event=dock_did_restart action="sudo yabai --load-sa" |
import React, { useEffect } from 'react' | |
import gsap from 'gsap' | |
import { useFrame } from '@react-three/fiber' | |
// sync gsap raf to r3f raf | |
gsap.ticker.remove(gsap.updateRoot) | |
export const GsapTicker = () => { | |
const pg = React.useRef(0) | |
gsap.ticker.remove(gsap.updateRoot) |
Texture2D shaderTexture; | |
SamplerState samplerState; | |
cbuffer PixelShaderSettings | |
{ | |
float Time; | |
float Scale; | |
float2 Resolution; | |
float4 Background; | |
}; |
using System.Collections; | |
using System.Collections.Generic; | |
using UnityEngine; | |
[ExecuteAlways] | |
public class BezierTest : MonoBehaviour { | |
public int numOfPoints; | |
public float height = 1; |
uniform vec3 color; | |
uniform vec3 borderColor; | |
uniform float borderWidth; | |
varying vec2 vUv; | |
// Technique based on Inigo Quilez's 'Analytic checkers pattern filtering' | |
// https://iquilezles.org/articles/checkerfiltering/ | |
float border(in vec2 uv, in vec2 ddx, in vec2 ddy) { | |
// filter kernel | |
vec2 w = max(abs(ddx), abs(ddy)) + 0.001; |
Shader "Unlit/MatCap Techniques" | |
{ | |
Properties | |
{ | |
[NoScaleOffset] _MatCap ("MatCap", 2D) = "white" {} | |
[KeywordEnum(ViewSpaceNormal, ViewDirectionCross, ViewDirectionAligned)] _MatCapType ("Matcap UV Type", Float) = 2 | |
} | |
SubShader | |
{ | |
Tags { "RenderType"="Opaque" } |