From b6a336aff26fbc94e7803719a8aeb8fa29eddb9b Mon Sep 17 00:00:00 2001 From: rodri Date: Tue, 1 Oct 2024 20:21:13 +0000 Subject: implement a uniforms interface through Shadertab. --- camera.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'camera.c') diff --git a/camera.c b/camera.c index f89640f..607f033 100644 --- a/camera.c +++ b/camera.c @@ -16,7 +16,7 @@ skyboxvs(Shaderparams *sp) { Point3 p; - addvattr(sp->v, "dir", VAPoint, &sp->v->p); + sp->setattr(sp, "dir", VAPoint, &sp->v->p); /* only rotate along with the camera */ p = sp->v->p; p.w = 0; p = world2vcs(sp->su->camera, p); @@ -32,7 +32,7 @@ skyboxfs(Shaderparams *sp) Vertexattr *va; Color c; - va = getvattr(sp->v, "dir"); + va = sp->getattr(sp, "dir"); c = samplecubemap(sp->su->camera->scene->skybox, va->p, neartexsampler); return c; } -- cgit v1.2.3