Files
cocos4/cocos/core/renderer/data-pool-manager.ts
T
Yun Hsiao Wu 2d431f7ec4 SubModel level joint data (#6260)
* submodel joints data

* map VB joint indices on demand

* fix joint mapping

* fix shadows

* minor
2020-03-09 21:45:37 +08:00

29 lines
953 B
TypeScript

// Copyright (c) 2017-2018 Xiamen Yaji Software Co., Ltd.
import { AnimationClip } from '../animation/animation-clip';
import { Skeleton } from '../assets';
import { GFXDevice } from '../gfx/device';
import { JointsAnimationInfo, JointsTexturePool } from './models/skeletal-animation-utils';
export class DataPoolManager {
public jointsTexturePool: JointsTexturePool;
public jointsAnimationInfo: JointsAnimationInfo;
constructor (device: GFXDevice) {
this.jointsTexturePool = new JointsTexturePool(device);
this.jointsAnimationInfo = new JointsAnimationInfo(device);
}
public releaseSkeleton (skeleton: Skeleton) {
this.jointsTexturePool.releaseSkeleton(skeleton);
}
public releaseAnimationClip (clip: AnimationClip) {
this.jointsTexturePool.releaseAnimationClip(clip);
}
public clear () {
this.jointsTexturePool.clear();
this.jointsAnimationInfo.clear();
}
}