Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
2023-01-31
-创建stb_image_write.cpp,并在CMakeLists.txt中创建stbiw库,包含cpp和h文件
-target_include_directories引入h文件的路径,保证main所在的项目可以让CMake通过链接stbiw时找到对应头文件
-stbiw是C风格库,前一半为函数声明,后一半为函数定义,其中函数定义被宏STB_IMAGE_WRITE_IMPLEMENTATION包含起来,当且仅当此宏被定义是,编译器才读取定义并给出编译结果,否则相当于仅仅读取一个包含了一系列函数声明的头文件,从而实现在一个给定区域通过STB_IMAGE_WRITE_IMPLEMENTATION定义函数,其他地方仅引入头文件用于编译通过的目的