repo_name stringlengths 6 97 | path stringlengths 3 341 | text stringlengths 8 1.02M |
|---|---|---|
pengdao/simcc | simcc/memmem.h | /* Copyright (C) 1991,92,93,94,96,97,98,2000,2004 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either... |
pengdao/simcc | simcc/gettimeofday.h | <reponame>pengdao/simcc
#pragma once
#include <time.h>
#ifdef WIN32
#define _WINSOCKAPI_
#include <windows.h>
#include <WinSock2.h>
#else
#include <sys/time.h>
#endif
#ifdef WIN32
#ifndef H_GETTIMEOFDAY
#define H_GETTIMEOFDAY
inline int gettimeofday(struct timeval* tp, void* tzp) {
time_t clock;
struct tm t... |
pengdao/simcc | simcc/misc/double_buffering.h | #pragma once
#include "simcc/inner_pre.h"
#include "simcc/ref_object.h"
#include "simcc/timestamp.h"
#include <mutex>
#include <map>
namespace simcc {
class SIMCC_EXPORT DoubleBuffering {
public:
class SIMCC_EXPORT Target : public RefObject {
public:
virtual bool Initialize(const string& conf) = 0;
... |
pengdao/simcc | simcc/base64.h | #pragma once
#include "simcc/inner_pre.h"
#include <string.h>
#include <string>
namespace simcc {
class SIMCC_EXPORT Base64 {
public:
// @brief b64 encode a c-style string with len
//
// @param[in] s the input string to encode
// @param[in] len the length of the input string
// @return a newly a... |
pengdao/simcc | simcc/file_util.inl.h | #pragma once
#ifdef H_OS_WINDOWS
#include <direct.h>
#include <io.h>
#else
#include <sys/stat.h>
#include <sys/types.h>
#include <dirent.h>
#include <unistd.h>
#include <limits.h>
#endif
namespace simcc {
inline bool FileUtil::IsValidDirName(const char* szName) {
return !(szName [0] == ('.') ||
(szN... |
pengdao/simcc | simcc/exp.h | #pragma once
#ifdef H_OS_WINDOWS
H_LINK_LIB("libglueasync")
#endif
// #include "glueasync_types.h"
// #include "glueasync_common.h"
// #include "glueasync_context.h"
// #include "glueasync_status.h"
// #include "glueasync_module.h"
// #include "sync_module.h"
// #include "gas_module_manager.h"
// #include "sync_mod... |
pengdao/simcc | simcc/ini_parser.h | #pragma once
#include "simcc/inner_pre.h"
#include "simcc/gcc_list.h"
#include <string>
#include <map>
#include <vector>
namespace simcc {
class DataStream;
// @brief The class for parsing an INI format file or memory data.
// The INI file can contains comments lines which start with '#' or '//' or ';'
class SIMC... |
abhay-agarwal/DueTimer | DueTimer.h | /*
DueTimer.h - DueTimer header file, definition of methods and attributes...
For instructions, go to https://github.com/ivanseidel/DueTimer
Created by <NAME>, March, 2013.
Modified by <NAME>, June 2013.
Released into the public domain.
*/
#include "Arduino.h"
#if defined(_SAM3XA_)
#ifndef DueTimer_h
#def... |
NataliaD/SocketApp---RN | client.c | /*
* client.c
*
* Created on: 27.12.2014
* Author: <NAME>
*/
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <string.h>
#include <signal.h>
#include <sys/ipc.h>
#include <sys/msg.h>
#include <sys/shm.h>
#include <sys/types.h>
#include <sys/sem.h>
#include <sys/socket.h>
#include <netdb.... |
NataliaD/SocketApp---RN | socketApp.c | //Autoren: <NAME>
//<NAME>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <unistd.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <netdb.h>
#include <time.h>
#define SRV_PORT 7777
void client(int argc, char** argv);
void server(char** arg... |
303774813/FFCategoryKit | FFCategoryKit/Classes/yuanma.h | //
// yuanma.h
// yuanma
//
// Created by yiche on 2019/4/8.
// Copyright © 2019 yiche. All rights reserved.
//
#import <Foundation/Foundation.h>
@interface yuanma : NSObject
- (void)sayhi;
@end
|
303774813/FFCategoryKit | Example/FFCategoryKit/FFViewController.h | <filename>Example/FFCategoryKit/FFViewController.h<gh_stars>0
//
// FFViewController.h
// FFCategoryKit
//
// Created by 303774813 on 04/09/2019.
// Copyright (c) 2019 303774813. All rights reserved.
//
@import UIKit;
@interface FFViewController : UIViewController
@end
|
noldeni/arduino-spectrum-analyzer | RPi_LED_Matrix_code/Dot_test/Dot_test.c | <reponame>noldeni/arduino-spectrum-analyzer<filename>RPi_LED_Matrix_code/Dot_test/Dot_test.c
// blink.c
//
// Example program for bcm2835 library
// Blinks a pin on an off every 0.5 secs
//
// After installing bcm2835, you can build this
// with something like:
// make or gcc -o led led.c -lbcm2835
// sudo ./led
/*
... |
noldeni/arduino-spectrum-analyzer | bcm2835-1.50/examples/spi/spi.c | // spi.c
//
// Example program for bcm2835 library
// Shows how to interface with SPI to transfer a byte to and from an SPI device
//
// After installing bcm2835, you can build this
// with something like:
// gcc -o spi spi.c -l bcm2835
// sudo ./spi
//
// Or you can test it before installing with:
// gcc -o spi -I ..... |
ShenYj/JSProgressHud | JSProgressHUD/JSProgressHUD/JSProgressHUD/JSLoadIngView.h | //
// JSLoadIngView.h
// JSProgressHUD
//
// Created by ShenYj on 2017/5/27.
// Copyright © 2017年 Auko. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface JSLoadIngView : UIView
/** 文本提示 */
@property (nonatomic,strong) UILabel *contentLabel;
@end
|
ShenYj/JSProgressHud | JSProgressHUD/JSProgressHUD/JSProgressHUD/JSProgressHUD.h | //
// JSProgressHUD.h
// JSProgressHUD
//
// Created by ShenYj on 2017/5/26.
// Copyright © 2017年 Auko. All rights reserved.
//
#import <Foundation/Foundation.h>
#import <UIKit/UIKit.h>
static NSString * const kJSProgressHUDRequest = @"正在请求...";
static NSString * const kJSProgressHUDSuccess = @"请求完成...";
static N... |
ShenYj/JSProgressHud | JSProgressHUD/JSProgressHUD/ViewController.h | //
// ViewController.h
// JSProgressHUD
//
// Created by ShenYj on 2017/5/26.
// Copyright © 2017年 Auko. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface ViewController : UIViewController
@end
|
ShenYj/JSProgressHud | JSProgressHUD/JSProgressHUD/Extension/UIColor+JSExtension.h | <reponame>ShenYj/JSProgressHud
//
// UIColor+JSExtension.h
// TableView联动
//
// Created by ShenYj on 16/8/18.
// Copyright © 2016年 ___ShenYJ___. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface UIColor (JSExtension)
/**
* 设置RGB颜色
*
* @param red red: 0 ~ 255
* @param green green: 0 ~ 255
* @p... |
nuin/freebayes | src/ResultData.h | <reponame>nuin/freebayes
#ifndef __RESULT_DATA_H
#define __RESULT_DATA_H
#include <vector>
#include <ostream>
#include <iomanip>
#include "Genotype.h"
#include "Allele.h"
#include "Utility.h"
#include "AlleleParser.h"
#include "Variant.h"
#include "version_git.h"
#include "Result.h"
using namespace std;
// for sorti... |
nuin/freebayes | src/DataLikelihood.h | <filename>src/DataLikelihood.h
#ifndef __DATALIKELIHOOD_H
#define __DATALIKELIHOOD_H
#include <iostream>
#include <vector>
#include <utility> // pair
#include <algorithm>
#include <numeric>
#include <vector>
#include <iterator>
#include <cmath>
#include "Allele.h"
#include "Sample.h"
#include "Genotype.h"
#include "Ut... |
wzhhh123/Vk | Moss/src/Moss/Moss.h | <reponame>wzhhh123/Vk
#pragma once
// for use by moss applications
#include "Application.h"
#include "Log.h"
#include "EntryPoint.h" |
wzhhh123/Vk | Moss/src/Moss/Core.h | #pragma once
#ifdef MOSS_PLATFORM_WINDOWS
#ifdef MOSS_BUILD_DLL
#define MOSS_API __declspec(dllexport)
#else
#define MOSS_API __declspec(dllimport)
#endif
#else
#error Moss only support Windows!
#endif |
wzhhh123/Vk | Moss/src/Moss/Log.h | <filename>Moss/src/Moss/Log.h<gh_stars>0
#pragma once
#include <memory.h>
#include "Core.h"
#include "spdlog/spdlog.h"
namespace Moss {
class MOSS_API Log
{
public:
static void Init();
inline static std::shared_ptr<spdlog::logger>&GetCoreLogger() { return s_CoreLogger; }
inline static std::shared_ptr<spd... |
leticiamp/LPI | include/automovel.h | #ifndef AUTOMOVEL_H
#define AUTOMOVEL_H
#include <iostream>
#include <string>
#include <vector>
#include <algorithm>
class Automovel {
private:
std::string m_marca;
float m_preco;
std::string m_chassi;
long int m_dataFabricacao;
std::string m_modelo;
public:
Automovel(); //Construtor padrão
Automovel(std::st... |
leticiamp/LPI | include/propriedade.h | <gh_stars>1-10
#ifndef PROPRIEDADE_H
#define PROPRIEDADE_H
template <class T>
class Propriedade {
private:
T m_primeiroNome;
T m_segundoNome;
public:
Propriedade(T primeiroNome_, T segundoNome_); //Construtor parametrizado
~Propriedade(); //Destrutor
T getPrimeiroNome();
void setPrimeiroNome(T primeiroNome_);
... |
leticiamp/LPI | include/system.h | #ifndef SYSTEM_H
#define SYSTEM_H
#include <iostream>
#include <fstream>
#include <cstdlib>
#include <string>
#include <streambuf>
#include "automovel.h"
#include "concessionaria.h"
class System {
private:
std::vector<Concessionaria> v_lojas; //Vetor de concessionarias
public:
System(); //Construtor padrão
~Syste... |
leticiamp/LPI | include/carro.h | #ifndef CARRO_H
#define CARRO_H
#include "automovel.h"
enum Tipo_motor {
GASOLINA,
ELETRICO
};
class Carro : public Automovel {
private:
Tipo_motor m_tipo_motor;
public:
Carro();
Carro(Tipo_motor tipo_motor_);
~Carro();
Tipo_motor getTipo_motor();
void setTipo_motor(Tipo_motor tipo_motor_);
};
#endif |
leticiamp/LPI | include/moto.h | <filename>include/moto.h
#ifndef MOTO_H
#define MOTO_H
#include "automovel.h"
enum Model {
CLASSICO,
ESPORTIVO
};
class Moto : public Automovel {
private:
Model m_model;
public:
Moto();
Moto(Model model);
~Moto();
Model getModel();
void setModel(Model model);
};
#endif |
leticiamp/LPI | include/concessionaria.h | <gh_stars>1-10
#ifndef CONCESSIONARIA_H
#define CONCESSIONARIA_H
#include "automovel.h"
#include "data.h"
#include "propriedade.h"
class Concessionaria {
private:
std::string m_nome;
int m_cnpj;
int m_estoque;
std::string m_proprietario;
//Propriedade<T> m_propriedade;
std::vector<Automovel> v_carros; //Vetor ... |
leticiamp/LPI | include/caminhao.h | <filename>include/caminhao.h<gh_stars>1-10
#ifndef CAMINHAO_H
#define CAMINHAO_H
#include "automovel.h"
enum Tipo_carga {
COMUM,
PERIGOSA
};
class Caminhao : public Automovel {
private:
Tipo_carga m_tipo_carga;
public:
Caminhao();
Caminhao(Tipo_carga tipo_carga_);
~Caminhao();
Tipo_carga getTipo_carga();
vo... |
aidan-clyens/Arduino_Data_Structures | Vector/src/Vector.h | /***********************************************************/
/* Vector
/*
/* A dynamically resizable vector data structure.
/* To be used with Arduino, so this uses no C++ standard
/* library functions.
/*
/* <NAME>
/* May 29, 2018
/***********************************************************/
#ifndef... |
aidan-clyens/Arduino_Data_Structures | SearchTree/src/SearchTree.h | <reponame>aidan-clyens/Arduino_Data_Structures
/***********************************************************/
/* Search Tree
/*
/* <NAME>
/* August 20, 2018
/***********************************************************/
#ifndef SEARCH_TREE_H
#define SEARCH_TREE_H
#ifdef ARDUINO_H
#include "Arduino.h"
#else
#inc... |
aidan-clyens/Arduino_Data_Structures | HashTable/src/HashTable.h | <reponame>aidan-clyens/Arduino_Data_Structures<filename>HashTable/src/HashTable.h
/***********************************************************/
/* Hash Table
/*
/* A hash table that uses quadratic probing.
/* To be used with Arduino, so this uses no C++ standard
/* library functions.
/*
/* <NAME>
/* J... |
aidan-clyens/Arduino_Data_Structures | MaxHeap/src/MaxHeap.h | /***********************************************************/
/* Max Heap
/*
/* To be used with Arduino, so this uses no C++ standard
/* library functions.
/*
/* <NAME>
/* May 31, 2018
/***********************************************************/
#ifndef MAX_HEAP_H
#define MAX_HEAP_H
#ifdef ARDUINO_H
#i... |
aidan-clyens/Arduino_Data_Structures | QueueList/include/LinkedList.h | /***********************************************************/
/* Doubly Linked List
/*
/* Uses sentinel nodes at the head and tail of the linked
/* list.
/* To be used with Arduino, so this uses no C++ standard
/* library functions.
/*
/* <NAME>
/* May 9, 2018
/*************************************... |
aidan-clyens/Arduino_Data_Structures | QueueList/src/QueueList.h | /***********************************************************/
/* QueueList
/*
/* This is an implementation used a custom Linked List
/* class.
/* To be used with Arduino, so this uses no C++ standard
/* library functions.
/*
/* <NAME>
/* May 17, 2018
/***********************************************... |
aidan-clyens/Arduino_Data_Structures | QueueArray/src/QueueArray.h | /***********************************************************/
/* QueueArray
/*
/* This is an implementation using arrays. Currently, there
/* is no dynamic array resizing.
/* To be used with Arduino, so this uses no C++ standard
/* library functions.
/*
/* <NAME>
/* May 23, 2018
/******************... |
airbit/ArduinoMQTT | src/PubSubClient.h | /*
PubSubClient.h - A simple client for MQTT.
<NAME>
http://knolleary.net
*/
#ifndef PubSubClient_h
#define PubSubClient_h
#include <Arduino.h>
#include <Stream.h>
#include <WiFi.h>
#include <IPAddress.h>
#include "MQTT.h"
#define MQTTPROTOCOLVERSION 3
#define MQTTCONNECT 1 << 4 // Client request to connec... |
airbit/ArduinoMQTT | examples/mqtt_subscriber/.creds.h | <gh_stars>0
// creds.h template
#ifndef CREDS_H
#define CREDS_H
const char *ssid = "xxxxxxxx"; // cannot be longer than 32 characters!
const char *pass = "<PASSWORD>"; //
#endif //CREDS_H
|
airbit/ArduinoMQTT | ArduinoMQTT.h | //
// Created by 陶源 on 15/6/17.
//
#ifndef ARDUINO_MQTT_H
#define ARDUINO_MQTT_H
#include "src/MQTT.h"
#include "src/PubSubClient.h"
#endif //ARDUINO_MQTT_H
|
airbit/ArduinoMQTT | src/MQTT.h | //
// Created by 陶源 on 15/6/18.
//
#ifndef MQTT_H
#define MQTT_H
#include <Arduino.h>
#include <stdint.h>
#include <stddef.h>
#include <WString.h>
#include <Client.h>
// MQTT_MAX_PACKET_SIZE : Maximum packet size
#ifdef __CC3200R1M1RGC__
#define MQTT_MAX_PACKET_SIZE 1024
#else
#define MQTT_MAX_PACKET_SIZE 128
#endif... |
airbit/ArduinoMQTT | examples/mqtt_basic/creds.h | <reponame>airbit/ArduinoMQTT<gh_stars>0
#ifndef CREDS_H
#define CREDS_H
char *ssid = "CCTY"; // cannot be longer than 32 characters!
char *pass = "<PASSWORD>"; //
#endif //CREDS_H
|
vodka-bears/LiteOSD | inc/ascii.h | #ifndef ascii_h
#define ascii_h
#define _a 0x08
#define _b 0x10
#define _c 0x18
#define _d 0x20
#define _e 0x28
#define _f 0x30
#define _g 0x38
#define _h 0x40
#define _i 0x48
#define _j 0x50
#define _k 0x58
#define _l 0x60
#define _m 0x68
#define _n 0x70
#define _o 0x78
#define _p 0x80
#define _q 0x88
#define _r 0x90... |
didaclis/Research_QuadTree | Handout/Motor2D/ent_Player.h | #ifndef __ENT_PLAYER_H__
#define __ENT_PLAYER_H__
#include "j1Entity.h"
#include "Animation.h"
#include "j1Collision.h"
struct SDL_Texture;
enum PlayerState {
IDLE = 0,
WALKING,
UNKNOWN
};
class Player : public j1Entity
{
public:
Player(int x, int y, std::string name);
~Player();
bool Start();
bool Up... |
didaclis/Research_QuadTree | Handout/Motor2D/j1QuadTree.h | <reponame>didaclis/Research_QuadTree
#ifndef __J1QUADTREE_H__
#define __J1QUADTREE_H__
#include "j1Module.h"
class j1QuadTree
{
public:
j1QuadTree(SDL_Rect area, uint maxCol, uint lvl);
~j1QuadTree();
void DebugDraw();
private:
SDL_Rect area;
uint lvl;
uint maxCol;
};
#endif
|
didaclis/Research_QuadTree | Handout/Motor2D/j1Collision.h | #ifndef __J1COLLISION_H__
#define __J1COLLISION_H__
#include "j1Module.h"
#include <vector>
class j1Entity;
enum COLLIDER_TYPE
{
COLLIDER_NONE = -1,
COLLIDER_ENTITY,
COLLIDER_MAX
};
struct Collider
{
SDL_Rect rect;
bool to_delete = false;
COLLIDER_TYPE type;
j1Entity* callback = nullptr;
Collider(SDL_Rect ... |
didaclis/Research_QuadTree | Handout/Motor2D/j1Map.h | #ifndef __j1MAP_H__
#define __j1MAP_H__
#include <list>
#include <string>
#include "j1Module.h"
#include "j1Collision.h"
struct SDL_Texture;
// ----------------------------------------------------
struct LayerProperties
{
bool draw = true;
};
struct MapProperties
{
std::string objects_path;
};
struct MapLayer {... |
didaclis/Research_QuadTree | Handout/Motor2D/ent_NPC.h | #ifndef __ENT_NPC_H__
#define __ENT_NPC_H__
#include "j1Entity.h"
#include "Animation.h"
struct SDL_Texture;
class ent_NPC : public j1Entity
{
public:
ent_NPC(int x, int y, std::string name);
~ent_NPC();
bool Start();
bool Update(float dt);
bool CleanUp();
void OnCollision(Collider*, Collider*, float dt)... |
didaclis/Research_QuadTree | Handout/Motor2D/Quadtree.h | #ifndef __QUADTREE_H__
#define __QUADTREE_H__
#include "p2Defs.h"
#include "p2Log.h"
#include "SDL/include/SDL.h"
class Quadtree
{
public:
//Constructor
Quadtree(uint max_levels, SDL_Rect area, uint level, uint maxElements);
~Quadtree();
//subdivide the node into 4 subnodes
virtual void Subdivide() {};
void ... |
didaclis/Research_QuadTree | Handout/Motor2D/CollisionQuadTree.h | #ifndef _COLLISIONQUADTREE_H_
#define _COLLISIONQUADTREE_H_
#include "Quadtree.h"
#include "j1Collision.h"
#include <list>
class CollisionQuadTree : public Quadtree
{
public:
CollisionQuadTree(uint max_levels, SDL_Rect area, uint level, uint maxElements, CollisionQuadTree* prev = nullptr);
~CollisionQuadTree();
vo... |
didaclis/Research_QuadTree | Solution/Motor2D/j1Scene.h | <gh_stars>0
#ifndef __j1SCENE_H__
#define __j1SCENE_H__
#include "j1Module.h"
#include "CollisionQuadTree.h"
#include <vector>
class j1Scene : public j1Module
{
public:
j1Scene();
// Destructor
virtual ~j1Scene();
// Called before render is available
bool Awake(pugi::xml_node& map);
// Called before the fir... |
didaclis/Research_QuadTree | Solution/Motor2D/j1Window.h | #ifndef __j1WINDOW_H__
#define __j1WINDOW_H__
#include "j1Module.h"
struct SDL_Window;
struct SDL_Surface;
class j1Window : public j1Module
{
public:
j1Window();
// Destructor
virtual ~j1Window();
// Called before render is available
bool Awake(pugi::xml_node&);
// Called before quitting
bool CleanUp();
... |
didaclis/Research_QuadTree | Handout/Motor2D/ent_Static.h | <filename>Handout/Motor2D/ent_Static.h
#ifndef __ENT_STATIC_H__
#define __ENT_STATIC_H__
#include "j1Entity.h"
struct SDL_Texture;
class ent_Static : public j1Entity
{
public:
enum class Type {
TREE,
STATUE,
POST,
HOUSE,
CENTER,
PILAR,
CORNER,
WALL_UP_RIGHT,
WALL_UP_LEFT,
WALL_DOWN_RIGHT,
... |
didaclis/Research_QuadTree | Handout/Motor2D/j1Entity.h | #ifndef __ENTITY_H__
#define __ENTITY_H__
#include "p2Point.h"
#include "Animation.h"
#include <string>
#include "j1Collision.h"
#include "SDL_image/include/SDL_image.h"
struct SDL_Texture;
struct Collider;
struct TileSetEntity {
SDL_Rect GetTileRect(int id) const;
std::string name;
uint tilewidth = 0;
uint t... |
cydrobolt/compos | compos.c | #include <linux/module.h>
#include <linux/kernel.h>
#include <linux/init.h>
#include <linux/list.h>
#include <asm/uaccess.h>
// Import proc_fs and netfilter
#include <linux/proc_fs.h>
#include <linux/seq_file.h>
#include <linux/tcp.h>
#include <linux/netfilter.h>
#include <linux/netfilter_ipv4.h>
#include <linux/ip.h>... |
eelfroth/orca-bytebeat | base36.c | #include <stdio.h>
#include <time.h>
#define NS_PER_S 1000000000L
struct timespec ts_subtract(struct timespec time1, struct timespec time2);
int main()
{
int c;
long dt;
struct timespec ts_now, ts_last;
clock_gettime(CLOCK_REALTIME, &ts_last);
for (;;) {
clock_gettime(CLOCK_REALTIME... |
giordi91/Compressonator | Compressonator/Applications/_Plugins/Common/PluginManager.h | <filename>Compressonator/Applications/_Plugins/Common/PluginManager.h
//=====================================================================
// Copyright 2016 (c), Advanced Micro Devices, Inc. All rights reserved.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software an... |
SicklySilverMoon/C-Utils | ArrayList/TEST_FOR_ARRAYLIST.c | <reponame>SicklySilverMoon/C-Utils
#include "ArrayList.h"
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
int compare(const void* a, const void* b);
int main() {
ArrayList* list = createArrayList(1);
srand(time(NULL));
int a = rand();
printf("value of added first element: %d\n", a);
... |
SicklySilverMoon/C-Utils | ArrayList/ArrayList.c | <filename>ArrayList/ArrayList.c
#include "ArrayList.h"
#include <stddef.h>
#include <stdlib.h>
#include <stdio.h>
struct ArrayList
{
size_t size;
size_t capacity;
void** elements;
};
static void expandArrayList(ArrayList* list);
//size is final index +1, meaning add just does elements[size] = x, whereas remov... |
SicklySilverMoon/C-Utils | ArrayList/ArrayList.h | #ifndef ARRAYLIST_H
#define ARRAYLIST_H
#include <stddef.h>
typedef struct ArrayList ArrayList;
ArrayList* createArrayList(size_t capacity);
int freeArrayList(ArrayList* list);
size_t getArrayListSize(const ArrayList* list);
size_t getArrayListCapacity(const ArrayList* list);
void* getArrayListElement(ArrayList* lis... |
bguest/Segment16Sign | lib/Segment.h | <filename>lib/Segment.h
#ifndef SEGMENT_H
#define SEGMENT_H
#include <stdint.h>
#include "Pixel.h"
#define VERTICAL 0
#define DIAGONAL_RIGHT 1
#define HORIZONTAL 2
#define DIAGONAL_LEFT 3
#define ORIENTATION_COUNT 4
class Segment {
public:
Segment();
void init(Pixel pixels[], uint8_t start, uint8_t endPlus... |
bguest/Segment16Sign | lib/Segment16.h | #ifndef SEGMENT_16_H
#define SEGMENT_16_H
#include "Arduino.h"
#include <FastLED.h>
#include "Sign.h"
#include "Effects.h"
#include "Keyboard.h"
#include "Sound.h"
#include "EffectData.h"
#define SAVED_INPUT_COUNT 2
class Segment16 {
public:
Segment16();
void pushChar(uint32_t character);
Sign sign;
... |
bguest/Segment16Sign | lib/effects/RandomScroll.h | #ifndef RANDOM_SCROLL_H
#define RANDOM_SCROLL_H
#include "Effect.h"
class RandomScroll : public Effect{
public:
RandomScroll();
void reset();
void run(Sign &sign, EffectData &data, uint8_t layer);
bool pushChar(char character, uint8_t layer);
private:
};
#endif
|
bguest/Segment16Sign | lib/effects/RandomOn.h | <reponame>bguest/Segment16Sign
#ifndef RANDOM_ON_H
#define RANDOM_ON_H
#include "Effect.h"
class RandomOn : public Effect{
public:
RandomOn();
void reset();
void run(Sign &sign, EffectData &data, uint8_t layer);
bool pushChar(char character, uint8_t layer);
void randomize(uint8_t ci);
privat... |
bguest/Segment16Sign | lib/Sound.h | #ifndef SOUND_H
#define SOUND_H
#include "EffectData.h"
class Sound {
public:
void init();
void run(EffectData &data);
private:
unsigned long lastCollect;
uint16_t volume;
uint16_t freqAmp[7];
};
#endif
|
bguest/Segment16Sign | lib/effects/RainbowLetter.h | #ifndef RAINBOW_LETTER_H
#define RAINBOW_LETTER_H
#include "Effect.h"
class RainbowLetter : public Effect{
public:
RainbowLetter();
void reset();
void run(Sign &sign, EffectData &data, uint8_t layer);
bool pushChar(char character, uint8_t layer);
void signWasUpdated(Sign &sign);
void signWas... |
bguest/Segment16Sign | lib/effects/RainbowSegment.h | #ifndef RAINBOW_SEGMENT_H
#define RAINBOW_SEGMENT_H
#include "Effect.h"
class RainbowSegment : public Effect{
public:
RainbowSegment();
void reset();
void run(Sign &sign, EffectData &data, uint8_t layer);
bool pushChar(char character, uint8_t layer);
void signWasUpdated(Sign &sign);
void ran... |
bguest/Segment16Sign | lib/effects/BasicTyping.h | #ifndef BASIC_TYPING_H
#define BASIC_TYPING_H
#include "Effect.h"
class BasicTyping : public Effect{
public:
BasicTyping();
void run(Sign &sign, EffectData &data, uint8_t layer);
};
#endif
|
bguest/Segment16Sign | lib/effects/WordsEnter.h | #ifndef WORDS_ENTER_H
#define WORDS_ENTER_H
#include "Effect.h"
const uint8_t WORDS_COUNT = 20;
class WordsEnter : public Effect{
public:
WordsEnter();
void reset();
void run(Sign &sign, EffectData &data, uint8_t layer);
bool pushInsert(char character);
bool pushChar(char character, uint8_t la... |
bguest/Segment16Sign | lib/effects/Clock.h | <reponame>bguest/Segment16Sign
#ifndef CLOCK_H
#define CLOCK_H
#include "Effect.h"
class Clock : public Effect{
public:
Clock();
void reset();
void run(Sign &sign, EffectData &data, uint8_t layer);
bool pushChar(char character, uint8_t layer);
private:
bool isClock; //As Apposed to Timer
bo... |
bguest/Segment16Sign | lib/Color16.h | <gh_stars>0
#ifndef COLOR_16_H
#define COLOR_16_H
// Shamelessly mimiced from fastled.io
struct CHSV16 {
union {
struct {
union {
uint16_t hue;
uint16_t h; };
union {
uint16_t saturation;
uint16_t sat;
uint16_t s; };
union {
uint16_t value;
... |
bguest/Segment16Sign | lib/Pixel.h | <reponame>bguest/Segment16Sign
#ifndef PIXEL_H
#define PIXEL_H
#include "FastLED.h"
#include "Color16.h"
class Pixel {
public:
Pixel();
void setColor(CHSV color);
void setHue16(uint16_t hue);
void addHue16(int16_t deltaHue);
uint16_t getHue16();
CHSV getColor();
CHSV16 getHsv16();
v... |
bguest/Segment16Sign | lib/effects/Seizure.h | <reponame>bguest/Segment16Sign
#ifndef SEIZURE_H
#define SEIZURE_H
#include "Effect.h"
#define SEIZURE_COLOR_COUNT 4
class Seizure : public Effect{
public:
Seizure();
void reset();
void run(Sign &sign, EffectData &data, uint8_t layer);
bool pushChar(char character, uint8_t layer);
void randomiz... |
bguest/Segment16Sign | lib/Letter.h | #ifndef LETTER_H
#define LETTER_H
#include <stdint.h>
#include "Converter.h"
#include "Segment.h"
/**Represents a sixteen segment single letter, it looks like this
# 0 1 2 3 4 5 6
#
# --- 0 --- --- 1 --- 0
# |\ | /|
# | \ | / | 1
# | \ | / |
# | \ | / | ... |
bguest/Segment16Sign | lib/Keyboard.h | #ifndef KEYBOARD_H
#define KEYBOARD_H
#include "Arduino.h"
class Keyboard {
public:
Keyboard();
void init();
void run();
uint32_t data;
bool isAvailable;
};
#endif
|
bguest/Segment16Sign | lib/effects/RandomLetters.h | #ifndef RANDOM_LETTERS_H
#define RANDOM_LETTERS_H
class RandomLetters : public Effect{
public:
RandomLetters();
void reset();
void run(Sign &sign, EffectData &data, uint8_t layer);
bool pushChar(char character, uint8_t layer);
private:
};
#endif
|
bguest/Segment16Sign | lib/effects/SolidColor.h | #ifndef SOLID_COLOR_H
#define SOLID_COLOR_H
#include "Effect.h"
class SolidColor : public Effect{
public:
SolidColor();
void reset();
void run(Sign &sign, EffectData &data, uint8_t layer);
bool pushChar(char character, uint8_t layer);
void randomize(uint8_t ci);
private:
};
#endif
|
bguest/Segment16Sign | lib/effects/WavePixels.h | #ifndef WAVE_SEGMENT_H
#define WAVE_SEGMENT_H
#include "Effect.h"
class WavePixels : public Effect{
public:
WavePixels();
void reset();
void run(Sign &sign, EffectData &data, uint8_t layer);
bool pushChar(char character, uint8_t layer);
void invertColors();
void randomize(uint8_t ci);
pri... |
bguest/Segment16Sign | lib/effects/WaveXY.h | #ifndef WAVE_XY_H
#define WAVE_XY_H
#include "Effect.h"
class WaveXY : public Effect{
public:
WaveXY();
void reset();
void run(Sign &sign, EffectData &data, uint8_t layer);
bool pushChar(char character, uint8_t layer);
void randomize(uint8_t ci);
void invertColors();
private:
uint8_t... |
bguest/Segment16Sign | lib/effects/Scrolling.h | #ifndef SCROLLING_H
#define SCROLLING_H
#include "Effect.h"
const uint8_t SCROLL_LENGTH = 100;
class Scrolling : public Effect {
public:
Scrolling();
void reset();
void run(Sign &sign, EffectData &data, uint8_t layer);
bool pushInsert(char character);
bool pushChar(char character, uint8_t laye... |
bguest/Segment16Sign | lib/EffectData.h | <reponame>bguest/Segment16Sign<gh_stars>0
#ifndef EFFECT_DATA_H
#define EFFECT_DATA_H
#define FREQ_COUNT 7
#include "Arduino.h"
const uint8_t UINT8_MAX_2 = UINT8_MAX/2;
struct EffectData{
uint16_t tempo;
uint8_t rolloff;
uint16_t volume;
uint16_t maxVolume;
uint16_t freqAmp[FREQ_COUNT];
uint16_t maxFreq... |
bguest/Segment16Sign | lib/effects/FadedXY.h | #ifndef FADED_XY_H
#define FADED_XY_H
#include "Effect.h"
#define FADED_XY_POINT_COUNT 4
class FadedXY : public Effect{
public:
FadedXY();
void reset();
void run(Sign &sign, EffectData &data, uint8_t layer);
bool pushChar(char character, uint8_t layer);
void randomize(uint8_t ci);
void inv... |
bguest/Segment16Sign | lib/effects/RandomFade.h | <reponame>bguest/Segment16Sign
#ifndef RANDOM_FADE_H
#define RANDOM_FADE_H
#include "Effect.h"
class RandomFade : public Effect{
public:
RandomFade();
void reset();
void run(Sign &sign, EffectData &data, uint8_t layer);
bool pushChar(char character, uint8_t layer);
void signWasUpdated(Sign &sign... |
bguest/Segment16Sign | lib/effects/FadeTo.h | #ifndef FADE_TO_H
#define FADE_TO_H
#include "Effect.h"
class FadeTo : public Effect{
public:
FadeTo();
void reset();
void run(Sign &sign, EffectData &data, uint8_t layer);
bool pushChar(char character, uint8_t layer);
void randomize(uint8_t ci);
private:
uint16_t fadeTime;
uint16_t ... |
mdzakirhussain/try1 | verilog/dv/la_test1/la_test1.c | /*
* SPDX-FileCopyrightText: 2020 Efabless Corporation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless require... |
szkzn/poc-cve-2021-4034 | payload/payload.c | <reponame>szkzn/poc-cve-2021-4034
#include <unistd.h>
#include <stdlib.h>
#include <stdio.h>
// build with gcc payload.c -o payload.so -shared -fPIC
void gconv() {}
void gconv_init() {
setuid(0);
setgid(0);
setenv("PATH", "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin", 1);
char* argv[]... |
Dish1306/reportlab-mirror | src/rl_addons/renderPM/gt1/gt1-namecontext.c | /* A module for a simple "name context", i.e. lisp-style atoms */
#include "gt1-misc.h"
#include "gt1-namecontext.h"
#if defined(_WIN32) || defined(macintosh) || defined(__APPLE__)
# include <string.h>
#endif
/* btw, I do not know who wrote the following comment. I modified this
file somewhat from gimp's app/proc... |
Dish1306/reportlab-mirror | src/rl_addons/renderPM/gt1/gt1-misc.h | /* What allocation functions are we going to use? */
#ifndef __GT1_MISC_H__
#define __GT1_MISC_H__
#include <stdlib.h> /* for malloc, etc. */
#if defined(macintosh) || defined(__APPLE__) || defined (__linux__) || defined(__FreeBSD_kernel__) || defined(__GNU__)
# include <string.h> /* for memcpy() */
#endif
#define g... |
UnofficialJuliaMirror/SDE.jl-0d6d677f-8475-5ebf-bbf8-769304748c2b | deps/sigma.c | <reponame>UnofficialJuliaMirror/SDE.jl-0d6d677f-8475-5ebf-bbf8-769304748c2b
#include <math.h>
#include <stdio.h>
int maxi(int x, int y)
{
return (x > y ? x : y);
}
int mini(int x, int y)
{
return (x < y ? x : y);
}
double hat(double x)
{
double z = 1.-fabs(2.*x-1.); /* (1 -|2x-1|)+ */
return z > 0.0 ? z : 0.0;... |
mungurk/binlex | src/decompiler.h | #include <elf.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <errno.h>
#include <capstone/capstone.h>
#ifndef DECOMPILER_H
#define DECOMPILER_H
#define DECOMPILER_TYPE_FUNCS 0
#define DECOMPILER_TYPE_BLCKS 1
#define DECOMPILER_TYPE_UNSET 2
#define DECOMPILER_TYPE_ALL 3
#define DECOMPILER_MA... |
loki-project/loki-storage-server | httpserver/omq_server.h | <reponame>loki-project/loki-storage-server
#pragma once
#include <cstdint>
#include <memory>
#include <string>
#include <string_view>
#include <vector>
#include <oxenmq/oxenmq.h>
#include <nlohmann/json_fwd.hpp>
#include "oxenmq/bt_serialize.h"
#include "sn_record.h"
namespace oxen {
class ServiceNode;
class Reque... |
loki-project/loki-storage-server | httpserver/request_handler.h | #pragma once
#include "channel_encryption.hpp"
#include "client_rpc_endpoints.h"
#include "http.h"
#include "onion_processing.h"
#include "oxen_common.h"
#include "oxend_key.h"
#include "service_node.h"
#include "string_utils.hpp"
#include <chrono>
#include <forward_list>
#include <future>
#include <string>
#include ... |
loki-project/loki-storage-server | httpserver/reachability_testing.h | #pragma once
#include "oxen_common.h"
#include "oxend_key.h"
#include "sn_record.h"
#include <chrono>
#include <queue>
#include <random>
#include <unordered_map>
#include <unordered_set>
#include <vector>
namespace oxen {
namespace detail {
// Returns std::greater on the std::get<N>(v)th element value.
template <t... |
loki-project/loki-storage-server | httpserver/http.h | #pragma once
#include <string>
#include <string_view>
#include <unordered_map>
#include <utility>
#include "string_utils.hpp"
/// Namespace for http constants/types
namespace oxen::http {
using namespace std::literals;
// HTTP response status code
using response_code = std::pair<int, std::string_view>;... |
dragon-archer/2048 | Include/Pch.h | #ifndef _PCH_H
#define _PCH_H
#include <QApplication>
#include <QHeaderView>
#include <QKeyEvent>
#include <QLabel>
#include <QLocale>
#include <QMainWindow>
#include <QMenuBar>
#include <QMessageBox>
#include <QStatusBar>
#include <QTableWidget>
#include <QTranslator>
#ifndef NDEBUG
#include <QDebug>
#endif
#inc... |
dragon-archer/2048 | Include/Common.h | <reponame>dragon-archer/2048
#ifndef _COMMMON_H
#define _COMMMON_H 1
#include <Pch.h>
size_t ReadBestScore(const std::string& filename = std::string());
bool WriteBestScore(const std::string& filename, size_t bestScore = 0);
#endif /* _COMMON_H */
|
dragon-archer/2048 | Include/MainWindow.h | #ifndef MainWindow_H
#define MainWindow_H
#include <Pch.h>
#include <Common.h>
class MainWindow : public QMainWindow
{
Q_OBJECT
public:
MainWindow(QWidget *parent = nullptr);
~MainWindow();
void keyPressEvent(QKeyEvent* event);
void print();
bool moveUp();
bool moveDown();
bool moveLeft();
bool moveRight()... |
serisman/arduboy-hangma | Hangman/EEPROM_Utils.h | <gh_stars>0
#ifndef EEPROM_UTILS_H
#define EEPROM_UTILS_H
#include <EEPROM.h>
#define EEPROM_START (EEPROM_STORAGE_SPACE_START + 72)
void EEPROM_saveScore(uint8_t w, uint8_t l) {
EEPROM.update(EEPROM_START+2, w);
EEPROM.update(EEPROM_START+3, l);
}
uint8_t EEPROM_getWins() {
return EEPROM.read(EEPROM_STA... |
serisman/arduboy-hangma | Hangman/sounds.h | #ifndef SOUNDS_H
#define SOUNDS_H
const uint16_t soundCorrect[] PROGMEM = {NOTE_F4,100,NOTE_A4,150,TONES_END};
const uint16_t soundWin[] PROGMEM = {NOTE_E4,100,NOTE_F4,100,NOTE_C5,250,TONES_END};
const uint16_t soundIncorrect[] PROGMEM = {NOTE_A4,100,NOTE_F3,150,TONES_END};
const uint16_t soundDead[] PROGMEM = {NOTE_D... |
RamsayBoy/Minishell-C | include/parser.h | #ifndef PARSER_H_INCLUDED
#define PARSER_H_INCLUDED
typedef struct {
char * filename;
int argc;
char ** argv;
} tcommand;
typedef struct {
int ncommands;
tcommand * commands;
char * redirect_input;
char * redirect_output;
char * redirect_error;
int background;
} tline;
extern tline * tokenize(char *str);
#... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.