PocketMatrix forums

A read-only archive of the PocketMatrix forums (2001–2014). Posting and accounts are closed.

Coding style in Samples

Hey guys.

I noticed that you put both declaration and code in the .H files rather than splitting code into .H and .CPP files. Any reason for doing that?
Hi Cardinal,

There is no particular reason for not splitting them into separate header and source files.

If you're using multiple c++ source files you need to include edgemain.h in the file that contains the EdgeMain() function, and include edge.h in the other source files.
OOOHHH ok ok... thats what I was after! I was trying to include EdgeMain.h in multiple files but that isn't a good idea! I didn't know about the other way! :) thanks