Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What does "#include <sndfile.h>" mean?

Tags:

c++

c

What does "#include <sndfile.h>" mean? (Sorry I'm c\c++ nub)

By the way I know ActionScript and HTML.

like image 249
Rella Avatar asked Dec 08 '22 05:12

Rella


2 Answers

That is a preprocessor directive to include the header file called 'sndfile.h'. Basically it means include the contents of that file in the place of that directive, which will usually give you function definitions for an object file that will be linked with your source code, and often defines constants, etc....

See wikipedia

like image 190
Gavin H Avatar answered Dec 30 '22 22:12

Gavin H


The #include directive tells the preprocessor to treat the contents of a specified file as if those contents had appeared in the source program at the point where the directive appears.

#include  "path-spec"
#include  <path-spec>

The path-spec is a filename optionally preceded by a directory specification. The filename must name an existing file. The syntax of the path-spec depends on the operating system on which the program is compiled.

You can organize constant and macro definitions into include files and then use #include directives to add these definitions to any source file. Include files are also useful for incorporating declarations of external variables and complex data types.

You need to define and name the types only once in an include file created for that purpose.

See also here, here and here.

like image 22
eKek0 Avatar answered Dec 30 '22 22:12

eKek0