text stringlengths 3.08k 12.5k |
|---|
//===- CompleteBottomUp.cpp - Complete Bottom-Up Data Structure Graphs ----===//
//
// The LLVM Compiler Infrastructure
//
// This file was developed by the LLVM research group and is distributed under
// the University of Illinois Open Source License. See LICENSE.TXT for details.
//
//===----------... |
#include "flv_demux.hpp"
#include "logger.hpp"
#include "byte_stream.hpp"
#include "flv_pub.hpp"
flv_demuxer::flv_demuxer(av_format_callback* cb):callback_(cb)
{
}
flv_demuxer::~flv_demuxer()
{
}
int flv_demuxer::handle_packet() {
uint8_t* p;
uint32_t ts_delta = 0;
if (!flv_header_ready_) {
if (... |
#include <bits/stdc++.h>
using namespace std;
const int MAXN = 32767;
class DisjointSet {
public:
int parent[MAXN], weight[MAXN];
int findp(int x) {
return parent[x] == x ? x : parent[x] = findp(parent[x]);
}
int joint(int tx, int ty) {
int x = findp(tx), y = findp(ty);
if (x == y)
return 0;
... |
/******************************************************************************
******************************************************************************
*** ***
*** Simple class to hold a list of processes and refresh this list, *... |
//===------- ShapeInferencePass.cpp - Shape Inference ---------------------===//
//
// Copyright 2019-2020 The IBM Research Authors.
//
// =============================================================================
//
// This file implements a Function level pass performing propagation of array
// shapes through func... |
#include "DriveTrainSmoothing.h"
#include <algorithm>
using namespace std;
//Data Pertaining to multiplier Table Start
// Data type for multiplier table
struct MultiplierDataType {
float leftMultiplier;
float rightMultiplier;
};
// Interval of data table
const float joystickStep = 0.05;
// Power Multiplier table. I... |
//
// Copyright 2016 Pixar
//
// Licensed under the Apache License, Version 2.0 (the "Apache License")
// with the following modification; you may not use this file except in
// compliance with the Apache License and the following modification to it:
// Section 6. Trademarks. is deleted and replaced with:
//
// 6. Trad... |
#include<iostream>
#include<string>
#include"picosha2.h"
#include<random>
#include<time.h>
#include<math.h>
using namespace std;
struct Transaction{
long long Id;
unsigned int timestamp;
string from;
string to;
};
uint32_t decToHex(string hexStr){
int decLength = hexStr.length();
uint32_t ... |
//
// Copyright 2013-2014 EvriChart, Inc. All Rights Reserved.
// See LICENSE.txt
//
// C++
#include <iostream>
#include <fstream>
#include <cerrno>
#include <thread>
// Boost
#include <boost/property_tree/info_parser.hpp>
#include <boost/program_options.hpp>
// Internal
#include "Extensions/IO/IO.h"
#include "Exten... |
/********************* */
/*! \file quant_util.cpp
** \verbatim
** Original author: ajreynol
** Major contributors: bobot, mdeters
** Minor contributors (to current version): none
** This file is part of the CVC4 prototype.
** Copyright (c) 2009-2012 ... |
#include "kdtree.h"
#include "common/ray.h"
#include <iostream>
#include <algorithm>
// Definition of a node
struct Node {
// Constructor / Destructor
Node() : dimension(0), split(0) {
child[0] = nullptr;
child[1] = nullptr;
primitives = nullptr;
}
virtual ~Node() {
delete child[0];
delet... |
#include "rocket.hpp"
void Rocket::initializeGL(GLuint program) {
terminateGL();
m_program = program;
m_colorLoc = abcg::glGetUniformLocation(m_program, "color");
// m_rotationLoc = abcg::glGetUniformLocation(m_program, "rotation");
m_scaleLoc = abcg::glGetUniformLocation(m_program, "scale");
m_translatio... |
#include <iostream>
#include <string>
#include <vector>
#include <cmath>
#include <chrono>
#include <random>
#include "Accelerator.hpp"
#include "Ion.hpp"
#include "IonSource.hpp"
#include "DriftTube.hpp"
#include "QuadrupoleMagnet.hpp"
#include "DipoleMagnet.hpp"
#include "Trafo.hpp"
#include "Screen.hpp"
#include "P... |
#include <iostream>
#include "bytegen.hpp"
#include "endian.hpp"
#include "VSysInstructions.hpp"
#include <random>
#include "CppUTest/TestHarness.h"
namespace
{
uint8_t getRandom8(uint8_t low, uint8_t high)
{
std::random_device rd;
std::mt19937 gen(rd());
std::uniform_int_d... |
#include <gsl/gsl_poly.h>
#include <gtest/gtest.h>
#include <array>
#include <eos/soave_redlich_kwong_eos.hpp>
#include <eos/van_der_waals_eos.hpp>
#include <eos/peng_robinson_eos.hpp>
#include <vector>
class CubicEquationSolver {
public:
std::vector<double> operator()(const std::array<double, 3>& a) const {
s... |
//-----------------------------------------------------------------------------
// luna2d engine
// Copyright 2014-2017 <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 re... |
/*
* 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 hope that it will be use... |
#include <cmath>
#include "SoloReadFeature.h"
#include "binarySearch2.h"
#include "serviceFuns.cpp"
#include "SoloCommon.h"
#include "SoloFeature.h"
bool inputFeatureUmi(fstream *strIn, int32 featureType, bool readInfoYes, array<vector<uint64>,2> &sjAll, uint32 &iread, int32 &cbmatch, uint32 &feature, uint32 &umi, vec... |
#include "AutomatedBehaviours.hpp"
AutomatedBehaviours::AutomatedBehaviours(Transform& transform)
: heading(glm::vec3(0)), angle(0), acceleration(0), topSpeed(0),
m_transformPtr(&transform), rotationSpeed(0), m_wanderAngle(0), state(0),
active(false)
{
}
void AutomatedBehaviours::accelerate(float topSpeed)
{
i... |
#define JOY1_POT_CS_PIN 2
#define JOY2_POT_CS_PIN 3
#define JOY1_BUTTON1_PIN 4
#define JOY1_BUTTON2_PIN 5
#define JOY2_BUTTON1_PIN 6
#define JOY2_BUTTON2_PIN 7
#define STATUS_LED_PIN 9
//
// USB joystick controllers
//
#include <usbhub.h>
#include <hiduniversal.h>
#include "XboxController.h"
#include "GenericController... |
#include "Transform.hpp"
#include <glm\gtc\matrix_transform.hpp>
const glm::vec3 Transform::globalUp(0, 0, 1);
const glm::vec3 Transform::globalDown(0, 0, -1);
const glm::vec3 Transform::globalLeft(-1, 0, 0);
const glm::vec3 Transform::globalRight(1, 0, 0);
const glm::vec3 Transform::globalForward(0, 1, 0);
const glm... |
#include <CGenPointFractal.h>
#include <CMathGen.h>
CGenPointFractal::
CGenPointFractal()
{
xmin_ = -2.0;
ymin_ = -1.2;
xmax_ = 1.2;
ymax_ = 1.2;
xi_type_ = POS; xi_ = 0.0;
yi_type_ = POS; yi_ = 0.0;
a_type_ = POS; a_ = 0.0;
b_type_ = POS; b_ = 0.0;
c_type_ = POS; c_ = 0.0;
d_type_ = POS;... |
/////////////////////////////////////////////////////////////////////////////////////////////
//FileName:MarchingCubesCross.cpp
//Author:<NAME>
//email:<EMAIL> or <EMAIL>
//website:www.angelfire.com/linux/myp
//date:July 2002
//
//Description:Basics of Marching Cubes Algorithm
//Computes normal vectors as cross produ... |
#include "FontSource.hpp"
#include <iostream>
FontSource::FontSource(const std::string font, const unsigned int s)
{
font_size = s;
FT_Error ft_error;
if ((ft_error = FT_Init_FreeType(&ft_library)))
{
std::cerr << "FT_Library initialization failed." << std::endl;
abort();
}
if ((ft_error = FT_New_Face(ft... |
/*
* Copyright (C) 2015 Menlo Park Innovation LLC
*
* This is licensed software, all rights as to the software
* is reserved by Menlo Park Innovation LLC.
*
* A license included with the distribution provides certain limited
* rights to a given distribution of the work.
*
* This distribution includes a copy o... |
#include "LEDControllerMk4.h"
LEDControllerMk4::LEDControllerMk4()
{
}
/**
* Setup function for Arduino file to call in setup
*/
void LEDControllerMk4::_setup()
{
// Setup Serial
Serial.begin(BAUDRATE);
delay(100);
// Info and Version print
Serial.println("# ======================== #");
Se... |
#include"Net/IPAddr.hpp"
#include"Net/IPAddrOrOnion.hpp"
#include<assert.h>
#include<cstdint>
#include<cstring>
namespace {
auto const onion_len = std::strlen(".onion");
bool is_dot_onion(std::string const& s) {
if (s.size() < onion_len)
return false;
return std::strncmp(&*(s.end() - onion_len), ".onion", onion_... |
#include <iostream>
#include <vector>
#include "error.hpp"
#include "generation.hpp"
#include "inputOutput.hpp"
#include "rule.hpp"
#include "table.hpp"
using namespace std;
const int units = 8;
const int generations = 3;
void initialisation(Table** test);
void neighbourhood(Table* test);
void file(Table* test);
vo... |
#include "internal_UaParser.h"
#include <fstream>
#include <string>
#include <vector>
#include <unordered_set>
#include <boost/regex.hpp>
#include <glog/logging.h>
#include <yaml-cpp/yaml.h>
namespace {
struct DeviceStore {
std::string replacement;
boost::regex regExpr;
};
struct AgentStore : DeviceStore {
s... |
#include "includes.h"
#include "ClientUnit.h"
#include "Display.h"
#include "ResourceManager.h"
spUnit ClientUnit::_selectedUnit;
SDL_Surface* ClientUnit::_image = NULL;
SDL_Surface* ClientUnit::_corpseImage = NULL;
SDL_Surface* ClientUnit::_pathImage = NULL;
SDL_Surface* ClientUnit::_pathEndImage = NULL;
... |
#include "gtest/gtest.h"
#include "utils/strings/rotate-matrix.h"
TEST(rotateMatrixBy90Degrees, with_empty_matrix)
{
std::vector<std::vector<int >> matrix;
EXPECT_EQ(rotateMatrixBy90Degrees(matrix), matrix);
}
TEST(rotateMatrixBy90Degrees, with_1x1_matrix)
{
std::vector<std::vector<int >> matrix;
std... |
#include "ParametersClip.h"
#include "Parameters.h"
#include "SequenceFuns.h"
#include "ErrorWarning.h"
void ParametersClip::initialize(Parameters *pPin)
{
pP = pPin;
//yes = false;
if (adapterType[0]!="Hamming" && adapterType[0]!="CellRanger4") {
exitWithError("EXITING because of fatal PARAME... |
/*
Author: <NAME>
Email: <EMAIL>
Version 0.1
*/
#include "Wheel.h"
#include <ctime>
#include <iostream>
// levels
constexpr auto LEVEL8 = 8000;
constexpr auto LEVEL10 = 10000;
constexpr auto LEVEL32 = 32000;
constexpr auto LEVEL20 = 20000;
constexpr auto LEVEL15 = 15000;
// Name the Wheel we want to use (G27 or S... |
//---
//
// License: MIT
//
// Author: <NAME>
//
// Description:
//
// Motion Imagery Segment TRE(MTIMSA) class definition.
//
// See document NGA.STND.0044_1.3_MIE4NITF, table 18 for more info.
// Contains binary data, see document NGA.STND.0044_1.3_MIE4NITF,
// table 8 for more info.
//---
// $Id
#include <ossim/sup... |
#include "CameraFlightProcess.h"
#include "..\interfaces\Locator.h"
#include "..\events\EventPauseTrip.h"
CameraFlightProcess::CameraFlightProcess(unsigned long ms) :
isPaused(false)
{
this->startTime = std::chrono::high_resolution_clock::now();
this->endTime = this->startTime + std::chrono::milliseconds(ms);
th... |
/* value_test_utils.cpp -*- C++ -*-
<NAME> (<EMAIL>), 25 Apr 2015
FreeBSD-style copyright and disclaimer apply
*/
#include "test_types.h"
#include "dsl/all.h"
#include "types/primitives.h"
#include "types/std/map.h"
#include "types/std/vector.h"
#include "types/std/string.h"
#inc... |
/*********************************************************************
* Software License Agreement (BSD License)
*
* Copyright (c) 2021,
* Max Planck Institute for Intelligent Systems (MPI-IS).
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, ar... |
/**
* @file llfloateropenobject.cpp
* @brief LLFloaterOpenObject class implementation
*
* $LicenseInfo:firstyear=2004&license=viewerlgpl$
* Second Life Viewer Source Code
* Copyright (C) 2010, Linden Research, Inc.
*
* This library is free software; you can redistribute it and/or
* modify it under the terms ... |
#include "CgaLander.h"
//----------------------CreateStartPopulation---------------------------
//
//-----------------------------------------------------------------------
void CgaLander::CreateStartPopulation()
{
//clear existing population
m_vecPop.clear();
for (int i=0; i<m_iPopSize; i++)
{
m_vecPop.push_b... |
#include <stdlib.h>
#include <time.h>
#include "raft_test_util.h"
#include "raft.h"
#include "default_logger.h"
#include "util.h"
// nextEnts returns the appliable entries and updates the applied index
void nextEnts(raft *r, Storage *s, EntryVec *entries) {
entries->clear();
// Transfer all unstable entries to "st... |
#include "TestHarness.h"
#include "DgR3Vector.h"
#include "DgR3Vector_ancillary.h"
typedef Dg::R3::Vector < float > vec3;
//--------------------------------------------------------------------------------
// Vector Construction
//--------------------------------------------------------------------------------
TEST(St... |
#include "D1GameMode.h"
#include "D1HUD.h"
#include "D1Character.h"
#include "PickupItem.h"
#include "NPC.h"
#include "NPCAIController.h"
#include "FSM/StateMachine.h"
#include "States/GroupStates.h"
#include "UObject/ConstructorHelpers.h"
#include "UObject/UObjectIterator.h"
#include "EngineUtils.h"
#include "DrawDe... |
#include "song.h"
#include "archive.h"
#include "sound/instruments/sampler.h"
#include "sound/instruments/drums.h"
#include "editor/sound/track_preset.h"
#include <unordered_set>
std::unique_ptr<Song::Track> Song::makeDefaultTrack(const std::string &type, TrackPreset *preset) {
auto track = std::make_unique<Song::T... |
/*
Filename: tree.cpp
Description: Tree class methods
Author: <NAME>
Date: 06/12/2020
Course: Data Structures II
*/
#include "tree.h"
/**
* Tree Constructor
* Default tree constructor, sets root to nullptr
* @param -
* @returns -
*/
Tree::Tree() {
_root = nullptr;
}
/**
* Tree Destructor
* Clears tree _root... |
//-----------------------------------------------------------------------------
// LsqSums4
//-----------------------------------------------------------------------------
#include <cmath>
#include "Offline/Mu2eUtilities/inc/LsqSums4.hh"
LsqSums4::LsqSums4() {
clear();
}
LsqSums4::LsqSums4(const LsqSums4& S) {
... |
/****************************************************************************/
// Eclipse SUMO, Simulation of Urban MObility; see https://eclipse.org/sumo
// Copyright (C) 2013-2020 German Aerospace Center (DLR) and others.
// This program and the accompanying materials are made available under the
// terms of the Ecli... |
#include "MFP_fillbc.H"
#include <AMReX_filcc_f.H>
#include "MFP_global.H"
#include "MFP_state.H"
#include <sstream>
using GD = GlobalData;
void StateBC::add_function(const std::string name, const Optional3D1VFunction &fun)
{
functions[name] = fun;
if (fun.has_func()) {
has_function = true;
}
... |
/**********
This library is free software; you can redistribute it and/or modify it under
the terms of the GNU Lesser General Public License as published by the
Free Software Foundation; either version 2.1 of the License, or (at your
option) any later version. (See <http://www.gnu.org/copyleft/lesser.html>.)
This libr... |
// Copyright (c) 2015, The Regents of the University of California (Regents)
// See LICENSE.txt for license details
#include <algorithm>
#include <cinttypes>
#include <iostream>
#include <vector>
#include "benchmark.h"
#include "builder.h"
#include "command_line.h"
#include "graph.h"
#include "pvector.h"
/*
GAP Ben... |
#include "wincom.hpp"
map<string,int> WinCom::mapPort;
map<string,int> WinCom::mapBaudRate;
map<string,int> WinCom::mapDataBit;
map<string,int> WinCom::mapStopBit;
map<string,int> WinCom::mapParity;
const map<string,int>& WinCom::enumSettingPort()
{
int i,ret = ERROR_SUCCESS;
HKEY key;
CHAR va... |
// ==============================================================================================
// This file is part of the VRmagic VRmUsbCam C API v2 Demo Application
// ==============================================================================================
// Camera Reading / Main Loop
// -------------------... |
// <NAME>
//
// File: delcher.cc
//
// Last Modified: 25 November 2002
//
// Common generic routines.
#include "delcher.hh"
const int COMMATIZE_BUFF_LEN = 50;
// Length of buffer for creating string with commas
char Clean_Exit_Msg_Line [MAX_ERROR_MSG_LEN];
// String to write error messages to before ... |
//
// shot_detection_m2.cpp
// OpenCVTest
//
// Created by Mipapamedijo on 05/09/18.
// 2018 No Budget Animation S de RL de CV.
//
#include <stdio.h>
#include <iostream>
#include <opencv2/opencv.hpp>
#include <opencv2/highgui.hpp>
#include <opencv2/imgproc.hpp>
#include <opencv2/core.hpp>
#include <opencv2/img_has... |
/*
* Copyright (C) 2005-2019 Centre National d'Etudes Spatiales (CNES)
*
* This file is part of Orfeo Toolbox
*
* https://www.orfeo-toolbox.org/
*
* 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 ... |
/// @file tVisSourceSnoop.cc
/// @details
/// This application runs VisSource in a parallel mode and prints some stats
/// similar to vsnoop utility (but it works via VisSource). It is handy for
/// ingest scaling tests as it mimics the behaviour of the receiving part
/// without metadata logic which simplifie... |
//////////////////////////////////////////////////////////////////////
//
// Crytek Source code
// Copyright (c) Crytek 2001-2004
//
// File:
//
// Description:
//
// History:
//
//////////////////////////////////////////////////////////////////////
#include "stdafx.h"
#include "MathUtils.h"
#in... |
// Copyright (c) 2016 Google Inc.
//
// Permission is hereby granted, free of charge, to any person obtaining a
// copy of this software and/or associated documentation files (the
// "Materials"), to deal in the Materials without restriction, including
// without limitation the rights to use, copy, modify, merge, publi... |
#include "TCPServer.h"
#include <fstream>
#include <thread>
#include <SDL_net.h>
#include <sdlxx/core/log.h>
int TCPServer::fileSize(const char *filename) {
std::ifstream in(filename, std::ifstream::ate | std::ifstream::binary);
return (int) in.tellg();
}
void TCPServer::serverManager() {
sdlxx::net::Lo... |
/*
* ===========================================================================
* Loom SDK
* Copyright 2011, 2012, 2013
* The Game Engine Company, LLC
*
* 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 o... |
/// @file UpdateThread.cpp
/// @brief Update wxThread class implementation.
/// @author zer0
/// @date 2014-09-04
#include "UpdateThread.h"
#include "UpdateConfig.h"
#include "MainFrame.h"
#include "log.h"
#include <wx/url.h>
#include <wx/wfstream.h>
#include <wx/sstream.h>
#include <wx/zipstrm.h>
#include <wx/filesy... |
/* Copyright (c) 2021 M.A.X. Port Team
*
* 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, ... |
//Convertion utility, modelled after osmconvert
#include <iostream>
#include <vector>
#include <string>
#include <fstream>
#include <boost/program_options.hpp>
#include "OsmData.h"
#include "osmxml.h"
#include "o5m.h"
#include "pbf.h"
#include "utils.h"
#include "pbf/osmformat.pb.h"
using namespace std;
namespace po ... |
/***********************************************************************************************************************
* *
* ANTIKERNEL v0.1 ... |
//%Header {
/*****************************************************************************
*
* File: src/Platform/MacOSX/PlatformInputUtils.cpp
*
* Copyright: <NAME> 2002-2007, 2020
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation fi... |
#include "MainScene.h"
#include "ui_MainScene.h"
#include "Config.h"
#include <QPainter>
#include <QIcon>
#include <QMouseEvent>
void MainScene::closeEvent(QCloseEvent *event)
{
qDebug()<<"MainScene关闭了";
// 发送事件
emit closeScene();
}
MainScene::MainScene(QWidget *parent) :
QWidget(parent),
ui(new U... |
#include <faunus/faunus.h>
using namespace Faunus;
typedef Space<Geometry::Cuboid> Tspace;
namespace Faunus {
namespace Potential {
class IonIonSP3 : public Coulomb {
private:
string _brief() { return "Coulomb SP3"; }
double rc1, rc1i, rc2, _lB;
public:
IonIonSP3(Tmjson &j, co... |
/*
$Author = <NAME>;
$Corp = RedM Inc;
$Web = https://redm.pro/;
$Lincese = BSD 3;
$Name = mLang;
$Description = A programming language for web programming.;
*/
#define _FILE_OFFSET_BITS 64
#include "exception.h"
#include "string_functions.h"//strtoupper
array <array <string> > f$debug_backtrace (void) {
dl::ente... |
// $Id$
#include "ContigIterator_AMOS.hh"
using namespace std;
using namespace AMOS;
TiledRead_t::TiledRead_t(Tile_t tile, Read_t red, int readidx)
: m_seq(red.getSeqString(tile.range)),
m_qual(red.getQualString(tile.range)),
m_readidx(readidx),
m_fragid(red.getFragment()),
m_iid(red.g... |
// FILE: LatGrb.cxx
#include <algorithm> // for sort
#include "LatGrb.h"
#include "GRBpulse.h"
#include "GRBobsConstants.h"
#include "CLHEP/Random/RandFlat.h"
const double LatGrb::s_emax=100.0;
const double latGeoArea=282743;
const double denom=7.;
// Constructor
LatGrb::LatGrb(CLHEP::HepRando... |
#include "lua_ws_client.hpp"
#include "client_ws.hpp"
#include "lua.hpp"
#ifndef lua_boxpointer
#define lua_boxpointer(L,u) \
(*(void **)(lua_newuserdata(L, sizeof(void *))) = (u))
#endif
#ifndef lua_unboxpointer
#define lua_unboxpointer(L,i) (*(void **)(lua_touserdata(L, i)))
#endif
#define method(class... |
#include<bits/stdc++.h>
using namespace std;
const int N = 1e5 + 9, B = 330;
struct Block {
vector<int> v, sorted_v; int sz = 0;
int assigned = -1;
bool rev = false;
Block() {}
Block(int s, int to_assign, bool to_rev = false) {
sz = s; rev = to_rev;
assigned = to_assign;
}
Block(... |
/*********************************************************************
*
* Copyright (C) 2005-2006, Karlsruhe University
*
* File path: sigma0_io.cc
* Description: IO-Port (IA32/AMD64) specific stuff
*
* Redistribution and use in source and binary forms, wit... |
// Copyright (c) 2020-2021 <NAME> <<EMAIL>>
// Available under the MIT License - see LICENSE.txt for details.
#include "3rdparty/pcg.hpp"
#include "common/xormix.hpp"
#include <pybind11/numpy.h>
#include <pybind11/pybind11.h>
#include <cstdint>
#include <map>
template<typename uint_t>
uint_t pcg_random(pcg32_rando... |
#include "DirectoryTree.h"
#include <dirent.h>
#include <iomanip>
#include <iostream>
#include <string.h>
#include <unistd.h>
std::vector<DirectoryTree *> DirectoryTree::trees = std::vector<DirectoryTree *>();
DirectoryTree::DirectoryTree(const std::string &root) {
std::cout << root << "\n";
trees.push_back(this);
... |
#ifndef __USE_BSD
#define __USE_BSD
#endif
#include <stdio.h>
#include <stdlib.h>
#include <errno.h>
#include <string.h>
#include <pcap.h>
#include <sys/socket.h>
#include <netinet/in_systm.h>
#include <netinet/in.h>
#include <netinet/ip.h>
#include <arpa/inet.h>
#include <net/ethernet.h>
#include <netinet/if_ether.h>... |
#include<cstdio>
#include<cmath>
#include<cstring>
#include<vector>
#include<algorithm>
typedef long long ll;
using namespace std;
#define lson l , mid , rt << 1
#define rson mid + 1 , r , rt << 1 | 1
const int N = 6e5+10;
const double pi = acos(-1.0);
const int mod=313;
char s1[N],s2[N];
int len,... |
// -*- mode: C++; tab-width: 4 -*-
// vi: ts=4
/*
* Copyright (c) 2010, <NAME> and <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 retai... |
/* FCE Ultra - NES/Famicom Emulator
*
* Copyright notice for this file:
* Copyright (C) 2002 Xodnizel
*
* 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, o... |
/*******************************************************************************
Author: <NAME> <<EMAIL>>
<NAME> <<EMAIL>>
Version: 2.0
Date: 2016/May/26
*******************************************************************************/
#include <Arduino.h>
#include "AccelStepper.h"
#include "... |
/**
* Copyright (c) 2020 nicegraf contributors
*
* 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, mer... |
/* Copyright(c) 2012 Optimal Bits Sweden AB. All rights reserved.
*
* 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,... |
/*
* ImageDatabase.cpp
*
* Created on: Jul 11, 2018
* Author: sujiwo
*/
#include <ros/package.h>
#include <map>
#include "ImageDatabase.h"
#include "MapPoint.h"
#include "KeyFrame.h"
#include "Frame.h"
#include "utilities.h"
using namespace std;
using namespace Eigen;
ImageDatabase::ImageDatabase(VMap *... |
// *********************************************************************
// **
// ** Informática Gráfica, curso 2019-20
// ** Implementación de la clase 'MallaRevol'
// **
// *********************************************************************
#include "ig-aux.h"
#include "tuplasg.h"
#include "lector-ply.h"
#include ... |
//-*-mode:c++; mode:font-lock;-*-
/*! \file VSAQuadrature.cpp
Classes for numerical integration.
\author <NAME> \n
UCLA \n
<EMAIL> \n
\version 0.1
\date 12/01/2008
*/
#include <VSAQuadrature.hpp>
using namespace V... |
#include "testApp.h"
void testApp::setup(){
image.loadImage("bg.png");
texture.loadImage("particleGrid.png");
ofDisableArbTex();
texture.loadImage("particleGrid.png");
ofEnableAlphaBlending();
texW = texture.getWidth();
texH = texture.getHeight();
cellRows = 2;
cellCol... |
/*****************************************************************************************
* *
* Copyright (c) 2016 - 2020 *
* <NAME>, <NAME>, <NAME> ... |
#include <stdio.h>
#include <math.h>
#include <stdlib.h>
#include <iostream>
#include <cstring>
#include <fstream>
#include <map>
#include <set>
#include <string>
#include <utility>
#include <algorithm>
#include <iomanip>
#include "utils.h"
#include "api/BamMultiReader.h"
#include "api/BamReader.h"
#include "api/BamWr... |
/*
* Copyright (c) 2009 Jice
* 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 ... |
// MIT License
//
// Copyright(c) 2021-2022 <NAME>
// Copyright(c) 2021-2022 <NAME> - Reality XP
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this softwareand associated documentation files(the "Software"), to deal
// in the Software without restriction, including without lim... |
/*
* Progarm Name: serial.cpp
* Created Time: 2015-12-23 13:29:37
* Last modified: 2016-10-19 15:28:37
*/
#include "serial.hpp"
#include <iostream>
#include <stdlib.h>
#include <stdio.h>
#include <unistd.h>
#include <string.h>
#include <errno.h>
#include <fcntl.h>
#include <pty.h>
#include <ctype.h>
#include <sche... |
#include <string>
#include <fstream>
#include <iostream>
#include <memory>
#include <stdexcept>
#include <limits>
#include "openssl/evp.h"
#include "openssl/rand.h"
#include "openssl/crypto.h"
#include "binaryManip.h"
static const unsigned int BLOCK_SIZE = 32;
template <typename T>
struct zallocator
{
public:
ty... |
//-----------------------------------------------------------------------------
// Copyright (c) 2013 GarageGames, LLC
//
// 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 restrictio... |
#include "heat_solver.hpp"
void heat_solver::bind_vertex_location()
{
// replcate to 3 after done debugging grid rendering
const size_t NUM_PAR = 3;
const size_t NUM_POINTS = NUM_PAR * X * Y * Z;
float *pos = new float[NUM_POINTS];
size_t i;
auto dx = heat_parameters::get_instance().get_dx()... |
// placebo.cpp
// Copyright (c) 2019, zhiayang
// Licensed under the Apache License Version 2.0.
#include <stdio.h>
#include <assert.h>
#include <stdint.h>
#include <stdlib.h>
#include <stddef.h>
#include <string.h>
#include <nx/ipc.h>
#include <nx/rpc.h>
#include <nx/syscall.h>
#include <svr/tty.h>
#include <svr/vf... |
#include "Fuji.h"
#include "MFSystem.h"
#include "MFStringCache.h"
#include "MFSound_Internal.h"
#include "MFHeap.h"
#include "stdarg.h"
struct WAVChunk
{
int id;
long size;
};
struct WAVFormatChunk : public WAVChunk
{
short wFormatTag;
unsigned short nChannels;
unsigned long nSamplesPerSec;
... |
// Copyright 2014 <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, publish,... |
#include <windows.h>
#include "vblic.h"
#ifdef BETA_BOMB
#include "timebomb.h"
#endif //BETA_BOMB
// NOTE: The following strings must match exactly the content of the registry as specified in
// vbprolic.reg.
#define LICENSES_KEY "Licenses"
void CalcValue(char * pszLicenseKey, char * pszKeyValue, LPTSTR p... |
#include<bits/stdc++.h>
#include<graphics.h>
using namespace std;
// declaring class point
class Point
{
public:
int x1, y1, x2, y2;
string lineType = "";
string region_code1 = "";
string region_code2 = "";
};
int n;
// declaring class poly
class Poly
{
private:
Point ... |
/*
* Software License Agreement (BSD License)
*
* Copyright (c) 2011, <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 of source code must reta... |
/*
* Copyright 2011, Pythia authors (see AUTHORS file).
* 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 of source code must retain the above copyright
* notice,... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.