C语言 在 C 中学习 SDL

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/6616601/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-02 09:05:10  来源:igfitidea点击:

Learning SDL in C

csdl

提问by Bottle Rocket

I know the basics of C and I'm looking into SDL. What I need at this point are some tutorials, documentation or perhaps a book about using the SDL libraries in C, especially about graphics.

我知道 C 的基础知识,我正在研究 SDL。我现在需要的是一些教程、文档或者可能是一本关于在 C 中使用 SDL 库的书,尤其是关于图形的。

The problem is that every online resource that I have found deals with C++, where I am looking for resources in C.

问题是我找到的每个在线资源都涉及 C++,我正在寻找 C 语言的资源。

I have looked at gpwiki.org, which had an entire section on C but mingw won't compile it because some of the includes are C++ libraries (I only installed the C compiler). Other sources like sol.gfxile.net/gp/ say that they are a C tutorial, but "use C++ for its conveniently loosened variable placement rules.". Most of the tutorials on the SDL site itself are based in C++.

我查看了 gpwiki.org,它有一整个关于 C 的部分,但 mingw 不会编译它,因为其中一些包含是 C++ 库(我只安装了 C 编译器)。其他来源如 sol.gfxile.net/gp/ 说它们是 C 教程,但“使用 C++ 是因为它方便地放松了变量放置规则。”。SDL 站点本身上的大多数教程都基于 C++。

Does anyone know of a good learning resource in C for SDL programming?

有谁知道用于 SDL 编程的 C 语言学习资源?

回答by scable

Have a look at this tutorial seriesat Parallel Realities. It covers SDL with C.

在 Parallel Realities查看本系列教程。它涵盖了 SDL 和 C。