From 94b7c240720ac3a561ff91106c7698b25cd5179b Mon Sep 17 00:00:00 2001 From: David Thompson Date: Tue, 7 Feb 2023 08:58:48 -0500 Subject: Store GLSL type name in primitive type. --- chickadee/graphics/seagull.scm | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/chickadee/graphics/seagull.scm b/chickadee/graphics/seagull.scm index be479ba..4488c04 100644 --- a/chickadee/graphics/seagull.scm +++ b/chickadee/graphics/seagull.scm @@ -1934,7 +1934,7 @@ ;; choosing to represent them opaquely for now to keep things simple. (define type:mat3 (primitive-type 'mat3)) (define type:mat4 (primitive-type 'mat4)) -(define type:sampler-2d (primitive-type 'sampler-2d)) +(define type:sampler-2d (primitive-type 'sampler2D)) (define (type-descriptor->type desc) (match desc @@ -2212,13 +2212,10 @@ ;; Transform a fully typed Seagull program into a string of GLSL code. -(define %type-name-map - '((sampler-2d . sampler2D))) - (define (type-descriptor->glsl desc) (match desc ((? symbol?) - (or (assq-ref %type-name-map desc) desc)) + desc) (('array desc* length) (format #f "~a[~a]" (type-descriptor->glsl desc*) -- cgit v1.2.3