text
stringlengths
8
6.88M
#ifndef ID_STRING_HPP_ #define ID_STRING_HPP_ #include "Text.hpp" struct ID_OR_STRING { WORD m_ID; std::wstring m_Str; ID_OR_STRING() : m_ID(0) { } ID_OR_STRING(WORD ID) : m_ID(ID) { } ID_OR_STRING(LPCWSTR Str) { if (IS_INTRESOURCE(Str)) ...
struct Shape { virtual float area() const noexcept = 0; virtual float circ() const noexcept = 0; }; struct Circle : public Shape { float R; Circle(float r) : R(r){} virtual float area() const noexcept { return 3.14*R*R; } virtual float circ() const noexcept { return 2.0*3.14*R; } }; struct Re...
// including the JeeLib (JeeNode library), Ports (JeeNode ports library), // and the Wire I2C library #include <JeeLib.h> #include <Ports.h> #include <Wire.h> /* The A2,A1,A0 pins are connected to ground, therefore the address is 0x20 * The address is 0b0100[A2][A1][A0] */ #define IOAddress 0x20 // Addresses for the ...
#include<iostream> using std::cout; using std::cin; using std::endl; int main() { int result = 12/3 * 4 + 5 *15 + 24%4/2; cout << result << endl; return 0; }
#include "common.h" #include "bintable.h" #include "pythonutils.h" #include "numpy.h" #include "exceptions.h" #include <vector> #include <string> #include <cstdio> #include <pybind11/pybind11.h> #include <numpy/arrayobject.h> namespace py = pybind11; using namespace NAMESPACE_BINTABLE; void _delete_columns(std::vect...
#pragma once #include <OGLML/Texture2D.h> #include <OGLML/Shader.h> #include <glm.hpp> #include <gtc/matrix_transform.hpp> #include <array> namespace oglml { class Sprite { public: Sprite(); ~Sprite() = default; void SetTexture(Texture2D& texture); void SetShader(Shader& shader); void SetScreenSize(f...
// Created by: Eugeny MALTCHIKOV // Copyright (c) 2018 OPEN CASCADE SAS // // This file is part of Open CASCADE Technology software library. // // This library is free software; you can redistribute it and/or modify it under // the terms of the GNU Lesser General Public License version 2.1 as published // by the Free S...
#pragma once #include <AbstractLogListener.h> namespace breakout { class ConsoleLogListener : public AbstractLogListener { public: ConsoleLogListener(const uint16_t& levelMask, const uint16_t& channelMask); virtual ~ConsoleLogListener(); protected: virtual void Write(const st...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- * * Copyright (C) 1995-2006 Opera Software AS. All rights reserved. * * This file is part of the Opera web browser. * It may not be distributed under any circumstances. */ #ifndef MODULES_FORMS_FORMS_MODULE_H #define MODULES_FORMS_FORMS_M...
#include<bits/stdc++.h> using namespace std; int stepup(int sc, int start, int end); int main(){ int end = 1; cout<<(0, 0, end); return 0; } int stepup(int sc, int start, int end){ if (abs(sc) > (end)) return INT_MAX; if (sc == end){ return start; } int pos = stepup(sc + start + 1, start + 1, end)...
#include <stdio.h> #include <stdlib.h> #include <string.h> #include "struc.h" //alocarea si realocarea memoriei student* reloc(student *a,int n){ a=(student*)realloc(a,n*sizeof(student)); if(!a){ printf("\a\nNu sa alocat memorie!\n"); system("pause"); exit(1); } return a; } //Versiunea 1 de citire Manual voi...
// Created on: 2013-11-11 // Created by: Anastasia BORISOVA // Copyright (c) 2013-2014 OPEN CASCADE SAS // // This file is part of Open CASCADE Technology software library. // // This library is free software; you can redistribute it and/or modify it under // the terms of the GNU Lesser General Public License version 2...
#pragma once #include <glm/glm.hpp> #include "EventHandeling\Event.h" #include "EventHandeling\EventHandeler.h" #include <memory> /* From learnopengl.com */ class Camera : public EventHandeler<MovementEvent>, public EventHandeler<MouseMovementEvent> { public: Camera(glm::ivec2 dimensions, glm::vec3 position, float ...
#include "ClientHandler.h" #ifdef CLIENT_H int main() { } #endif
#ifndef BOARD_H #define BOARD_H #include "brick.h" class Brick; class Board { public: int score;//当前分数 int scoreRank[10]; Brick *brick;//下落的方块 char map[100][100];//保存地图信息 Board(); void addTomap();//将下落到底的块更新到map bool endJudge();//判断是否游戏结束 }; #...
#ifndef CPP_2020_RANDOM_FOREST_RANDOM_FOREST_H #define CPP_2020_RANDOM_FOREST_RANDOM_FOREST_H #include <iostream> #include <string> #include <cstdlib> #include <queue> #include <thread> #include <mutex> #include <cmath> #include "data.h" #include "decision_tree.h" class tree_queue { public: std::queue<Tree> bas...
#ifndef PIONEER_H #define PIONEER_H #include <iostream> #include <string> #include <vector> #include <QtSql> #include <QtWidgets> using namespace std; class Pioneer { public: Pioneer(); //Default constructor Pioneer(string pName, string s, int birthY, int deathY, string desc, QByteArray image); ...
#include "core/pch.h" #include "modules/ecmascript/carakan/src/util/es_codegenerator_arm.h" void Output(ES_CodeGenerator &cg, const char *name) { unsigned *code = cg.GetBuffer(); printf("const MachineInstruction cv_%s[] =\n{\n", name); for (unsigned index = 0; index < cg.GetBufferUsed(); ++index) printf("...
// Example 8.1 Operator overloading : class Vec2 #include <iostream> #include <string> #include "./Vec2.h" using namespace std; //============================== int main() { { cout << "\nVec2 constructor, ==, !=, output :\n\n"; Vec2 a(1.0, 2.0), b(1.0, 2.0), c(2.0, 1.0); // cout...
/* * Stopping Times * Copyright (C) Leonardo Marchetti 2011 <leonardomarchetti@gmail.com> */ #ifndef _STOPPING_TIMES_H_ #define _STOPPING_TIMES_H_ #include <boost/function.hpp> #include <boost/bind.hpp> #include <utility> #include "maximizer.h" #include "sde.h" #include "de-solver.h" #include "maximizer2D.h" #defin...
#ifndef SIMGRAPHICS_SIMROOT_H #define SIMGRAPHICS_SIMROOT_H #include "include/SimPrerequisites.h" #include "include/SimSingleton.h" /* * @brief Root is used to load modules of the SimEngine ,such as the render module; */ namespace sim { class SIM_ROOT_EXPORT Root : public Singleton<Root>{ public: // @param init_fil...
// Lexer for Makefile of gmake, nmake, bmake, qmake #include <string.h> #include <assert.h> #include <ctype.h> #include "ILexer.h" #include "Scintilla.h" #include "SciLexer.h" #include "WordList.h" #include "LexAccessor.h" #include "Accessor.h" #include "StyleContext.h" #include "CharacterSet.h" #incl...
#include "Persona.h" #include "Poder.h" #ifndef MAESTRO_H #define MAESTRO_H class Maestro:public Persona{ public: Poder* poder; Maestro(); Maestro(string,string,int,string,Elemento*, Poder*); Poder* getPoder(); virtual string toString(); ~Maestro(); }; #endif
#include "face.h" Face::Face() : QListWidgetItem(0) { } void Face::assignID(int id) { this->id = id; } void Face::assignHalfEdge(HalfEdge *halfEdge) { this->halfEdge = halfEdge; } void Face::assignColor(glm::vec4 color) { this->color = color; } HalfEdge* Face::getHalfEdge() { return halfEdge; } g...
#include "RecognizerListener.hh" //#include "str.hh" RecognizerListener::RecognizerListener(msg::InQueue *in_queue, RecognizerStatus *recognition) { this->m_in_queue = in_queue; this->m_recognition = recognition; this->m_stop = false; this->m_enabled = true; this->m_t...
void DisplayModeMain() { if (ReadValues.newValues == 1 && ReadValues.ButtonPressed == FuncStop) { #if defined(DEBUGMODE) Serial.print("DisplayMode | Changed to: "); #endif switch (Settings.LedEffects[Settings.EffectNumber].DisplayMode) { case Left: Settings.LedEffects[Settings.EffectNumber].DisplayMod...
// 问题的描述:旋转词 // 给定两个字符串,判断它们是否互为旋转词,即A字符串前面一部分字符移到后面形成的新字符串与B字符串相同 // 如 A = "1234", B = "2341"就是其中的一个旋转词 // 关键点在于(A + A)形成的新字符串,包含了A所有的旋转词 // 测试用例有3组: // 1、空字符串 // 输入: // string sequence1 = ""; // string sequence2 = ""; // 输出:false // 2、A、B互为旋转词 // 输入: // string sequence1 = "abcd"; // s...
#include "General.h" #include "Log.h" #include "Figure.h" using namespace RsaToolbox; #include <QDebug> #include <QString> #include <QtTest> #include <QSignalSpy> #include <QScopedPointer> #include <QWidget> #include <QDialog> ComplexRowVector makeComplex(QRowVector mag, QRowVector phase_rad); class test_smoothSqr...
#include "SceneBase.h" #include "GL\glew.h" #include "shader.hpp" #include "MeshBuilder.h" #include "Application.h" #include "Utility.h" #include "LoadTGA.h" #include <sstream> SceneBase::SceneBase() { } SceneBase::~SceneBase() { } void SceneBase::Init() { // Blue background glClearColor(0.0f, 0.0f, 0.4f, 0.0f); ...
#include <iostream> using std::string; class Container{ public: class NumberBook{ public: string name, lastName; int number; string birthDay; NumberBook(string name, string lastName, int number, string birthDay){ setName(name); ...
#include "SettingsDialog.h" SettingsDialog::SettingsDialog(wxWindow* parent, wxFont& font): SettingsDialog1(parent) { SetTitle(_("Settings")); if(font.IsOk()){ setFont(font); this->settingsFont = font; } } void SettingsDialog::setFont(wxFont& font) { fontPicker->SetSelectedFont(font);...
/**************************************************************************** ** Meta object code from reading C++ file 'accountcreation.h' ** ** Created by: The Qt Meta Object Compiler version 67 (Qt 5.13.2) ** ** WARNING! All changes made in this file will be lost! **********************************************...
#ifndef _SYSLOG_WIN32_INCLUDED #define _SYSLOG_WIN32_INCLUDED 1 #include <windows.h> #include <stdio.h> #include <stdlib.h> #include <memory.h> #include <string.h> /* http://www.codeproject.com/system/mctutorial.asp?df=100&forumid=15526&exp=0&select=1238561 */ #include <tchar.h> #include "messages.h"...
// // Created by 史浩 on 2020-01-12. // #ifndef NDK_OPENGLES_GLRENDER_H #define NDK_OPENGLES_GLRENDER_H #include <android/native_window.h> #include "egl/IGLRender.h" #include "egl/EGLCore.h" #include "egl/WindowSurface.h" #include "ScreenFilter.h" #include "Triangle.h" #include <android/native_window.h> #include <andro...
#pragma once #include "Forms/KeyForm/KeyForm.h" class QWidget; namespace Ui { class ScaleForm; } class UniqueAnswerOptionsKeyForm : public KeyForm { Q_OBJECT signals: void scaleDeleted(const QString &scaleName); public: explicit UniqueAnswerOptionsKeyForm(Scale *scale, ...
#include <QTimer> #include <QtConcurrentRun> #include <QFile> #include "hashchecker.h" #include "../VFS/IFile.h" #include "../Md5Utils/Md5Utils.h" #include <assert.h> HashChecker::HashChecker(QObject *parent) : QObject(parent) { connect(&watcher, SIGNAL(finished()), this, SLOT(OnCheckFinish())); assert(!wo...
// AutoGetAwsFileDlg.h : 头文件 // #pragma once // CAutoGetAwsFileDlg 对话框 class CAutoGetAwsFileDlg : public CDialog { // 构造 public: CAutoGetAwsFileDlg(CWnd* pParent = NULL); // 标准构造函数 // 对话框数据 enum { IDD = IDD_AUTOGETAWSFILE_DIALOG }; protected: virtual void DoDataExchange(CDataExchange* pDX); //...
// -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=// // Определение старшей цифры числа n, если его разрядность неизвестна // Determination of the most significant digit of the number n, if its capacity is unknown // Функция log10 вычисляет десятичный логарифм // V 1.0 // -=-=-=-=-=-=-=-=-=-=...
#ifndef CAPP_MISC_H #define CAPP_MISC_H #include <iostream> #include <string> #include <stack> #include <vector> #include <queue> #include <unordered_map> #include <unordered_set> #include <algorithm> #include <limits.h> #include <sstream> #include <memory> using namespace std; struct Node{ int val...
#include <QDebug> // RsaToolbox includes #include "General.h" #include "VnaSegmentedSweep.h" #include "VnaChannel.h" #include "Vna.h" using namespace RsaToolbox; // Qt includes // #include <Qt> /*! * \class RsaToolbox::VnaSegmentedSweep * \ingroup VnaGroup * \brief The \c %VnaSegmentedSweep class * configures a...
#include<iostream> #include<queue> #include<stack> #include<vector> #include<stdio.h> #include<algorithm> #include<string> #include<string.h> #include<sstream> #include<set> #include<map> #include<iomanip> #define N 505 using namespace std; int root[N]; int key[N]; int cost[N]; struct edge{ int from, to,len; edge(...
#ifndef VECTOR_H #define VECTOR_H #include <algorithm> #include <iostream> #include <memory> template<typename T, typename A>struct vector_base { A allocator; T* elements; int length; int space; vector_base(){}; vector_base(A& a, int n): allocator{a}, elements{a.allocate(n)}, length{n}...
#include <vector> template<typename T, std::size_t N> class matrix { public: static constexpr std::size_t order = N; using value_type = T; using iterator = typename std::vector<T>::iterator; using const_iterator = typename std::vector<T>::const_iterator; matrix() = default; matrix(matrix&&) = ...
// Copyright Epic Games, Inc. All Rights Reserved. /*=========================================================================== Generated code exported from UnrealHeaderTool. DO NOT modify this manually! Edit the corresponding .h files instead! ========================================================================...
#ifndef _CONTROLLER_MANAGER #define _CONTROLLER_MANAGER #include <sdl2/SDL.h> #include <map> #include <iostream> #include <glm/glm.hpp> #define controller_manager controller_manager_t::instance() struct controller_manager_t { static controller_manager_t *instance(); void set_keydown(const SDL_Keycode keycod...
#include"stdio.h" #include"conio.h" void main(){ clrscr(); int i, end=10; printf("*\n"); for(i=0; i<=end; i++){ printf("*"); for(int j=1; j<=i; j++){ if(i==end) printf("*"); else printf(" "); } printf("*\n"); } getch(); }
#include <iostream> #include <vector> #include <string> using namespace std; class GreatFairyWar { public: int getSumDps(int pos,int size,vector <int> dps) { int sumDps = 0; for (int i=pos; i<size; ++i) { sumDps += dps.at(i); } return sumDps; } int minHP(vector <int> dps, vector <int> hp) { int su...
#include <iostream> using namespace std; int dp[501][501]; int sp[501][501]; int nums[501]; int main() { ios_base::sync_with_stdio(false); cin.tie(0); int tc; cin >> tc; while (tc--) { int n; cin >> n; for (int i = 1; i <= n; i++) { cin >> sp[i][i]...
/**************************************************************************** ** Copyright (C) 2017 Olaf Japp ** ** This file is part of FlatSiteBuilder. ** ** FlatSiteBuilder is free software: you can redistribute it and/or modify ** it under the terms of the GNU General Public License as published by ** the Free S...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 1995-2012 Opera Software AS. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. ** */ #include "core/pch.h" #ifdef CANVAS3D_SUPPORT #include "modu...
#include <algorithm> #include <iostream> #include <string> #include <vector> #include <unordered_map> #include <unordered_set> using namespace std; #define cn(x) cout << #x << " = " << x << endl; void print(unordered_set<int> & set){ cout << set.size() << " "; for(auto x : set){ cout << x+1 << " "; } cout << e...
#include <stdio.h> #include <iostream> #include <math.h> #include <algorithm> #include <memory.h> #include <set> #include <map> #include <queue> #include <deque> #include <string> #include <string.h> #include <vector> typedef long long ll; typedef long double ld; typedef unsigned long long ull; const ld PI = acos(-1.)...
// To find the lowest common ancestor of a binary serach tree node * lca(node * root, int v1, int v2) { if (root == NULL || root->data == v1 || root->data == v2) return root; node * left = lca(root->left, v1, v2); node * right = lca(root->right, v1, v2); if (left != NULL && right != NULL) ...
#include <iostream> #include <stdexcept> #include "am_pm_clock.h" /* * Default constructor - initial time should be midnight */ am_pm_clock::am_pm_clock(): hours(12),minutes(0),seconds(0),am(true){} /* * Constructor - sets fields to the given argument values */ am_pm_clock::am_pm_clock(unsi...
namespace wrapper { struct Base {}; struct Derived : public Base {}; void Fun(Base* pObj) { // compare the two type_info objects corresponding // to the type of *pObj and Derived if (typeid(*pObj) == typeid(Derived)) { // ... aha, pObj actually points to a Derived object } } class TypeInfo {...
#ifdef _DEBUG #pragma comment(lib, "opencv_world440d.lib") #pragma comment(lib, "jsoncppd.lib") #else #pragma comment(lib, "opencv_world440.lib") #pragma comment(lib, "jsoncpp.lib") #endif #include <direct.h> #include <io.h> #include <json/json.h> #include <stdio.h> #include <stdlib.h> #include <iostrea...
#include <iostream> #include <cmath> using namespace std; int main(){ long long int mid, c, d, n, i, cn; double root; cin >> cn; for (i=0; i<cn; i++){ cin >> n; cout << "Case " << i+1 << ": "; root = sqrt (n); if (root - floor (root) == 0){ if (n%2==0) cout << root << " " << 1 << endl; else ...
// stdafx.h : include file for standard system include files, // or project specific include files that are used frequently, but // are changed infrequently // #pragma once #define WIN32_LEAN_AND_MEAN #include <stdio.h> #include <tchar.h> #include <iostream> #include <stdlib.h> #include <windows.h> #include <commdlg....
#include "static_lib2/sublib2.h" // #include "interface_lib2/sublib2.h" int main(int argc, char *argv[]) { sublib2 hi; hi.print(); // sublib2 howdy; // howdy.print(); return 0; }
#include<stdio.h> #include<conio.h> #include<string.h> #include<stdlib.h> #include<cstdio> using namespace std; int func(int a) { return (a++); } int i; int main() { /* int i; for(i=1;i<4;i++) switch(i) case 1: printf("%d",i);break; { case 2: printf("%d",i);bre...
#ifndef PSEUDOGENOMEGENERATORBASE_H_INCLUDED #define PSEUDOGENOMEGENERATORBASE_H_INCLUDED #include "../../pseudogenome/DefaultPseudoGenome.h" #include "../../pseudogenome/PseudoGenomeInterface.h" #include "../../readsset/DefaultReadsSet.h" #include "../SeparatedPseudoGenome.h" using namespace PgSAHelpers; using names...
#include "../src/Logger.hpp" int main() { Logger log( "test", "./logs" ); log.writeInfo( "testinfo" ); log.writeWarn( "testwarn" ); log.writeDebug( "testdebug" ); log.writeError( "testerror" ); return 0; }
#include "GnSystemPCH.h" #include "GnPath.h" #ifdef WIN32 bool GnGetCurrentDirectory(gchar* pcStr, gtuint uiMaxSize) { if( GetCurrentDirectoryA( uiMaxSize, pcStr ) == 0 ) return false; return true; } #else #endif gsize GnPath::ConvertToAbsolute(char* pcAbsolutePath, size_t stAbsBytes, const char*...
#pragma once #include "..\Common\Pch.h" #include "..\Graphic\Direct3D.h" #include "..\RenderResource\InputLayout.h" class Sphere : public InputLayout { public: Sphere(); ~Sphere(); void Initialize(); void SetBuffer(); private: vector<IL_PosTexNor> mVertexData; vector<UINT> mIndexData; virtual void ...
#ifndef CoinConf_H #define CoinConf_H #include "BaseCoinConf.h" #include "Table.h" class CoinConf : public BaseCoinConf { public: public: static CoinConf* getInstance(); virtual ~CoinConf(); virtual bool GetCoinConfigData(); Cfg* getCoinCfg() { return &coinCfg; } int getWinCount(int64_t &bankerwin, int64_t &pl...
#include <iostream> #include <fstream> #include <string.h> #include <stdio.h> #include <stdlib.h> #include <map> #include <vector> #include <algorithm> #include <math.h> #define pb push_back using namespace std; int n; void input() { scanf("%d", &n); } // use for loop /*int calcFactorial(int n) { int factori...
/* * Copyright (C) 2008 The Android Open Source Project * * 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 requir...
/* TouchKeys: multi-touch musical keyboard control software Copyright (c) 2013 Andrew McPherson This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at you...
#include <iostream> #include <string> #include <vector> #include <sstream> #include <queue> #include <unordered_map> #include <map> using namespace std; // A binary tree node has data, pointer to left child and a pointer to right child struct Node{ int data; struct Node *left, *right; Node (int data){ ...
#include "stdafx.h" #include "MainGame.h" #include "TestScene.h" #include "ToolMain.h" #include "ToolSub.h" MainGame::MainGame() { //SUBWIN->Init(); } MainGame::~MainGame() { } HRESULT MainGame::Init() { GameNode::Init(); SOUND->Init(); SUBWIN->Init(); isDebug = false; IMAGE->AddImage("tile_main", "images/...
#include "storage/sstable/sstable_builder.h" #include <iostream> #include "absl/strings/str_cat.h" #include "utils/file/filewriter.h" #include "utils/file/filereader.h" #include "utils/sort/qsort.h" namespace storage { namespace sstable { const std::string DEFAULT_FILEPATH = "default"; using utils::file::filewrite...
#ifndef _MA_COROUTINES_H #define _MA_COROUTINES_H #include "type_manipulation.h" #include "allocators.h" namespace ma { template <typename T> struct identity { typedef T type; }; template <class T> inline T &&forward(typename remove_reference<T>::type &t) noexcept { return static_cast<T &&>(t); } template <class ...
#ifndef GRID_H #define GRID_H // Qt #include <QObject> #include <QRunnable> #include <QList> // PCL #include "../DataTypes.h" // Grid data #include "GridCell.h" class Grid : public QObject, public QRunnable { Q_OBJECT public: explicit Grid(QObject *parent = 0); protected: double minX; double maxX; ...
#include <iostream> #include <string> #include <windows.h> #include "CircularContainer.h" HANDLE hCon; enum Color { DARKBLUE = 1, DARKGREEN, DARKTEAL, DARKRED, DARKPINK, DARKYELLOW, GRAY, DARKGRAY, BLUE, GREEN, TEAL, RED, PINK, YELLOW, WHITE }; void SetColor(Color c){ if (hCon == NULL) hCon = GetStdHandle(STD_OUTPU...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 2011 Opera Software ASA. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. ** */ #ifndef UNIX_PROCESS_MANAGER_H #define UNIX_PROCESS_MANAGER_H #in...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- ** ** Copyright (C) 1995-2011 Opera Software ASA. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. */ #include "core/pch.h" #include "modules/logdoc/logdoc_module.h"...
// // Ball.cpp // header_redo // // Created by Tyler Henry on 11/18/14. // // #include "Ball.h" //constructor for a ball Ball::Ball() { pos.x = ofGetWindowWidth() * 0.5; pos.y = 0; //gold(-ish) r = 218; g = 183; b = 74; } void Ball::setup() { //ball radius radius = 50; ...
// // Created by 周华 on 2021/5/5. // #include "RendererComponent.h"
// @author sadmb // @date 10th,Feb,2014. // modified from utils/DepthRemapToRange.h of ofxNI2 by @satoruhiga #pragma once #include "ofMain.h" namespace ofxKinect2 { template <typename PixelType> struct DoubleBuffer; } // namespace ofxKinect2 template <typename PixelType> struct ofxKinect2::DoubleBuffer { public: ...
class Category_687 { duplicate = 629; }; class Category_579 { duplicate = 629; }; class Category_635 { duplicate = 629; };
/* -*- Mode: c++; indent-tabs-mode: nil; c-file-style: "gnu" -*- * * Copyright (C) 1995-2005 Opera Software ASA. All rights reserved. * * This file is part of the Opera web browser. It may not be distributed * under any circumstances. */ #include "core/pch.h" #ifdef XSLT_SUPPORT # include "modules/xslt/src/xs...
#ifndef BBPLUS_HPP_INCLUDED #define BBPLUS_HPP_INCLUDED #include <regex> #include "./marks.hpp" namespace bbplus { std::string parse(std::string input) { std::string output = input; for (int_fast8_t i = 0; i < MARKS_NB; ++i) { while (std::regex_search(output, MARKS[i].input_regex) == true) { ...
#include "arena.h" #include "globals.h" #include "doublely_linked_list.h" #include "goal.h" #include "wall.h" #include "pothole.h" #include "windmill.h" #include "token.h" #include "game.h" #include "sandtrap.h" //add more elements later //the order of an arena is walls,potholes,element1,element2,element3,goal,bal...
#include <stdio.h> #include <math.h> #include <vector> #include <stdlib.h> using namespace std; #define EPS 10e-9 #define CASAS_DECIMAIS 2 typedef struct { double first, second; int amount; bool interval; } number_t; typedef vector<number_t> vN; void f_changeMode(vN &numbers, int &mode); void f_clear(); void ...
#include <Python.h> #include <iostream> #include <opencv2/imgproc/imgproc.hpp> #include <boost/python.hpp> #include "conversion.h" #include "brisk/brisk.h" #include <sys/time.h> namespace py = boost::python; static cv::Mat get_gray_img(PyObject *p_img); static std::vector<cv::KeyPoint> detect(cv::Mat img, PyObject...
/* * Assignment 1 Part 1 Main Function for CS 1337 * Programmer: Medha Aiyah * Description: This main function is used to make the drink machine and allow the user to by a specific drink. *4 */ //These are the appropriate headers used for this function #include "drinkmachine.h" using namespace std; int main() { ...
#ifndef MESH_H #define MESH_H #include <vector> #include <unordered_map> #include <string> #include <iostream> #include <array> #include <glm/glm.hpp> #include "commun.h" #include "resource.h" struct vertex { glm::vec3 position; glm::vec3 normal; glm::vec2 texcoord; }; class mesh { uint _vao...
// Fill out your copyright notice in the Description page of Project Settings. #pragma once #include "Proto.h" #include "GameFramework/Character.h" #include "Dragon.generated.h" DECLARE_MULTICAST_DELEGATE(FOnAttackEndDelegate); DECLARE_MULTICAST_DELEGATE(FonAlertEndDelegate); enum AttackPatten { Not...
/* -*- Mode: c++; tab-width: 2; indent-tabs-mode: s; c-basic-offset: 2 -*- ** ** Copyright (C) 2012 Opera Software AS. All rights reserved. ** ** This file is part of the Opera web browser. It may not be distributed ** under any circumstances. ** */ #include "adaptation_layer/system_utils.h" #include "platforms/wind...
/* * Copyright (C) 2013 Tom Wong. All rights reserved. */ #include "gtdoccommand.h" #include "gtbookmark.h" #include "gtbookmarks.h" #include "gtdocmodel.h" #include "gtdocnote.h" #include "gtdocnotes.h" #include <QtCore/QDebug> GT_BEGIN_NAMESPACE GtDocCommand::GtDocCommand(GtDocModel *model, ...
/* -*- Mode: c++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- * * Copyright (C) 2012 Opera Software ASA. All rights reserved. * * This file is part of the Opera web browser. * It may not be distributed under any circumstances. */ #include "core/pch.h" #ifdef PI_SHARED_MEMORY #include "modules/pi/...
#include "pch.h" #include "ppl.h" #include <iostream> #include <iostream> #include"amp.h" #include<array> #include<iostream> using namespace concurrency; std::vector<accelerator> findAccelerators() { std::vector<accelerator> accels; accels = accelerator::get_all(); for (int i = 0; i < accels.size(); i++) { st...
#include "ShapesBlocks.h" void rectBlocks:: addItem(int a,int b ,int c){ w.push_back(a); h.push_back(b); l.push_back(c); }
#include "stdafx.h" #include "DBUtil.h" #include <stdexcept> DBUtil * DBUtil::instance = nullptr; DBUtil::DBUtil() { } DBUtil::~DBUtil() { } void DBUtil::open(std::string _filename) { if (sqlite3_open(_filename.c_str(), &conn)) throw std::runtime_error(std::string("Couldn't open database: ") + sqlite3_errmsg(...
#include "renderingConfig.h" //=========================================================================== //! @file renderigConfig.cpp //! @brief 描画設定管理 //=========================================================================== //--------------------------------------------------------------------------- //! インスタン...
/* Copyright (c) 2014 Mircea Daniel Ispas This file is part of "Push Game Engine" released under zlib license For conditions of distribution and use, see copyright notice in Push.hpp */ #pragma once #include <cstdint> namespace Push { enum class LogType : uint32_t { Info, Warning, Err...
#include <unistd.h> #include <cctype> #include <sstream> #include <string> #include <vector> #include <iostream> #include "process.h" #include "linux_parser.h" using std::string; using std::to_string; using std::vector; Process::Process(int ID) : PassID(ID) { } // TODO: Return this process's ID int Process::Pid(){...
#include "scoreform.h" #include "ui_scoreform.h" #include <QStringListModel> #include <QDebug> bool moreThan( const QString& v1, const QString& v2 ) { return v1.toInt() > v2.toInt(); } ScoreForm::ScoreForm(QWidget *parent) : QDialog(parent) , ui(new Ui::ScoreForm) , m_settings("Trainer", "Multiplicat...
#ifndef STATS_H #define STATS_H #include <cmath> #include <iostream> #include <QDialog> #include <QtSql/QSqlDatabase> #include <QtSql/QSqlError> #include <QtSql/QSqlTableModel> #include <QTableView> #include <QMessageBox> #include <QSqlQuery> #include <QtSql/QSqlDriver> namespace Ui { class Stats; }...
#include <iostream> int calc_fib(int n) { int fib_arr[n + 1]; fib_arr[0] = 0; fib_arr[1] = 1; for(int i = 2; i < n + 1; i++) { fib_arr[i] = fib_arr[i - 1] + fib_arr[i - 2]; } return fib_arr[n]; } int main() { int n = 0; std::cin >> n; std::cout << calc_fib(n) << '\n'; ...