text stringlengths 3.08k 12.5k |
|---|
#include "babeltrader/base/babeltrader_base.h"
#include "test_utils/test_utils.h"
USING_NS_BABELTRADER;
; // for avoid pragma warning tip in vim
#pragma pack(push, 1)
struct NetworkMsgDemo
{
NetworkMessage head; //!< network message head
uint32_t u32;
int32_t i32;
float f;
double d;
};
static_assert(size... |
#include <ross.h>
#define TW_GVT_NORMAL 0
#define TW_GVT_COMPUTE 1
static unsigned int g_tw_gvt_max_no_change = 10000;
static unsigned int g_tw_gvt_no_change = 0;
static tw_stat all_reduce_cnt = 0;
static unsigned int gvt_cnt = 0;
static unsigned int gvt_force = 0;
static double globalGVT;
static const tw_optdef gvt... |
/*
* Copyright (c) 2008, Autodesk, 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 retain the above copyright
* notice, this li... |
/*
* Copyright (C) 2016 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... |
/*
* Copyright (c) 2015-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*/
#include "M... |
//
// Created by haisheng.yhs on 2017/5/5.
//
#include "ws/membuf.h"
#include "ws/uvutil.h"
#include "ws/CWSClient.h"
#include "test_header.h"
#include "simple_log.h"
#include <string>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <assert.h>
class MyCWSClient : public arc::CWSClient{
publi... |
#include "stdafx.h"
#include <algorithm>
#include <fstream>
#include "attractors.h"
using namespace attractors;
/////////////////
// float color //
/////////////////
color color::hue(number h) {
h *= 6.0;
int hi = static_cast<int>(h);
number hf = h - hi;
switch (hi % 6) {
case 0:
return color(1.0, hf, 0.0... |
//=========================================================================
// 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... |
/*
* Copyright 2007 <NAME>
* For license terms, see the file COPYING along with this library.
*/
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <signal.h>
#include "spporting.hpp"
#include "splfserver.hpp"
#include "speventcb.hpp"
#include "spthreadpool.hpp"
#include "sphandler.hpp"
#include... |
#include "TypeScopeIDTypedefDecorator.h"
#include "ConcreteTableColumn.h"
#include "TypedefDecorator.h"
#include "TypesTable.h"
#include "FindClassOfFunction.h"
#include "SetOperations.h"
TypeScopeIDTypedefDecorator::TypeScopeIDTypedefDecorator(DataExtractor *next, ConcreteTableColumn *prototype, TypedefDecorator *con... |
#include "3X3Matrix.h"
#include "4Vector.h"
#include "MyMath.h"
C3X3Matrix::C3X3Matrix()
{
}
C3X3Matrix::C3X3Matrix(const C3Vector& xAxis,const C3Vector& yAxis,const C3Vector& zAxis)
{
(*this).axis[0]=xAxis;
(*this).axis[1]=yAxis;
(*this).axis[2]=zAxis;
}
C3X3Matrix::C3X3Matrix(const C4Vector& q)
{
... |
#include "linux_Thread.h"
#include <QDebug>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
#include <sys/un.h>
#include <sys/ioctl.h>
#include <sys/socket.h>
#include <linux/types.h>
#include <linux/netlink.h>
#include <errno.h>
#include <unistd.h>
#include <arpa/inet.h>
#include <netinet... |
#include <dirent.h>
#include <unistd.h>
#include <string>
#include <vector>
#include <sstream>
#include <iostream>
#include "linux_parser.h"
using std::stof;
using std::string;
using std::to_string;
using std::vector;
// DONE: An example of how to read data from the filesystem
string LinuxParser::OperatingSystem(... |
#include <algorithm>
#include <array>
#include <cassert>
#include <cstdint>
#include <iostream>
#include <map>
#include <queue>
#include <set>
#include <string>
#include <vector>
#include <sstream>
using Registers = std::array<int64_t, 6>;
struct Instruction
{
int opcode;
int a, b, c;
};
using Program = std:... |
/* p12_utl.c */
/* Written by Dr <NAME> (<EMAIL>) for the OpenSSL
* project 1999.
*/
/* ====================================================================
* Copyright (c) 1999 The OpenSSL Project. All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are pe... |
// Copyright Yahoo. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
#include <vespa/document/bucket/bucketidfactory.h>
#include <vespa/vdslib/distribution/distribution.h>
#include <vespa/vdslib/state/clusterstate.h>
#include <vespa/vespalib/util/programoptions.h>
#include <vespa/co... |
#pragma once
#include <array>
#include <cassert>
#include <iostream>
#include <list>
// CUT begin
// Fibonacci heap
// - Complexity:
// - empty(), size(), top(), push(), meld(): O(1)
// - pop(), decrease(): O(lg N) amortized
// - Reference:
// - "Introduction to Algorithms, Third Edition", Chapter 19
// - <htt... |
// Copyright 2012 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 "base/debug/trace_event.h"
#include "cc/content_layer_client.h"
#include "cc/picture.h"
#include "cc/rendering_stats.h"
#include "skia/ext/analys... |
#pragma once
#include "shared/core_defines.hpp"
#include <string>
#include <memory>
#include <vector>
enum class StorySource : uint8_t
{
NONE = 0,
FF = 1,
AO3 = 2,
COUNT = 3
};
enum class ContentRating : uint8_t
{
NONE,
K,
K_PLUS,
T,
M,
COUNT
};
enum class Genre : uint8... |
/**
* @copyright Copyright (c) 2020 All Right Reserved, B-com http://www.b-com.com/
*
* This file is subject to the B<>Com License.
* All other rights reserved.
*
* THIS CODE AND INFORMATION ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY
* KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE
* IMPL... |
/*
* Copyright (C) 2006 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... |
/*
This program was created at: Fri Apr 17 14:59:53 2015
This program was created by: <NAME>
Contact: <EMAIL>
Organization: Unviersity of Utah
School of Medicine
Salt Lake City, Utah
The MIT License (MIT)
Copyright (c) <2015> <<NAME>>
Permission is hereby granted, free of charge, to any person obtaini... |
#include "HKTLV.h"
//////////////////////////////////////
// TLV constructor()
TLV::TLV(){
numTags = 0;
//////////////////////////
// Create TLV8 records //
//////////////////////////
create(kTLVType_State, 1, "STATE");
create(kTLVType_PublicKey, 384, "PUBKEY");
create(kTLVType_Method, 1, "METHOD");
... |
//=============================================================================
//
// Adventure Game Studio (AGS)
//
// Copyright (C) 1999-2011 <NAME> and 2011-20xx others
// The full list of copyright holders can be found in the Copyright.txt
// file, which is part of this source code distribution.
//
// The AGS sourc... |
//-----------------------------------------------------------------------------
// Copyright (c) 2012 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... |
/**************************************************************************\
* Copyright (c) <NAME> & Gas Technologies AS
* 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... |
// Copyright (c) 2011, Cornell 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 of source code must retain the above copyright notice,
// this list ... |
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
/*
* File: AppClass.cpp
* Author: eye
*
* Created on September 17, 2019, 7:31 PM
*/
#include "app/AppClass.h"
#include "scen... |
/* Copyright (c) 2002,2003 CrystalClear Software, Inc.
* Use, modification and distribution is subject to the
* Boost Software License, Version 1.0. (See accompanying
* file LICENSE_1_0.txt or http://www.boost.org/LICENSE_1_0.txt)
* Author: <NAME>, <NAME>
*/
#include "boost/date_time/posix_time/posix_time... |
#include <cstring>
#include <emmintrin.h>
#include <immintrin.h>
void matvec2_naive(double* y_vect, const double* a_matr, const double* x_vect, int size)
{
for (int i = 0; i < size; ++i) {
y_vect[i] = 0.0;
for (int j = 0; j < size; ++j) {
y_vect[i] += a_matr[i * size + j] * x_vect[j];
... |
/* This file is part of the Gudhi Library - https://gudhi.inria.fr/ - which is released under MIT.
* See file LICENSE or go to https://gudhi.inria.fr/licensing/ for full license details.
* Author(s): <NAME>, <NAME>
*
* Copyright (C) 2020 Inria
*
* Modification(s):
* - YYYY/MM Author: De... |
#include "androidprojectmodifier.h"
AndroidProjectModifier::AndroidProjectModifier(QString path)
{
m_directory = QDir(path);
}
void AndroidProjectModifier::addSupportLibrary()
{
const auto path = QStringLiteral("/app/build.gradle");
auto fileContent = getFileContent(path);
fileContent = fileContent.r... |
#include <rxcpp/rx.hpp>
#include <memory>
#include <map>
#include <algorithm>
#include <string>
#include <vector>
#include <windows.h>
#include <functional>
#include <thread>
#include <future>
using namespace std;
////////////////////////////////////
//-------------- Forward Declarations
//-------------- Model Folder/F... |
/*
* Copyright 2019 Xilinx, 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... |
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <ImfArray.h>
#include <ImfTiledRgbaFile.h>
// Handle the case when the custom namespace is not exposed
#include <ImfChannelList.h>
#include <ImfMultiPartInputFile.h>
#include <ImfMultiPartOutputFile.h>
#include... |
#include "util.h"
#include "DictionaryTrie.h"
#include <iostream>
#include <stack>
/**
* Name: <NAME> and <NAME>
* Date: Feb 9
* Overview: implements a dictionary using MWT as backend
* Assignment number: 2
*/
using namespace std;
/* Create a new Dictionary that uses a Trie back end */
DictionaryTrie::Dictionary... |
#pragma once
#include <set>
#include <stdlib.h>
#include <stdint.h>
#include <assert.h>
#include <stdio.h>
#include "c9/channel9.hpp"
#include "memcheck.h"
namespace Channel9
{
class GCRoot;
class GC { // GC base class, must be subclassed by one of the others
//small allocations are smaller than SMALL, medium... |
/*
On an infinite number line (x-axis), we drop given squares in the order they are given.
The i-th square dropped (positions[i] = (left, side_length)) is a square with the left-most point being positions[i][0] and sidelength positions[i][1].
The square is dropped with the bottom edge parallel to the number line, and... |
#include<iostream>
#include<iomanip>
#include<vector>
#include<math.h>
#include "Element.h"
#include "Basis.h"
#include "GaussQuad.h"
#include<algorithm>
using namespace std;
// constructor
Element::Element(const Node &N1, const Node &N2, const Node &N3, const int &ID)
: node1(N1), node2(N2), no... |
/**
* \file dnn/src/cuda/group_local/forward/opr_impl.cpp
* MegEngine is Licensed under the Apache License, Version 2.0 (the "License")
*
* Copyright (c) 2014-2021 Megvii Inc. All rights reserved.
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distribut... |
/* ---------------------------------------------------------------------------
** This software is in the public domain, furnished "as is", without technical
** support, and with no warranty, express or implied, as to its usefulness for
** any purpose.
**
** v4l2copy.cpp
**
** Copy from a V4L2 capture device to an oth... |
/* SPDX-License-Identifier: BSD-2-Clause-Patent
*
* Copyright (c) 2016-2019 Intel Corporation
*
* This code is subject to the terms of the BSD+Patent license.
* See LICENSE file for more details.
*/
#include "config.h"
#include <exception>
#include <mapf/broker/broker.h>
#include <mapf/common/err.h>
#include <ma... |
#include "ns3/core-module.h"
#include "ns3/network-module.h"
#include <cmath>
#include <iomanip>
#include "ns3/yans-wifi-channel.h"
#include "ns3/propagation-loss-model.h"
#include "ns3/propagation-delay-model.h"
#include "ns3/nist-error-rate-model.h"
#include "ns3/applications-module.h"
class Experiment{
private:
P... |
//// cell: core lisp data structure with ref-counted garbage collection
// Design considered the following:
// represent numbers, strings, symbols, lists, and hash-tables
// reclaim unused cells
// minimize memory footprint
// avoid fragmentation
// so all cells try to have the same size (exceptions: strings, t... |
#include "life.hpp"
#include <algorithm>
#include <cmath>
#include <iostream>
#include <sstream>
#include <numeric>
LifeLine::LifeLine(const std::string& input_line) {
std::istringstream input(input_line);
std::string state;
input >> state >> state >> state; // Ignore first 2 words
int game_index = 0;... |
#define _USE_MATH_DEFINES
#include <cmath>
#include <stdio.h>
#include <stdlib.h>
#include <string>
#include "KpMop_19.hpp"
#include "KpToRigHelper.hpp"
#include "RigToKpHelper.hpp"
#include "KpHelper.hpp"
#include "Utility.hpp"
KpMop_19::KpMop_19( std::string kpType,
const std::map< KEYPOINT_TYPE, int > & kpLayout... |
// Copyright (C) 2018-2022 Intel Corporation
// SPDX-License-Identifier: Apache-2.0
//
#include <cstdlib>
#include <iomanip>
#include <memory>
#include <set>
#include <string>
#include <tuple>
#include <vector>
// clang-format off
#include "openvino/openvino.hpp"
#include "samples/common.hpp"
#include "samples/slog.h... |
#include <stdio.h>
#ifdef OMP_COMPILE
#include <omp.h>
#endif
#include <stdlib.h>
#include <sys/time.h>
#include "convolve.h"
#include "net_specs.h"
#include "data.h"
#define INPUTSZ(OPSZ, S, K) (K + (OPSZ-1)*S)
#define RANGE (100)
// Use values from net_spec.h
#define PARAMS ::hyperparameters
#define ... |
/**
\file
test file for CSCDetId
\author <NAME>
\date 27 Jul 2005
*/
#include <cppunit/extensions/HelperMacros.h>
#include <DataFormats/MuonDetId/interface/CSCDetId.h>
#include <FWCore/Utilities/interface/Exception.h>
#include <iostream>
using namespace std;
class testCSCDetId : public CppUnit::TestFixt... |
// Copyright (C) 2004-2006 <NAME>, <NAME>, <NAME>
// 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)
#define SOCI_MYSQL_SOURCE
#include "soci/soci-platform.h"
#include "soci/mysql/soci-mysql.h"
#include "soci-compi... |
#include <stdio.h>
#include "Hexy.h"
using namespace std;
#define MAX_MESSAGE_SIZE 11
#define HEXY_INIT_RESPONSE "SERVOTOR"
#define INIT_MESSAGE "V\n"
#define RESET_MESSAGE "C\n"
static char messageBuffer[MAX_MESSAGE_SIZE + 1];
static char receiveBuffer[MAX_PATH + 1];
const int SERVO_NUMBERS[][SERVOS_PER_LEG] = {... |
/***************************************************
DFRobot Gravity: Analog TDS Sensor/Meter
<https://www.dfrobot.com/wiki/index.php/Gravity:_Analog_TDS_Sensor_/_Meter_For_Arduino_SKU:_SEN0244>
***************************************************
This sample code shows how to read the tds value and calibrate it w... |
#include "collection.h"
#include "ui_collection.h"
Collection::Collection(QWidget *parent, bool gameMode) :
QDialog(parent),
ui(new Ui::Collection),
gameMode {gameMode},
customPosition {OUT_OF_SIGHT, OUT_OF_SIGHT},
menu {this}
{
ui->setupUi(this);
// for correct resizing when w... |
/*
===========================================================================
Doom 3 BFG Edition GPL Source Code
Copyright (C) 1993-2012 id Software LLC, a ZeniMax Media company.
This file is part of the Doom 3 BFG Edition GPL Source Code ("Doom 3 BFG Edition Source Code").
Doom 3 BFG Edition Source Code is free... |
#include <iostream>
#include <sstream>
#include <occa/defines.hpp>
#include <occa/tools/cli.hpp>
#include <occa/tools/testing.hpp>
void testPretty();
void testOption();
void testArgument();
void testParser();
void testCommand();
int main(const int argc, const char **argv) {
testPretty();
testOption();
testArgum... |
/* MIT License
Copyright (c) 2021 <NAME> (github.com/agustinBassi)
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, modif... |
/***************************************************************************
* Copyright 1998-2020 by authors (see AUTHORS.txt) *
* *
* This file is part of LuxCoreRender. *
* ... |
/* ============================================================
* QupZilla - WebKit based browser
* Copyright (C) 2013 <NAME> <<EMAIL>>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either ... |
#include "stfspackage.h"
using namespace std;
using namespace Streams;
StfsPackage::StfsPackage( Streams::IStream *Stream )
{
this->Stream = Stream;
checkedIfIsStfsPackage = false;
_isStfsPackage = false;
_magic = 0;
_contentType = 0;
_titleId = 0;
_consoleId = 0;
_profileI... |
// Copyright (c) 2009-2010 <NAME>
// Copyright (c) 2009-2015 The Bitcoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "pow.h"
#include "arith_uint256.h"
#include "chain.h"
#include "chainparams.h"
#i... |
/*
* Copyright (c) 2016, 2017 ARM Limited.
*
* SPDX-License-Identifier: MIT
*
* 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
* r... |
/**
*
* \file
* \brief [Breadth First Search Algorithm
* (Breadth First Search)](https://en.wikipedia.org/wiki/Breadth-first_search)
*
* \author [<NAME>](https://github.com/ayaankhan98)
* \author [<NAME>](https://github.com/gpamangkp)
*
*
* \details
* Breadth First Search also quoted as BFS is a Graph Traver... |
#include "../_contract-shared-headers/migration_helpers.hpp"
void daccustodian::updateVoteWeight(name custodian, int64_t weight, name dac_id) {
if (weight == 0) {
print("\n Vote has no weight - No need to continue.");
return;
}
candidates_table registered_candidates(_self, dac_id.value);
... |
#include "IG1App.h"
#include "CheckML.h"
#include <iostream>
using namespace std;
//-------------------------------------------------------------------------
// static single instance (singleton pattern)
IG1App IG1App::s_ig1app; // default constructor (constructor with no parameters)
//-----------------... |
#include "NNVisualizer.h"
//-----------------
//Created by <NAME> on February 02 2016
//-----------------
NNVisualizer::NNVisualizer()
{
windowTopX = 200;
windowTopY = CParams::borderWidth + 20;
windowWidth = CParams::WindowWidth - 50 - windowTopY;
windowHeight = CParams::bottomLimit - 10 - windowT... |
//
// Server.cpp
// LAB2
//
// Created by 钱依柔 on 6/8/19.
// Copyright © 2019 钱依柔. All rights reserved.
//
#include "Server.hpp"
#include <cstdio>
#include <stdlib.h>
#include <unistd.h>
#include <errno.h>
#include <cstring>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <netdb.h>
... |
/**
* ============================================================================
*
* Copyright (C) 2020, Hisilicon Technologies Co., Ltd. All Rights Reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
... |
#include "MyMesh.h"
// MyMesh
void MyMesh::Init(void)
{
m_bBinded = false;
m_nVertexCount = 0;
m_vao = 0;
m_VertexBuffer = 0;
m_ColorBuffer = 0;
//Compile Color shader
m_nShaderProgram = LoadShaders("shaders\\BasicColor.vs", "shaders\\BasicColor.fs");
}
void MyMesh::Swap(MyMesh& other)
{
std::swap(m_bBinded,... |
//
// Created by AregevDev on 23/04/2020.
//
#include <imgui.h>
#include <fmt/core.h>
#include "rvpt.h"
#define TINYOBJLOADER_IMPLEMENTATION // define this in only *one* .cc
#include "tinyobjloader/tiny_obj_loader.h"
void load_model(RVPT& rvpt, std::string inputfile, int material_id)
{
rvpt.get_asset_path(input... |
// Programa de prueba de la clase ModbusServe
#define TITULO "ModbusRTU: Escritura salidas analógica única (función 0x06)"
#include <iostream>
#include <iomanip>
#include <vector>
#include "Mensaje.hpp"
#include "ModbusRTU.hpp"
int pruebas = 0;
int fallos = 0;
#define ID_DEV 6
void testea(ModbusRTU &mbs, std::s... |
// Copyright (c) 2006-2008 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 <time.h>
#include "base/platform_thread.h"
#include "base/time.h"
#include "build/build_config.h"
#include "testing/gtest/include/gtest... |
#include <arpa/inet.h>
#include <string.h>
#include "core/ByteOrder.h"
#include "core/Comparison.h"
#include "core/File.h"
#include "core/MemoryUtils.h"
#include "core/TritonSortAssert.h"
#include "mapreduce/common/boundary/KeyList.h"
KeyList::KeyList(
uint64_t _numKeys, uint64_t _numBytes, uint64_t _lowerBoundOffs... |
//
// 最近点対
//
// verified:
// AOJ Course CGL_5_A Point Set - Closest Pair
// http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=CGL_5_A&lang=jp
//
#include <iostream>
#include <vector>
#include <cmath>
#include <iomanip>
#include <algorithm>
using namespace std;
////////////////////////////
// 基本要素 (点, ... |
#include "JPEGData.h"
JPEGData::~JPEGData() {
freebuffers();
_width = _height = _stride = 0;
}
void JPEGData::freebuffers() {
if(_image) {
free((void *)_image);
_image = nullptr;
}
if(_scanlines) {
free((void *)_scanlines);
_scanlines = nullptr;
}
}
// fuzzy integer comparison
int JPEGData::fuzzy_cmp( co... |
/* main_slicer.cpp
* Copyright (C) (2011) <NAME>, <NAME>, <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 3 of the License, or
* (at your option) any later version... |
#include <stdlib.h>
#include <stdio.h>
#include <iostream> // std::cout, std::endl
#include <iomanip> // std::setfill, std::setw
////////////////////////////////////////////////////////////////////////////
/// This is a generated file. Edit it on your risk.
/// This was produced by running: elfasm2c.php ../da... |
// Copyright (c) 2018 <NAME>
//
// I am making my contributions/submissions to this project solely in my
// personal capacity and am not conveying any rights to any intellectual
// property of any third parties.
#include <pch.h>
#include <jet/anisotropic_points_to_implicit3.h>
#include <jet/fmm_level_set_solver3.h>
#... |
#include <ros/ros.h>
#include <geometry_msgs/PoseStamped.h>
#include <mavros_msgs/CommandBool.h>
#include <mavros_msgs/SetMode.h>
#include <mavros_msgs/State.h>
#include "include/movement.h"
using namespace std;
enum flying_step
{
IDLE,
TAKEOFF,
HOVER,
LAND,
SWAY,
MOVE,
END,
};
static flyi... |
// Copyright <NAME> 2006
// Copyright <NAME> 2010
// Use, modification and distribution are subject to the
// Boost Software License, Version 1.0.
// (See accompanying file LICENSE_1_0.txt
// or copy at http://www.boost.org/LICENSE_1_0.txt)
#ifdef _MSC_VER
# pragma warning(disable: 4512) // assignment operator could... |
#include <Eigen/Dense>
#include <iostream>
#include "general.h"
using EigenMatrix = Eigen::MatrixXd;
using EigenVector = Eigen::VectorXd;
EigenMatrix oneD()
{
EigenMatrix m(1,4);
m(0,0) = 3;
m(0,1) = 2.5;
m(0,2) = -1;
m(0,3) = 1.5;
return m;
}
EigenMatrix lapack_oneD()
{
auto eigenM = one... |
/*
* Copyright (c) 2021, <NAME> <<EMAIL>>
*
* SPDX-License-Identifier: MIT
*/
#include "GlobalObject.h"
#include <AK/Format.h>
#include <AK/JsonObject.h>
#include <AK/Result.h>
#include <AK/String.h>
#include <AK/Vector.h>
#include <LibCore/ArgsParser.h>
#include <LibCore/File.h>
#include <LibJS/Bytecode/BasicBloc... |
//
// ImageQueue.cpp
// FluxOF
//
// Created by <NAME> on 14/06/14.
//
//
#include "ImageQueue.h"
void ImageQueue::setupUI(){
incommingSizeLabel = gui->addLabel("");;
oldSizeLabel = gui->addLabel("");;
lastImageUI = gui->addImage("Last image", nil, 100, 100, true);
currentImageUI = gui->addI... |
#include "config.h"
#include "module.h"
#include <WinSock2.h>
#include <Windows.h>
#include <netadr.h>
#include <vector>
#include <ImageHlp.h>
#include <ws2tcpip.h>
typedef enum netsrc_s
{
NS_CLIENT,
NS_SERVER,
NS_MULTICAST
} netsrc_t;
typedef void (*fnNetchan_OutOfBandPrint) (netsrc_t sock, netadr_t adr, char *f... |
// This file is part of Eigen, a lightweight C++ template library
// for linear algebra.
//
// Copyright (C) 2008-2009 <NAME> <<EMAIL>>
//
// Eigen 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; eith... |
/*
* MIT License
*
* Copyright (c) 2021 Samsung Electronics Corporation
*
* 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 th... |
/****************************** Module Header ******************************\
* Module Name: CppSparseFile.cpp
* Project: CppSparseFile
* URL: http://code.msdn.microsoft.com/windowsapps/CppSparseFile-7f28156b
* Copyright (c) Microsoft Corporation.
*
* CppSparseFile demonstrates the common operations on sparse fi... |
#pragma once
#include"strsearch.h"
int intoint(char a)
{
if ('a' <= a && a <= 'z') return int(a) - 'a' + 1;
if (a == ' ') return 27;
if ('A' <= a && a <= 'Z') return int(a) - 'A' + 28;
if ('0' <= a && a <= '9') return int(a) - '0' + 54;
return 65;
}
void Hash_resource::make_poww(int n)
{
int k =... |
/*++
Copyright (C) 2020 Autodesk 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 retain the above copyright
notice, this list of conditions and the follow... |
#include "stdafx.h"
#pragma hdrstop
#include "dz_errs.h"
#undef _DZ_FILE_
#define _DZ_FILE_ DZ_UNZCRYPT_CPP
/*
* crypt.c (full version) by Info-ZIP. Last revised: [see crypt.h]
*
* This code is not copyrighted and is put in the public domain. The
* encryption/decryption parts (as opposed to the non-ec... |
////////////////////////////////////////////////////////////////////////////////
/// DISCLAIMER
///
/// Copyright 2014-2016 ArangoDB GmbH, Cologne, Germany
/// Copyright 2004-2014 triAGENS GmbH, Cologne, Germany
///
/// Licensed under the Apache License, Version 2.0 (the "License");
/// you may not use this file except... |
/*
* Copyright (C) 2001-2003 <NAME> (<EMAIL>)
* 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, this li... |
/***************************************************************************/
/**
** @file
** @brief unit test code for Tipper triangulator
**
** Use with:
** (stand-alone)
** g++ -DTIPPER_TEST -DDONT_USE_PREDICATE TipperTriangulator_test.cpp
** TipperTriangulator.cpp TipperTriangulatorError.cpp
** (with al... |
#include "include/junosconfparser/junosconfparser.hpp"
#include <algorithm>
#include <iostream>
#include <queue>
#include <set>
#include <sstream>
#include <stack>
#include <string>
#include <vector>
struct iface {
std::string intf;
std::string unit;
std::string descr;
std::string isismetric;
std::string upd... |
/*
* 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... |
/**
* Copyright (c) Microsoft Corporation
*
* 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
*
* THIS CODE IS P... |
// SPDX-License-Identifier: BSD-3-Clause
/* Copyright 2018-2020, Intel Corporation */
/*
* concurrent_hash_map_reorder.cpp -- pmem::obj::concurrent_hash_map test
*
*/
#include "unittest.hpp"
#include <libpmemobj++/make_persistent.hpp>
#include <libpmemobj++/p.hpp>
#include <libpmemobj++/persistent_ptr.hpp>
#inclu... |
// (c) Facebook, Inc. and its affiliates. Confidential and proprietary.
#include <fcntl.h>
#include <folly/Conv.h>
#include <folly/String.h>
#include <folly/init/Init.h>
#include <gflags/gflags.h>
#include <stdlib.h>
#include <sys/mman.h>
#include <sysexits.h>
#include <unistd.h>
#include <sstream>
#include <string>
... |
#include "ros_controller.h"
RosController::RosController(ros::NodeHandle &nh, std::string controller_name,
std::string refCallback_topic, double *state,
double *force_or_torque, double frequency)
: state_ptr_(state), controller_name_(controller_name),
... |
#include "main.h"
#ifdef WIN32
#include <windows.h>
#endif
//update code and stuff here
void handle_mouse(float scale, int w, int h) {
int x,y;
mouse_state = SDL_GetMouseState(&x,&y);
Point virtualMouse = { 0 };
virtualMouse.x = (mouse_pos.x - (w - (WINDOW_WIDTH*scale))*0.5f)/scale;
virtualMouse... |
#include <wiringPi.h>
#include <cstdint>
#include <iostream>
#include <sstream>
#include <array>
#include <bitset>
struct ScopedTimer
{
const uint32_t t0;
ScopedTimer() : t0(micros()) {}
uint32_t duration() const {
const uint32_t t = micros();
// check if we wrapped
if (t < t0)
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.