text
stringlengths
3.08k
12.5k
/********************************************************************** * LeechCraft - modular cross-platform feature rich internet client. * Copyright (C) 2006-2014 <NAME> * * Distributed under the Boost Software License, Version 1.0. * (See accompanying file LICENSE or copy at https://www.boost.org/LICENSE_1_0....
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <time.h> #include <unistd.h> #include <iostream> // sudo apt-get install libboost-filesystem1.54.0 // sudo apt-get install libboost-filesystem1.55-dev #include <boost/filesystem.hpp> // Only used to test if file exists // Redefines what the comment...
#include "MeshOrient.h" #include "triMesh.h" #include <iostream> #include <queue> #include <set> #include <unordered_map> #include <unordered_set> #include <igl/winding_number.h> using namespace std; void resetOrientation(sfMesh& mesh); void resetOrientationBFS(sfMesh& mesh, int start); void resetOrientationVisualD...
// Copyright (c) 2016-2019 LG Electronics, Inc. // // 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 required by applicable law or...
#include "Simon.h" Simon::Simon(Font& f) { //scores scr.setPosition(20, 10); scr.setCharacterSize(20); scr.setFillColor(Color::White); scr.setFont(f); //read from file std::string hsc; hs.open("res/simon/hs.txt"); std::getline(hs, hsc); highscore = std::stoi(hsc); hs.close(); //setup back button std::st...
#include "cylinder.h" void Cylinder::setRadius(GLfloat radius) { this->radius = radius; } GLfloat Cylinder::getRadius() { return this->radius; } void Cylinder::setHeight(GLfloat height) { this->height = height; } GLfloat Cylinder::getHeight() { return this->height; } void Cylinder::setCountSectors(...
/* Print CPUID the right way * * Copyright (c) 2014, <NAME> and contributors. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * Redistributions of source code must retain the above copyright * notice, thi...
// Copyright (c) 2019-2020 <NAME> // SPDX-License-Identifier: BSD-3-Clause #include "ArrayFireBlock.hpp" #include "DeviceCache.hpp" #include "Utility.hpp" #include <Pothos/Exception.hpp> #include <Pothos/Framework.hpp> #include <Pothos/Object.hpp> #include <Poco/File.h> #include <Poco/Format.h> #include <Poco/Logger...
#include <string> #include <cstdio> // b站视频 仔细看完 会有很大收获 https://www.bilibili.com/video/BV1xb411A7wC?t=364 /* 题目7:重建二叉树 输入某二叉树的前序遍历和中序遍历的结果,请重建出该二叉树。假设输入的前序遍历和中序遍历的结果中都不包含重复的数字。 eg:输入前序遍历序列{1, 2, 4, 7, 3, 5, 6, 8}和中序遍历序列{4, 7, 2, 1, 5, 3, 8, 6},则重建吃二叉树并输出头结点。 */ struct BinaryTreeNode { int m_dbValue...
/* implementation file for GlastRandomSvc gets adresses of CLHEP random number engines used in Gleam shared libraries and sets seeds for them based on run and particle sequence number obtained from the MCHeader $Header: /nfs/slac/g/glast/ground/cvs/GlastSvc/src/GlastRandomSvc/GlastRandomObs.cxx,v 1.2 2011/12/12 ...
#include "moab_mpi.h" #include "moab/Core.hpp" #include <sstream> #include <iostream> #include <stdlib.h> #include <unistd.h> const char usage[] = "[-b|-d|-f] [-P <rank>] [-p <name>] [-R] [-g <level>] [-O <option>] <filename>"; const char DEFAULT_PARTITION_TAG[] = "PARALLEL_PARTITION"; void error( const char* argv0 ...
/* * * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); y...
/*This file is part of the FEBio source code and is licensed under the MIT license listed below. See Copyright-FEBio.txt for details. Copyright (c) 2020 University of Utah, The Trustees of Columbia University in the City of New York, and others. Permission is hereby granted, free of charge, to any person obtaining ...
#include <sstream> #include <vector> #include <cmath> #include <fftw3.h> #include <omp.h> #include <vector_types.h> double sinc(double x) { if (x != 0) { return sin(x)/x; } else { return 1.0; } } double CICgridCorrection(double kx, double ky, double kz, int3 N, double3 L) { double prod...
// https://dmoj.ca/problem/lazy #include <bits/stdc++.h> #define all(x) (x).begin(), (x).end() #define gc getchar() #define pc(x) putchar(x) template<typename T> void scan(T &x){x = 0;bool _=0;T c=gc;_=c==45;c=_?gc:c;while(c<48||c>57)c=gc;for(;c<48||c>57;c=gc);for(;c>47&&c<58;c=gc)x=(x<<3)+(x<<1)+(c&15);x=_?-x:x;}...
/* * Copyright 1999-2001, <NAME> <<EMAIL>>. All rights reserved. * Distributed under the terms of the MIT License. */ #include "Utilities.h" NewsBeUtilities::NewsBeUtilities() { app_info appInfo; BEntry *beAppParent; BEntry *beAppEntry; BPath *bpAppPath; char *itsAppPath; itsSubsPath = (char *)mal...
#include <stdio.h> #include <string.h> const int MAXN = 100005; const int R = 15; const int C = 22; const int dir[4][2] = {{1, 0}, {0, -1}, {0, 1}, {-1, 0}}; const char sign[5] = "DLRU"; struct Map { char state[R][C]; char order[C]; int cnt; }aid, begin; int sumPace, sumGem; int r, c; bool isGem(char c) ...
#include <array> #include <chrono> #include <filesystem> #include <iomanip> #include <iostream> #include <sstream> #include <string> #include "graph.hpp" #include "graph_generation_controller.hpp" #include "graph_printer.hpp" #include "graph_traversal.hpp" #include "graph_traversal_controller.hpp" #include ...
// Copyright (c) 2012 The Chromium Embedded Framework Authors. All rights // reserved. Use of this source code is governed by a BSD-style license that // can be found in the LICENSE file. #include "include/base/cef_build.h" #if defined(OS_LINUX) #include <X11/Xlib.h> // Definitions conflict with gtest. #undef None #u...
/** Compiler Phase 2: PRSGEN predictive_parser.cpp Purpose: The actual implementation of the parser flowchart itself that uses STACK, INPUT BUFFER and PARSING TABLE to parse the input program. @author(s) <NAME> @version 1.0 @date 21/4/2020 */ #include "predictive_parser.h" #include <utility> #...
/* ** Copyright (C) 1998-2010 <NAME> <<EMAIL>> ** ** 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 2 of the License, or ** (at your option) any later version. ** ** This program...
/*== GRAPHFAB ======================================================================= * Copyright (c) 2012-2015 <NAME> * All rights reserved. * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * Redistributions of s...
/* ------------------------------------------------------------------------------- Copyright (c) <NAME>. This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. Permission is granted to a...
/* ** gl_vertexmap.cpp ** Vertex management for precise wall rendering. ** **--------------------------------------------------------------------------- ** Copyright 2021-2022 <NAME> ** All rights reserved. ** ** Redistribution and use in source and binary forms, with or without ** modification, are permitted provided ...
/////////////////////////////////////////////////////////////////////////////// /// /// Written 2009-2013, <NAME> (assarbad.net) - PUBLIC DOMAIN/CC0 /// /// Original filename: looklink.cpp /// Project : looklink /// Date of creation : 2009-02-03 /// Author(s) : <NAME> /// /// Purpose :...
// Author: <NAME> #include "UserInterface.h" #include <Arduino.h> #include <LiquidCrystal.h> byte UserInterface::customBackslash[8] = { 0b00000, 0b10000, 0b01000, 0b00100, 0b00010, 0b00001, 0b00000, 0b00000 }; //const char UserInterface::motorGlyphs[] = "-\\|/"; const char UserInterface::motorG...
#include <sys/types.h> #include <sys/socket.h> #include <sys/inotify.h> #include <sys/stat.h> #include <iostream> #include <fstream> #include <string.h> #include <unistd.h> #include <stdio.h> #include <string> #include "defines.h" #include "lookup3.h" using namespace std; /*sendall - repeatedly performs a send on a ...
/* * Copyright (c) 2017 ARM Limited. All rights reserved. * SPDX-License-Identifier: Apache-2.0 * 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...
//<NAME> <EMAIL> #include <iostream> #include <thread> #include <mutex> #include <deque> #include <fstream> #include <vector> #include <ctime> #include <ratio> #include <chrono> using namespace std; mutex job_queue_mtx; const unsigned MAX_N_THREAD=10; bool njp_flag[MAX_N_THREAD];//new job possible flag struct job {...
#include <array> #include <fstream> #include <iomanip> #include <iostream> #include <sstream> #include "dumpers.hh" #include "grid.hh" void Dumper::set_min(float min) { m_min = min; } void Dumper::set_max(float max) { m_max = max; } float Dumper::min() const { return m_min; } float Dumper::max() const { r...
//////////////////////////////////////////////////////////////////////// // All keyboard, mouse, and other interactions are implemented here. // The single entry point, InitInteraction, sets up GLUT callbacks for // various events that an interactive graphics program needs to // handle. // // The various callbacks are:...
#include <iostream> #include <sstream> #include "Renderer.hpp" #include "Events.hpp" #include "Camera.hpp" #include "FrameBuffer.hpp" #include "Chunk.hpp" #include "Map.hpp" #include "glm/glm.hpp" #include "glm/gtc/matrix_transform.hpp" #include "Settings.hpp" #include "UI.hpp" void hello(float) { ...
#include <stdio.h> #include <math.h> //pow #include "main.h" #include "equalizer.h" #include "coef.h" #include "algorithm" #define MY_DEBUG 0 static float octave_bands[] = {31.5, 63, 125, 250, 500, 1000, 2000, 4000, 8000, 16000}; /* constructor */ Equalizer::Equalizer(void) { //Your code here num_bands = M...
// // Copyright 2004 <NAME> // // This 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 version 2 of the License, or any later version. // The library is distributed in the hope that...
/* * Copyright (c) 2021 Nuovation System Designs, LLC * All rights reserved. * * 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/L...
#include "autoclicker.h" #include <QDir> #include <QFile> #include <QIODevice> #include <QMessageBox> #include <QSettings> #include "beep.h" #include "hook.h" #include "mainwindow.h" #include "util.h" using sac::kb::keycomb_t; using sac::kb::parse; namespace sac { AutoClicker *_autoClicker; AutoClicker *autoClicke...
#include <utils/string.h> #include <memory/heap.h> #include <memory/page_frame_allocator.h> #include <memory/page_table_manager.h> using namespace memory; void* heap_start; void* heap_end; heap_segment_header_t* last_hdr; //#memory::initialize_heap-doc: Initialize the memory heap. void memory::initialize_heap(void* ...
// See LICENSE_CELLO file for license and copyright information /// @file enzo_EnzoComputeAcceleration.cpp /// @author <NAME> (<EMAIL>) /// @date 2014-10-27 22:37:41 /// @brief Implements the EnzoComputeAcceleration class #include "cello.hpp" #include "enzo.hpp" //--------------------------------------...
/* =========================================================================== Doom 3 BFG Edition GPL Source Code Copyright (C) 1993-2012 id Software LLC, a ZeniMax Media company. This file is part of the Doom 3 BFG Edition GPL Source Code ("Doom 3 BFG Edition Source Code"). Doom 3 BFG Edition Source Code is free so...
#include "pc.h" #include "UIRoundrect.h" // TopLeft, TopRight, BottomRight, BottomLeft const float4 UIRoundrect::lRounding = float4(16.f, 16.f, 16.f, 16.f); UIRoundrect::UIRoundrect(float2 TopLeft, float2 BottomRight) { UIRoundrect::UIRoundrect(TopLeft.x, TopLeft.y, BottomRight.x, BottomRight.y, lRounding); } U...
#include "GL/glew.h" #include "Application.h" #include "ModuleImporter.h" #include "ModuleSceneIntro.h" #include "GameObject.h" #include "Component_Transform.h" #include "Component_Mesh.h" #include "Component_Material.h" #include "Mesh.h" #include "Texture.h" #include "MathGeoLib.h" ModuleImporter::ModuleImporter...
/* Copyright (c) 2009-2015, <NAME> All rights reserved. This file is part of Elemental and is under the BSD 2-Clause License, which can be found in the LICENSE file in the root directory, or at http://opensource.org/licenses/BSD-2-Clause */ #include "El.hpp" using namespace std; using namespace El; t...
/* * FILE: Dungeon_Master-532.cpp * * @author: Md. <NAME> <arafathasanjenin[at]gmail[dot]com> * * LINK: * * Description: * * DEVELOPMENT HISTORY: * Date Change Version Description * -------------------------------------------------------------- * 09 Apr 2017 New 1...
#include <Rcpp.h> #include <unordered_map> #include <iterator> #include <regex> #include "nonstd/string_view.hpp" #include "utils.h" struct MultipartFile { std::string filename; std::string content_type; std::size_t offset; std::size_t length; }; namespace Rcpp { template <> SEXP wrap(const MultipartFile&...
/* ***CHRONO*** Bullet Continuous Collision Detection and Physics Library Copyright (c) 2003-2006 <NAME> http://continuousphysics.com/Bullet/ This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. P...
#include "assembler.h" #include <nsvector> #include <nsstring> #include <nsio> #include "utils.h" int Assembler::calcInstructionSize(const Statement& instruction, const int optimize) { return 0; } vector<byte> Assembler::DoAll(const vector<string>& files, const vector<string>& source, int optimize, const strin...
// Copyright (c) FIRST and other WPILib contributors. // Open Source Software; you can modify and/or share it under the terms of // the WPILib BSD license file in the root directory of this project. #include "Subsystems/Shooter.h" Shooter::Shooter(Robot *pRobot) { this->pRobot = pRobot; } //Wheel (Shooter) Function...
#include <getopt.h> #include <stdio.h> #include <list> #include "utils.h" #include "data.h" #include "eval.h" void print_usage_and_exit() { // print usage information printf("*************************** Predict by Poupularity *****************************\n"); printf("(c) Copyright 2014-2015 <NAME> ( <EMA...
#pragma once #include "MathFunctions.h" #include "Polygon.h" #include "Fixture.h" #include "Utility.h" #include "IShape.h" #include <vector> #include <iterator> using namespace phy; void Polygon::setShape(Vec2d * verts, int count) { //set the vertices amount parameter vCount = count; for (int i = ...
#include <opencv2/opencv.hpp> #include <iostream> #include <string> #include <math.h> #define M_PI (4*atan(1)) // since M_PI is not defined by c++11 static void meshgrid(const cv::Mat &xgv, const cv::Mat &ygv, cv::Mat1i &X, cv::Mat1i &Y) { cv::repeat(xgv.reshape(1,1), ygv.total(), 1, X); cv::...
#pragma once #include "platform.hh" #include "../asyncjob.hh" #include "../rpc.hh" namespace Steam { using UserHandle = u32; using PipeHandle = u32; using InterfaceConstructor = void *(*)(UserHandle h); using InterfaceDestructor = void (*)(void *); typedef void *(*InstantiateInterfaceFn)(void); ...
// // Copyright 2012 <NAME> and <NAME> // // 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 required by applicable law o...
// Copyright (c) 2017-2019 LG Electronics, Inc. // // 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 required by applicable law or...
#include <Rcpp.h> using namespace Rcpp; // [[Rcpp::export]] double chisq_fix_reject(S4 design, double n1, double nuisance, String type) { double reject_prob = 0; double r = design.slot("r"); double alpha = design.slot("alpha"); double delta = design.slot("delta"); String alternative = design.slot("alternativ...
// // Copyright (c) 2016 - 2017 Mesh Consultants Inc. // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal // in the Software without restriction, including without limitation the rights // to use, copy, mod...
#include "facade/DTex.h" #include <unirender/Device.h> #include <unirender/Context.h> #include <unirender/IndexBuffer.h> #include <unirender/VertexBuffer.h> #include <unirender/VertexArray.h> #include <unirender/VertexInputAttribute.h> #include <unirender/ComponentDataType.h> #include <unirender/DrawState.h> #include ...
/* * Copyright 2009-2017 Alibaba Cloud All rights reserved. * * 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 required...
#include "base64.h" const char* Base64::base64chars = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/"; const unsigned char Base64::d[256] = { 66,66,66,66,66,66,66,66,66,66,64,66,66,66,66,66,66,66,66,66,66,66,66,66,66, 66,66,66,66,66,66,66,66,66,66,66,66,66,66,66,66,66,66,62,66,66,66,63,52,53, ...
/////////////////////////////////////////////////////////// //*-----------------------------------------------------*// //| Part of Endless Journey (https://www.maus-games.at) |// //*-----------------------------------------------------*// //| Copyright (c) 2021 <NAME> |// //| Released under the zlib Li...
#include <co_fun/lazy.h> #include <gtest/gtest.h> #include <type_traits> using namespace co_fun; TEST(Co_FunLazyTest, TestGTest) { ASSERT_EQ(1, 1); } using ::testing::Test; namespace testing { namespace { int func_called; int func2_called; int func3_called; } // namespace namespace { int func() { func_called+...
#include<glad/glad.h> #include<GLFW/glfw3.h> #include<iostream> void ProcessInput(GLFWwindow* window); void FramebufferSizeCallback(GLFWwindow* window, int width, int height); //setting const unsigned int SCR_WIDTH = 800; const unsigned int SCR_HEIGHT = 600; const char* vertexShaderSource = "#version 33...
/* * This file is part of Universal-Core-Example * Copyright (C) 2020 SuperSaiyajinStackie * * 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...
// // ELF object format helpers - x86:x32 // // Copyright (C) 2012 <NAME>, <NAME> // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following conditions // are met: // 1. Redistributions of source code must retain the above copyright // notice...
#include <stdio.h> #include <stdlib.h> #include "rplidar.h" #include <opencv2/opencv.hpp> #ifndef _countof #define _countof(_Array) (int)(sizeof(_Array) / sizeof(_Array[0])) #endif #ifdef _WIN32 #include <Windows.h> #define delay(x) ::Sleep(x) #else #include <unistd.h> static inline void delay(_word_size_t ms) { w...
// This file is part of CxxDoc, The RAVL C++ Documentation tool // Copyright (C) 2004, University of Surrey // This code may be redistributed under the terms of the GNU General // Public License (GPL). See the gpl.licence file for details or // see http://www.gnu.org/copyleft/gpl.html // file-header-ends-here ///////...
// // Created by barto on 25.06.18. // #include <iostream> #include "Program.h" Program::Program() {} std::ifstream Program::file = {}; std::vector<unsigned long long> Program::resultArray = {}; // {16, 0} doesnt work... unsigned long long Program::lineNumber = 1; std::shared_ptr<spdlog::logger> Program::consoleLo...
#include<iostream> #include<fstream> #include<vector> #include<unordered_map> struct plant_state { std::unordered_map<int64_t, char> pots; int64_t min_set; int64_t max_set; }; plant_state parse_initial_state(std::string state_string) { plant_state state; std::unordered_map<int64_t, char> pots; int64_t i =...
/* the vast starry sky, bright for those who chase the light. */ #include<bits/stdc++.h> using namespace std; typedef long long ll; typedef pair<int,int> pii; #define mk make_pair const int inf=(int)1e9; const ll INF=(ll)5e18; const int MOD=998244353; int _abs(int x){return x<0 ? -x : x;} int add(int x,int y){x+=y; ret...
// File : parallel-cfitsio-read.cc // ---------------------------------- // Created : Wed Nov 25 14:19:14 2015 // Authors : <NAME> (RCT) - <EMAIL> // // MPI parallel read test of multi-extension FITS files with CFITSIO library. // This is designed around using raw DECam exposure files available in the // Cosmo Dat...
#include <mpi.h> #include <algorithm> #include <cassert> #include <fstream> #include <iterator> #include <numeric> #include <stdexcept> #include <string> #include <vector> struct Vertex { std::vector<unsigned> targets; std::vector<unsigned> weights; void add_edge(unsigned dst, unsigned weight) { ta...
// This file is part of Empirical, https://github.com/devosoft/Empirical // Copyright (C) Michigan State University, 2016. // Released under the MIT Software license; see doc/LICENSE // // // Example code for converting string pattern representations. #include <iostream> #include <string> #include "emp/compiler/D...
/// /// @file ImageStack.cpp /// @brief Reading in and checking image data #include <QColor> #include <QImage> #include <algorithm> #include <filesystem> #include <iostream> #include "ImageStack.h" void ImageStack::ReadImages(const std::string _imageDirectory) { // The following function is adapted from: // <NA...
/* Copyright (c) <NAME>, 1994. */ /** * (c) Copyright 1993, Silicon Graphics, Inc. * ALL RIGHTS RESERVED * Permission to use, copy, modify, and distribute this software for * any purpose and without fee is hereby granted, provided that the above * copyright notice appear in all copies and that both the copyrig...
/* * Copyright (c) 2011 The WebRTC project authors. All Rights Reserved. * * Use of this source code is governed by a BSD-style license * that can be found in the LICENSE file in the root of the source * tree. An additional intellectual property rights grant can be found * in the file PATENTS. All contribut...
/* USER CODE BEGIN Header */ /** ****************************************************************************** * @file : main.c * @brief : Main program body ****************************************************************************** * @attention * * <h2><center>&copy; Copyright (c) ...
/* ImageTrans_plugin.cpp * This is a test plugin, you can use it as a demo. * 2019-7-5 : by YourName */ #include "v3d_message.h" #include <vector> #include "ImageTrans_plugin.h" #include "trans_class.h" #include <basic_surf_objs.h> using namespace std; Q_EXPORT_PLUGIN2(ImageTrans, TestPlugin); QStringList TestPl...
#include "cpl_frameimageincludes.h" ///// static variable and function ///// /* * cut off a sub-image from a large image */ static void s_getSubImageFromBitArray(unsigned char * obits, /*large image*/ int ow, /*width of large image*/ ...
// Note - pyconfig.h must be included before condor_common to avoid // re-definition warnings. # include <pyconfig.h> #include "condor_common.h" #include "condor_config.h" #include "read_user_log.h" #include "file_lock.h" #include <classad/operators.h> #include <memory> #include <boost/python.hpp> #include "old_bo...
#include "NodeGraph.h" #include <raylib.h> std::deque<NodeGraph::Node*> NodeGraph::findPath(Node* start, Node* end) { // Find a path from start to end (The current implementation is obviously insufficient) Node* begin = start; Node* goal = end; begin->gScore = 1; //Check if the start or the goal pointer is null ...
#include <DescriptorAllocatorPage.h> #include <Application.h> #include <d3dx12.h> #include <DX12LibPCH.h> #include <mutex> DescriptorAllocatorPage::DescriptorAllocatorPage(D3D12_DESCRIPTOR_HEAP_TYPE type, uint32_t numDescriptors) : m_HeapType(type) , m_NumDescriptorsInHeap(numDescriptors) { Microsoft::WR...
#include <algorithm> #include <cassert> #include <cstdio> #include <cstdlib> #include <cstring> #include <iostream> #include <sstream> #include <string> #include <vector> #include <map> using namespace std; const long long mod = 1000000007; bool G[50][2]; int C[51][51]; map<long long, int> memo; int calc(int n, long ...
/** * Created by <NAME> on 20/04/2020. **/ #include <cmath> #include "NasNas/core/data/Config.hpp" #include "NasNas/core/Scene.hpp" #include "NasNas/core/Camera.hpp" using namespace ns; Camera::Camera(std::string name, int render_order) : m_name(std::move(name)), m_render_order(render_order), m_visible(true), m_sce...
/* * This file is part of SpatialCL, a library for the spatial processing of * particles. * * Copyright (c) 2017, 2018 <NAME> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * 1. Redis...
#include "pch.h" #include "AttackGroup.h" #include <regex> #include <sstream> std::wstring team_to_string(const Team t) { switch (t) { case IMMUNE_SYSTEM: return L"Immune System"; case INFECTION: return L"Infection"; case NO_TEAM: default: return L"N/A"; } } AttackGroup::AttackGroup(const std:...
#include "mytcpserver.h" #include <QDebug> #include <QThread> #include "mytcpsocket.h" #include <QByteArray> #include <QJsonDocument> #include <QJsonObject> #include <db/dbutil.h> MyTcpServer::MyTcpServer(QObject *parent) : QTcpServer(parent) { clients = new QMap< qint32, MyTcpSocket *> (); } void MyTcpServer::i...
#include <Box2D/Box2D.h> #include <SDL.h> #include <SDL_image.h> #include <SDL_ttf.h> #include <sstream> #include <stdio.h> #include <string> #include "Entity.h" #include "PlayerShip.h" #include "Projectile.h" #include "screenConst.h" #include "Texture.h" #include "Timer.h" #include "worldConst.h" //Global font TTF_F...
#include "Seeker.hpp" const int Seeker::MIN_OBJECT_AREA = 20 * 20; vector<Point> Seeker::circle_contour = {Point(100, 100), Point(200,100), Point(200, 200), Point(100, 200)}; Mat Seeker::freezedTrajectory(720, 1280, CV_8UC3); Mat Seeker::freezedTrajectoryGrey(720, 1280, CV_8UC1); /// В конструкторе инициализируем ма...
#include <CQGameBoyVideo.h> #include <CQGameBoyGraphics.h> #include <CQGameBoyScreen.h> #include <CQGameBoyTiles.h> #include <CQGameBoyTile.h> #include <CQGameBoySprites.h> #include <CQGameBoySpriteList.h> #include <CQGameBoyPalette.h> #include <CQGameBoyVReg.h> #include <CQGameBoy.h> #include <QHBoxLayout> #include <Q...
#include <LightMesh.h> LightMesh::LightMesh(const std::vector<Triangle>& triangleList, size_t materialId, bool softShadingFlag) : Mesh(triangleList, materialId, softShadingFlag) { this->randomGenerator = new RandomGenerator(0.0f, 1.0f); this->triangleList = triangleList; this->totalArea = 0.0f; ...
/** * @file * This file is part of SeisSol. * * @author <NAME> (breuer AT mytum.de, http://www5.in.tum.de/wiki/index.php/Dipl.-Math._Alexander_Breuer) * @author <NAME> (c.uphoff AT tum.de, http://www5.in.tum.de/wiki/index.php/Carsten_Uphoff,_M.Sc.) * @author <NAME> (sebastian.rettenberger AT tum.de, http://www5.i...
/**************************************************************************** * * (c) 2009-2020 QGROUNDCONTROL PROJECT <http://www.qgroundcontrol.org> * * QGroundControl is licensed according to the terms in the file * COPYING.md in the root of the source code directory. * ***************************************...
#include "library/common/jni/jni_utility.h" #include <stdlib.h> #include <string.h> #include "library/common/jni/jni_version.h" // NOLINT(namespace-envoy) static JavaVM* static_jvm = nullptr; static thread_local JNIEnv* local_env = nullptr; void set_vm(JavaVM* vm) { static_jvm = vm; } JavaVM* get_vm() { return st...
#include <qt/styleSheet.h> #include <QFile> #include <QWidget> #include <QApplication> #include <QStyleFactory> #include <QProxyStyle> #include <QListView> #include <QComboBox> #include <QMessageBox> #include <QPushButton> #include <QPainter> #include <QLineEdit> #include <QtGlobal> #include <QSettings> static const ...
// Copyright (C) 2018-2021 Intel Corporation // SPDX-License-Identifier: Apache-2.0 // #pragma once #include <chrono> #include <iomanip> #include <map> #include <openvino/openvino.hpp> #include <samples/slog.hpp> #include <string> #include <vector> typedef std::chrono::high_resolution_clock Time; typedef std::chrono...
#include "neural_network_utilities.hpp" #include "matrix.hpp" #include "signals.hpp" #include "figure_eight_target.hpp" #include <math.h> #include <iostream> #define NUM_SIGNAL 11 #define PI 3.1415926535897932384626433832795 void print_matrix(Matrix2); void print_array(float*, int); unsigned long timestamp; float c...
// Copyright 2021 The Chromium OS Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. // // The folder_size_dump helper dumps the size of various system folders. #include <algorithm> #include <functional> #include <iostream> #include <it...
// Boost.Geometry (aka GGL, Generic Geometry Library) // Unit Test // Copyright (c) 2010 <NAME>, Amsterdam, the Netherlands. // Use, modification and distribution is subject to the Boost Software License, // Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at // http://www.boost.org/LICENSE_1_0.txt)...
#include "mcts.h" #include "experiment.h" #include <boost/program_options.hpp> #include <APS.h> using namespace std; using namespace boost::program_options; void disableBufferedIO(void) { setbuf(stdout, NULL); setbuf(stdin, NULL); setbuf(stderr, NULL); setvbuf(stdout, NULL, _IONBF, 0); setvbuf(std...
/* Authors: <NAME> (<EMAIL>, <EMAIL>), * <NAME> (<EMAIL>, <EMAIL>), * <NAME> (<EMAIL>, <EMAIL>) and * Dr. <NAME> (<EMAIL>) * for the Reconfigurable Computing Research Lab at the * Univerity of New Brunswick in Fredericton, New Brunswick, Canada */ #includ...
// ********************************************************************************** // ESP8266 Teleinfo WEB Server configuration Include file // ********************************************************************************** // Creative Commons Attrib Share-Alike License // You are free to use/extend this library ...