Revision f4888b83

View differences:

doc/ffmpeg-doc.texi
987 987
bugs).
988 988

  
989 989
Comments: use the JavaDoc/Doxygen 
990
format (see examples in @file{libavformat/utils.c}) so that a documentation
990
format (see examples below) so that a documentation
991 991
can be generated automatically. All non trivial functions should have a comment
992 992
above it explaining what the function does, even if its just one sentance.
993 993
All Structures and their member variables should be documented too.
994

  
994
@example
995
/**
996
?* @file mpeg.c
997
?* mpeg codec.
998
?* @author ...
999
?*/
1000

  
1001
/**
1002
?* Summary sentance.
1003
?* more text ...
1004
?* ...
1005
?*/
1006
typedef struct Foobar{
1007
? ? int var1; /**< var1 description */
1008
? ? int var2; ///< var2 description
1009
? ? /** var3 description */
1010
? ? int var3;
1011
} Foobar;
1012

  
1013
/**
1014
?* Summary sentance.
1015
?* more text ...
1016
?* ...
1017
?* @param my_parameter description of my_parameter
1018
?* @return return value description
1019
?*/
1020
int myfunc(int my_parameter)
1021
...
1022
@end example
995 1023

  
996 1024
fprintf and printf are forbidden in libavformat and libavcodec, 
997 1025
please use av_log() instead.

Also available in: Unified diff