Changeset 5440:3bd9f7ab48ed in roaraudio
- Timestamp:
- 03/20/12 17:53:57 (12 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
plugins/universal/helloworld.c
r5439 r5440 26 26 #include <roaraudio.h> 27 27 28 // A simple function printing our message. 28 29 static int hw_init (struct roar_dl_librarypara * para) { 29 (void)para; 30 (void)para; // We ignore all parameters passed to us. 30 31 31 32 roar_vio_printf(roar_stdout, "Hello world!\n"); … … 34 35 } 35 36 37 // This struct contains the AppSched pointers. 36 38 static struct roar_dl_appsched sched = { 37 39 .init = hw_init, … … 42 44 }; 43 45 46 // This is the plugin control block. 44 47 ROAR_DL_PLUGIN_START(helloworld) { 48 // Here we set the name and vendor of our plugin. 49 // If you have no Vendor ID you need to use ROAR_DL_PLUGIN_META_PRODUCT_NV(). 45 50 ROAR_DL_PLUGIN_META_PRODUCT_NIV("helloworld", ROAR_VID_ROARAUDIO, ROAR_VNAME_ROARAUDIO); 51 52 // This sets the version of your plugin. 46 53 ROAR_DL_PLUGIN_META_VERSION(ROAR_VERSION_STRING); 54 55 // This sets the license of your plugin. 56 // If there is no tag for the license you use you can just 57 // use ROAR_DL_PLUGIN_META_LICENSE(). 47 58 ROAR_DL_PLUGIN_META_LICENSE_TAG(GPLv3_0); 59 60 // This sets the author and contact infos. 61 // There are several other macros to do this with other parameters. 62 // See ROAR_DL_PLUGIN_META_CONTACT*() in the header or documentation. 48 63 ROAR_DL_PLUGIN_META_CONTACT_FLNE("Philipp", "Schafft", "ph3-der-loewe", "lion@lion.leolix.org"); 64 65 // This sets the description for your plugin. 49 66 ROAR_DL_PLUGIN_META_DESC("This plugin prints the string \"Hello world!\"."); 67 68 // Here the AppSched block from above is registered. 50 69 ROAR_DL_PLUGIN_REG_APPSCHED(&sched); 70 71 // This is the end of the control block. 51 72 } ROAR_DL_PLUGIN_END 52 73
Note: See TracChangeset
for help on using the changeset viewer.