repo_name stringlengths 6 97 | path stringlengths 3 341 | text stringlengths 8 1.02M |
|---|---|---|
mikeadams1/oculus-drone | drone-sdk/ARDroneLib/VP_SDK/ATcodec/ATcodec.h | <gh_stars>10-100
/**
* @file ATcodec_Buffer.h
* @author <EMAIL>
* @date 2006/12/06
*/
#ifndef _AT_CODEC_INCLUDE_
#define _AT_CODEC_INCLUDE_
#include <stdarg.h>
#include <VP_Os/vp_os_types.h>
#include <ATcodec/ATcodec_Memory.h>
#define INIT_CHAR_COUNT 128
#define INIT_SON_COUNT 1
#defin... |
mikeadams1/oculus-drone | drone-sdk/Examples/Linux/Navigation/Sources/common/main_raw_capture.c | <reponame>mikeadams1/oculus-drone
/**
* @file mobile_main.c
* @author <EMAIL>
* @date 2006/05/01
*/
#include "rfcomm.h"
#include "bnep.h"
#include "common/mobile_config.h"
#include <VP_Api/vp_api.h>
#include <VP_Api/vp_api_error.h>
#include <VP_Api/vp_api_thread_helper.h>
#include <VP_Os/vp_os_print.h>
#include ... |
mikeadams1/oculus-drone | drone-sdk/Examples/Android/ardrone/project/jni/control_ack.h | /*
* control_ack.h
* ARDroneEngine
*
* Created by Mykonos on 25/03/10.
* Copyright 2010 Parrot SA. All rights reserved.
*
*/
#ifndef _PARROT_CONTROL_ACK_H_
#define _PARROT_CONTROL_ACK_H_
#include <ardrone_api.h>
void control_ack_init(void);
bool_t control_ack_configure_navdata_demo(bool_t navdata_demo);
#... |
mikeadams1/oculus-drone | drone-sdk/ARDroneLib/VP_SDK/VP_Stages/vp_stages_io_file.c | <gh_stars>10-100
/**
* \brief VP Stages. File stage declaration
* \author <NAME> <<EMAIL>>
* \author <NAME> <<EMAIL>>
* \author <NAME> <<EMAIL>>
* \version 2.0
* \date first release 16/03/2007
* \date modification 19/03/2007
*/
///////////////////////////////////////////////
// INCLUD... |
mikeadams1/oculus-drone | drone-sdk/Examples/Linux/Navigation/Sources/ihm/ihm_stages_o_gtk.c | <gh_stars>10-100
/*
* @ihm_stages_o_gtk.c
* @author m<EMAIL>
* @date 2007/07/27
*
* ihm vision thread implementation
*
*/
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
#include <termios.h>
#include <fcntl.h>
#include <errno.h>
#include <unistd.h>
#include <gtk/gtk.h>
#include <gtk/gtkcontainer.h>
#i... |
mikeadams1/oculus-drone | drone-sdk/ARDroneLib/VP_SDK/VP_Stages/vp_stages_io_file.h | <gh_stars>10-100
/**
* \brief VP Stages. File stage declaration
* \author <NAME> <<EMAIL>>
* \author <NAME> <<EMAIL>>
* \author <NAME> <<EMAIL>>
* \version 2.0
* \date first release 16/03/2007
* \date modification 19/03/2007
*/
///////////////////////////////////////////////
// INCLUD... |
mikeadams1/oculus-drone | drone-sdk/Examples/Multiplatform/Protocol/vlib.c | /*
* AR Drone demo
*
*/
#include "vlib.h"
#define HAS_UVLC_DECODE_BLOCKLINE
extern C_RESULT video_utils_init( video_controller_t* controller );
extern C_RESULT video_utils_close( video_controller_t* controller );
extern void uvlc_codec_alloc( video_controller_t* controller );
extern void uvlc_codec_free( video_c... |
mikeadams1/oculus-drone | drone-sdk/ARDroneLib/Soft/Lib/ardrone_tool/config_keys.c |
#include <Maths/maths.h>
#include <Maths/matrices.h>
#undef ARDRONE_CONFIG_KEY_IMM
#undef ARDRONE_CONFIG_KEY_REF
#undef ARDRONE_CONFIG_KEY_STR
#include <config_keys.h>
const vector31_t default_accs_offset = {{{ -2048.0f, 2048.0f, 2048.0f}}};
const matrix33_t default_accs_gain = {1.0f, 0.0f, 0.0f, 0.0f, -1.0f, 0.0f, ... |
mikeadams1/oculus-drone | drone-sdk/Examples/Multiplatform/Protocol/VP_Os/vp_os_signal.h | <gh_stars>10-100
/**
* @file signal.h
* @author <EMAIL>
* @date 2006/12/15
*/
#ifndef _SIGNAL_INCLUDE_OS_
#define _SIGNAL_INCLUDE_OS_
#include <VP_Os/vp_os_types.h>
#include <vp_os_signal_dep.h>
#ifdef __cplusplus
extern "C"
{
#endif
/**
* Initializes a mutex.
*
* @param mutex The mutex to initialize
*/
... |
mikeadams1/oculus-drone | drone-sdk/ControlEngine/iPhone/Classes/wifi.c | /*
* wifi.c
* ARDroneEngine
*
* Created by f.dhaeyer on 30/03/11.
* Copyright 2011 Parrot SA. All rights reserved.
*
*/
#include "wifi.h"
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <sys/ioctl.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h... |
dss875914213/DesignPatterns | test/28_VisitorPattern/Action.h | <reponame>dss875914213/DesignPatterns<filename>test/28_VisitorPattern/Action.h
#pragma once
#include "Person.h"
class Man;
class Woman;
class Action
{
public:
virtual void GetManConclusion(Man* concreateElementA)=0;
virtual void GetWomanConclusion(Woman* concreateElementB)=0;
};
class Success : public Action
{
publi... |
dss875914213/DesignPatterns | test/18_MemoPattern/RoleStateMemento.h | <reponame>dss875914213/DesignPatterns
#pragma once
class RoleStateMemento
{
public:
RoleStateMemento(int vit, int atk, int def);
void SetVitality(int vit);
int GetVitality();
void SetAttck(int atk);
int GetAttck();
void SetDefense(int def);
int GetDefense();
private:
int m_vit;
int m_atk;
int m_def;
};
|
dss875914213/DesignPatterns | test/26_FlyWeightPattern/WebSite.h | #pragma once
#include <string>
#include <iostream>
#include "User.h"
using namespace std;
class WebSite
{
public:
virtual void Use(User* user) = 0;
};
class ConcreteWebSite :public WebSite
{
public:
ConcreteWebSite(string name);
void Use(User* user) override;
private:
string m_name = "";
};
|
dss875914213/DesignPatterns | test/14_ObserverPattern/Secretary.h | <reponame>dss875914213/DesignPatterns<gh_stars>0
#pragma once
#include <vector>
#include <string>
#include <functional>
#include "StockObserver.h"
using namespace std;
class Subject
{
public:
void Attach(function<void(string)> observer);
//void Detach(void* observer);
void Notify();
void SetAction(string action);
... |
dss875914213/DesignPatterns | test/9_PrototypePattern/Prototype.h | #pragma once
#include <string>
#include "WorkExperience.h"
using namespace std;
class Prototype
{
public:
Prototype() {}
~Prototype() {}
virtual Prototype* clone() = 0;
};
class Resume :public Prototype
{
public:
Resume(string name);
~Resume();
void SetPersonalInfo(string sex, int age);
void SetWorkExperience... |
dss875914213/DesignPatterns | test/15_AbstractFactoryPattern/SqlServerUser.h | <gh_stars>0
#pragma once
#include "User.h"
class User;
class IUser
{
public:
virtual void Insert(User* user) = 0;
virtual User* GetUser(int id) = 0;
};
class SqlserverUser :public IUser
{
public:
void Insert(User* user) override;
User* GetUser(int id) override;
};
class AccessUser :public IUser
{
public:
void I... |
dss875914213/DesignPatterns | test/5_ProxyPattern/SchoolGirl.h | #pragma once
#include <string>
using namespace std;
class SchoolGirl
{
public:
void SetName(string name);
string GetName();
private:
string m_name;
};
|
dss875914213/DesignPatterns | test/15_AbstractFactoryPattern/User.h | #pragma once
#include <string>
#include <iostream>
#include "SqlServerUser.h"
#include "Department.h"
using namespace std;
class IUser;
class IFactory
{
public:
virtual IUser* CreateUser() = 0;
virtual IDepartment* CreateDepartment() = 0;
};
class SqlServerFactory :public IFactory
{
public:
IUser* CreateUser() ove... |
dss875914213/DesignPatterns | test/SimpleFactoryPattern/MyOperation.h | #pragma once
#include<iostream>
using namespace std;
class BaseOperation
{
public:
void SetNum1(int num1);
void SetNum2(int num2);
int GetNum1() const;
int GetNum2() const;
virtual double GetResult();
private:
int m_num1, m_num2;
};
class OperationAdd :public BaseOperation
{
virtual double GetResult() overrid... |
dss875914213/DesignPatterns | test/15_AbstractFactoryPattern/Department.h | <reponame>dss875914213/DesignPatterns
#pragma once
#include <string>
#include <iostream>
using namespace std;
class Department
{
public:
void SetID(int id);
int GetID();
void SetName(string name);
string GetName();
private:
int m_id;
string m_deptName;
};
class IDepartment
{
public:
virtual void Insert(Depar... |
dss875914213/DesignPatterns | test/14_ObserverPattern/StockObserver.h | #pragma once
#include <string>
#include "Secretary.h"
using namespace std;
class Observer
{
public:
Observer(string name);
protected:
string m_name;
};
class StockObserver :public Observer
{
public:
StockObserver(string name) : Observer(name) {}
void StopStock(string msg);
};
class NBAObserver :public Observer
... |
dss875914213/DesignPatterns | test/24_ChainOfResponsibilityPattern/Request.h | #pragma once
#include <string>
#include <iostream>
using namespace std;
class Request
{
public:
void SetRequestType(string requestType);
string GetRequestType();
void SetRequestContent(string requestContent);
string GetRequestContent();
void SetNumber(int number);
int GetNumber();
private:
string m_requestType;... |
dss875914213/DesignPatterns | test/16_StatePattern/Work.h | <filename>test/16_StatePattern/Work.h
#pragma once
#include "State.h"
class State;
class Work
{
public:
Work();
void WriteProgram();
void SetHour(int hour);
void SetWorkFinished(bool workFinished);
int GetHour();
bool GetWorkFinished();
void SetState(State* s);
private:
int m_hour = 0;
bool m_workFinished = ... |
dss875914213/DesignPatterns | test/23_OrderPattern/Waiter.h | <reponame>dss875914213/DesignPatterns<filename>test/23_OrderPattern/Waiter.h
#pragma once
#include <vector>
using namespace std;
#include "Command.h"
class Waiter
{
public:
void SetOrder(Command* command);
void CancelOrder(Command* command);
void Notify();
private:
Command* m_command;
vector<Command*> m_orders;
... |
dss875914213/DesignPatterns | test/11_AppearancePattern/Stock.h | <gh_stars>0
#pragma once
#include <string>
#include <iostream>
using namespace std;
class Stock1
{
public:
void Sell();
void Buy();
};
class Stock2
{
public:
void Sell();
void Buy();
};
|
dss875914213/DesignPatterns | test/26_FlyWeightPattern/WebSiteFactory.h | #pragma once
#include <unordered_map>
#include <string>
#include "WebSite.h"
using namespace std;
class WebSiteFactory
{
public:
WebSite* GetWebSiteCategory(string key);
int GetWebSiteCount();
private:
unordered_map<string, WebSite*> m_flyWeights;
};
|
dss875914213/DesignPatterns | test/28_VisitorPattern/Person.h | <reponame>dss875914213/DesignPatterns<gh_stars>0
#pragma once
#include "Action.h"
class Action;
class Person
{
public:
virtual void Accept(Action* visitor)=0;
};
class Man : public Person
{
public:
void Accept(Action* visitor) override;
};
class Woman : public Person
{
public:
void Accept(Action* visitor) overrid... |
dss875914213/DesignPatterns | test/9_PrototypePattern/WorkExperience.h | <gh_stars>0
#pragma once
#include <string>
using namespace std;
class WorkExperience
{
public:
WorkExperience();
WorkExperience(WorkExperience& rhs);
void SetTimeArea(string timeArea);
void SetCompany(string company);
string GetCompany();
string GetTimeArea();
private:
string m_timeArea;
string m_company;
};
|
dss875914213/DesignPatterns | test/27_InterpretPattern/Expression.h | <filename>test/27_InterpretPattern/Expression.h
#pragma once
#include <string>
#include <iostream>
#include "PlayContext.h"
using namespace std;
static int FindBlankPosition(string str);
class Expression
{
public:
void Interpret(PlayContext* context);
virtual void Excute(string key, double value) = 0;
};
class Note ... |
dss875914213/DesignPatterns | test/5_ProxyPattern/Pursuit.h | #pragma once
#include "SchoolGirl.h"
class IGiveGift
{
virtual void GiveDolls() = 0;
virtual void GiveFlowers() = 0;
virtual void GiveChocolate() = 0;
};
class Pursuit:IGiveGift
{
public:
Pursuit(SchoolGirl* mm);
void GiveDolls() override;
void GiveFlowers() override;
void GiveChocolate() override;
private:
S... |
dss875914213/DesignPatterns | test/8_FactoryPattern/Factory.h | <filename>test/8_FactoryPattern/Factory.h
#pragma once
#include "LeiFeng.h"
#include <string>
using namespace std;
class SimpleFactory
{
public:
static LeiFeng* CreateLeiFeng(string type);
};
class IFactory
{
public:
virtual LeiFeng* CreateLeiFeng() = 0;
};
class UndergraduateFactory : public IFactory
{
public:
L... |
dss875914213/DesignPatterns | test/12_BuilderPattern/Builder.h | <filename>test/12_BuilderPattern/Builder.h
#pragma once
class PersonBuilder
{
public:
virtual void BuildHead() = 0;
virtual void BuildBody() = 0;
};
class PersonThinBuilder:public PersonBuilder
{
public:
void BuildHead() override;
void BuildBody() override;
};
class PersonFatBuilder :public PersonBuilder
{
publi... |
dss875914213/DesignPatterns | test/2_StrategyPattern/CashContext.h | <reponame>dss875914213/DesignPatterns
#pragma once
#include<string>
using namespace std;
#include"Cash.h"
class CashContext
{
public:
CashContext(string type);
double GetResult(double money);
private:
CashSuper* m_cs;
};
|
dss875914213/DesignPatterns | test/9_PrototypePattern/Resume.h | <gh_stars>0
//#pragma once
//#include <string>
//using namespace std;
//
//class Resume
//{
//public:
// Resume(string name);
// void SetPersonalInfo(string sex, int age);
// void SetWorkExperience(string timeArea, string company);
// void Display();
//
//private:
// string m_name;
// string m_sex;
// int m_age;
// str... |
dss875914213/DesignPatterns | test/22_BridgePattern/HandsetBrand.h | #pragma once
#include "HandsetSoft.h"
class HandsetBrand
{
public:
void SethandsetSoft(HandsetSoft* soft);
virtual void Run() = 0;
protected:
HandsetSoft* m_pSoft;
};
class HandsetBrandN :public HandsetBrand
{
public:
void Run() override;
};
class HandsetBrandM :public HandsetBrand
{
public:
void Run() overrid... |
dss875914213/DesignPatterns | test/20_IteratorPattern/Iterator.h | <filename>test/20_IteratorPattern/Iterator.h
#pragma once
#include "Aggregate.h"
template<class object>
class Iterator
{
public:
virtual object First() = 0 ;
virtual object Next() = 0 ;
virtual bool IsDone() = 0 ;
virtual object CurrentItem() = 0;
};
template<class object>
class ConcreteAggregate;
template<class... |
dss875914213/DesignPatterns | test/26_FlyWeightPattern/User.h | #pragma once
#include <string>
#include <iostream>
using namespace std;
class User
{
public:
User(string name);
string GetName();
private:
string m_name;
};
|
dss875914213/DesignPatterns | test/27_InterpretPattern/PlayContext.h | <reponame>dss875914213/DesignPatterns<filename>test/27_InterpretPattern/PlayContext.h
#pragma once
#include <string>
#include <iostream>
using namespace std;
class PlayContext
{
public:
string GetText();
void SetText(string text);
private:
string m_text;
};
|
dss875914213/DesignPatterns | test/25_IntermediaryPattern/UnitedNations.h | #pragma once
#include <string>
#include <iostream>
#include "Country.h"
using namespace std;
class Country;
class UnitedNations
{
public:
virtual void Declare(string message, Country* colleague)=0;
};
class USA;
class Irap;
class UnitedNationsSecurityCouncil : public UnitedNations
{
public:
void Declare(string me... |
dss875914213/DesignPatterns | test/3_DecorativePattern/Person.h | <reponame>dss875914213/DesignPatterns
#pragma once
#include<string>
#include<iostream>
using namespace std;
class Person
{
public:
Person() {}
Person(string name);
virtual void Show();
private:
string m_name;
};
|
dss875914213/DesignPatterns | test/8_FactoryPattern/LeiFeng.h | <filename>test/8_FactoryPattern/LeiFeng.h
#pragma once
class LeiFeng
{
public:
void Sweep();
void Wash();
void BuyRice();
};
class Undergraduate :public LeiFeng
{
};
class Volunteer : public LeiFeng
{
};
|
dss875914213/DesignPatterns | test/19_CombinationPattern/Company.h | #pragma once
#include <string>
#include <iostream>
#include <vector>
using namespace std;
class Company
{
public:
Company(string name);
virtual void Add(Company* c) = 0;
virtual void Remove(Company* c) = 0;
virtual void Display(int depth) = 0;
virtual void LineOfDuty() = 0;
protected:
string m_name;
};
class C... |
dss875914213/DesignPatterns | test/24_ChainOfResponsibilityPattern/Manager.h | #pragma once
#include <string>
#include <iostream>
#include "Request.h"
using namespace std;
class Manager
{
public:
Manager(string name);
void SetSuperior(Manager* superior);
virtual void RequestApplications(Request* request) = 0;
protected:
string m_name;
Manager* m_superior;
};
class CommonManager :public Ma... |
dss875914213/DesignPatterns | test/23_OrderPattern/Barbecuer.h | <reponame>dss875914213/DesignPatterns<gh_stars>0
#pragma once
class Barbecuer
{
public:
void BakeMutton();
void BakeChickenWing();
private:
};
|
dss875914213/DesignPatterns | test/2_StrategyPattern/Cash.h | #pragma once
class CashSuper
{
public:
virtual double acceptCash(double money) = 0;
};
class CashNormal :public CashSuper
{
public:
double acceptCash(double money) override;
};
class CashRebate :public CashSuper
{
public:
CashRebate(double moneyDebate);
double acceptCash(double money) override;
private:
double ... |
dss875914213/DesignPatterns | test/18_MemoPattern/RoleStateCaretaker.h | #pragma once
#include "RoleStateMemento.h"
class RoleStateCaretaker
{
public:
void SetMemonto(RoleStateMemento* memento);
RoleStateMemento* GetMemonto();
private:
RoleStateMemento* m_memento;
};
|
dss875914213/DesignPatterns | test/16_StatePattern/State.h | #pragma once
#include "Work.h"
#include <iostream>
#include <string>
using namespace std;
class Work;
class State
{
public:
virtual void WriteProgram(Work* w)=0;
};
class ForenoonState :public State
{
public:
void WriteProgram(Work* w) override;
};
class NoonState :public State
{
public:
void WriteProgram(Work* w... |
dss875914213/DesignPatterns | test/28_VisitorPattern/ObjectStructure.h | #pragma once
#include <vector>
#include "Person.h"
#include "Action.h"
using namespace std;
class ObjectStructure
{
public:
void Attach(Person* element);
void Detach(Person* element);
void Display(Action* visitor);
private:
vector<Person*> elements;
};
|
dss875914213/DesignPatterns | test/25_IntermediaryPattern/Country.h | #pragma once
#include "UnitedNations.h"
#include <string>
#include <iostream>
#include "Country.h"
using namespace std;
class UnitedNations;
class Country
{
public:
Country(UnitedNations* mediator);
protected:
UnitedNations* m_mediator;
};
class USA : public Country
{
public:
USA(UnitedNations* mediator);
void De... |
dss875914213/DesignPatterns | test/20_IteratorPattern/Aggregate.h | <reponame>dss875914213/DesignPatterns
#pragma once
#include "Iterator.h"
#include <vector>
using namespace std;
template<class object>
class Iterator;
template<class object>
class Aggregate
{
public:
virtual Iterator<object>* CreateItertor() = 0;
};
template<class object>
class Iterator;
template<class object>
clas... |
dss875914213/DesignPatterns | test/17_AdapterPattern/Player.h | #pragma once
#include <string>
using namespace std;
class Player
{
public:
Player(string name) :m_name(name) {}
virtual void Attack() = 0;
virtual void Defense() = 0;
protected:
string m_name;
};
class Forwards : public Player
{
public:
Forwards(string name) : Player(name) {}
void Attack() override;
void Def... |
dss875914213/DesignPatterns | test/21_SingletonPattern/Singleton.h | <filename>test/21_SingletonPattern/Singleton.h<gh_stars>0
#pragma once
#include <mutex>
class Singleton
{
public:
static Singleton* GetInstance();
void ShowState();
private:
Singleton();
private:
static Singleton* instance;
static std::mutex mtx;
};
|
dss875914213/DesignPatterns | test/22_BridgePattern/HandsetSoft.h | #pragma once
class HandsetSoft
{
public:
virtual void Run() = 0;
};
class HandsetGame : public HandsetSoft
{
public:
void Run() override;
};
class HandsetAddressList :public HandsetSoft
{
public:
void Run() override;
};
|
dss875914213/DesignPatterns | test/10_TemplateMethodPattern/TestPaper.h | <gh_stars>0
#pragma once
#include <string>
using namespace std;
class TestPaper
{
public:
void TestQuestion1();
void TestQuestion2();
protected:
virtual string Answer1();
virtual string Answer2();
};
class TestPaperA:public TestPaper
{
protected:
string Answer1() override;
string Answer2() override;
};
class Te... |
dss875914213/DesignPatterns | test/23_OrderPattern/Command.h | #pragma once
#include <string>
using namespace std;
#include "Barbecuer.h"
class Command
{
public:
Command(Barbecuer* receiver);
virtual void ExceuteCommand() = 0;
virtual string GetType() = 0;
protected:
Barbecuer* m_receiver;
};
class BakeMuttonCommand :public Command
{
public:
BakeMuttonCommand(Barbecuer* rece... |
dss875914213/DesignPatterns | test/18_MemoPattern/GameRole.h | #pragma once
#include "RoleStateMemento.h"
class GameRole
{
public:
void StateDisplay();
void GetInitState();
void Fight();
RoleStateMemento* SaveState();
void RecoveryState(RoleStateMemento* memonto);
private:
int m_vit;
int m_atk;
int m_def;
};
|
dss875914213/DesignPatterns | test/11_AppearancePattern/Fund.h | <gh_stars>0
#pragma once
#include "Stock.h"
class Fund
{
public:
Fund();
void BuyFund();
void SellFund();
private:
Stock1* gu1;
Stock2* gu2;
};
|
dss875914213/DesignPatterns | test/2_StrategyPattern/CashFactory.h | #pragma once
#include"Cash.h"
#include<string>
using namespace std;
class CashFactory
{
public:
static CashSuper* createCashAccept(string type);
};
|
dss875914213/DesignPatterns | test/3_DecorativePattern/Finery.h | <filename>test/3_DecorativePattern/Finery.h
#pragma once
#include "Person.h"
class Finery:public Person
{
public:
Finery() { ; }
void Decorate(Person* component);
void Show() override;
protected:
Person* m_component = nullptr;
};
class TShirts :public Finery
{
public:
void Show() override;
};
class BigTrouser :p... |
dss875914213/DesignPatterns | test/test/test.h | #include <string>
#include <iostream>
using namespace std;
class IObj
{
public:
virtual int callback(string t_data) = 0;
};
class AppleObj : public IObj
{
public:
virtual int callback(string t_data) final
{
cout << "this is appleobj : " << endl;
return 0;
}
};
class BananaObj : public IObj
{
public:
virtu... |
WojciechMula/pyDAWG | dawg.h | /*
This is part of pydawg Python module.
DAWG header -- basic operataions on graph.
Author : <NAME>, <EMAIL>
WWW : http://0x80.pl/proj/pydawg/
License : 3-clauses BSD (see LICENSE)
*/
#ifndef dawg_h_included__
#define dawg_h_included__
#include "common.h"
#include "dawgnode.h"
#define DAWG_OK (0)... |
WojciechMula/pyDAWG | common.h | <filename>common.h<gh_stars>10-100
/*
This is part of pydawg Python module.
common definitions and includes
Author : <NAME>, <EMAIL>
WWW : http://0x80.pl/proj/pydawg/
License : public domain
*/
#ifndef dawg_common_h_included__
#define dawg_common_h_included__
#include <Python.h>
#include <structmem... |
WojciechMula/pyDAWG | dawgnode.h | <filename>dawgnode.h
/*
This is part of pydawg Python module.
Declaration of nodes/edges of graph.
Author : <NAME>, <EMAIL>
WWW : http://0x80.pl/proj/pydawg/
License : 3-clauses BSD (see LICENSE)
*/
#ifndef dawgnode_h_included__
#define dawgnode_h_included__
#include "common.h"
struct DAWGNode;
ty... |
WojciechMula/pyDAWG | hash/hashtable_test.c | /*
This is part of pydawg Python module.
Example of hash table template usage.
Author : <NAME>, <EMAIL>
WWW : http://0x80.pl/proj/pydawg/
License : Public domain
Date : $Date$
$Id$
*/
#include <stdlib.h>
#include <stdio.h>
#include <stdint.h>
#include <string.h>
#include "hashtable_setup.h"
#i... |
WojciechMula/pyDAWG | DAWGIterator_class.c | <gh_stars>10-100
/*
This is part of pydawg Python module.
Definition of python class DAWG iterator.
Author : <NAME>, <EMAIL>
WWW : http://0x80.pl/proj/pydawg/
License : 3-clauses BSD (see LICENSE)
*/
#include "DAWGIterator_class.h"
#include "dawgnode.h"
static PyTypeObject dawg_iterator_type;
typ... |
WojciechMula/pyDAWG | hash/hashtable.c | /*
This is part of pydawg Python module.
Hash table template body.
See hashtable_test.c and hashtable_setup.h for example
how to setup parameters.
Author : <NAME>, <EMAIL>
WWW : http://0x80.pl/proj/pydawg/
License : Public domain
Date : $Date$
$Id$
*/
#include "hashtable.h"
#define L HASH... |
WojciechMula/pyDAWG | DAWG_class.h | /*
This is part of pydawg Python module.
Declaration of Python class DAWG.
(wrapper for functions from dawg/dawgnode.{c,h})
Author : <NAME>, <EMAIL>
WWW : http://0x80.pl/proj/pydawg/
License : 3-clauses BSD (see LICENSE)
*/
#ifndef dawgclass_h_included__
#define dawgclass_h_included__
#include "daw... |
WojciechMula/pyDAWG | hash/hashtable_setup.h | <reponame>WojciechMula/pyDAWG<gh_stars>10-100
uint32_t fnv_hash(const char*);
#define HASH_TYPE uint32_t // hash value
#define HASH_KEY_TYPE char* // key type
#define HASH_DATA_TYPE int // data type [optional]
#define HASH_EQ_FUN(a, b) (strcmp((a), (b)) == 0) // key's equality
#define HASH_GET_HAS... |
WojciechMula/pyDAWG | DAWGIterator_class.h | <filename>DAWGIterator_class.h
/*
This is part of pydawg Python module.
Declaration of python class DAWG iterator.
Author : <NAME>, <EMAIL>
WWW : http://0x80.pl/proj/pydawg/
License : 3-clauses BSD (see LICENSE)
License : Public domain
*/
#ifndef pydawg_DAWGIterator_class_h_included__
#define pyda... |
WojciechMula/pyDAWG | hash/hashtable.h | /*
This is part of pydawg Python module.
Hash table template header.
See hashtable_test.c and hashtable_setup.h for example
how to setup parameters.
Author : <NAME>, <EMAIL>
WWW : http://0x80.pl/proj/pydawg/
License : Public domain
Date : $Date$
$Id$
*/
/* there is no include guard */
#def... |
WojciechMula/pyDAWG | DAWG_class.c | <reponame>WojciechMula/pyDAWG<gh_stars>10-100
/*
This is part of pydawg Python module.
Definition of Python class DAWG.
(wrapper for functions from dawg/dawgnode.{c,h})
Author : <NAME>, <EMAIL>
WWW : http://0x80.pl/proj/pydawg/
License : 3-clauses BSD (see LICENSE)
*/
#include "DAWG_class.h"
#includ... |
WojciechMula/pyDAWG | hash/hashtable_undefall.h | <reponame>WojciechMula/pyDAWG
#ifdef HASH_TYPE
# undef HASH_TYPE
#endif
#ifdef HASH_KEY_TYPE
# undef HASH_KEY_TYPE
#endif
#ifdef HASH_DATA_TYPE
# undef HASH_DATA_TYPE
#endif
#ifdef HASH_EQ_FUN
# undef HASH_EQ_FUN
#endif
#ifdef HASH_GET_HASH
# undef HASH_GET_HASH
#endif
#ifdef HASH_STATIC
# undef HASH_STATIC
#endif... |
WojciechMula/pyDAWG | dawgnode.c | /*
This is part of pydawg Python module.
Definitions of nodes/edges of graph.
Author : <NAME>, <EMAIL>
WWW : http://0x80.pl/proj/pydawg/
License : 3-clauses BSD (see LICENSE)
*/
#include "dawgnode.h"
DAWGNode*
dawgnode_new() {
DAWGNode* new = (DAWGNode*)memalloc(sizeof(DAWGNode));
if (new) {
ne... |
WojciechMula/pyDAWG | dawg_mph.c | <gh_stars>10-100
/*
This is part of pydawg Python module.
Implementation of functions related to minmal perfect hashing.
This file is included directly in dawg.c.
Algorithm is described in:
"Applications of Finite Automata Representing Large Vocabularies",
<NAME> and <NAME>,
Software Practice and Experience... |
WojciechMula/pyDAWG | pydawg.c | <filename>pydawg.c
/*
This is part of pydawg Python module.
Python module body.
Author : <NAME>, <EMAIL>
WWW : http://0x80.pl/proj/pydawg/
License : 3-clauses BSD (see LICENSE)
Date : $Date$
$Id$
*/
#include "common.h"
#include "dawgnode.h"
#include "dawg.h"
#include "DAWG_class.h"
#include "... |
WojciechMula/pyDAWG | dawg_pickle.c | <filename>dawg_pickle.c
/*
This is part of pydawg Python module.
Procedures to serialize/deserialize DAWG.
This file is included directly in dawg.c.
Author : <NAME>, <EMAIL>
WWW : http://0x80.pl/proj/pydawg/
License : 3-clauses BSD (see LICENSE)
*/
// hashtable type
#include "hash/hashtable_undefall... |
wilddylan/AsyncDisplayKitDemo | TimeLine/TimeLine/MutiImageNode/DLSImageNode/DLSImageNode.h | //
// DLSImageNode.h
// TimeLine
//
// CREATED BY: Dylan
// FOLLOW:
// BLOG: http://www.jianshu.com/users/81c4380481c1/latest_articles
// FACEBOOK: https://www.facebook.com/Dylanccccc
// TWITTER: https://twitter.com/Dylanccccc
// LICENSE: MIT
//
#import <AsyncDisplayKit/AsyncDisplayKit.h>
@c... |
wilddylan/AsyncDisplayKitDemo | TimeLine/TimeLine/FavourAndComment/CommentCell/DLFCellNode.h | //
// DLFCellNode.h
// TimeLine
//
// CREATED BY: Dylan
// FOLLOW:
// BLOG: http://www.jianshu.com/users/81c4380481c1/latest_articles
// FACEBOOK: https://www.facebook.com/Dylanccccc
// TWITTER: https://twitter.com/Dylanccccc
// LICENSE: MIT
//
#import <AsyncDisplayKit/AsyncDisplayKit.h>
@cl... |
wilddylan/AsyncDisplayKitDemo | TimeLine/TimeLine/TimeLineNode.h | <gh_stars>0
//
// TimeLineNode.h
// TimeLine
//
// CREATED BY: Dylan
// FOLLOW:
// BLOG: http://www.jianshu.com/users/81c4380481c1/latest_articles
// FACEBOOK: https://www.facebook.com/Dylanccccc
// TWITTER: https://twitter.com/Dylanccccc
// LICENSE: MIT
//
#import <AsyncDisplayKit/AsyncDispl... |
wilddylan/AsyncDisplayKitDemo | TimeLine/TimeLine/OptionNode/DLSharedNode.h | //
// DLSharedNode.h
// TimeLine
//
// CREATED BY: Dylan
// FOLLOW:
// BLOG: http://www.jianshu.com/users/81c4380481c1/latest_articles
// FACEBOOK: https://www.facebook.com/Dylanccccc
// TWITTER: https://twitter.com/Dylanccccc
// LICENSE: MIT
//
#import <AsyncDisplayKit/AsyncDisplayKit.h>
@c... |
wilddylan/AsyncDisplayKitDemo | TimeLine/TimeLine/MutiImageNode/DLMutiImageNode.h | //
// DLMutiImageNode.h
// TimeLine
//
// CREATED BY: Dylan
// FOLLOW:
// BLOG: http://www.jianshu.com/users/81c4380481c1/latest_articles
// FACEBOOK: https://www.facebook.com/Dylanccccc
// TWITTER: https://twitter.com/Dylanccccc
// LICENSE: MIT
//
#import <AsyncDisplayKit/AsyncDisplayKit.h>
... |
wilddylan/AsyncDisplayKitDemo | TimeLine/TimeLine/TimeLineDisplayLayout.h | //
// TimeLineDisplayLayout.h
// TimeLine
//
// CREATED BY: Dylan
// FOLLOW:
// BLOG: http://www.jianshu.com/users/81c4380481c1/latest_articles
// FACEBOOK: https://www.facebook.com/Dylanccccc
// TWITTER: https://twitter.com/Dylanccccc
// LICENSE: MIT
//
#import <Foundation/Foundation.h>
typ... |
cedoduarte/DuImageViewer | MainWindow.h | #ifndef MAINWINDOW_H
#define MAINWINDOW_H
#include <QMainWindow>
#include <QPixmap>
namespace Ui
{
class MainWindow;
}
class MainWindow : public QMainWindow
{
Q_OBJECT
public:
explicit MainWindow(QWidget *parent = nullptr);
~MainWindow();
private slots:
void on_actionAbrir_triggered();
void on_a... |
PiJoules/cpython-modified | Modules/_curses_panel.c | <filename>Modules/_curses_panel.c
/*
* Interface to the ncurses panel library
*
* Original version by <NAME>
*/
/* Release Number */
static const char PyCursesVersion[] = "2.1";
/* Includes */
#include "Python.h"
#include "py_curses.h"
#include <panel.h>
typedef struct {
PyObject *PyCursesError;
Py... |
PiJoules/cpython-modified | Custom/custom.c | #include "Python.h"
#include "custom.h"
PyObject* builtin_prod(PyModuleDef *module, PyObject *args){
PyObject *return_value = NULL;
PyObject *iterable;
PyObject *start = NULL;
if (!PyArg_UnpackTuple(args, "prod", 1, 2, &iterable, &start)){
return return_value;
}
return builtin_prod_imp... |
PiJoules/cpython-modified | Custom/custom.h | <gh_stars>1-10
#ifndef CUSTOM_H
#define CUSTOM_H
PyObject* builtin_prod_impl(PyModuleDef *module, PyObject *iterable, PyObject *start);
PyObject* builtin_prod(PyModuleDef *module, PyObject *args);
static const char builtin_prod_doc[] =
"prod($module, iterable, start=1, /)\n"
"--\n"
"\n"
"Return the product of a \... |
donqustix/colvox-cpp | src/chunk_location.h | #ifndef CHUNKLOCATION_H
#define CHUNKLOCATION_H
#include "constants.h"
namespace minecpp
{
class ChunkLocation
{
int x;
int z;
public:
static constexpr ChunkLocation fromWorld(int x, int z) noexcept
{
return
{
x < 0 ? (x + 1) / const... |
donqustix/colvox-cpp | src/timer.h | #ifndef TIMER_H
#define TIMER_H
#include <SDL2/SDL_stdinc.h>
namespace minecpp
{
class Timer
{
Uint32 previousTime;
public:
Uint32 calculateElapsedTime() noexcept;
};
}
#endif
|
donqustix/colvox-cpp | src/resource_loader.h | #ifndef RESOURCELOADER_H
#define RESOURCELOADER_H
namespace minecpp
{
class Config;
class ResourceContainer;
class ResourceLoader
{
ResourceContainer* resourceContainer;
public:
explicit ResourceLoader(ResourceContainer& resourceContainer) noexcept;
void load(const Config... |
donqustix/colvox-cpp | src/chunk_manager.h | <reponame>donqustix/colvox-cpp
#ifndef CHUNKMANAGER_H
#define CHUNKMANAGER_H
#include "chunk_location_hash.h"
#include <unordered_map>
#include <memory>
#include <queue>
namespace minecpp
{
class RenderData;
class ChunkLoadService;
class ChunkUpdateService;
class Chunk;
class ResourceContainer;
... |
donqustix/colvox-cpp | src/color.h | #ifndef COLOR_H
#define COLOR_H
namespace minecpp
{
namespace color
{
constexpr unsigned make(unsigned r, unsigned g, unsigned b) noexcept
{
return r | (g << 4) | (b << 8);
}
/*
* 07 12 05 10
* 07 00 05 10 & 0xF0FF 0xFFF0 0xFF0F 0xF... |
donqustix/colvox-cpp | src/mesh_shader_data.h | <filename>src/mesh_shader_data.h
#ifndef MESHSHADERDATA_H
#define MESHSHADERDATA_H
#include "raw_shader_data.h"
#include <vector>
namespace minecpp
{
struct VertexP3FRGBA8;
struct VertexP2BUV8;
template<typename T>
class MeshShaderData : public RawShaderData
{
public:
using VertexTyp... |
donqustix/colvox-cpp | src/mesh.h | <gh_stars>0
#ifndef MESH_H
#define MESH_H
#include <memory>
#include <vector>
namespace minecpp
{
struct VertexP3FRGBA8;
struct VertexP2BUV8;
template<typename T>
class MeshShaderData;
template<typename T>
class Mesh
{
public:
using VertexType = T;
private:
std::... |
donqustix/colvox-cpp | src/extract_brights_post_processing.h | #ifndef EXTRACTBRIGHTSPOSTPROCESSING_H
#define EXTRACTBRIGHTSPOSTPROCESSING_H
#include <memory>
namespace minecpp
{
class Framebuffer;
class Texture;
class ShaderProgram;
class ResourceContainer;
class RenderData;
class ExtractBrightsPostProcessing
{
std::unique_ptr<Framebuffer> f... |
donqustix/colvox-cpp | src/resource_container.h | #ifndef RESOURCECONTAINER_H
#define RESOURCECONTAINER_H
#include <unordered_map>
#include <string>
#include <memory>
#include <utility>
#include <cassert>
namespace minecpp
{
struct Resource;
class ResourceContainer
{
std::unordered_map<std::string, std::unique_ptr<Resource>> resources;
publ... |
donqustix/colvox-cpp | src/chunk_location_hash.h | <filename>src/chunk_location_hash.h
#ifndef CHUNKLOCATIONHASH_H
#define CHUNKLOCATIONHASH_H
#include "chunk_location.h"
#include <functional>
namespace std
{
template<>
struct hash<minecpp::ChunkLocation>
{
size_t operator()(const minecpp::ChunkLocation& chunkLocation) const noexcept;
};
}
#... |
donqustix/colvox-cpp | src/hdr_post_processing.h | <reponame>donqustix/colvox-cpp
#ifndef HDRPOSTPROCESSING_H
#define HDRPOSTPROCESSING_H
#include <memory>
namespace minecpp
{
class ResourceContainer;
class Texture;
class Framebuffer;
class ShaderProgram;
class RenderData;
class HdrPostProcessing
{
std::unique_ptr<Framebuffer> fbo... |
donqustix/colvox-cpp | src/god_rays_post_processing.h | <filename>src/god_rays_post_processing.h
#ifndef GODRAYSPOSTPROCESSING_H
#define GODRAYSPOSTPROCESSING_H
namespace minecpp
{
class GodRaysPostProcessing
{
};
}
#endif
|
donqustix/colvox-cpp | src/utility.h | #ifndef UTILITY_H
#define UTILITY_H
#include <sstream>
#include <string>
#include <functional>
namespace minecpp
{
namespace utility
{
std::string readFile(const std::string& filepath);
template<typename T>
T convert(const std::string& str) noexcept
{
std::istrings... |
donqustix/colvox-cpp | src/config.h | #ifndef CONFIG_H
#define CONFIG_H
#include "config_block.h"
#include "utility.h"
#include <algorithm>
#include <istream>
namespace minecpp
{
class Config
{
ConfigBlock mainBlock;
template<typename Char, typename Traits>
void load(std::basic_istream<Char, Traits>& stream, ConfigBlock&... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.