repo_name
stringlengths
5
122
path
stringlengths
3
232
text
stringlengths
6
1.05M
straight-coding/straight-httpd-lwip-mbedtls-simulator
lwip-port/win32/lwipopts.h
/* lwipopts.h, lwIP Options Configuration. */ #ifndef __LWIPOPTS_H__ #define __LWIPOPTS_H__ #define ENABLE_HTTPS 1 /* if lwip is used with mbedtls package, there are three options that need to be set carefully. MEM_SIZE: More memory is better TCP_MSS: MUST be bigger enough TCP_WND: MUST be greater...
straight-coding/straight-httpd-lwip-mbedtls-simulator
straight-httpd/straight-httpd/straight-httpd.c
<filename>straight-httpd/straight-httpd/straight-httpd.c<gh_stars>1-10 /* straight-httpd.c Author: <NAME><<EMAIL>> Date: April 12, 2020 */ #include <stdlib.h> #include <stdio.h> #include <conio.h> #include <time.h> #include "../../lwip-port/win32/arch/port.h" #include "ssdp/ssdp.h" #include "lwip...
straight-coding/straight-httpd-lwip-mbedtls-simulator
straight-httpd/straight-httpd/utils.c
<filename>straight-httpd/straight-httpd/utils.c /* utils.c Author: <NAME><<EMAIL>> Date: April 12, 2020 */ #include <stdlib.h> #include <stdio.h> #include <string.h> #include <ctype.h> #ifdef WIN32 #include <direct.h> #endif #include "utils.h" static const TypeHeader contentTypes[] = { { "html"...
straight-coding/straight-httpd-lwip-mbedtls-simulator
lwip-port/win32/arch/port.h
/* port.h Author: <NAME><<EMAIL>> Date: April 12, 2020 */ #ifndef _PORT_H_ #define _PORT_H_ /////////////////////////////////////////////////////////////////////////////////////////// // Network /////////////////////////////////////////////////////////////////////////////////////////// #define MAX...
vineetrc/CS411EC
Join.h
<reponame>vineetrc/CS411EC #pragma once #include <cmath> #include <string> #include <vector> class Join { public: Join(std::string input1, std::string input2, std::string joinkey); void LoopJoin(std::string output); void HashJoin(std::string output); private: std::vector< st...
josuegaleas/JayKey
Firmware/config.h
<reponame>josuegaleas/JayKey<filename>Firmware/config.h /* * Author: <NAME> * Last Edit: 2019.11.09 */ #ifndef CONFIG_H #define CONFIG_H #define VENDOR_ID 0xDEAD #define PRODUCT_ID 0x0001 #define DEVICE_VER 0x0002 #define MANUFACTURER Josue Galeas #define PRODUCT JayK #define DESCRIPTION Firmware for JayK #define...
bferguson3/quasi88-port
src/SDL2/graph.c
/*********************************************************************** * �����ե��å����� (�����ƥ���¸) * * �ܺ٤ϡ� graph.h ���� ************************************************************************/ #include <stdio.h> #include <stdlib.h> #include <SDL.h> #include "quasi88.h" #include "graph.h" #include "device.h...
bferguson3/quasi88-port
src/WIN32/resource.h
#ifndef RESOURCE_H_INCLUDED #define RESOURCE_H_INCLUDED /*---------------------------------------------------------------------------*/ #define M_SYS 10000 /*---------------------------------------------------------------------------*/ #define M_SYS_RESET 10100 #define M_SYS_MODE 10200 #define M_SYS_MODE_V2 1020...
bferguson3/quasi88-port
src/SDL2/event.c
<reponame>bferguson3/quasi88-port<gh_stars>0 #include <SDL.h> #include "quasi88.h" #include "keyboard.h" // KEY88_xxx syms #include "event.h" // quasi88_key // globals... int use_cmdkey = FALSE; int keyboard_type = 1; // never changed in SDL2 int use_joydevice = FALSE; int show_fps = FALSE; char* file_keyboard = NULL...
bferguson3/quasi88-port
src/snddrv-old/quasi88/X11/audio.h
/* * MAME/XMAME の サウンドドライバとのインターフェイス */ #ifndef SNDDRV_X11_H_INCLUDED #define SNDDRV_X11_H_INCLUDED #undef EXTERN #ifdef SNDDRV_WORK_DEFINE #define EXTERN #else #define EXTERN extern #endif #include <stdio.h> #include <stdlib.h> #include <string.h> #include "quasi88.h" #include "snddrv.h" #include "initval.h" #i...
bferguson3/quasi88-port
src/WIN32/graph.c
<reponame>bferguson3/quasi88-port /*********************************************************************** * グラフィック処理 (システム依存) * * 詳細は、 graph.h 参照 ************************************************************************/ #include <stdio.h> #include <stdlib.h> #include "quasi88.h" #include "graph.h" #include "devi...
cnlohr/bridgesim
src/cclient/util/linmath.c
<reponame>cnlohr/bridgesim<filename>src/cclient/util/linmath.c #include "linmath.h" #include <math.h> void cross3d( float * out, const float * a, const float * b ) { out[0] = a[1]*b[2] - a[2]*b[1]; out[1] = a[2]*b[0] - a[0]*b[2]; out[2] = a[0]*b[1] - a[1]*b[0]; } void sub3d( float * out, const float * a, const flo...
cnlohr/bridgesim
src/cclient/util/linmath.h
#ifndef _LINMATH_H #define _LINMATH_H //Yes, I know it's kind of arbitrary. #define DEFAULT_EPSILON 0.001 //NOTE: Inputs may never be output with cross product. void cross3d( float * out, const float * a, const float * b ); void sub3d( float * out, const float * a, const float * b ); void add3d( float * out, const...
cnlohr/bridgesim
src/cclient/util/3dutils.h
<gh_stars>1-10 #ifndef _3DUTILS_H #define _3DUTILS_H //NOTE: Expects triples for all three. //Returns quadruples float * CalculateTangentSpace( int Triangles, int VertexCount, int * Indices, float * verts, float * normals, float * texs ); #endif
cnlohr/bridgesim
src/cclient/gui/button.c
<gh_stars>1-10 #include "button.h" #include <stdlib.h> #include <string.h> #include <stdio.h> struct GUIBase * CreateButton( struct GUIWindow * parent, const char * text ) { struct Button * ret = malloc( sizeof( struct Button ) ); ret->text = text?strdup(text):0; ret->x = 100; ret->y = 0; ret->w = 100; ret->h = ...
cnlohr/bridgesim
src/cclient/graphics/glutmain.h
<filename>src/cclient/graphics/glutmain.h #ifndef _GLUTMAIN_H #define _GLUTMAIN_H extern int fpscount; //Only in warp mode. extern double absoluteMouseMotionX; extern double absoluteMouseMotionY; extern double currentMouseX; extern double currentMouseY; //This must be done in your main. int StartGlutMain(int argc, ...
cnlohr/bridgesim
src/cclient/graphics/glutmain.c
<filename>src/cclient/graphics/glutmain.c<gh_stars>1-10 #include <stdio.h> #include <GL/glew.h> #include <GL/freeglut.h> #include "graphicscore.h" #include "bitmapfont.h" #include <os_generic.h> #include "objreader.h" #include <math.h> #include "commonassets.h" #include "guibase.h" #include "button.h" #include <string....
cnlohr/bridgesim
src/cclient/graphics/test.c
#include <stdio.h> #include <GL/glew.h> #include <GL/freeglut.h> #include "graphicscore.h" #include "bitmapfont.h" #include <os_generic.h> #include "objreader.h" #include <math.h> struct Shader * modelshader; struct Shader * defshader; struct Shader * texcoords; struct Shader * textshader; struct UniformMatch * shader...
cnlohr/bridgesim
src/cclient/test.c
#include <stdio.h> #include <GL/glew.h> #include <GL/freeglut.h> #include "graphicscore.h" #include "bitmapfont.h" #include <os_generic.h> #include "objreader.h" #include <math.h> #include "commonassets.h" #include "guibase.h" #include "button.h" #include "glutmain.h" #include <string.h> double StartTime; double Last...
cnlohr/bridgesim
src/cclient/gui/button.h
#ifndef _BUTTON_H #define _BUTTON_H #include "commonassets.h" #include "guibase.h" struct Button { float x, y; float w, h; float color[4]; int depressed; int clicked; int focused; struct GUIWindow * wp; void (*Prerender)( struct Button * b ); void (*Render)( struct Button * b ); int (*CheckClick)( struct G...
cnlohr/bridgesim
src/cclient/commonassets.h
#ifndef _COMMONASSETS_H #define _COMMONASSETS_H #include "graphicscore.h" #include "bitmapfont.h" #include <os_generic.h> #include "objreader.h" extern struct UniformMatch * OverallUniforms; extern struct Shader * ButtonShader; extern struct Shader * TextShader; extern struct BitmapFont * OldSansBlack; extern float...
cnlohr/bridgesim
src/cclient/graphics/objreader.c
//Copyright 2013 <>< <NAME>, Relicensed under the MIT/x11 License. #include "objreader.h" #include <stdlib.h> #include <stdio.h> #include <string.h> #include "3dutils.h" #define TBUFFERSIZE 256 #define VBUFFERSIZE 524288 struct TempObject { char CNameBuffer[TBUFFERSIZE]; int CVertCount; float CVerts[VBUFFERSI...
cnlohr/bridgesim
src/cclient/graphics/bitmapfont.c
#include "bitmapfont.h" #include <stdio.h> #include <string.h> #include <stdlib.h> struct BitmapFont * LoadBitmapFontByName( const char * fontpath ) { int line = 0; struct BitmapFont * ret = 0; char sfname[2048]; FILE * f = fopen( fontpath, "r" ); if( !f ) { fprintf( stderr, "Error: could not open up path to: ...
cnlohr/bridgesim
src/cclient/graphics/bitmapfont.h
<reponame>cnlohr/bridgesim<filename>src/cclient/graphics/bitmapfont.h #ifndef _BITMAPFONT_H #define _BITMAPFONT_H #include "graphicscore.h" struct MChar { float loffx; //(U,V Tex coord) (Upper left) float loffy; float loffxe; //(U,V Tex coord) (Lower right) float loffye; int iW; //Pixles Width int lbitrows;...
cnlohr/bridgesim
src/cclient/gui/guibase.c
#include "guibase.h" #include <stdlib.h> #include <string.h> #include <stdio.h> void GenericHandleKeyboard( struct GUIBase * b, int c, int down, int focused ) { if( b->focused ) { if( c == '\n' || c == ' ' ) { if( b->depressed && !down ) { b->ProcessClick( b ); } else if( down ) { b->depr...
cnlohr/bridgesim
src/cclient/commonassets.c
#include "commonassets.h" struct UniformMatch * OverallUniforms; struct Shader * ButtonShader; struct Shader * TextShader; struct BitmapFont * OldSansBlack; float Ambient[4]; float Emission[4]; float TexSlot0; float TexSlot1; void SetupCommonAssets() { ButtonShader = CreateShader( "../assets/shaders/button" ); T...
cnlohr/bridgesim
src/cclient/graphics/graphicscore.h
#ifndef _GARPHICSCORE_H #define _GARPHICSCORE_H #include <stdint.h> #include <GL/gl.h> #define USE_PNG #define USE_JPG #define USE_IBO #define MAX_TEXTURES 16 extern double TotalTime; extern double DeltaTime; extern float RenderW; extern float RenderH; extern float ScreenW; extern float ScreenH; struct Shader { G...
cnlohr/bridgesim
src/cclient/util/3dutils.c
#include "3dutils.h" #include <stdlib.h> #include <string.h> //WARNING: This function probably doesn't work AT ALL! float * CalculateTangentSpace( int Triangles, int VertexCount, int * Indices, float * verts, float * normals, float * texs ) { //Here is the place to calculate the Tangent values. //It is a vector poin...
cnlohr/bridgesim
src/cclient/gui/guibase.h
<filename>src/cclient/gui/guibase.h<gh_stars>1-10 #ifndef _GUIBASE_H #define _GUIBASE_H #define MAX_GUI_ELEMENTS 2048 #include "graphicscore.h" struct GUIWindow; struct GUIBase { float x, y; float w, h; float color[4]; int depressed; int clicked; int focused; struct GUIWindow * wp; void (*Prerender)( struct...
cnlohr/bridgesim
src/cclient/graphics/graphicscore.c
<gh_stars>1-10 #include <sys/types.h> #include <stdint.h> #include "os_generic.h" #include <GL/glew.h> #include "graphicscore.h" #include <GL/glext.h> #include <stdio.h> #include <stdlib.h> #include <string.h> double TotalTime; double DeltaTime; float RenderW; float RenderH; float ScreenW; float ScreenH; #define MAX...
cnlohr/bridgesim
src/cclient/graphics/objreader.h
<gh_stars>1-10 //Copyright 2013 <>< <NAME>, Relicensed under the MIT/x11 License. #ifndef _OBJREADER_H #define _OBJREADER_H #define MAX_OBJECTS_PER_OBJ 128 #include "linmath.h" #include "graphicscore.h" struct OBJObject { const char * OName; int VertCount; //3 floats per vert count float * Vertices; int Norm...
Civica-EE/DUTCHess
src/gpio.h
#ifndef __DUTCHESS_GPIO_H__ #define __DUTCHESS_GPIO_H__ void dutchess_gpio_init (); void dutchess_gpio_configure (int pin); void dutchess_gpio_set (int pin, int value); int dutchess_gpio_get (int pin); #endif // __DUTCHESS_GPIO_H__
Civica-EE/DUTCHess
src/fs.h
#ifndef __DUTCHESS_FS_H__ #define __DUTCHESS_FS_H__ void dutchess_fs_init (); #endif // __DUTCHESS_FS_H__
Civica-EE/DUTCHess
src/web.c
<reponame>Civica-EE/DUTCHess #include <posix/pthread.h> #include <data/json.h> #include "civetweb.h" #include "relay.h" #include "web.h" #define HTTP_PORT 80 #define MAX_REQUEST_SIZE_BYTES 1024 #define HTTP_OK "HTTP/1.1 200 OK\r\n" \ "Content-Type: text/html\r\n" \ "Connection: close...
Civica-EE/DUTCHess
src/net.h
#ifndef __DUTCHESS_NET_H__ #define __DUTCHESS_NET_H__ #include <net/net_ip.h> void dutchess_net_init (); void dutchess_net_address_set (struct in_addr address); void dutchess_net_netmask_set (struct in_addr netmask); void dutchess_net_gateway_set (struct in_addr gateway); #endif // __DUTCHESS_NET_H__
Civica-EE/DUTCHess
src/shell.c
#include <shell/shell.h> #include "relay.h" #include "net.h" #include "temperature.h" static int dutchess_relay_cmd (const struct shell *shell, size_t argc, char **argv) { if (argc != 2) { shell_print(shell, "Usage: Please supply on/off as a parameter\n"); } else { if (!strcmp(argv...
Civica-EE/DUTCHess
src/main.c
#include "gpio.h" #include "fs.h" #include "led.h" #include "net.h" #include "relay.h" #include "settings.h" #include "temperature.h" #include "terminal_server.h" #include "tftp.h" #include "tftp_eeprom.h" #include "web.h" static struct dutchess_terminal_server_cfg dut_serial_cfg[] = { { .cfg = { ...
Civica-EE/DUTCHess
src/terminal_server.c
<reponame>Civica-EE/DUTCHess<filename>src/terminal_server.c #include <fcntl.h> #include <logging/log.h> #include <poll.h> #include <posix/pthread.h> #include <settings/settings.h> #include "terminal_server.h" #ifndef CONFIG_UART_INTERRUPT_DRIVEN #error "We must has interrupts" #endif #define DUTCHESS_TERMINAL_SERVER...
Civica-EE/DUTCHess
src/temperature.c
<gh_stars>0 #include <drivers/sensor.h> #include <logging/log.h> #include "temperature.h" LOG_MODULE_REGISTER(dutchess_temperature); static const struct device *dev = NULL; double dutchess_temperature_read () { int rc = 0; struct sensor_value temp; if (!device_is_ready(dev)) { LOG_ERR("De...
Civica-EE/DUTCHess
src/led.c
#include <drivers/gpio.h> #include "gpio.h" #include "led.h" #define BLINK_INTERVAL_MS 500 #define PIN 5 void dutchess_led_init () { dutchess_gpio_configure(PIN); } void dutchess_led_blink (int32_t *durations_ms, int32_t blinks) { // Blink the LED for the specified durations and number of blinks. for (...
Civica-EE/DUTCHess
src/led.h
#ifndef __DUTCHESS_LED_H__ #define __DUTCHESS_LED_H__ #include <stdint.h> void dutchess_led_init (); void dutchess_led_blink (int32_t *durations_ms, int32_t blinks); #endif // __DUTCHESS_LED_H__
Civica-EE/DUTCHess
src/tftp_eeprom.c
<gh_stars>0 #include <zephyr.h> #include <sys/printk.h> #include <drivers/eeprom.h> #include <device.h> #include "tftp.h" const struct device *dev = NULL; size_t eeprom_size; int eepromOpen(char *filename) { unsigned char buf[1]; return eeprom_read( dev, 0 , buf, 1); } int eepromRead(unsigned int *addr, unsign...
Civica-EE/DUTCHess
pct2075/zephyr/pct2075.c
<gh_stars>0 #define DT_DRV_COMPAT nxp_pct2075 #include <errno.h> #include <kernel.h> #include <drivers/i2c.h> #include <init.h> #include <drivers/sensor.h> #include <init.h> #include <sys/byteorder.h> #include <sys/__assert.h> #include <logging/log.h> LOG_MODULE_REGISTER(pct2075, CONFIG_SENSOR_LOG_LEVEL); struct p...
Civica-EE/DUTCHess
src/settings.c
<filename>src/settings.c<gh_stars>0 #include <logging/log.h> #include <settings/settings.h> #include "settings.h" LOG_MODULE_REGISTER(dutchess_settings); void dutchess_settings_init () { if (settings_subsys_init()) { LOG_ERR("Error during settings subsystem initialization\n"); return; } ...
Civica-EE/DUTCHess
src/tftp_eeprom.h
<gh_stars>0 #ifndef __TFTP_EEPROM_H__ #define __TFTP_EEPROM_H__ void dut_tftp_eeprom(void); #endif // __TFTP_EEPROM_H__
Civica-EE/DUTCHess
src/relay.h
<gh_stars>0 #ifndef __DUTCHESS_RELAY_H__ #define __DUTCHESS_RELAY_H__ void dutchess_relay_init (); void dutchess_relay_set (int value); int dutchess_relay_state (); #endif // __DUTCHESS_RELAY_H__
Civica-EE/DUTCHess
src/fs.c
<filename>src/fs.c #include <storage/disk_access.h> #include <fs/fs.h> #include <ff.h> #include <logging/log.h> #include "fs.h" LOG_MODULE_REGISTER(dutchess_fs); static FATFS fat_fs; static struct fs_mount_t mp = { .type = FS_FATFS, .fs_data = &fat_fs, }; static const char *disk_mount_pt = "/SD:"; void du...
Civica-EE/DUTCHess
src/temperature.h
#ifndef __DUTCHESS_TEMPERATURE_H__ #define __DUTCHESS_TEMPERATURE_H__ void dutchess_temperature_init (); double dutchess_temperature_read (); #endif // __DUTCHESS_TEMPERATURE_H__
Civica-EE/DUTCHess
src/tftp.h
#ifndef TFTP_H #define TFTP_H void dut_start_tftpServer(void); typedef int (*openDataType)(char *filename); typedef int (*readDataType)(unsigned int *addr, unsigned char *buf, unsigned int len); typedef int (*writeDataType)(unsigned int *addr, unsigned char *buf, unsigned int len); typedef struct { char *id; // firs...
Civica-EE/DUTCHess
src/terminal_server.h
<reponame>Civica-EE/DUTCHess #ifndef __DUTCHESS_TERMINAL_SERVER_H__ #define __DUTCHESS_TERMINAL_SERVER_H__ #include <drivers/uart.h> struct dutchess_terminal_server_cfg { struct uart_config cfg; int tcp_port; }; void dutchess_terminal_server_init (); int dutchess_terminal_server_add (struct du...
Civica-EE/DUTCHess
src/settings.h
#ifndef __DUTCHESS_SETTINGS_H__ #define __DUTCHESS_SETTINGS_H__ void dutchess_settings_init (); #endif // __DUTCHESS_SETTINGS_H__
Civica-EE/DUTCHess
src/gpio.c
#include <stdio.h> #include <drivers/gpio.h> #include "gpio.h" static const struct device *dev = NULL; void dutchess_gpio_init () { #ifdef CONFIG_BOARD_MIMXRT1020_EVK dev = device_get_binding("GPIO_1"); #endif } void dutchess_gpio_configure (int pin) { #ifdef CONFIG_BOARD_MIMXRT1020_EVK gpio_pin_configure(d...
Civica-EE/DUTCHess
src/net.c
<reponame>Civica-EE/DUTCHess #include <net/net_if.h> #include <settings/settings.h> #include "net.h" struct net_if *iface = NULL; static struct in_addr address; int network_settings_set (const char *name, size_t len, settings_read_cb read_cb, ...
Civica-EE/DUTCHess
src/relay.c
#include <stdio.h> #include <drivers/gpio.h> #include "gpio.h" #include "relay.h" #define PIN 22 // D7 on the Arduino header. void dutchess_relay_init () { dutchess_gpio_configure(PIN); } void dutchess_relay_set (int value) { // Relay is active low so invert the value here to abstract that. dutchess_gpi...
Civica-EE/DUTCHess
src/web.h
<reponame>Civica-EE/DUTCHess #ifndef __WEB_H__ #define __WEB_H__ void dutchess_web_server_init (); #endif // __WEB_H__
Civica-EE/DUTCHess
src/tftp.c
<gh_stars>0 #include <logging/log.h> LOG_MODULE_REGISTER(tftp_server, LOG_LEVEL_DBG); #include <zephyr.h> #include <errno.h> #include <stdio.h> #include <posix/sys/socket.h> #include <net/net_core.h> #include <net/net_mgmt.h> #include <net/net_event.h> #include <net/net_conn_mgr.h> #include <net/socket.h> #include ...
harryji168/dart-samples
ffi/structs/structs_library/structs.c
// Copyright (c) 2019, the Dart project authors. Please see the AUTHORS file // for details. All rights reserved. Use of this source code is governed by a // BSD-style license that can be found in the LICENSE file. #include <stdio.h> #include <stdlib.h> #include "structs.h" int main() { printf("%s\n", hello_worl...
samuelgr/Spindle
source/barrier.c
/***************************************************************************** * Spindle * Multi-platform topology-aware thread control library. * Distributes a set of synchronized tasks over cores in the system. ***************************************************************************** * Authored by <NAME>...
samuelgr/Spindle
include/spindle/init.h
<reponame>samuelgr/Spindle /***************************************************************************** * Spindle * Multi-platform topology-aware thread control library. * Distributes a set of synchronized tasks over cores in the system. ************************************************************************...
samuelgr/Spindle
include/spindle/osthread.h
/***************************************************************************** * Spindle * Multi-platform topology-aware thread control library. * Distributes a set of synchronized tasks over cores in the system. ***************************************************************************** * Authored by <NAME>...
samuelgr/Spindle
include/spindle/datashare.h
/***************************************************************************** * Spindle * Multi-platform topology-aware thread control library. * Distributes a set of synchronized tasks over cores in the system. ***************************************************************************** * Authored by <NAME> * De...
samuelgr/Spindle
include/spindle/barrier.h
/***************************************************************************** * Spindle * Multi-platform topology-aware thread control library. * Distributes a set of synchronized tasks over cores in the system. ***************************************************************************** * Authored by <NAME>...
samuelgr/Spindle
include/spindle/align.h
/***************************************************************************** * Spindle * Multi-platform topology-aware thread control library. * Distributes a set of synchronized tasks over cores in the system. ***************************************************************************** * Authored by <NAME> * De...
samuelgr/Spindle
include/spindle.h
<reponame>samuelgr/Spindle<gh_stars>1-10 /***************************************************************************** * Spindle * Multi-platform topology-aware thread control library. * Distributes a set of synchronized tasks over cores in the system. **********************************************************...
samuelgr/Spindle
source/osthread.c
/***************************************************************************** * Spindle * Multi-platform topology-aware thread control library. * Distributes a set of synchronized tasks over cores in the system. ***************************************************************************** * Authored by <NAME>...
samuelgr/Spindle
source/osthread-windows.c
/***************************************************************************** * Spindle * Multi-platform topology-aware thread control library. * Distributes a set of synchronized tasks over cores in the system. ***************************************************************************** * Authored by <NAME>...
samuelgr/Spindle
source/osthread-linux.c
/***************************************************************************** * Spindle * Multi-platform topology-aware thread control library. * Distributes a set of synchronized tasks over cores in the system. ***************************************************************************** * Authored by <NAME>...
samuelgr/Spindle
source/spawn.c
/***************************************************************************** * Spindle * Multi-platform topology-aware thread control library. * Distributes a set of synchronized tasks over cores in the system. ***************************************************************************** * Authored by <NAME>...
samuelgr/Spindle
source/datashare.c
<reponame>samuelgr/Spindle<gh_stars>1-10 /***************************************************************************** * Spindle * Multi-platform topology-aware thread control library. * Distributes a set of synchronized tasks over cores in the system. **************************************************************...
samuelgr/Spindle
include/spindle/types.h
<filename>include/spindle/types.h /***************************************************************************** * Spindle * Multi-platform topology-aware thread control library. * Distributes a set of synchronized tasks over cores in the system. *****************************************************************...
heshanlk/InterstitialAdControllerCocos2d
Example/Pods/Target Support Files/Pods-InterstitialAdControllerCocos2d_Tests/Pods-InterstitialAdControllerCocos2d_Tests-umbrella.h
#import <UIKit/UIKit.h> FOUNDATION_EXPORT double Pods_InterstitialAdControllerCocos2d_TestsVersionNumber; FOUNDATION_EXPORT const unsigned char Pods_InterstitialAdControllerCocos2d_TestsVersionString[];
heshanlk/InterstitialAdControllerCocos2d
Pod/Classes/InterstitialAdControllerCocos2d.h
<filename>Pod/Classes/InterstitialAdControllerCocos2d.h // // SimpleAdControllerCocos2d.h // JigsawHero // // Created by <NAME> on 12/9/15. // Copyright © 2015 Apportable. All rights reserved. // #import <iAd/iAd.h> @import GoogleMobileAds; @interface InterstitialAdControllerCocos2d : NSObject <ADInterstitialAdDe...
heshanlk/InterstitialAdControllerCocos2d
Example/Pods/Target Support Files/InterstitialAdControllerCocos2d/InterstitialAdControllerCocos2d-umbrella.h
<gh_stars>0 #import <UIKit/UIKit.h> FOUNDATION_EXPORT double InterstitialAdControllerCocos2dVersionNumber; FOUNDATION_EXPORT const unsigned char InterstitialAdControllerCocos2dVersionString[];
Ratheshprabakar/Top-Interview-Questions
Array/Two_sum.c
<reponame>Ratheshprabakar/Top-Interview-Questions /*Given an array of integers, return indices of the two numbers such that they add up to a specific target. You may assume that each input would have exactly one solution, and you may not use the same element twice. Given nums=[2,7,11,15], target=9, Because nums[0] +...
Ratheshprabakar/Top-Interview-Questions
Strings/Reverse_integer.c
<reponame>Ratheshprabakar/Top-Interview-Questions /*Given a 32-bit signed integer, reverse digits of an integer. Example 1: Input: 123 Output: 321 Example 2: Input: -123 Output: -321 Example 3: Input: 120 Output: 21 Note: Assume we are dealing with an environment which could only store integers within the 32-bit s...
Ratheshprabakar/Top-Interview-Questions
Array/Remove_Duplicates_from_sorted_array.c
<gh_stars>0 /*Given a sorted array nums, remove the duplicates in-place such that each element appear only once and return the new length. Do not allocate extra space for another array, you must do this by modifying the input array in-place with O(1) extra memory. Example 1: Given nums = [1,1,2], Your function shou...
Ratheshprabakar/Top-Interview-Questions
Strings/First_unique_character.c
/*Given a string, find the first non-repeating character in it and return it's index. If it doesn't exist, return -1. Examples: s = "leetcode" return 0. s = "loveleetcode", return 2. Note: You may assume the string contain only lowercase letters. */ #include<stdio.h> int main() { char input_array[100]; static int ...
Ratheshprabakar/Top-Interview-Questions
Strings/Valid_anagram.c
<reponame>Ratheshprabakar/Top-Interview-Questions /*Given two strings s and t , write a function to determine if t is an anagram of s. Example 1: Input: s = "anagram", t = "nagaram" Output: true Example 2: Input: s = "rat", t = "car" Output: false Note: You may assume the string contains only lowercase alphabets. *...
Ratheshprabakar/Top-Interview-Questions
Array/Move_zeros.c
/*Given an array nums, write a function to move all 0's to the end of it while maintaining the relative order of the non-zero elements. Example: Input: [0,1,0,3,12] Output: [1,3,12,0,0] Note: 1.You must do this in-place without making a copy of the array. 2.Minimize the total number of operations.*/ #include<stdio....
Ratheshprabakar/Top-Interview-Questions
Array/Plus_one.c
/*Given a non-empty array of digits representing a non-negative integer, plus one to the integer. The digits are stored such that the most significant digit is at the head of the list, and each element in the array contain a single digit. You may assume the integer does not contain any leading zero, except the number...
Ratheshprabakar/Top-Interview-Questions
Strings/Reverse_string.c
<filename>Strings/Reverse_string.c /*Write a function that reverses a string. The input string is given as an array of characters char[]. Do not allocate extra space for another array, you must do this by modifying the input array in-place with O(1) extra memory. You may assume all the characters consist of printable...
Ratheshprabakar/Top-Interview-Questions
Array/Contains_duplicates.c
<filename>Array/Contains_duplicates.c /*Given an array of integers, find if the array contains any duplicates. Your function should return true if any value appears at least twice in the array, and it should return false if every element is distinct. Example 1: Input: [1,2,3,1] Output: true Example 2: Input: [1,2,3,...
Ratheshprabakar/Top-Interview-Questions
Array/Single_number.c
<reponame>Ratheshprabakar/Top-Interview-Questions /*Given a non-empty array of integers, every element appears twice except for one. Find that single one. Note: Your algorithm should have a linear runtime complexity. Could you implement it without using extra memory? Example 1: Input: [2,2,1] Output: 1 Example 2: ...
Ratheshprabakar/Top-Interview-Questions
Array/Intersection_of_two_arraysII.c
/*Given two arrays, write a function to compute their intersection. Example 1: Input: nums1 = [1,2,2,1], nums2 = [2,2] Output: [2,2] Example 2: Input: nums1 = [4,9,5], nums2 = [9,4,9,8,4] Output: [4,9] Note: Each element in the result should appear as many times as it shows in both arrays. The result can be in any ...
salass00/png16_lib
include/interfaces/png16.h
<gh_stars>0 #ifndef PNG16_INTERFACE_DEF_H #define PNG16_INTERFACE_DEF_H #ifndef EXEC_TYPES_H #include <exec/types.h> #endif #ifndef EXEC_EXEC_H #include <exec/exec.h> #endif #ifndef EXEC_INTERFACES_H #include <exec/interfaces.h> #endif #ifndef LIBRARIES_PNG16_H #include <libraries/png16.h> #endif #ifdef __cplusplus #...
salass00/png16_lib
init.c
/* * AmigaOS shared library implementation of libpng 1.6.x * * Copyright (C) 2017 <NAME> <<EMAIL>> * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * 1. Redistributions of source code must retain the above c...
salass00/png16_lib
png16_vectors.c
/* * AmigaOS shared library implementation of libpng 1.6.x * * Copyright (C) 2017 <NAME> <<EMAIL>> * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * 1. Redistributions of source code must retain the above c...
salass00/png16_lib
zlib/stubs.c
<gh_stars>0 /* * AmigaOS shared library implementation of libpng 1.6.x * * Copyright (C) 2017 <NAME> <<EMAIL>> * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * 1. Redistributions of source code must retain...
salass00/png16_lib
include/proto/png16.h
<filename>include/proto/png16.h #ifndef PROTO_PNG16_H #define PROTO_PNG16_H /****************************************************************************/ #ifndef __NOLIBBASE__ extern struct Library * PNG16Base; #endif /****************************************************************************/ #ifdef __amigaos4...
salass00/png16_lib
png16.library_rev.h
#define VERSION 53 #define REVISION 1 #define DATE "25.12.2017" #define VERS "png16.library 53.1" #define VSTRING "png16.library 53.1 (25.12.2017)\r\n" #define VERSTAG "\0$VER: png16.library 53.1 (25.12.2017)"
salass00/png16_lib
pngcrush-1.8.13/pngcrush.c
/* pngcrush.c - recompresses png files * Copyright (C) 1998-2002, 2006-2017 <NAME> * (glennrp at users.sf.net) * Portions Copyright (C) 2005 <NAME> */ #define PNGCRUSH_VERSION "1.8.13" #undef BLOCKY_DEINTERLACE /* This software is released under a license derived from the libpn...
salass00/png16_lib
static/autoinit_png16_base.c
/* * AmigaOS shared library implementation of libpng 1.6.x * * Copyright (C) 2017 <NAME> <<EMAIL>> * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * 1. Redistributions of source code must retain the above c...
salass00/png16_lib
static/stubs.c
<gh_stars>0 /* * AmigaOS shared library implementation of libpng 1.6.x * * Copyright (C) 2017 <NAME> <<EMAIL>> * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * * 1. Redistributions of source code must retain...
ncantelmo/testbed
src/test.c
<gh_stars>0 #include <stdio.h> int add(int, int); int main() { printf("Hello, world!\n"); int added = add(3, 5); printf("add(3,5) result: %d\n", added); return 0; } int add(int x, int y) { return x + y; }
BlueberryMC/NativeUtil
src/main/c/net_blueberrymc_native_util_NativeAccessor.h
/* DO NOT EDIT THIS FILE - it is machine generated */ #include <jni.h> /* Header for class net_blueberrymc_native_util_NativeAccessor */ #ifndef _Included_net_blueberrymc_native_util_NativeAccessor #define _Included_net_blueberrymc_native_util_NativeAccessor #ifdef __cplusplus extern "C" { #endif /* * Class: net_...
ljnferreira/TP1ED1-2021
dataTypes.h
#ifndef _DATA_TYPES_H_ #define _DATA_TYPES_H_ typedef struct { unsigned long id; char nome[100]; char cpf[12]; char email[50]; char telefone[15]; } Cliente; typedef struct { unsigned long id; unsigned long idCliente; unsigned long idVendedor; char dataCompra[11]; float valorTotal; } NotaFiscal; t...
ljnferreira/TP1ED1-2021
main.c
<reponame>ljnferreira/TP1ED1-2021 #include <stdio.h> #include <string.h> #include <locale.h> #include <stdlib.h> #include "dataTypes.h" #include "files.h" #include "userInteraction.h" #include "utils.h" int iniciar(){ setlocale(LC_ALL, "Portuguese_Brasil"); setlocale (LC_CTYPE, "pt_BR.UTF-8"); menuPrincipal(); ...
ljnferreira/TP1ED1-2021
memoryManagement.h
#ifndef _MEMORY_MANAGEMENT_ #define _MEMORY_MANAGEMENT_ #include "dataTypes.h" int *alocaVetorInteiros(int tamanho); int *realocaVetorInteiros(int *vetor, int *tamanho, int acrescimo); /** Aloca um vetor do tipo item carrinho de tamanho definido pelo usuario, retornando um ponteiro para o mesmo. */ ItemCarrinho ...
ljnferreira/TP1ED1-2021
userInteraction.h
#ifndef _INTERATION_H_ #define _INTERATION_H_ void bemVindo(); void menuPrincipal(); void limparTela(); void creditos(); void pause(); #endif #ifndef WIN32 #define PAUSE 1 #endif
ljnferreira/TP1ED1-2021
files.h
#ifndef _FILES_H_ #define _FILES_H_ #include <stdio.h> #include "dataTypes.h" #define CLIENTE "data/Clientes.dat" #define VENDEDOR "data/Vendedores.dat" #define FORNECEDOR "data/Fornecedores.dat" #define PRODUTO "data/Produtos.dat" #define NOTA_FISCAL "data/NotasFiscais.dat" #define ITEM_NOTA_FISCAL "data/ItensNotaFi...