text stringlengths 3.08k 22k |
|---|
/* ************************************************************************
* Copyright 2016-2021 Advanced Micro Devices, Inc.
*
* ************************************************************************ */
#include <stdio.h>
#include <stdlib.h>
#include <vector>
#include "testing_common.hpp"
using namespace std;... |
/*
Copyright 2014 Google 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 applicable law or agreed to in ... |
//=================================================================================//
// Copyright (c) 2021 <NAME>
//=================================================================================//
#include "simpleMesh.h"
//< counter-clockwise winding order
static float s_cubeVertices[] =
{
//< Posi... |
/*
* Copyright (C) 2017-2018 <NAME>
*
* This source code is provided 'as-is', without any express or implied
* warranty. In no event will the author be held liable for any damages
* arising from the use of this software.
*
* Permission is granted to anyone to use this software for any purpose,
* i... |
#include "glad/glad.h"
#include "GLFW/glfw3.h"
#include "camera.hpp"
#include "shader.hpp"
//#define QUAD
#define PI 3.14159265
void framebuffer_size_callback(GLFWwindow *window, int w, int h);
void mouse_callback(GLFWwindow *window, double xpos, double ypos);
void scroll_callback(GLFWwindow *window, double xoffse... |
/*
* Copyright (C) 2017 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... |
//============================================================================
// Name : ubuntu_researchUtil2.cpp
// Author : kimcholmin
// Version :
// Copyright : kimcholmin
// Description : Hello World in C++, Ansi-style
//============================================================================... |
/*
* tester.cc
*
* created on: 11.05.2017
* author: <NAME>
*/
#include <array>
#include <iostream>
#include "cuddObj.hh"
#include "nfts.hh"
#include "SymbolicDetector.hh"
using namespace std;
using namespace scots;
#define SS_DIM 1
#define IS_DIM 1
#define OS_DIM 1
typedef array<double,SS_DIM> state_t... |
// Copyright (C) 2021 Intel Corporation
// SPDX-License-Identifier: Apache-2.0
//
#pragma once
#include <cudnn.h>
#include <functional>
#include <ngraph/type/element_type.hpp>
#include <optional>
#include "constant_factory.hpp"
#include "runtime.hpp"
inline std::string cudnnGetErrorString(cudnnConvolutionFwdAlgo_t... |
#include <Kross_pch.h>
#include "VoxelRenderer.h"
#include "Kross/Core/Application.h"
#include "Kross/Core/Stack.h"
#include "Renderer.h"
#include "RenderTypes.h"
#include "VertexArray.h"
#include "Textures/Array.h"
#include <inttypes.h>
static constexpr size_t MaxQuadCount = 2048;
static constexpr size_t MaxVertex... |
#include <volentixstak.hpp>
void volentixstak::registrglobl(name owner, uint64_t stake_id, asset quantity ){
lck_accounts lock_from_acnts(_self, owner.value);
const auto &lock_from = lock_from_acnts.get(stake_id, "No such stake object found with provided stake_id");
global_amounts global_amnt(_self, _self.v... |
// Source: https://github.com/ssloy/tinyraytracer/blob/master/tinyraytracer.cpp
// Source license: DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
#pragma GCC optimize("Ofast")
#include "geometry.h"
extern "C" {
#include <libdragon.h>
}
#include <limits>
#include <fstream>
#include <vector>
#include <algorithm>
#defi... |
#include "Graphics/Program.h"
Program::Program() {
this->_g = GLFuncs::GetInstance();
this->_shaderMgr = ShaderMgr::GetInstance();
Program::_programs.push_back(this);
this->_inUse = false;
}
Program::Program(vector<string> vertexShaders, vector<string> fragmentShaders) : Program() {
for (string shaderFile : vert... |
//
// Copyright (C) Microsoft. All rights reserved.
//
#include "stdafx.h"
#include "AdapterTest.h"
#include "WebSocketHandler.h"
#include <boost/filesystem.hpp>
#include <assert.h>
#include <cassert>
using namespace std;
using namespace boost::filesystem;
AdapterTest::AdapterTest(WebSocketHandler *handler, HWND adp... |
#include "../TileMap.h"
#include "../Terrain.h"
#include "../../Debugger.h"
#include <GFX/gl_engine.h>
#include <tools_utilities.h>
#include <iostream>
#define LOWBITS 5
#define terrain_index( a, b ) ( ( ( b ) * terrain_width ) + ( a ) )
#define chunk_index( a, b ) ( ( ( b ) * width ) + ( a ) )
inline uint32 Chunk... |
/*
Copyright (c) 2014, <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 source code must retain the above copyright
notice, this list of condit... |
#include "core/renderer.h"
#include "core/global_clock.h"
#include "ui/views/views.h"
// ----------------------------------------------------------------------------
Renderer::~Renderer() {
particle_.deinit();
hair_.deinit();
grid_.deinit();
skybox_.deinit();
gizmo_.deinit();
postprocess_.deinit();
}
vo... |
/*
* Copyright 2004-2008, <NAME>, <<EMAIL>>.
* Distributed under the terms of the MIT License.
*/
/*
* stream based deframer
* has a state machine and handles each packet separately.
* much more complex than the buffering one, and I thought it didn't work,
* but since I fixed the rest it seems to be working eve... |
// Fill out your copyright notice in the Description page of Project Settings.
#include "UMod.h"
#include "LuaEngine.h"
#include "UModGameInstance.h"
#include "Renderer/Render2D.h"
#include "Renderer/Render3D.h"
#include "Lib.h"
#include "LibsInclude.h"
#include "Entities/EntityBase.h"
//TArray<LuaLib*> LuaEngine:... |
/****************************************************************************
**
** Copyright (C) 2015 The Qt Company Ltd.
** Contact: http://www.qt.io/licensing/
**
** This file is part of the examples of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL21$
** Commercial License Usage
** Licensees holding valid commercial ... |
#include "settings.h"
#include "logger.h"
#include <sstream>
#include <fstream>
bool SettingType::parseLong(cstr_t &str, long *v, int base)
{
const char *start = str.c_str();
return parseLong(&start, v, base);
}
bool SettingType::parseLong(const char **pos, long *v, int base)
{
char *endp = nullptr;
long val = st... |
#include "Grid.h"
#include "Flux.h"
#include <math.h>
#include <gtest/gtest.h>
using namespace ibpm;
#define EXPECT_ALL_X_EQUAL(a,b) \
for (int lev=0; lev<_ngrid; ++lev) { \
for ( int i=0; i<_nx+1; ++i ) { \
for ( int j=0; j<_ny; ++j ) { \
E... |
/***************************************************************
* Fan Animation
* Author: <NAME>
* email: <EMAIL>
* Last update: April 15 2021
***************************************************************/
//File Input Headers for reading from VRML file
#include <Inventor/SoInput.h>
// SoWin headers for th... |
// Copyright by <NAME>
// 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 distributed in the hop... |
/*=========================================================================
Program: GDCM (Grassroots DICOM). A DICOM library
Copyright (c) 2006-2011 <NAME>
All rights reserved.
See Copyright.txt or http://gdcm.sourceforge.net/Copyright.html for details.
This software is distributed WITHOUT ANY WARRANTY... |
/*!
* Copyright 2017 by Contributors
* \file cli_main.cc
* \brief The command line interface program of treelite.
* \author <NAME>
*/
#include <treelite/frontend.h>
#include <treelite/annotator.h>
#include <treelite/compiler.h>
#include <treelite/semantic.h>
#include <dmlc/config.h>
#include <dmlc/data.h>
#includ... |
//
// Created by <EMAIL>(抖音id:cyberdash_yuan) on 2021/2/4.
//
#include "graph_algorithm.h"
#include <iostream>
template<class T, class E>
void DFS(Graph<T, E>& graph, const T& vertex) {
set<T> visited_vertex_set;
DFSOnVertex(graph, vertex, visited_vertex_set);
}
/**
* @brief 图节点深度优先遍历(递归)
* @tparam T 节点模板类... |
// Copyright (C) 2018-2020 <NAME> All Rights Reserved.
#include <QtGui/QMessageBox>
#include "dzapp.h"
#include "dzscene.h"
#include "dzexportmgr.h"
#include "DzFileIOSettings.h"
#include "dzexporter.h"
#include "dzmainwindow.h"
#include "dzmaterial.h"
#include "dzproperty.h"
#include "QtCore/qfile.h"
#include "QtCor... |
// Copyright 2015-2016 Espressif Systems (Shanghai) PTE LTD
//
// 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 "base/color.hpp"
#include "boost/tokenizer.hpp"
#include "core/plan/runner.hpp"
#include "core/index/range_key_to_part_mapper.hpp"
#include <cmath>
#include <string>
DEFINE_string(url, "", "The url for hdfs file");
DEFINE_int32(num_data, -1, "The number of data in the dataset");
DEFINE_int32(num_params, -1,... |
#include "pch.h"
#include "WsClient.h"
#include <utility>
#include <iostream>
#include <assert.h>
#define WS_MESSAGE_MAX_SIZE 32768
#define WS_KEEPALIVE_INTERVAL 10
WsClient::WsClient(std::string address, int port, std::string url, std::string ca_path, WsCallback* callback) {
this->address_ = address;
this->port... |
#define BIORBD_API_EXPORTS
#include "Utils/Equation.h"
#include <boost/lexical_cast.hpp>
#include "Utils/Error.h"
std::vector<biorbd::utils::Equation> biorbd::utils::Equation::prepareMathSymbols(){
// Classés en ordre de priorité des opérations
std::vector<biorbd::utils::Equation> symbols;
symbols.push_ba... |
/*
* Copyright (c) 2011, 2021, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under the terms of the GNU General Public License version 2 only, as
* published by the Free ... |
/****************************************************************************
**
** Copyright (C) 2016 The Qt Company Ltd.
** Contact: https://www.qt.io/licensing/
**
** This file is part of the demonstration applications of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:BSD$
** Commercial License Usage
** Licensees holding v... |
#include <unistd.h>
#include <algorithm>
#include <cassert>
#include <cinttypes>
#include <cstdlib>
#include <iostream>
#include <thread>
#include <vector>
#include "defs.h"
#include "config.h"
#include "rpc_call.h"
#include "rpc_client.h"
#include "rpc_client_pool.h"
#include "rpc_types.h"
#include "utils.h"
#includ... |
/*
* Copyright 2017 <NAME>
*
* 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 ... |
/*---------------------------------------------------------------------------*\
Copyright (C) 2011-2015 OpenFOAM Foundation
-------------------------------------------------------------------------------
License
This file is part of CAELUS.
CAELUS is free software: you can redistribute it and/or modify it
... |
/*
*/
#include <stdlib.h>
#include <RooRealVar.h>
#include <RooRealSumPdf.h>
#include <RooProduct.h>
#include <RooPlot.h>
#include <RooWorkspace.h>
#include <TCanvas.h>
#include "Hzzws/ParametrizedSample.h"
#include "Hzzws/SampleHist.h"
#include "Hzzws/SampleKeys.h"
#include <RooStats/HistFactory/RooBSpline.h>
void ... |
#include "plugin.hpp"
#include "Widgets.hpp"
#include "Util.hpp"
#include <algorithm> // std::replace
const float MIN_EXPONENT = -3.0f;
const float MAX_EXPONENT = 1.0f;
// quick and dirty copy-paste of LittleUtils PulseGenerator.
// TODO: move modules that are shared with LittleUtils common folder
// TODO: show samp... |
/**
* @file ncl.cpp
*
*/
#include "ncl.h"
#include "forecast_time.h"
#include "level.h"
#include "logger.h"
#include "plugin_factory.h"
#include <boost/lexical_cast.hpp>
#include "neons.h"
#include "radon.h"
using namespace std;
using namespace himan::plugin;
const string itsName("ncl");
ncl::ncl() : itsBottomL... |
/* functions for managing a stack of file and buffer input streams. */
/*
Copyright (c) 2001, <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:
o Redistributions of source code must retain the ab... |
#include "collisionsystem.h"
#include "world.h"
#include "Components/collision.h"
#include "Components/gui.h"
#include "Components/transform.h"
#include "GSL/matrix4x4.h"
#include "Components/camera.h"
#include "GSL/gsl_math_extensions.h"
void CollisionSystem::tick(float /*deltaTime*/)
{
for (auto const& entity : ... |
#include <cstdio>
#include <cstdlib>
#include <optional>
#include "sha.hpp"
#include "sha_test.hpp"
using B = std::byte;
const std::size_t NUM_TESTCASES = 16;
const testcases_t<crypto::sha::sha512_256_hash, NUM_TESTCASES> testcases{
{{"",
{B{0xc6}, B{0x72}, B{0xb8}, B{0xd1}, B{0xef}, B{0x56}, B{0xed}, B{0x2... |
//
// gameState.cpp
// Mississippi10
//
// Created by <NAME> on 8/24/13.
// Copyright (c) 2013 __MyCompanyName__. All rights reserved.
//
#include <iostream>
#include <math.h>
#include "gameState.h"
#include "enemy.h"
gameState::gameState(int w,int h,int frames,float timeperframe,float nRad,vector2 gravity):w(w),h... |
/*/////////////////////////////////////////////////////////////////////////////
/// @summary Implements a rectangle packer using an (unbalanced) binary tree
/// subdividing the space in the master rectangle. The algorithm is described
/// at http://www.blackpawn.com/texts/lightmaps.
/// @author <NAME> (<EMAIL>)
///////... |
#include <cstdio>
#include <iostream>
#include <algorithm>
#include <vector>
#include <cstring>
using namespace std;
#define cmax(a, b) ((a) < (b) ? (a) = (b) : 0)
#define rep(i, x, y) for (int i = (x), _ = (y); i < _; ++i)
#define dow(i, x, y) for (int i = (x) - 1, _ = (y); i >= _; --i)
#define bin(x) (1 << (x))
nam... |
#include "../Common/CellGrid3D.h"
#include "../Common/SelectionSet.h"
#include "../Common/Timer.h"
#include "../Common/Heightmap.h"
#include "../Common/Xml.h"
#include "../Common/Obj.h"
#include <iostream>
const char EARTH = 'e';
const char AIR = 'a';
const char COAL = 'c';
const char DRILL = 'd';
const... |
// C3-5.cpp : This file contains the 'main' function. Program execution begins and ends there.
// 20201203 <NAME>
#include <iostream>
#include <string>
#include <vector>
#include <ctime>
#include <cstdlib>
using namespace :: std;
int ncexpr()
{
return 1;
}
constexpr int cexpr()
{
return 1;
}
void iprint(i... |
/*
Name: syskbd
Copyright: Copyright (C) SIL International.
Documentation:
Description:
Create Date: 22 Jan 2007
Modified Date: 3 Feb 2015
Authors: mcdurdin
Related Files:
Dependencies:
Bugs:
Todo:
Notes: ... |
#include "logger.h"
#include "../utils/mem.hpp"
#include "../utils/utils.h"
logger* l = nullptr;
logger::logger( )
{
auto main = GetModuleHandle( nullptr );
auto get_function_start = [=]( uint8_t* ptr ) -> uint8_t*
{
for ( size_t i = 0; i < 0x1000; ++i )
{
if ( *reinterpret_cast<uint32_t*>( ptr - i ) == ... |
#include <esp_log.h>
#include <esp_system.h>
#include <GeneralUtils.h>
#include <json11.hpp>
#include <iostream>
#include <sstream>
#include <functional>
#include "webserver.h"
#include "reboot.h"
#include "Config.h"
#include "REST.h"
#include "WatchDog.h"
#include "BleHidJson.h"
#include "boardconfig.h"
#include "sdk... |
//
// mcmc.cpp
// dynblp4LTE
//
// Created by <NAME> on 7/24/15.
// Copyright (c) 2015 <NAME>. All rights reserved.
//
#include <math.h>
#include <float.h>
#include "mcmc.h"
#include "tools.h"
#include "global.h"
#include "extern.h"
#include "fxpMap.h"
#include "functions.h"
void mcmc
(
int &mcID,
int &seed,
in... |
/*
* MRustC - Rust Compiler
* - By <NAME> (Mutabah/thePowersGang)
*
* hir_typeck/common.hpp
* - Typecheck common methods
*/
#pragma once
#include "impl_ref.hpp"
#include <hir/generic_params.hpp>
#include <hir/type.hpp>
// TODO/NOTE - This is identical to ::HIR::t_cb_resolve_type
typedef ::std::function<const ::... |
//! Code counter class methods for Makefiles.
/*!
* \file CMakefileCounter.cpp
*
* This file contains the code counter class methods for Makefiles.
*/
#include "CMakefileCounter.h"
/*!
* Constructs a CMakefileCounter object.
*/
CMakefileCounter::CMakefileCounter()
{
classtype = MAKEFILE;
language_nam... |
//
// main.cpp
// EMD
//
// Created by chenjie on 2020/7/14.
// Copyright © 2020 chenjie. All rights reserved.
//
#include <iostream>
#include <opencv2/highgui.hpp>
#include <opencv2/imgproc.hpp>
void help(const char * argv[]) {
std::cout << "//\nExample. Ccompare signatures from histograms with all method;" ... |
//-----------------------------------------------------------------------------
// pkg_nnebula.cc
// MACHINE GENERATED FROM
// code\nebula2\bldfiles\nebula2libs.bld
// DON'T EDIT!
//-----------------------------------------------------------------------------
#include "kernel/ntypes.h"
#include "kernel/nkernelse... |
/****************************************************************************
**
** Copyright (C) 2016 The Qt Company Ltd.
** Contact: https://www.qt.io/licensing/
**
** This file is part of Qt Creator.
**
** Commercial License Usage
** Licensees holding valid commercial Qt licenses may use this file in
** accordance w... |
/**
* particle_filter.cpp
*
* Created on: Dec 12, 2016
* Author: <NAME>
*/
#include "particle_filter.h"
#include <math.h>
#include <algorithm>
#include <iostream>
#include <iterator>
#include <numeric>
#include <random>
#include <string>
#include <vector>
#include "helper_functions.h"
using std::string;
using ... |
#include <iostream>
#include "DTLib/DTString.h"
#include "DTLib/StaticArray.h"
#include "DTLib/DynamicArray.h"
#include "DTLib/DynamicList.h"
#include "DTLib/LinkList.h"
#include "DTLib/LinkStack.h"
#include "DTLib/LinkQueue.h"
#include "DTLib/BTree.h"
#include "DTLib/ListGraph.h"
#include "DTLib/SmartPointer.h"
#inclu... |
/*
* This file is part of the statismo library.
*
* Author: <NAME> (<EMAIL>)
*
* Copyright (c) 2011 University of Basel
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
*
* Redistribu... |
#include "../include/raylib-cpp.hpp"
#include "raylib.h"
#include <algorithm>
#include <array>
#include <iostream>
namespace
{
const int SCREEN_WIDTH = 800;
const int SCREEN_HEIGHT = 450;
double Y_speed = 0.0;
const double GRAVITATIONAL_ACCELRATION = 0.07;
const double BOUNCE_FORCE = -1.2;
const int MAX_TUBES = 100;... |
#include "widgetdraw.h"
widgetDraw::widgetDraw(QWidget* parent)
: QGLWidget(parent)
{
lightEnable = false;
doubleFaceEnable = false;
infiniteEnable = false;
globalAmbientEnable = false;
diffuseColor = QColor(Qt::black);
specularColor = QColor(Qt::white);
ambientColor = QColor(Qt::white);... |
#include <iostream>
#include <windows.h>
#include <math.h>
#include <MMSystem.h>
#pragma comment (lib, "winmm.lib")
constexpr auto SAMPLING = 192000;
constexpr auto CHANNEL = 2;
constexpr auto BITSPERSAMPLE = 16;
constexpr auto MAXAMP = 32767;
constexpr auto DIV = 4;
constexpr auto BUFFERING = 10;
void createWave(L... |
/*
* 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 "ElasticPass/CircuitGenerator.h"
#include "ElasticPass/Utils.h"
#include "OptimizeBitwidth/OptimizeBitwidth.h"
#define CONTROL_SIZE 0
#define DATA_SIZE 32
//---------------------------------------------
// defined in Utils.h :
int getSuccIdxInPred(const ENode* node, const ENode* pred) {
// search for n... |
#include "SDOT/Distances/Wasserstein2.h"
#include "SDOT/Distances/LineQuadrature.h"
#include "SDOT/Distances/TriangularQuadrature.h"
#include "SDOT/Distances/RectangularQuadrature.h"
using namespace sdot;
using namespace sdot::distances;
double Wasserstein2::Evaluate(double z, double penaltyCoeff){
return z;
};
... |
// BeeWarm - Freie Universität Berlin - AG Neurobiologie
//
// Copyright © 2015 <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... |
/*
* =====================================================================================
*
* Filename: sync_unit.h
*
* Description: sync uint class definition.
*
* Version: 1.0
* Created: 09/08/2020
* Revision: none
* Compiler: gcc
*
* Author: zhulin, <EMA... |
//------------------------------------------------------------------------
// flashloader.cpp
//
// A very simple Flash loader for supporting Opal Kelly FPGA modules.
//
// For System Flash devices (USB 3.0):
// Uses the FlashEraseSector, FlashWrite, and FlashRead APIs to
// write an FPGA configuration to the Syst... |
#include "main.h"
template<class T>
T f0(T v0, T v1)
{
//return T(0.0);
return (v0 + v1) * 0.5;
}
template<class T>
T f1(T v0, T v1)
{
T v2 = v0 * 0.1 * v1 / -0.5;
T v3 = cos(sin(0.6 / -v0 + v1 * v1 * 0.7));
T v4 = 0.9 * sqrt(v3 * v3) + 1.0;
T v5 = 0.8 + pow(v4, v4);
return v5;
}
vector<double> RGToHSV(doubl... |
/*
* Copyright 2014 Samsung Research America, Inc. - SiliconValley
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#include "SkShapeStrokerPriv.h"
#include "SkGeometry.h"
#include "SkPath.h"
static void ButtCapper(SkPath* path, const SkPoint& pivot,
... |
//
// Created by <NAME> (<EMAIL>) on 17.04.18.
//
#include "PrintSystemC.h"
std::map<std::string, std::string> PrintSystemC::printModel(Model *node) {
pluginOutput.insert(std::make_pair("CMakeLists.txt", Text_CMake()));
this->ss.str("");
Text_DataTypes();
pluginOutput.insert(std::make_pair("Data_Type... |
//
// Color the map.cpp
// laboratory
//
// Created by 徐子珊 on 15/11/13.
// Copyright © 2015年 xu_zishan. All rights reserved.
//
#include <iostream>
#include <fstream>
#include <sstream>
#include <string>
#include <hash_map>
#include <vector>
using namespace std;
struct Segment{
pair<int, int> a, b... |
#include "Devices/PATADiskDevice.h"
#include "KSyms.h"
#include "Process.h"
#include "RTC.h"
#include "Scheduler.h"
#include "kmalloc.h"
#include <AK/Types.h>
#include <Kernel/Arch/i386/CPU.h>
#include <Kernel/Arch/i386/PIC.h>
#include <Kernel/Arch/i386/PIT.h>
#include <Kernel/CMOS.h>
#include <Kernel/Devices/BXVGADevi... |
/*
===============================================================================
FILE: lasexample_recover_returns_from_trajectory_in_extra_bytes.cpp
CONTENTS:
This source code serves as an example how easily you can write your own
LAS to LAS converter in case you need a complex conversion ... |
//=========================================================================
// Copyright (c) Kitware, Inc.
// All rights reserved.
// See LICENSE.txt for details.
//
// This software is distributed WITHOUT ANY WARRANTY; without even
// the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
// PURPOSE... |
/********************************************************
Stanford Driving Software
Copyright (c) 2011 Stanford University
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... |
/**************************************************************
*
* 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 y... |
/**
* @file SpectralRolloff.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 Gener... |
#include <iostream>
#include <stdio.h>
#include <stdint.h>
#include <vector>
#include <typeinfo>
#include <iterator>
#include <cstring>
#include <iomanip>
#include <new>
#include <algorithm>
#include <type_traits>
#include <new>
#include <functional>
using namespace std;
void convertTest() {
int i = 1234567890;
... |
/***************************************************************************
machine.c
Functions to emulate general aspects of the machine (RAM, ROM, interrupts,
I/O ports)
***************************************************************************/
#include "driver.h"
static int shift_data1,shift_data2,shi... |
#include "FilteringApp.hpp"
#include "input/Input.hpp"
#include "system/System.hpp"
#include "graphics/GPU.hpp"
FilteringApp::FilteringApp(RenderingConfig & config) :
CameraApp(config) {
const glm::vec2 renderResolution = _config.renderingResolution();
// Setup camera parameters.
_userCamera.projection(config.s... |
#include "rWeaponRaybeam.h"
#include "de/hackcraft/psi3d/GLS.h"
#include "de/hackcraft/psi3d/Primitive.h"
std::string rWeaponRaybeam::cname = "RAYBEAM";
unsigned int rWeaponRaybeam::cid = 5357;
rWeaponRaybeam::rWeaponRaybeam(Entity* obj) {
object = obj;
clipSize = 12;
depotSize = 1;
remaining... |
#include <quanGL.hpp>
#include <quan/constrain.hpp>
#include <quan/three_d/rotation.hpp>
#include <quan/angular_velocity.hpp>
#include <quan/atan2.hpp>
#include <quan/three_d/vect.hpp>
#include <quan/three_d/make_vect.hpp>
#include "get_torque.hpp"
namespace {
/// @todo approx this by linear function maybe?
... |
#include "kinematics.h"
/*
Kinematic Equations
distance = initial_velocity * time + 1/2 * acceleration * time^2
time = sqrt(2 * distance / acceleration)
final_velocity^2 = initial_velocity^2 + 2 * acceleration * distance
final_velocity = initial_velocity + acceleration * time
distance = (initial... |
#include "pc.h"
#include "Log.h"
#include "StringUtils.h"
#include "Platform/Window.h"
#if SMOL_OS == SMOL_OS_WIN
#include <Windows.h>
#include <stdio.h>
#else
#include <cstdarg>
#include <sys/socket.h>
#include <arpa/inet.h>
#define printf_s printf
#endif
CONSOLE_HANDLE Log::hConsole = (C... |
/**
* @file test-jump32.cpp
*
* @brief test jump function.
*
* @author <NAME> (Hiroshima University)
* @author <NAME> (The University of Tokyo)
*
* Copyright (C) 2012 <NAME>, <NAME>,
* Hiroshima University and The University of Tokyo.
* All rights reserved.
*
* The 3-clause BSD License is applied to this so... |
/////////////////////////////////////////
//
// OpenLieroX
//
// code under LGPL, based on JasonBs work,
// enhanced by <NAME> and <NAME>
//
//
/////////////////////////////////////////
// Sounds header file
// Created 29/7/02
// <NAME>
// Disable this pseudo-warning
#ifdef _MSC_VER
#pragma warning(disab... |
#pragma once
#include <vector>
#include <cstdint>
#include <map>
#include <SFML/Graphics/Sprite.hpp>
#include <SFML/Graphics.hpp>
#define LEFT_TABLE_START 0x0000 // starts at 0x0000
#define LEFT_TABLE_END 0x0FFF // left table ends at 0x0FFF
#define RIGHT_TABLE_START 0x1000 // right table starts at 0x1000
#define RIGH... |
/***************************************************************************
* tools/benchmark_disks_random.cpp
*
* Part of FOXXLL. See http://foxxll.org
*
* Copyright (C) 2009 <NAME> <<EMAIL>>
* Copyright (C) 2009 <NAME> <<EMAIL>>
* Copyright (C) 2013 <NAME> <<EMAIL>>
*
* Distributed under the Boost Sof... |
#include "Graphics/ShaderProgram.h"
#include "Core/Assert.h"
#include "Core/Log.h"
#include "Graphics/GraphicsContext.h"
#include "Graphics/Shader.h"
#include "Graphics/UniformBufferObject.h"
#include "Graphics/UniformTypes.h"
#include <algorithm>
#include <array>
#include <cstring>
#include <sstream>
#include <utili... |
//
// Created by sokol on 02.10.19.
//
#include "path_finder/storage/GraphReader.h"
#include "path_finder/graphs/Grid.h"
#include <fcntl.h>
#include <fstream>
#include <iostream>
#include <path_finder/helper/Static.h>
void pathFinder::GraphReader::readFmiFile(pathFinder::Graph &graph, const std::string &filepath) {
... |
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT license.
#include "pch.h"
#include "PrimitiveRenderer.h"
#include "Common/DirectXHelper.h"
using namespace AoaSampleApp;
using namespace DirectX;
using namespace winrt::Windows::Foundation::Numerics;
using namespace winrt::Windows::... |
#include "Event.h"
#include <assert.h>
#define DEBUG_UNPACKER 0
using namespace H4DAQ;
void Event::createOutBranches (TTree* tree,treeStructData& treeData)
{
//Instantiate the tree branches
tree->Branch("runNumber" ,&treeData.runNumber,"runNumber/i");
tree->Branch("spillNumber" ,&treeData.spillNumber,"spillNumb... |
#include <rosbag/bag.h>
#include <rosbag/view.h>
#include <sensor_msgs/JointState.h>
#include <jaco2_kin_dyn_lib/jaco2_dynamic_model.h>
#include <jaco2_kin_dyn_lib/joint_vel_pos_estimator.h>
#include <jaco2_msgs/Jaco2JointState.h>
#include <ros/ros.h>
#include <gtest/gtest.h>
using namespace Jaco2KinDynLib;
std::vect... |
/*Header-MicMac-eLiSe-25/06/2007
MicMac : Multi Image Correspondances par Methodes Automatiques de Correlation
eLiSe : ELements of an Image Software Environnement
www.micmac.ign.fr
Copyright : Institut Geographique National
Author : <NAME>
Contributors : <NAME>, <NAME>.
[1] <NAME>, <NAM... |
#include <windows.h>
#include "ncbind.hpp"
struct LongExposure {
/**/~LongExposure() { term(); }
/**/ LongExposure(iTJSDispatch2 *obj) : self(obj), buffer(0), width(0), height(0) {}
void init() {
term();
if (!GetLayerSize(self, width, height))
TVPThrowExceptionMessage(TJS_W("LongExposure.init: invalid lay... |
#include "TestHarness.h"
#include "MockSupport.h"
#include "MockSupport_c.h"
extern "C"{
#include "stm32f4xx_conf.h"
#include "stm32f4xx_rcc.h"
#include "bsp.h"
#include "pwm_driver.h"
}
#include "test_rcc_mock.h"
#include "test_gpio_mock.h"
#include "test_tim_mock.h"
TIM_TimeBaseInitTypeDef TIM2_Ini... |
/*
homework 10.8 Hugeint.cpp
*/
#include "Hugeint.h"
#include <cctype>
#include <iostream>
using namespace std;
HugeInt::HugeInt(long value) {
if (value < 0) negative = 1;
for (int i = 0; i < digits; i++)
integer[i] = 0;
for (int j = digits - 1; value != 0 && j >= 0; j--) {
integer[j] = valu... |
/*
* $Id: XMReceiverMediaPatch.cpp,v 1.39 2008/10/24 12:22:02 hfriederich Exp $
*
* Copyright (c) 2005-2008 XMeeting Project ("http://xmeeting.sf.net").
* All rights reserved.
* Copyright (c) 2005-2008 <NAME>. All rights reserved.
*/
#include "XMReceiverMediaPatch.h"
#include <opal/mediastrm.h>
#include <opal/m... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.