原文
| ||||||||||||||
| ||||||||||||||
![]() |
原始链接: https://news.ycombinator.com/item?id=43667693
一个 Hacker News 讨论串正在热议一个将 Shadertoy 移植到 Rust GPU 的项目。一位名为“hackyhacky”的评论者对项目介绍中的一句话提出了异议,该句话声称 CUDA 和 OpenCL 是 HLSL 和 GLSL 的“更好替代方案”,但由于厂商锁定或缺乏传统的图形管道支持而不适用。“hackyhacky”认为这种比较具有误导性,因为 CUDA 和 OpenCL 是计算语言,而 HLSL 和 GLSL 是着色器语言,两者服务于根本不同的目的。虽然两者都可以用于超出其最初目的的用途,“hackyhacky”认为将 CUDA 作为 GLSL 的直接替代方案是不诚实的。
| ||||||||||||||
| ||||||||||||||
![]() |
Are CUDA and OpenCL really "better alternatives" to HLSL and GLSL?
CUDA and OpenCL are compute languages; HLSL and GLSL and shader languages. And while one can theoretically do compute in a shader (and we used to!) or shaders in a compute language, I think it's dishonest to claim that CUDA is intended as an updated alternative to GLSL. It's simply apples and oranges.
reply