text
stringlengths
3.08k
22k
/*---------------------------------------------------------------- Raven Library Source Code Copyright (c) 2008-2017 the Raven Development Team ------------------------------------------------------------------ Abstraction (partitioning of ponded water/snowmelt to depression storage) -----------------...
#include <iostream> #include <fstream> #include <vector> #include <chrono> #include <thread> #include "CustomMath.h" #include "Solid.h" #include "World.h" #define PI 3.1415926 #pragma region SKYBOX_LOADER extern "C" { #define STB_IMAGE_IMPLEMENTATION #include "stbi_image.h" } std::vector<unsigned ...
#include <v8.h> #include <string> #include <vector> #include "macros.h" #include "gc.h" #include "bytestorage.h" #define BS_OTHER(object) reinterpret_cast<ByteStorage *>(object->GetPointerFromInternalField(0)) #define BS_THIS BS_OTHER(args.This()) #define WRONG_CTOR JS_TYPE_ERROR("Buffer() called with wrong arguments....
/* * Copyright (C) 2020 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 required by app...
#include "LMC++.hpp" const uint64_t MEMORY_SIZE = 65536; // slots const uint8_t REG_COUNT = 16; uint32_t memory[MEMORY_SIZE] = { 0 }; enum InstructionEnum { HLT = 0b00000, // Halt LDR = 0b00010, // Load mem into Rn STR = 0b00011, // Store Rn into mem INP = 0b00100, // Store input in Rn OUT = 0b...
#include <iostream> #include <vector> #include <queue> #include <limits.h> using namespace std; class SortCollection { public: // 1.冒泡排序:O(n^2) 稳定 vector<int> bubble_sort(vector<int> nums) { int n = nums.size(); for (int i = 0; i < n-1; i++) for (int j = 0; j < n-1-i; j++) ...
#include "circuit.h" #include "logic.h" #include <vector> #include <fstream> #include <string> #include <tuple> #include "line_iterator.h" using std::ifstream; using std::string; using std::get; using std::make_tuple; using std::make_pair; void conditional_emplace(string g, LogicType t) { } std::vector<std::string>...
#include "robot_car.hpp" #include <sstream> #include <algorithm> #include <math.h> #include <GoPiGo3.h> RobotCar::RobotCar() : _motor_left(0), _motor_right(0), _power_difference(0), _current_color(""), _last_color(""), ...
/* * ***** BEGIN GPL LICENSE BLOCK ***** * * 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 is d...
#include "StdAfx.h" #include <iostream> #define GLM_FORCE_RADIANS #include "glm/glm.hpp" #include "Source.h" //Main int main() { LPTSTR windowClass; // Window Class windowClass = MAKEINTATOM(registerClass(GetModuleHandle(NULL))); if (windowClass == 0) { //showMessage(L"registerClass() failed."); MessageBox(null...
/* * @file graphm.cpp * @brief This class represents a graph using an adjacency matrix. A second * matrix is used to store the shortest path from each node to every * other node. This matrix is populated by invoking findShortestPath() * on a graph. Dijkstra's algorithm is used to de...
/* * Copyright (C) 2015, <NAME> * TU Darmstadt - Graphics, Capture and Massively Parallel Computing * All rights reserved. * * This software may be modified and distributed under the terms * of the BSD 3-Clause license. See the LICENSE.txt file for details. */ #include <iomanip> #include <iostream> #include <cs...
// FFMPEG Video Encoder Integration for OBS Studio // Copyright (c) 2019 <NAME> <<EMAIL>> // // 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 limitati...
#include "src/s3_cmds/zgw_s3_bucket.h" #include "slash/include/env.h" #include "slash/include/slash_hash.h" #include "src/s3_cmds/zgw_s3_xml.h" #include "src/zgw_utils.h" bool ListMultiPartUploadCmd::DoInitial() { all_virtual_bks_.clear(); http_response_xml_.clear(); if (!TryAuth()) { DLOG(INFO) << "ListMu...
//---------------------------------------------------------------------------- // // TSDuck - The MPEG Transport Stream Toolkit // Copyright (c) 2005-2020, <NAME> // All rights reserved. // // Redistribution and use in source and binary forms, with or without // modification, are permitted provided that the following c...
//LIC// ==================================================================== //LIC// This file forms part of oomph-lib, the object-oriented, //LIC// multi-physics finite-element library, available //LIC// at http://www.oomph-lib.org. //LIC// //LIC// Copyright (C) 2006-2022 <NAME> and <NAME> //LIC// //LIC// This lib...
#include <AMReX.H> #include <AMReX_ParmParse.H> #include <AMReX_MultiFab.H> #include <AMReX_Geometry.H> #include <AMReX_BoxArray.H> #include <AMReX_MultiCutFab.H> #include <AMReX_EBFArrayBox.H> #include <AMReX_EBFabFactory.H> #include <AMReX_DistributionMapping.H> #include <AMReX_EB2.H> #include <AMReX_EB2_IF_Torus....
/* * PlayState.cpp * Example gameplay: ball-hits-sheep, with physics... * * Created by <NAME> on R0515. * Copyright 2015 PUCRS. All rights reserved. * */ #include <iostream> #include <cmath> #include "Game.h" #include "PlayState_Solution.h" #include "InputManager.h" PlayState PlayState::m_PlayState; using...
/* Copyright (c) 2014, The Linux Foundation. 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 source code must retain the above copyright notice, this list of co...
/* Copyright 2016-2020 Intel Corporation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in w...
/* Copyright (c) 2010 <NAME> (http://www.visual-experiments.com) 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 "replication_api.h" #include <fstream> #include <thread> #include "core/cjson/jsonbuilder.h" #include "core/dbconfig.h" #include "tools/fsops.h" #include "vendor/gason/gason.h" const std::string ReplicationApi::kStoragePath = "/tmp/reindex_repl_test/"; const std::string ReplicationApi::kReplicationConfigFile...
/* <:copyright-BRCM:2016-2020:Apache:standard Copyright (c) 2016-2020 Broadcom. All Rights Reserved The term “Broadcom” refers to Broadcom Inc. and/or its subsidiaries 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 ...
#include <GL/glew.h> #include <GLFW/glfw3.h> #include <SOIL2/soil2.h> #include <Box2D/Box2D.h> #include <soloud.h> #include <soloud_speech.h> #include <soloud_thread.h> #include <soloud_wav.h> #include <soloud_wavstream.h> #include <soloud_modplug.h> #include <stdlib.h> #include <stdio.h> #include <iostream> #include...
/* Copyright 2000-2004 KnowNow, Inc. All rights reserved. @KNOWNOW_LICENSE_START@ 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, this list of cond...
#include "testApp.h" //-------------------------------------------------------------- void testApp::setup() { ofBackground(0, 0, 0); ofSetVerticalSync(true); ofSetLineWidth(3.0); vboMode = 0; // ------------------------- Particles 2d Vbo particleCount = 0; for(int i=0; i<NUM_PARTICLES; i++) { particlePos...
/* * Copyright 2018-present Facebook, 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 a...
// Copyright (c) 2009 The Chromium 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 "chrome/browser/views/bubble_border.h" #include "app/gfx/canvas.h" #include "app/gfx/path.h" #include "app/resource_bundle.h" #include "base...
#pragma once #include "map/bookmark_manager.hpp" #include <functional> #include <string> enum class RouteMarkType : uint8_t { // Do not change the order! Start = 0, Intermediate = 1, Finish = 2 }; struct RouteMarkData { std::string m_title; std::string m_subTitle; RouteMarkType m_pointType = RouteMark...
// Copyright 2017 <NAME>, 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, // modify, merge, publish, d...
#include "gfx.hpp" #include "ili9341_t3n_font_Arial.h" #include "ili9341_t3n_font_ArialBold.h" #include "log.hpp" struct point { uint8_t x; uint8_t y; }; point corner[5] = {{4, 1}, {3, 1}, {2, 2}, {1, 3}, {1, 4}}; void GFX::DrawBMP(const char *filename, uint16_t x, uint16_t y, ILI9341_t3n &lcd) { File bm...
#include <windows.h> #include <GL/glut.h> #include <iostream> #include <cmath> const GLdouble PI = std::acos(-1); void display(); void reshape(GLsizei width, GLsizei height); void initOpenGL(); void drawRoad(); void drawCar(); void drawMountains(); void drawSun(); namespace sazid { // Draw the string s at the sp...
#include <string> #include <iostream> #include "../../../../include/DynamsoftBarcodeReader.h" #include "../../../../include/DynamsoftCommon.h" using namespace std; using namespace dynamsoft::dbr; // Link libraries of DynamsoftBarcodeReader SDK for Windows. #if defined(_WIN64) || defined(_WIN32) #ifdef _WI...
#include <sched.h> #include <limits.h> #include <map> #include "_stopwatch.h" double nowf(void); /* * Stopwatch */ #define NANO 1000000000L static timespec zerotime = {0, 0}; static timespec maxtime = {LONG_MAX, NANO}; static inline timespec now() { struct timespec tp; clock_gettime(CLOCK_MONOTONIC, &tp); retur...
#include "SpecializedShaderProgram.h" #include <imgui.h> #include "Debug.h" #include "ShaderProgram.h" #include "RenderPass.h" #include "Pipeline.h" #include "Material.h" #define SHADER_CODE_ERROR_VS "#version 420 core\n#pragma pass opaque\nlayout (location = 0) in vec3 vp;\nlayout (std140, binding = 1) uniform Camer...
#include <cstdio> #include <cfloat> #include <chrono> #include <ctime> #include <cmath> #include "matrix.h" #include "utils.h" void divideIntoLUD(Matrix *A, Matrix **L, Matrix **U, Matrix **D) { *L = createMatrix(A->size, true); *U = createMatrix(A->size, true); *D = createMatrix(A->size, true); for (int i = 0; i ...
/**************************************************************************** * * Copyright (C) 2022 PX4 Development Team. 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. Redistri...
 #include "cbase.h" #include "editorCommon.h" static CMaterialSysDeletionHelper gMatSysDelHint; CMaterialSysDeletionHelper *GetMatSysShutdownHelper() { return &gMatSysDelHint; }; RTDef::RTDef() { szRTName[0] = '\0'; ref = NULL; Format = IMAGE_FORMAT_RGBA8888; DepthMode = MATERIAL_RT_DEPTH_NONE; ...
#define IL2CPP_FUNC_VISIBILITY public #include "register.hpp" #include "logging.hpp" // Ensure we can see the il2cpp-functions "private" held values #include "beatsaber-hook/shared/utils/il2cpp-functions.hpp" #include "beatsaber-hook/shared/utils/hooking.hpp" #include "beatsaber-hook/shared/utils/capstone-utils.hpp" t...
//===-- FileSystemTest.cpp ------------------------------------------------===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===---------------------------...
/* * Copyright 2019 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 required by applica...
#include "common/timer.h" #include "common/utils.h" #include "marian.h" #include "service/api/json_request_handler.h" #include "service/common/translation_service.h" #include "translator/beam_search.h" #include "translator/output_printer.h" #include <cstdlib> #include <sstream> #pragma GCC diagnostic push #pragma GCC ...
// #include <ESP8266WiFi.h> #include <Adafruit_NeoPixel.h> #include <Adafruit_NeoMatrix.h> #include <Adafruit_GFX.h> // #include <Fonts/FreeMono9pt7b.h> #include <math.h> #include <string.h> #define NUMPIXELS_1 24 #define PIN_1 D5 #define TOTAL_EFFECTS 1 #define DELAY_BETWEEN_EFFECTS 10000 // MATRIX DECLARATION: // ...
/*========================================================================= Program: ParaView Module: $RCSfile$ Copyright (c) 2005,2006 Sandia Corporation, Kitware Inc. All rights reserved. ParaView is a free software; you can redistribute it and/or modify it under the terms of the ParaView lice...
// Copyright 2014 PDFium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com #include "xfa/fde/cfde_path.h" #include "third_party/base/stl_util.h" void C...
// Copyright 2020 <NAME> #include <mpi.h> #include <vector> #include <random> #include <ctime> #include <algorithm> #include <iostream> #include "./ops_mpi.h" std::vector<double> getRandomVector(int n) { std::vector<double> vec(n); double lower_bound = -100.0; // Why? double upper_bound = 100.0; // Why? ...
#include <cstdio> #include <cstdlib> #include <CL/cl.h> #include <chrono> // This is a macro for checking the error variable. #define CHK_ERROR(err) if (err != CL_SUCCESS) fprintf(stderr,"Error: %s\n",clGetErrorString(err)) #define ARRAY_SIZE 100000000 // A errorCode to string converter (forward declaration) const c...
/* Copyright (c) 2015-2017 <NAME>, <NAME>, <NAME>, <NAME> 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, modify, me...
/*************************************************************************/ /* collision_polygon_2d.cpp */ /*************************************************************************/ /* This file is part of: */ /* ...
#include "DamicBackSideCalibrationFit.h" std::array<double, npar> nominalParameters = {0.00745023, 0.027043, 0.00371954, 0.0728877, -0.0416052, 0.00999033, -0.0011136, 4.68929e-05, 0, 1}; double fpcc(double *x, double * par){ // Check to see if we are outside PCC region double shift = 675; if(x[0] < (shift - 7 / ...
// test.cpp --- // // Filename: test.cpp // Description: // Author: <NAME>, <NAME> // Maintainer: <NAME> // Created: Tue Mar 3 17:47:28 2015 (+0100) // Version: 0.5a // Package-Requires: () // Last-Updated: Tue Jun 16 17:09:04 2015 (+0200) // By: Kwang // Update #: 26 // URL: // Doc URL: // Keywords...
//=---------------------------------------------------------------------= // // $Id$ $Name$ // // The contents of this file are subject to the AAF SDK Public Source // License Agreement Version 2.0 (the "License"); You may not use this // file except in compliance with the License. The License is available // in AAFSD...
#include "ros/ros.h" #include "std_msgs/String.h" #include <iostream> #include <ctype.h> #include <unistd.h> #include "geometry_msgs/PoseStamped.h" char robot1[10]; char robot2[10]; int cnt = 0; int flag1 = 1; int flag2 = 1; ros::Publisher ctrl_pub1; ros::Publisher ctrl_pub2; void number_callback(const std_msgs::Strin...
// ========================================================================== // // Copyright (c) 2014-2020 The University of Texas at Austin. // // All rights reserved. // // ...
/* certreqgen-ui.c - Simple user interface for certreqgen.c * Copyright (C) 2007, 2010, 2011 Free Software Foundation, Inc. * * This file is part of GnuPG. * * GnuPG 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 ...
#include "control.h" #include "endpoints.h" #include <optimsoc-baremetal.h> #include "../include/optimsoc-baremetal.h" #ifdef RUNTIME #include <optimsoc-runtime.h> #endif #include <stdlib.h> #include <assert.h> #include <stdio.h> unsigned int timeout_insns = 1000; #define EXTRACT(x,msb,lsb) ((x>>lsb) & ~(~0 << (ms...
/** * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. */ #include "blingfire-compile_src_pch.h" #include "FAConfig.h" #include "FASelectTrPatterns.h" #include "FALimits.h" #include "FARSDfaCA.h" #include "FAMealyDfaCA.h" #include "FAMultiMapCA.h" #include "F...
#include "global.h" #include "camera.h" #include "timer.h" #include "scene.h" #include "plane.h" #include "sphere.h" #include "triangle.h" #include "light.h" #include "grouplist.h" #include "grouptree.h" #include "shadowshader.h" #include "textureshader.h" #include "texturesphereshader.h" #include "reflectionshader.h"...
#include "HttpEnv.h" #include "logging.h" #include <algorithm> #include <cstring> #include <stdio.h> HttpEnv::HttpEnv() { } HttpEnv::~HttpEnv() { for (auto& file : files) { remove(file.second.path.c_str()); } } char* HttpEnv::percentEscapedToRealBytes( const char* start, const char* end, ...
/**********************************************************************************/ /* This file is part of spla project */ /* https://github.com/JetBrains-Research/spla */ /****************************************************************...
/* Copyright 2016-2020 Intel Corporation Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in w...
/* $Id: astarsearch.cpp 48426 2011-02-06 14:54:27Z ai0867 $ */ /* Copyright (C) 2003 by <NAME> <<EMAIL>> 2005 - 2011 by <NAME> <<EMAIL>> Part of the Battle for Wesnoth Project http://www.wesnoth.org/ This program is free software; you can redistribute it and/or modify it under the t...
#pragma once #include <seqan/graph_msa.h> #include <seqan/sequence.h> // Helper function for rounding to n significant digits. Ported from // Java code found here: http://stackoverflow.com/questions/202302 inline double roundToSignificantFigures(double num, int n) { if (num == 0) return 0; const dou...
/* * Copyright 2013 Google Inc. * * Use of this source code is governed by a BSD-style license that can be * found in the LICENSE file. */ #include "SkLuaCanvas.h" #include "SkRRect.h" extern "C" { #include "lua.h" } static void setfield_string(lua_State* L, const char key[], const char value[]) { lua_p...
/** Example 001 HelloWorld adapted to emscripten This Tutorial shows how to run code with emscripten. Emscripten compiles c++ to asm.js to allow it running inside a webbrowser. You have to setup the emscripten environment on your system first to use this. */ #include <irrlicht.h> #include "exampleHelper.h" #in...
/*===========================================================================*\ * * * CoMISo * * Copyright (C) 2008-2009 by Computer Graphics Group, RWTH Aachen * * ...
/****************************************************************************** * * Project: WCS Client Driver * Purpose: Implementation of RasterBand classes for WCS. * Author: <NAME>, <EMAIL> * ****************************************************************************** * Copyright (c) 2006, <NAME> * Co...
////////////////////////////////////////////////////////////////////////// // @name timed_state_space.cc => Code that implements timed_state_space // class defined in bap.h // @version 0.1 alpha // // (c)opyright 2001 by <NAME> // // @author <NAME> ////////////////////////////////////////////////////////////////...
/* * (c) Copyright 2020 Xilinx, Inc. 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 by ap...
/***************************************************************************** * * $Id$ * * Copyright (C) 2006-2009 <NAME>, Ingenieurgemeinschaft IgH * * This file is part of the IgH EtherCAT Master. * * The IgH EtherCAT Master is free software; you can redistribute it and/or * modify it under the terms ...
// Copyright 2016 Google 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 agreed to in wri...
/** * @file TemporalCentroid.cpp * @author <NAME> <<EMAIL>> * @version 1.0 * * @section LICENSE * * MIR.EDU * * A vamp plug-in library for teaching MIR. * Copyright (C) 2013-2014 <NAME>. * * MIR.EDU is free software: you can redistribute it and/or modify * it under the terms of the GNU Gene...
#include <cmath> #include <ctime> #include <iostream> #include <memory> #include <string> #include <unordered_map> #include <vector> #include "option_portfolio.h" #include "pricing.h" /* Implementation Pricing functions */ float Pricing::fixed_mc(Instrument::Params &instr, std::vector<std::ve...
#define _USE_MATH_DEFINES // for C++ #include "mex.h" #include <windows.h> #include <stdio.h> #include <process.h> #include <string.h> #include <time.h> #include <cmath> /*These global variables will be accessible to both threads and will exist *in the MEX function through multiple calls to the MEX fun...
#include "FileImportFactory.h" #include "MeshImpl.h" #include "DynamicArray.h" #include <assimp/Importer.hpp> #include <assimp/postprocess.h> #include <assimp/scene.h> #include <string> #include <mutex> using namespace Leviathan; LSPtr<IFileImportFactory> FileImportFactory::m_spFileImportFactory = nullptr; std::vect...
/*************************************************************************** * * 18.atomic.xchg.cpp - test exercising the __rw_atomic_exchange() function * template * * $Id$ * *************************************************************************** * * Licensed to the Apache Software F...
/* * Abuse - dark 2D side-scrolling platform game * Copyright (c) 1995 Crack dot Com * Copyright (c) 2005-2011 <NAME> <<EMAIL>> * * This software was released into the Public Domain. As with most public * domain software, no warranty is made or implied by Crack dot Com, by * <NAME>, or by <NAME>. */ #if ...
/* * EdUrlParser.cpp * * Created on: Nov 25, 2014 * Author: netmind */ #include "EdUrlParser.h" #define CHECK_LEN_END(POS, LEN) if(POS>=LEN) {_url_errorno=100;goto __PARSE_END;} #define WALK_SP(POS, LEN, BUF) for(;POS<LEN && BUF[POS]==' ';POS++) #define WALK_UNTIL(POS, LEN, BUF, DELC) for(;POS<LEN && BUF[P...
#include <iostream> #include <iomanip> #include <cmath> #include "ufVincenty.h" using std::sin; using std::asin; using std::cos; using std::acos; using std::abs; using std::pow; using std::tan; using std::atan; using std::atan2; using std::sqrt; using namespace UF::GeographicConversions; Vincenty::Vincenty (std::st...
#ifdef CH_LANG_CC /* * _______ __ * / ___/ / ___ __ _ / / ___ * / /__/ _ \/ _ \/ V \/ _ \/ _ \ * \___/_//_/\___/_/_/_/_.__/\___/ * Please refer to Copyright.txt, in Chombo's root directory. */ #endif #include <stdio.h> #include "BoxIterator.H" #include "ParmParse.H" #include ...
/*========================================================================= Copyright 2009 Rensselaer Polytechnic Institute 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/lice...
#include <vector> #include <iterator> #include "window_game.h" #include "yaml.h" #include "worm.h" #include "camera.h" #include <limits.h> #define MAP_WIDTH 2500 #define MAP_HEIGHT 1500 #define BACKGROUND_PATH "/usr/etc/worms/temp/background.png" View::WindowGame::WindowGame(YAML::Node & staticNode, int w, int h, boo...
/** * raflvis: main.cpp * Copyright (c) Torr Vision Group, University of Oxford, 2015. All rights reserved. */ #include <boost/assign/list_of.hpp> #include <boost/format.hpp> using boost::assign::list_of; #include <evaluation/core/ParamSetUtil.h> #include <evaluation/core/PerformanceMeasure.h> #include <evaluation...
/* * Copyright 2001-2018 <NAME> <<EMAIL>> * * 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, modify, merge, p...
#include "../ApplicationSFML.h" #include "Graphics2D/GraphicsMgr.h" #include "GUI/GUIMgr.h" #include "Resource/ResourceMgr.h" #include "GamePlay/GameMgr.h" #include "Base/MsgLogger.h" #include <SFML/System/Sleep.hpp> #include <SFML/Graphics/Text.hpp> #include <SFML/Window/Event.hpp> #include <SFML/Window/Event.hpp> #in...
#include "ECChaser.h" #include "ECFieldOfViewEmitter.h" #include "ECPathMover.h" #include "Map.h" #include "Game.h" #include "QtUtilities.h" using namespace qge; ECChaser::ECChaser(Entity* entity): EntityController(entity), stopDistance_(100), fovEmitter_(new ECFieldOfViewEmitter(entity)), pathMover_...
//////////////////////////////////////////////////////////////////////////////// /// DISCLAIMER /// /// Copyright 2014-2016 ArangoDB GmbH, Cologne, Germany /// Copyright 2004-2014 triAGENS GmbH, Cologne, Germany /// /// Licensed under the Apache License, Version 2.0 (the "License"); /// you may not use this file except...
#include "model.h" vector<Mesh> meshes; Mesh createMesh(vector<Vertex> vertices, vector<GLuint> indices, mat4 transform, Material material, BoundingBox bb) { Mesh m; m.elements = indices.size(); m.transform = transform; m.material = material; m.bb = bb; glGenVertexArrays(1, &m.vao); glGenBuffers(1, &m.vbo); ...
/* * Copyright (C) 2011-2017 Redis Labs Ltd. * * This file is part of memtier_benchmark. * * memtier_benchmark 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, version 2. * * memtier_benchmark is distr...
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////// // Copyright (c) Microsoft Corporation. All rights reserved. /////////////////////////////////////////////////////////...
/* * Adapted from scipy/special/chephes/ndtri.c * The original code is licensed under BSD. * * Inverse of Normal distribution function * * * * SYNOPSIS: * * double x, y, inv_norm_cdf(); * * x = inv_norm_cdf( y ); * * * * DESCRIPTION: * * Returns the argument, x, for which the area under the * Gau...
// Jim and his LAN Party // https://www.hackerrank.com/challenges/jim-and-his-lan-party // In C++14. #include <algorithm> #include <cassert> #include <cstdlib> #include <iostream> #include <iterator> #include <memory> #include <numeric> #include <unordered_map> #include <utility> #include <vector> namespace { voi...
#include <glm/glm.hpp> #include <vector> #include <png.h> #include "world.h" #include "sphere.h" #include "surface.h" #include "image.h" #include "parse.h" #include <cstdio> #define CAST(x) ((Object *)(x)) static const float view_width = 720.0f, view_height = 405.0f; static const int width = 3600, height = 2000; co...
/**************************************************************************** * * * Name: <NAME> * * Class: CS202 Professor Fant * * Assig...
/*========================================================================= Program: Image Guided Surgery Software Toolkit Module: $RCSfile: MultiTrackerLogger.cxx,v $ Language: C++ Date: $Date: 2011-03-17 20:12:26 $ Version: $Revision: 1.00 $ Copyright (c) ISC Insight Software Consortium....
// This file is a part of the OpenSurgSim project. // Copyright 2013, SimQuest Solutions 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/LICE...
/** * @file heap_storage_test.cpp * @author <NAME>) Ta, <NAME> * @brief tests for the heresy that is pointer arithmetic, bc otherwise I might die debugging * @version 0.1 * @date 2022-04-13 */ #include "db_cxx.h" #include "heap_storage.h" #include <string.h> #include <memory> DbEnv *_DB_ENV; const unsigned int...
//------------------------------------------------------------------------------- // DelftOnline -- General Utilities // // <EMAIL> // 30 jun 12 //------------------------------------------------------------------------------- //---- LGPL -------------------------------------------------------------------- // // Cop...
#include "usb/device.hpp" #include "usb/descriptor.hpp" #include "usb/setupdata.hpp" #include "usb/classdriver/base.hpp" #include "usb/classdriver/keyboard.hpp" #include "usb/classdriver/mouse.hpp" #include "logger.hpp" namespace { class ConfigurationDescriptorReader { public: ConfigurationDescriptorReader(...
#include "UnixTime.h" double YearUnixT[101]; bool PopYearUnixT = false; /*********************************************************************** * NAME : void PopulateYearUnixT() * * DESCRIPTION : Calculates the unix time in hours since 00:00 * on 19700101 for all years between 1950 and 2050 * * *****...