text
stringlengths
3.08k
22k
#include <opencv2/opencv.hpp> #include <forms/forms.hpp> #include <core/core.hpp> #include <iostream> #include <algorithm> #include <numeric> using namespace std; class ToolWidow: public nv::ui::Form { public: ToolWidow(std::string const& title, cv::Mat const &rm, cv::Mat &dm, cv::Mat &sm): nv::ui::Form(title...
#include "gstplayer.h" GstPlayer::GstPlayer(QObject *parent): IMediaPlayer(parent), playing(false), loaded(false), error(false), playingRequested(false), mustSeek(true), duration(-1), position(0), formatTime(GST_FORMAT_TIME), pipeline(0), gstObjectName("player") { GstPla...
/* BLAKE reference C implementation Copyright (c) 2012 <NAME> <<EMAIL>> To the extent possible under law, the author(s) have dedicated all copyright and related and neighboring rights to this software to the public domain worldwide. This software is distributed without any warranty. You should have...
/* * Copyright (c) 2012 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...
// ========================================================================== // // Copyright (c) 2014-2019 The University of Texas at Austin. // // All rights reserved. // // ...
#include <cstdio> #include <cstdlib> #include <cstring> #define MQTTCLIENT_QOS2 1 #include "mbed.h" #include "Timer.h" #include <cmath> #include "MQTTmbed.h" #include "MQTTClientMbedOs.h" #include "string.h" #include "stdio.h" #include "stdlib.h" #include "DS1820.h" WiFiInterface *wifi; AnalogIn light(A1); Analog...
#include "../Test.h" #include <math/math.h> // NOLINT #include <sstream> template<class T> class Vec4TestCase : public Test { bool testInitialization() { vec4<T> foo; assert(foo.x == (T)0); assert(foo.y == (T)0); assert(foo.z == (T)0); assert(foo.w == (T)0); vec4<T...
#include<bits/stdc++.h> using namespace std; const int N = 3e5 + 9; using ll = long long; int mod_inv(int a, int mod) { int b = mod, s = 1, t = 0, old_a = a; while (b) { int q = a / b; swap(a %= b, b); swap(s -= t * q, t); } if (a != 1) { fprintf(stderr, "Error: %d^{-1...
// 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"); you may n...
/*------------------------------------------------------------------------------ DHT22 CPP temperature & humidity sensor AM2302 (DHT22) driver for ESP32 Jun 2017: <NAME>, new for DHT22 This example code is in the Public Domain (or CC0 licensed, at your option.) Unless required by applicable law or agreed t...
#include <stdio.h> #include <stdlib.h> #include <math.h> #include <string> #include <cstring> #include <unistd.h> #include "graphics_common_func.h" GLfloat yellow[4] = {1.0, 1.0, 0.0, 1.0}; GLfloat white[4] = {1.0, 1.0, 1.0, 1.0}; GLfloat grey[4] = {0.2, 0.2, 0.2, 1.0}; GLfloat black[4] = {0, 0, 0, 1}; GLfloat red[4] ...
#include "Config.h" #include "DistributedField.h" #include "FieldProp.h" #include "KeyMessage.h" #include "datadesc.h" #include "nctools.h" #include <cstring> #include <filesystem> #include <iostream> #include <memory> #include <netcdf.h> #include <rdkafka.h> #include <rdkafkacpp.h> #include <stdint.h> #include <string...
#include<stdio.h> #include<stdlib.h> #include<conio2.h> #include<string.h> #include<windows.h> #include<ctype.h> #include<locale.h> #include<time.h> #include "TADFILAComPrioridades.h" char menu(){ system("cls"); printf("\n\n\n\n\n\n\n\t\t\t\t\t====================================\n"); printf("\t\t\t\t\t ...
/* This file is part of KDDockWidgets. SPDX-FileCopyrightText: 2019-2022 Klarälvdalens Datakonsult AB, a KDAB Group company <<EMAIL>> Author: <NAME> <<EMAIL>> SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only Contact KDAB at <<EMAIL>> for commercial licensing options. */ #include "utils.h" #include "D...
#include <algorithm> #include <cstddef> #include <deque> #include <gtest/gtest.h> #include <iostream> #include <list> #include <numeric> #include <queue> #include <string> #include <tests/utils/allocator_statistics_checker.h> #include <unordered_map> #include <vector> TEST(AllocationPatternStlLibstdTest, Vector) // NO...
/******************************************************************************* Copyright (c) 2001-2016, Perforce Software, Inc. 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. Redistributions...
#include<cstdio> #include<cstdlib> #include<cstring> #include<algorithm> #include<vector> #include<iostream> using namespace std; const int maxN=101000; const int Alpha=26; class PAM { public: int son[Alpha],fail,len,delta,nxt; }; int n,Q; char Input[maxN]; int nodecnt=1,last=0,Pos[maxN]; PAM P[maxN]; vector<int> T...
// Copyright 2014 The Galactic Bloodshed Authors. All rights reserved. // Use of this source code is governed by a license that can be // found in the COPYING file. import gblib; import std; #include "gb/commands/capture.h" #include "gb/GB_server.h" #include "gb/buffers.h" #include "gb/defense.h" #include "gb/files....
// -*- C++ -*- // // Package: ​RecoBTag/​SecondaryVertex // Class: DeepFlavourJetTagsProducer // /**\class DeepFlavourJetTagsProducer DeepFlavourJetTagsProducer.cc ​RecoBTag/DeepFlavour/plugins/DeepFlavourJetTagsProducer.cc * * Description: EDProducer that produces collection of ShallowTagInfos * * Implemen...
// multi_server.cpp // // Example program showing how to use multiple module RH_RF69/RH_RF95 on Raspberry Pi // Requires bcm2835 library to be already installed // http://www.airspayce.com/mikem/bcm2835/ // Use the Makefile in this directory: // cd example/raspi/multi_server // make // sudo ./multi_server // // Contrib...
// Copyright 2014 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 "Config.h" #include "RecordInfo.h" #include "clang/AST/Attr.h" using namespace clang; using std::string; RecordInfo::RecordInfo(CXXRecordDecl*...
#include <iostream> #include <sstream> #include <string> #include <climits> #include <vector> #include <algorithm> #include <iterator> #include <chrono> #include <future> #include <thread> #include <atomic> #include <random> #include <cstdint> #include "sha256.h" #include "grid.h" using namespace std; // using a sig...
/* * Copyright 2021 IBM 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...
/*************************************************************************** * __________ __ ___. * Open \______ \ ____ ____ | | _\_ |__ _______ ___ * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < ...
/* USER CODE BEGIN Header */ /* // Example file name : main.cpp // Description: // Test file for ERM19264_UC1609_library, // Multi-buffer mode , graphics // ***************************** // NOTES : // (1) This is for software SPI // ****************************** */ /* USER CODE END Header */ /* Includes...
#include <cstdio> #include <cstring> #include <cstdarg> #include "pyc_module.h" #include "pyc_numeric.h" #include "bytecode.h" #ifdef WIN32 # define PATHSEP '\\' #else # define PATHSEP '/' #endif static const char* flag_names[] = { "CO_OPTIMIZED", "CO_NEWLOCALS", "CO_VARARGS", "CO_VARKEYWORDS", "CO_NESTED",...
// #include "Building.h" #include "glm/glm.hpp" #import "Parameters.h" #include <iostream> #include <map> #include <set> #include <glm/gtx/vector_angle.hpp> using namespace glm; using namespace std; // // Created by morten on 13/11/14. Building::Building(kick::Random *rnd) : rnd(rnd) { } void Building::createGeomet...
#pragma once #include <cstdint> #include <vector> #include "common.hpp" #include "join.hpp" #include "insert.hpp" #include "find.hpp" #include "get.hpp" #include "set.hpp" #include "foreach.hpp" #include "erase.hpp" #include "count.hpp" #include "sort.hpp" #include "clear.hpp" #include "has.hpp" #include "extract.hpp" ...
#include "glm/glm.hpp" #include "glm/gtc/matrix_transform.hpp" #include "glad/glad.h" #include "TestCubeScene.h" #include "../Renderer/PerspectiveCamera.h" #include "../Renderer/Renderer.h" #define TEXTURE_SIZE 256 bool cgl::TestCubeScene::InitPrograms() { if (!_testCubeProgram.Init()) return false; ...
/** * @file visibility */ #include "visibility.h" #include "forecast_time.h" #include "level.h" #include "logger.h" #include "plugin_factory.h" #include "util.h" #include "fetcher.h" #include "hitool.h" using namespace std; using namespace himan; using namespace himan::plugin; const double defaultVis = 40000; //...
/* * Copyright 2019 <NAME> <<EMAIL>> * * A non-blocking thread pool implementation with optimizations: * - Work stealing * - One spinning wait thread * * This file is part of Salus * (see https://github.com/SymbioticLab/Salus). * * Licensed under the Apache License, Version 2.0 (the "License"); * you may no...
/********************************************************************* * * Copyright (c) 2014, <NAME>, Inc. * 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 ...
/** * @file PubSub.cpp * @brief Library implementation to manage Topic-based Publish Subscribe for Distributed QoT based Coordinated Applications * @author <NAME> * * Copyright (c) Carnegie Mellon University, 2018. All rights reserved. * * Redistribution and use in source and binary forms, with or without modifi...
#include <gflags/gflags.h> #include <glog/logging.h> #include <algorithm> #include <boost/asio.hpp> #include <chrono> #include <cstdint> #include <deque> #include <limits> #include <memory> #include <string> #include <tuple> #include <unordered_map> #include <unordered_set> #include <utility> #include <vector> #inclu...
// align.cc // // Find rmse of rigid body alignment of target and query, // matching residues found by clique analysis // // Reference: // <NAME>, // Least-squares estimation of transformation parameters // between two point patterns, // IEEE Transactions on Pattern Analysis and Machine Intelligence, // Vo...
#include "exponential-fit.h" #include <algorithm> #include <cmath> #include <iomanip> #include <iostream> #include <numeric> using namespace std; void ExpFit::SetTest(int n, double a, double b, double c) { this->n = n; GenTestData(n, a, b, c); PrintTestData(n, a, b, c); CalcFit(); } void ExpFit::GenTestData(...
/* +----------------------------------------------------------------------+ | HipHop for PHP | +----------------------------------------------------------------------+ | Copyright (c) 2010 Facebook, Inc. (http://www.facebook.com) | +---------...
/* ******************************************************************************* * Copyright (C) 2012 <NAME> * MIT license. All Rights Reserved. ******************************************************************************* */ #include "ContextImpl.hpp" #include "TypeImpl.hpp" #include "Codegen/LlvmEmitter....
#include <ESP8266WebServer.h> #include "chug.h" #include "support.h" #include "pin_defines.h" extern ESP8266WebServer server; extern Chug chug; extern float motor_pct; extern bool motor_state; extern float lights_pct; extern bool lights_state; extern float volume_pct; extern bool volume_state; void writeToMotorP...
/* * Copyright 2019 Carnegie Technologies * * 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 l...
#include <algorithm> #include <pistache/net.h> #include <pistache/http.h> #include <pistache/peer.h> #include <pistache/http_headers.h> #include <pistache/cookie.h> #include <pistache/router.h> #include <pistache/endpoint.h> #include <pistache/common.h> #include <string.h> #include <signal.h> using namespace std; usi...
#include "constants.h" #include "hardware.h" #include "leveleditor.h" #include "soundplayer.h" #include "titlescreen.h" #include "leveldefinitions.h" TitleScreen::TitleScreen(WoopsiGfx::Graphics* topGfx, WoopsiGfx::Graphics* bottomGfx) : ScreenBase(topGfx, bottomGfx) { _timer = 0; _chosenLevel = NULL; _...
/// Exercise: Robot localization WITH a map /// /// Task: /// ----- /// The goal of this exercise is to let students think /// about own ideas to localize a robot that wakes up /// (is switched on) and does not have a localization /// sensor. /// /// The robot has to localize itself on the map just using /// its distan...
/* ============================================================================== PoleZeroPlot.cpp Created: 22 Jul 2020 1:55:43pm Author: <NAME> ============================================================================== */ #include <JuceHeader.h> #include "PoleZeroPlot.h" //=======...
#define _USE_MATH_DEFINES #define INF 0x3f3f3f3f #include <iostream> #include <cstdio> #include <sstream> #include <cmath> #include <cstdlib> #include <algorithm> #include <queue> #include <stack> #include <limits> #include <map> #include <string> #include <cstring> #include <set> #include <deque> #include <bitset> #i...
#include "main.hpp" #pragma ident "@(#)functions.cpp 1.0 98/11/12 (c) <NAME>" // Constructor default argument initializes to today's values void Date::setDate ( int d , int m , int y ){ time_t t; struct tm * ptm; t = time ( NULL ) ; if ( date != NULL ) delete date; date = NULL; if ( d == 0 && m == 0 && y == 0 ...
// // buildModelTree.cc // // Input // - reference .tx file (seqID => sppID) // - full taxon file, .fullTx // - reference fasta file // - output directory (outDir) // Output // - For each node of the ref tree (except root) a fasta file of all ref // seq's corresopnding to the node's subtree // -...
#include <cstdlib> #include <iostream> #include <algorithm> #include <time.h> using namespace std; string libros [39][3]; void cargarLibros() { srand (time(NULL)); libros [ 0 ] [ 0 ] = " Algoritmos " ; libros [ 0 ] [ 1 ] = " Algoritmos y Programacion (Guia para docentes) "; libros [ 0 ] [ 2] = "Yari" ; libros ...
#include "utf8.h" #include "ilang/Lexer.hpp" using namespace ilang; using SourceIter = std::string_view::const_iterator; static bool isOpChar(std::uint32_t cp){ switch(cp){ case '\\': case '!': case '+': case '-': case '*': case '/': case '^': case '=': case ':': case '%': ...
/* * Copyright (c) 2008 <NAME>, <NAME>, <NAME> * * Permission to use, copy, modify, and distribute this software for any * purpose with or without fee is hereby granted, provided that the above * copyright notice and this permission notice appear in all copies. * * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR...
// Copyright (c) 2018 <NAME> // This code is licensed under MIT license (See LICENSE for details) #include "Lexer.h" #include "Parser.h" #include "ast/nodes.h" #include "exceptions.h" #include "NameResolver.h" #include "TypeChecker.h" #include "ByteCodeCompiler.h" #include "Scope.h" #include "vm/VM.h" #include "vm/Byt...
/*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...
/* * Copyright (c) 2021 Huawei Device Co., 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 applicable law ...
// system includes #include <stdexcept> #include <cassert> // stl includes #include <iostream> #include <sstream> #include <poco-lib/include/Poco/Net/NetException.h> // hyperion util includes #include "HyperionConfig.h" #include "hyperion/ImageProcessorFactory.h" #include "hyperion/ImageProcessor.h" #include "hyperio...
//********************************************************* // Skim_Group.cpp - zone skim control parameters //********************************************************* #include "Skim_Group.hpp" #include "Utility.hpp" //--------------------------------------------------------- // Skim_Group constructor //-----------...
#include "ImageLoader.h" #include "ImageHeader.h" #include "ImageSettings.h" #include "ImageTransformations.h" #include "ImageCpuRecord.h" #include "ParcellationCpuRecord.h" #include "HZeeTypes.hpp" #include "itkbridge/ImageDataFactory.hpp" #include "itkbridge/ITKBridge.hpp" #include "itkdetails/ImageData.hpp" #incl...
#include <iostream> #include <fstream> #include <math.h> #include <pcl_conversions/pcl_conversions.h> #include <pcl/point_cloud.h> #include <pcl/point_types.h> #include <ros/ros.h> #include <ros/console.h> #include <sensor_msgs/PointCloud2.h> #include <nav_msgs/Odometry.h> #include <nav_msgs/Path.h> #include <geometry...
// divide.cpp : test suite runner for division of abitrary precision integers // // Copyright (C) 2017-2021 Stillwater Supercomputing, Inc. // // This file is part of the universal numbers project, which is released under an MIT Open Source license. #include <universal/utility/directives.hpp> #include <iostream> #incl...
// // This source file is a part of borsch.3d // // Copyright (C) borsch.3d team 2017-2018 // // 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 limitat...
/* FILE: multiatlas.cc -*-Mode: c++-*- * * Combining atlas class, derived from OXS extension class. * */ #include "nb.h" #include "multiatlas.h" // Oxs_Ext registration support OXS_EXT_REGISTER(Oxs_MultiAtlas); /* End includes */ // Constructor Oxs_MultiAtlas::Oxs_MultiAtlas ( const char* name, ...
/* Copyright (c) 2017 <NAME> (kb1vc) 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 conditions and the follow...
/* * * Copyright (c) 2014, weizhenwei * 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 condi...
#include "../include/Game.h" /** Buttons Enum for easier in Switch */ enum Button { START, QUIT, PUSHW, RESTART, }; /** Game set all pointers to nullptr and clear vars */ Game::Game() { blockWall = nullptr; timer = nullptr; rend = nullptr; music = nullptr; isGameRunning = false; clearVars(); } /** In...
#include<bits/stdc++.h> using namespace std; const int N = 3e5 + 9, mod = 104857601; struct base { double x, y; base() { x = y = 0; } base(double x, double y): x(x), y(y) { } }; inline base operator + (base a, base b) { return base(a.x + b.x, a.y + b.y); } inline base operator - (base a, base b) { re...
// Copyright 2009 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...
#include "map/square_grid.hpp" #include "config_reader/config_reader.hpp" using namespace librav; void SquareCell::UpdateMapInfo(int32_t row_size, int32_t col_size, double side_size, int32_t pixel_per_meter) { int32_t vis_side_size = side_size * pixel_per_meter; bbox_.x.min = coordinate_.x * vis_side_size; ...
#include "StdAfx.h" #include "GLRenderer.h" #include "GL\gl.h" #include "GL\glu.h" #include "GL\glaux.h" #include "GL\glut.h" #include "DImage.h" #include "Tex.h" //#pragma comment(lib, "GL\\glut32.lib") const double M_PI = 3.141592653589793238463; CTex *tex; CGLRenderer::CGLRenderer(void) { tex = new CTex(); } C...
#include "dtdnssync.hpp" #include "logger.hpp" #include <getopt.h> #include <grp.h> #include <iostream> #include <pwd.h> #include <signal.h> #include <sys/types.h> using namespace dtdnssync; static void daemonize(); static void daemon(const dtdnssync_config & cfg); static void signal_handler(int sig); static volat...
/** Stepper Motor (Unipolar) control library * * @class StepperMotorUni * @author <NAME> * @version 1.1.2 * @date 27-Apr-2015 * * Copyright: 2010, 2014, 2015 <NAME> * Released under the Apache 2 license License * * The library that controls stepper motor via motor driver chip * This ...
// xls2csv.cpp : Defines the entry point for the console application. // #include <SDKDDKVer.h> #include <stdio.h> #include <tchar.h> #include <stdlib.h> #include <string.h> #include <ctype.h> #include "libxls/xls.h" #include <iostream> #include <fstream> #include <iomanip> static char stringSeparator = '\...
// Copyright (c) 2012, 2013 <NAME>. // This Source Code Form is subject to the terms of the Mozilla Public // License, v. 2.0. If a copy of the MPL was not distributed with this // file, You can obtain one at http://mozilla.org/MPL/2.0/. #include "i23dSFM/image/image.hpp" #include "i23dSFM/sfm/sfm.hpp" /// Featur...
/** * 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 "wavefunction.h" #include <random> #include "../Eigen/Dense" #include <cmath> #include <ctime> #include <fstream> #include "hastings_tools.h" #include "gibbs_tools.h" using namespace Eigen; using namespace std; //Mersenne Twister RNG random_device rd; //Will be used to o...
#include <wchar.h> #include <assert.h> #include <locale.h> #include <ctype.h> #include <cmath> #include "lib/logger.h" #include "cvxtext.h" #include <signal.h> static int get_utf8_size(unsigned char ch) { unsigned char c = ch; // 0xxxxxxx 返回0 // 10xxxxxx 不存在 // 110xxxxx 返回2 // 1110xxxx 返回3 // 1...
#include "renderer.h" #include "../state.h" void renderer_init(Renderer *self) { //*self = (Renderer) {0}; self->camera_type = CAMERA_PERSPECTIVE; self->current_shader = SHADER_NONE; self->shaders[SHADER_BASIC_TEXTURE] = shader_create( "res/shaders/basic_texture.vs", "res/shaders/basic_texture...
#include<bits/stdc++.h> using namespace std; using vi = vector<int>; using vvi = vector<vi>; using ii = pair<int,int>; using vii = vector<ii>; using l = long long; using vl = vector<l>; using vvl = vector<vl>; using lu = unsigned long long; using vb = vector<bool>; using vvb = vector<vb>; using vd = vector<double>; us...
#include <vector> #include <unordered_map> #include <set> #include <map> #include <algorithm> #include <cassert> #include <iostream> #include <iterator> #include "gl_core_4_5.h" #include "buffer_allocator.h" using namespace glt; glt::SubBuffer::SubBuffer(size_t offset, size_t size, GLuint buf) : offset(offset), size...
#include "metrics.h" #include "proc_scanner.h" #include <boost/functional/hash.hpp> #include <boost/thread/condition_variable.hpp> #include <unistd.h> #include <sys/types.h> static const string DURATION_NAME = "opsian.metrics.read_duration"; static const uint32_t DURATION_ID = 1; static const uint32_t NANOS_IN_SECO...
//------------------------------------------------------------------------------ // ImGuiAdvanced.cc //------------------------------------------------------------------------------ #include "Pre.h" #include "Core/Main.h" #include "Gfx/Gfx.h" #include "Input/Input.h" #include "IMUI/IMUI.h" #include "IO/IO.h" #include ...
#include<iostream> #include<fstream> #include<string.h> #include <bits/stdc++.h> using namespace std; // BST Node for data1 struct Node { int num; char ad[30]; char soyad[30]; struct Node *left, *right; }; Node* newNode(int num, char ad[30], char soyad[30]) { Node* temp = new Node; temp->num = num; ...
#include <iostream> #include <string> #include <vector> #include <fstream> #include <chrono> #include "PriorityQueue.h" #include <iomanip> class Program { // NOLINT(hicpp-special-member-functions, cppcoreguidelines-special-member-functions) public: explicit Program(std::istream & is = std::cin, std::ostream & os = ...
#include "tcp_service.h" #include "log_util.h" #include <cerrno> #include <signal.h> #include <string.h> #include <unistd.h> #include <sys/epoll.h> #include <sys/socket.h> #include <netinet/in.h> #include <netinet/tcp.h> #include <arpa/inet.h> #include <fcntl.h> #include <sys/select.h> #include "connection.h" #define ...
#include "stdafx.h" #include "GrassLayer.h" #include "RenderMethodTags.h" #include "ActionQueueRenderInstance.h" #include "Frustum.h" #include "Renderer.h" extern Frustum g_Frustum; GrassLayer::~GrassLayer() { delete [] cells; } GrassLayer::GrassLayer(shared_ptr<class Renderer> renderer, ...
/* * Register map for the MPU6050 available at: https://www.invensense.com/wp-content/uploads/2015/02/MPU-6000-Register-Map1.pdf */ #include "TinyMPU6050.h" /* * Constructor */ MPU6050::MPU6050(TwoWire &w,int i2cAddress) { // Setting I²C stuff wire = &w; if(i2cAddress == MPU6050_ADDRESS_LOW || i2cAddress == MP...
// C/C++ header #include <ctime> #include <sstream> // Athena++ headers #include "../athena.hpp" #include "../athena_arrays.hpp" #include "../parameter_input.hpp" #include "../coordinates/coordinates.hpp" #include "../eos/eos.hpp" #include "../field/field.hpp" #include "../hydro/hydro.hpp" #include "../mesh/mesh.hpp" ...
/* * program to map gencode datafiles to older assemblies. */ #include <getopt.h> #include "gxf.hh" #include "typeOps.hh" #include "FIOStream.hh" #include "transMap.hh" #include "geneMapper.hh" #include "annotationSet.hh" #include "bedMap.hh" #include "globals.hh" #include "gxf.hh" #include "./version.h" /* verbose...
// Copyright 2018 InnoVisioNate Inc. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "Text.h" static DataPoint movePoint = {-DBL_MAX,-DBL_MAX,-DBL_MAX}; static POINT ptPoints[1024]; static int contourPointsCount[32]; sta...
/*---------------------------------------------------------------------------*\ 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 "gtest/gtest.h" #include <climits> #include <ostream> #include "base/safemath.h" static_assert(SCHAR_MIN < -SCHAR_MAX, "this test assumes 2's-complement arithmetic"); static_assert(SCHAR_MAX == 127, "this test assumes 8-bit bytes"); static_assert(UCHAR_MAX == 255U, "this test assumes 8-bit byt...
// Author: Greg "fugue" Santucci, 2011 // Email: <EMAIL> // Web: http://createuniverses.blogspot.com/ #include "VoxelBlock.h" #include "Voxel.h" #include "ML_Maths.h" VoxelBlock * g_pVoxelBlock = 0; VoxelBlock::VoxelBlock() { g_pVoxelBlock = 0; m_pFirst = 0; m_nSizeX = 100; m_nSizeY = 10...
/** * @file AllSpikingSynapses.cpp * * @ingroup Simulator/Edges * * @brief A container of all dynamic STDP synapse data */ #include <iomanip> #include "AllSpikingSynapses.h" #include "ParameterManager.h" using namespace std; AllSpikingSynapses::AllSpikingSynapses() : AllNeuroEdges() { decay_ = nullptr; ...
/* * The purpose of this program is to run inference on a chosen model. The * inference is done N number of times (provided as argument). This program * spawn a seperate thread to record the cpu load. Different load tracking * algorithms (smoothing by averaging, smoothing by exponentinal averaging) * are used, al...
#include <kvs/Message> #include <kvs/glut/Application> #include <kvs/glut/Screen> #include <kvs/ValueArray> #include <kvs/ColorMap> #include <kvs/PolygonObject> #include <kvs/OrthoSlice> #include <kvs/Isosurface> #include <kvs/StructuredVolumeObject> #include <kvs/ExternalFaces> #include <kvs/RayCastingRenderer> #inclu...
#include "core/tracer.h" Tracer::Tracer() { // some sane defaults setNumberOfThreads(2); setMaxRayDepth(100); setRenderResolution(640, 480); setPixelSampleType(SAMPLE_NONE); setShadowSampleType(SAMPLE_NONE); } Tracer::~Tracer() { // delete the frame buffer if (m_frameBuffer) { delete [] m_frameBu...
/* * Copyright (c) 2019 Samsung Electronics Co., Ltd. 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...
/* Copyright 2018 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 ...
#include <iostream> #include <fstream> #include <sstream> #include <streambuf> #include <string> #include <vector> #include <map> // util functions to read // read all file // ref: https://stackoverflow.com/questions/2602013/read-whole-ascii-file-into-c-stdstring const std::string readfile(const std::string& path) {...
// Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. See LICENSE in the project root for license // information. #include "pch.h" #include "sdp_utils.h" #include "api/jsepsessiondescription.h" #include "pc/sessiondescription.h" #include "pc/webrtcsdp.h" namespace { /// As...
/*========================================================================= Program: Visualization Toolkit Module: $RCSfile$ Copyright (c) <NAME>, <NAME>, <NAME> All rights reserved. See Copyright.txt or http://www.kitware.com/Copyright.htm for details. This software is distributed WITHOUT ANY WA...
// // blocking_tcp_client.cpp // ~~~~~~~~~~~~~~~~~~~~~~~ // // Copyright (c) 2003-2016 <NAME> (chris at kohlhoff dot com) // // Distributed under 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 <boost/asio/connect.hpp> #inc...