text string | size int64 | token_count int64 |
|---|---|---|
/*
ArmA 3 TAW View Distance Management
*/
#define ST_LEFT 0x00
#define ST_MULTI 0x10
#define GUI_GRID_CENTER_WAbs ((safezoneW / safezoneH) min 1.2)
#define GUI_GRID_CENTER_HAbs (GUI_GRID_CENTER_WAbs / 1.2)
#define GUI_GRID_CENTER_W (GUI_GRID_CENTER_WAbs / 40)
#define GUI_GRID_CENTER_H (GUI_GRID_... | 14,960 | 8,011 |
#include "OrthoCamera.h"
#include <glm/gtc/matrix_transform.hpp>
OrthoCamera::OrthoCamera()
: mLeft(-1.0f)
, mTop(1.0f)
, mRight(1.0f)
, mBottom(-1.0f)
, mNearZ(-10.0f)
, mFarZ(10.0f)
{
}
void OrthoCamera::setLeft(float left)
{
if (mLeft != left) {
mLeft = left;
invalidateP... | 2,560 | 969 |
/*
* Copyright 2016 Google Inc.
*
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#include "src/gpu/GrTextureRenderTargetProxy.h"
#include "include/gpu/GrTexture.h"
#include "src/gpu/GrCaps.h"
#include "src/gpu/GrContextPriv.h"
#include "src/gpu/GrRenderTa... | 9,358 | 2,450 |
#include "testing/testing.hpp"
#include "generator/generator_tests_support/test_with_classificator.hpp"
#include "indexer/classificator.hpp"
#include "search/localities_source.hpp"
#include <algorithm>
#include <cstdint>
#include <string>
#include <vector>
using namespace std;
using generator::tests_support::TestW... | 1,432 | 487 |
#include<iostream>
#include<string>
using namespace std;
string Question[]= {"Which of the following is the correct identifier?", "Which of the following is the address operator?","Which of the following features must be supported by any programming language to become a pure object-oriented programming language?","Whi... | 6,041 | 2,282 |
/*
* Copyright (c) Facebook, Inc. and its affiliates.
* 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.
*/
#include <proxygen/lib/transport/PersistentFizzPskCache.h>
#include <fizz/record/Types.h>
using nam... | 773 | 265 |
#pragma hdrstop
#include <string>
#include "rr/rrRoadRunner.h"
#include "rrplugins/common/telException.h"
#include "rrplugins/common/telLogger.h"
#include "rrplugins/common/telOSSpecifics.h"
#include "rrplugins/common/telTelluriumData.h"
#include "telplugins_properties_api.h"
#include "telplugins_c_api.h"
#include "tel... | 14,240 | 4,372 |
//
// Quantum Script Extension Task
//
// Copyright (c) 2020-2021 Grigore Stefan <g_stefan@yahoo.com>
// Created by Grigore Stefan <g_stefan@yahoo.com>
//
// MIT License (MIT) <http://opensource.org/licenses/MIT>
//
#ifndef QUANTUM_SCRIPT_EXTENSION_TASK_VERSION_HPP
#define QUANTUM_SCRIPT_EXTENSION_TASK_VERSI... | 1,213 | 541 |
/*********************************************************\
* File: XmlAttribute.cpp *
*
* Copyright (C) 2002-2013 The PixelLight Team (http://www.pixellight.org/)
*
* This file is part of PixelLight.
*
* Permission is hereby granted, free of charge, to any person obtaining a co... | 6,797 | 2,307 |
// Copyright (c) 2019 PaddlePaddle Authors. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required... | 2,575 | 773 |
#include <Property.h>
ObjectSP Property::GetOwner() const
{
return mOwner.lock();
}
void Property::SetOwner(ObjectSP owner)
{
mOwner = owner;
}
| 148 | 54 |
//
// Copyright Copyright 2009-2019, AMT – The Association For Manufacturing Technology (“AMT”)
// 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
//
// ... | 3,759 | 1,123 |
// Copyright 2021 The IREE Authors
//
// Licensed under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
#include <cstddef>
#include <string>
#include <vector>
#include "iree/base/api.h"
#include "iree... | 2,143 | 797 |
#include "stdafx.h"
#include "Camera.h"
#include "Engine.h"
void CameraTPSController::Update()
{
HWND k = GetForegroundWindow();
if ( k != Engine.m_Renderer.m_Window.m_Hwnd )
{
return;
}
XMVECTOR direction = m_Cam.Focus - m_Cam.Eye;
XMVECTOR magnitude = XMVector3Length( direction );
direction = XMVector3Nor... | 2,211 | 990 |
// Copyright (c) 2019 Max Planck Gesellschaft
// Author : Vincent Berenz
#pragma once
#include "o80/back_end.hpp"
#include "o80/burster.hpp"
#include "o80/driver.hpp"
#include "o80/frequency_manager.hpp"
#include "o80/observation.hpp"
#include "o80/time.hpp"
#include "o80_internal/standalone_runner.hpp"
#include "syn... | 6,208 | 1,879 |
// Generated by imageconverter. Please, do not edit!
#include <touchgfx/hal/Config.hpp>
LOCATION_EXTFLASH_PRAGMA
KEEP extern const unsigned char _pause_notPressed[] LOCATION_EXTFLASH_ATTRIBUTE = { // 60x60 ARGB8888 pixels.
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,... | 72,498 | 69,288 |
#pragma ident "$Id$"
/**
* @file PRSolution2.hpp
* Autonomous pseudorange navigation solution, including RAIM algorithm
*/
#ifndef PRS_POSITION_SOLUTION_NEW_HPP
#define PRS_POSITION_SOLUTION_NEW_HPP
//============================================================================
//
// This file is part of GPSTk, ... | 12,260 | 3,274 |
// FCAI – Programming 1 – 2022 - Assignment 2
// Program Name: sorted insert for a circular linked list.cpp
// Program Description:sorted insert for a circular linked list ………
//Author: ali sidat
// Last Modification Date: 23/3/2022
// Author1 and ID and Group:20210762
// Teaching Assistant:
// Purpos... | 2,319 | 855 |
#include"../localedef.h"
namespace fast_io_i18n
{
namespace
{
inline constexpr std::size_t numeric_grouping_storage[]{4};
inline constexpr basic_lc_time_era<char> time_era_storage[]{{.direction=true,.offset=2,.start_date_year=1913,.start_date_month=1,.start_date_day=1,.end_date_special=1,.era_name=tsc("民國"),.era_fo... | 17,458 | 10,125 |
#include <stdint.h>
#include <initializer_list>
#include <memory>
#include <string>
#include <vector>
#include "EmitFunctionContext.h"
#include "EmitModuleContext.h"
#include "LLVMJITPrivate.h"
#include "WAVM/IR/Module.h"
#include "WAVM/IR/OperatorPrinter.h"
#include "WAVM/IR/Operators.h"
#include "WAVM/IR/Types.h"
#i... | 14,457 | 5,304 |
/* -*- mode: c++; -*-
*-----------------------------------------------------------------------------
* $RCSfile: IdManager_main.cpp,v $
*
* See Copyright for the status of this software.
*
* The OpenSOAP Project
* http://opensoap.jp/
*-----------------------------------------------------------------------------... | 3,594 | 1,349 |
#include<bits/stdc++.h>
using namespace std;
#define endl "\n"
int main() {
ios_base :: sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
int arr[128] {0};
for (int i = 2; i < 128; i++) {
int key = arr[i - 1], j;
for (j = i - 2; j >= 0; j--) {
if (arr[j] == key) {
break;
}
}
if (j == -1) {
ar... | 569 | 316 |
#include "FHE/FFT.h"
#include "Math/Zp_Data.h"
#include "Math/modp.hpp"
/* Computes the FFT via Horner's Rule
theta is assumed to be an Nth root of unity
*/
void NaiveFFT(vector<modp>& ans,vector<modp>& a,int N,const modp& theta,const Zp_Data& PrD)
{
int i,j;
modp thetaPow;
assignOne(thetaPow... | 5,154 | 2,363 |
/* -*- mode: C++; c-basic-offset: 4; tab-width: 4 -*-
*
* Copyright (c) 2015 Apple Inc. All rights reserved.
*
* @APPLE_LICENSE_HEADER_START@
*
* This file contains Original Code and/or Modifications of Original Code
* as defined in and that are subject to the Apple Public Source License
* Version 2.0 (the 'Lic... | 17,240 | 6,561 |
//Тестирование алгоритма set_intersection (range1,range2,result,less)
#include <stdio.h>
#include <stl/algorithm>
#include <stl/vector>
#include "test.h"
using namespace stl;
int main ()
{
printf ("Results of alg_set03_2:\n");
int A1[] = {1, 3, -5, 7, 9, -11};
int A2[] = {1, -1, 2, -3, 5, -8, 13};
const int... | 688 | 321 |
/*
***********************************************************************************************************************
*
* Copyright (c) 2018-2020 Advanced Micro Devices, Inc. All Rights Reserved.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associ... | 23,596 | 7,139 |
#pragma once
#include "storage_manager_message.hpp"
#include <belt.pp/global.hpp>
#include <belt.pp/parser.hpp>
#include <belt.pp/http.hpp>
#include <string>
#include <vector>
#include <utility>
#include <unordered_map>
#include <set>
using std::string;
using std::vector;
using std::pair;
using std::unordered_map;
... | 8,180 | 2,338 |
#include <pybind11/pybind11.h>
#include <pybind11/stl.h>
#include <set>
#include <vector>
#include <string>
#include <map>
#include "SmartPointers.hpp"
#include "UblasIncludes.hpp"
#include "ChemotacticForce.hpp"
#include "ChemotacticForce2.cppwg.hpp"
namespace py = pybind11;
typedef ChemotacticForce<2 > ChemotacticF... | 1,609 | 581 |
/*
* cde.cpp
* !CHOAS
* Created by Bisegni Claudio.
*
* Copyright 2012 INFN, National Institute of Nuclear Physics
*
* 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
*
... | 11,458 | 4,506 |
#define CATCH_CONFIG_MAIN
#include "../../Utils/Cacth/single_include/catch2/catch.hpp"
#include "solution.h"
TEST_CASE("Maximum Subarray")
{
Solution s;
SECTION("normal input") {
vector<int> nums{ -2,1,-3,4,-1,2,1,-5,4 };
CHECK(s.maxSubArray(nums) == 6);
}
SECTION("all negative input... | 416 | 169 |
// Copyright 2018 Google 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 of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in ... | 1,596 | 552 |
// $Id$
//
// Copyright (C) 2003-2006 Rational Discovery LLC
//
// @@ All Rights Reserved @@
// This file is part of the RDKit.
// The contents are covered by the terms of the BSD license
// which is included in the file license.txt, found at the root
// of the RDKit source tree.
//
#include <RDGeneral/test.h>
#... | 9,470 | 3,708 |
/* test_libFLAC++ - Unit tester for libFLAC++
* Copyright (C) 2002-2009 Josh Coalson
* Copyright (C) 2011-2016 Xiph.Org Foundation
*
* 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; eithe... | 17,793 | 6,881 |
// Copyright (c) 2019-2020 Xenios SEZC
// https://www.veriblock.org
// Distributed under the MIT software license, see the accompanying
// file LICENSE or http://www.opensource.org/licenses/mit-license.php.
#include <gtest/gtest.h>
#include <veriblock/keystone_util.hpp>
using namespace altintegration;
const static ... | 2,549 | 1,129 |
/*
* 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 ... | 4,129 | 1,231 |
#ifndef PYTHONIC_INCLUDE_NUMPY_BINCOUNT_HPP
#define PYTHONIC_INCLUDE_NUMPY_BINCOUNT_HPP
#include "pythonic/include/numpy/max.hpp"
#include "pythonic/include/utils/numpy_conversion.hpp"
PYTHONIC_NS_BEGIN
namespace numpy
{
template <class T, class pS>
typename std::enable_if<std::tuple_size<pS>::value == 1,
... | 1,058 | 391 |
// Warning! This file is autogenerated.
#include <boost/text/normalize_string.hpp>
#include <boost/text/utility.hpp>
#include <boost/text/string_utility.hpp>
#include <gtest/gtest.h>
#include <algorithm>
TEST(normalization, nfkc_018_000)
{
// B0A0;B0A0;1102 1161 11AF;B0A0;1102 1161 11AF;
// (날; 날; 날; 날;... | 730,115 | 285,835 |
/* -*- mode: c++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*
Copyright (C) 2014 Jose Aparicio
This file is part of QuantLib, a free-software/open-source library
for financial quantitative analysts and developers - http://quantlib.org/
QuantLib is free software: you can redistribute it and/o... | 7,466 | 2,485 |
// Geometric Tools, LLC
// Copyright (c) 1998-2014
// Distributed under the Boost Software License, Version 1.0.
// http://www.boost.org/LICENSE_1_0.txt
// http://www.geometrictools.com/License/Boost/LICENSE_1_0.txt
//
// File Version: 5.0.1 (2010/10/01)
#include "Wm5MathematicsPCH.h"
#include "Wm5DistLine2Li... | 3,948 | 1,251 |
//<Snippet1>
using namespace System;
using namespace System::Threading;
void ThreadProc()
{
Thread::Sleep(2000);
};
void main()
{
Thread^ t = gcnew Thread(gcnew ThreadStart(ThreadProc));
Console::WriteLine("Before setting apartment state: {0}",
t->GetApartmentState());
t->... | 1,169 | 352 |
/*
* MIT License
*
* Copyright (c) 2021 CSCS, ETH Zurich
* 2021 University of Basel
*
* 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 with... | 19,435 | 5,704 |
// Copyright 2013 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 "media/cdm/ppapi/cdm_file_io_impl.h"
#include <sstream>
#include "media/cdm/ppapi/cdm_logging.h"
#include "ppapi/c/pp_errors.h"
#include "ppapi... | 16,996 | 6,081 |
#include <jee.h>
UartBufDev< PinA<2>, PinA<3> > console;
int printf(const char* fmt, ...) {
va_list ap; va_start(ap, fmt); veprintf(console.putc, fmt, ap); va_end(ap);
return 0;
}
PinB<13> led;
int main() {
console.init();
console.baud(115200, fullSpeedClock());
led.mode(Pinmode::out);
whi... | 446 | 197 |
/*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
#include <openr/tests/benchmark/OpenrBenchmarkBase.h>
namespace openr {
OpenrBenchmarkBase::OpenrBenchmarkBase() {}
OpenrBenchmar... | 992 | 361 |
/*
* Output a sound from the channels of another sound.
*
* This is intended for splitting a FileReader, and assumes the
* GetStreamToSourceRatio of the source is 1.0.
*
* If multiple readers are created, they should be read in parallel. If their
* source position drifts apart, the data between will be buffere... | 7,931 | 3,034 |
// Copyright (c) 2010 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 <windows.h>
#include "base/basictypes.h"
#include "base/strings/string_util.h"
#include "base/win/win_util.h"
#include "base/win/windows_ver... | 1,581 | 563 |
// Copyright (c) 2015-2018 William W. Fisher (at gmail dot com)
// This file is distributed under the MIT License.
#include "ofp/message.h"
#include "ofp/flowmod.h"
#include "ofp/unittest.h"
using namespace ofp;
TEST(message, constructor) {
Message message{nullptr};
EXPECT_EQ(8, message.size());
}
TEST(message,... | 2,184 | 1,203 |
// SPDX-License-Identifier: Apache-2.0
// ----------------------------------------------------------------------------
// Copyright 2011-2021 Arm Limited
//
// 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 ... | 51,453 | 21,947 |
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: LocaleMessage.proto
#include "LocaleMessage.pb.h"
#include <algorithm>
#include <google/protobuf/io/coded_stream.h>
#include <google/protobuf/extension_set.h>
#include <google/protobuf/wire_format_lite.h>
#include <google/protobuf/descriptor.h>
#... | 18,445 | 6,738 |
#include "base.hpp"
//#include "consts.hpp"
/* include禁止(コピペする) */
/*! http://codeforces.com/blog/entry/1256 http://codeforces.com/blog/entry/18051 */
constexpr int N = 262144; /*- たぶん2^xじゃなくても大丈夫 */
int same[N*2]; /*- 1, 2 3, 4 5 6 7, 8 9 10 11 12 13 14 15 */
int val[N*2]; /*- 1, 2 3, 4 5 6 7, 8 9 10 11 12 13 14 15 ... | 2,166 | 1,105 |
// Block.cpp
// OpenGL SuperBible, Chapter 1
// Demonstrates an assortment of basic 3D concepts
// Program by Richard S. Wright Jr.
#include <glew.h>
#include <glxew.h>
#include <GLTools.h> // OpenGL toolkit
#include <GLMatrixStack.h>
#include <GLFrame.h>
#include <GLFrustum.h>
#include <GLBatch.h>
#include <GLGeomet... | 24,810 | 10,329 |
/**
* Copyright Soramitsu Co., Ltd. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0
*/
#include "blockchain/impl/key_value_block_storage.hpp"
#include "blockchain/impl/storage_util.hpp"
#include "scale/scale.hpp"
OUTCOME_CPP_DEFINE_CATEGORY(kagome::blockchain,
KeyValueBlockS... | 8,265 | 2,488 |
#include <set>
#include <vector>
#include <limits>
#include <regex>
#include <cmath>
#include "acmacs-base/string.hh"
#include "acmacs-base/enumerate.hh"
#include "acmacs-base/fmt.hh"
#include "acmacs-chart-2/lispmds-import.hh"
#include "acmacs-chart-2/lispmds-encode.hh"
using namespace acmacs::chart;
// -----------... | 32,070 | 10,445 |
#ifndef STAN_MATH_PRIM_MAT_PROB_MULTI_NORMAL_PREC_RNG_HPP
#define STAN_MATH_PRIM_MAT_PROB_MULTI_NORMAL_PREC_RNG_HPP
#include <stan/math/prim/meta.hpp>
#include <stan/math/prim/mat/err/check_pos_definite.hpp>
#include <stan/math/prim/mat/err/check_symmetric.hpp>
#include <stan/math/prim/mat/fun/Eigen.hpp>
#inclu... | 3,123 | 1,113 |
/* -*-C++-*- */
/*
(c) Copyright 2008, Hewlett-Packard Development Company, LP
See the file named COPYING for license details
*/
/** @file
Tests for TestUtil
*/
#include <Lintel/TestUtil.hpp>
int main(int, char **) {
INVARIANT(true, "...");
TEST_INVARIANTMSG(FATAL_ERROR("die now"), "die now");
... | 739 | 295 |
/*
* Copyright 2020 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... | 10,320 | 3,993 |
//
// Created by c6s on 18-1-13.
//
#include "NgxString.h"
| 60 | 35 |
#include <jni.h>
#include <stdint.h>
#include "as_mobileawareness.h"
extern "C" {
JNIEXPORT jint JNICALL JNI_OnLoad(JavaVM *vm, void *reserved)
{
// one of everything, for linking purposes
jint ret = AS_JNI_OnLoad(vm, reserved);
uint8_t uuid[32];
ret = AS_UUID_Default_Serial(uuid);
ret = AS_Initialize( ... | 525 | 226 |
/*
*
* Copyright (c) 2020-2021 Project CHIP Authors
* Copyright (c) 2013-2017 Nest Labs, Inc.
* All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
... | 16,173 | 5,792 |
// This code contains NVIDIA Confidential Information and is disclosed to you
// under a form of NVIDIA software license agreement provided separately to you.
//
// Notice
// NVIDIA Corporation and its licensors retain all intellectual property and
// proprietary rights in and to this software and related documentation... | 12,247 | 5,259 |
//============================================================================
// Name : MySqlWrapper.cpp
// Author : youngwelle@gmail.com
// Version :
// Copyright : Copyright GODPAPER
// Description : Hello World in C++, Ansi-style
//==================================================================... | 551 | 155 |
#include <stdio.h>
void quickSortR(int* a, long N)
{
long i = 0, j = N;
int temp, p;
p = a[ N>>1 ];
do
{
while ( a[i] < p ) i++;
while ( a[j] > p ) j--;
if (i <= j) {
temp = a[i]; a[i] = a[j]; a[j] = temp;
i++; j--;
}
} while ( i<=j );
if ( j > 0 ) quickSortR(a, j);
... | 1,022 | 577 |
#include "imstkcpdPointTriangleCollisionConstraint.h"
namespace cpd
{
void PointTriangleCollisionConstraint::initConstraint(ParticleObjectPtr p_object1, const size_t p_idx1, ParticleObjectPtr p_object2, const size_t p_idx2, const size_t p_idx3, const size_t p_idx4, double p_stiffness)
{
m_object = p_object1;
... | 4,714 | 2,014 |
// -----------------------------------------------------------------------------------------------------
// Copyright (c) 2006-2020, Knut Reinert & Freie Universität Berlin
// Copyright (c) 2016-2020, Knut Reinert & MPI für molekulare Genetik
// This file may be used, modified and/or redistributed under the terms of th... | 6,376 | 2,768 |
//---------------------------------------------------------------------------
//
// redistribute base class
//
// Matthieu Dreher
// Argonne National Laboratory
// 9700 S. Cass Ave.
// Argonne, IL 60439
// mdreher@anl.gov
//
//--------------------------------------------------------------------------
#include <iostrea... | 17,164 | 5,413 |
// -*- C++ -*-
//
// Package: MuonGeometryDBConverter
// Class: MuonGeometryDBConverter
//
/**\class MuonGeometryDBConverter MuonGeometryDBConverter.cc Alignment/MuonAlignment/plugins/MuonGeometryDBConverter.cc
Description: <one line class summary>
Implementation:
<Notes on implementation>
*/
//
// Ori... | 8,556 | 2,919 |
//////////////////////////////////////////////////////////////////////////////////////
// This file is distributed under the University of Illinois/NCSA Open Source License.
// See LICENSE file in top directory for details.
//
// Copyright (c) 2016 Jeongnim Kim and QMCPACK developers.
//
// File developed by: Jaron T. ... | 42,111 | 16,826 |
EXPORT void fun_nostruct_alt /* weird by purpos */ (double * X , double *Y ,
int N, double a, double b,/* even weirder */
int threads, char * txt){
printf("\nfun_nostruct_alt(...)\n");
#pragma omp parallel num_threads(threads)
{
#pragma omp for
for(int i = 0; i < N; i++){
... | 599 | 241 |
#include "MetaImg.hpp"
#include <cstring>
IndexedImage::~IndexedImage()
{
freeBuffer();
}
IndexedImage::IndexedImage(uint32_t _width, uint32_t _height) :
width(_width),
height(_height),
framesLowerBits(0),
framesUpperBits(0),
frameLoop(0),
transparentColor(0xFF),
colorMode((uint8_t)ColorMode::INDEXED),
imgDa... | 3,634 | 1,577 |
/*
* <one line to give the program's name and a brief idea of what it does.>
* Copyright (C) 2016 <copyright holder> <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 versi... | 1,365 | 443 |
/*=========================================================================
*
* Copyright NumFOCUS
*
* 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
*
* https://www.apache.o... | 6,093 | 2,084 |
/*!
* Copyright (C) tkornuta, IBM Corporation 2015-2019
*
* 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... | 1,949 | 784 |
/*
* Distributed under the OSI-approved Apache License, Version 2.0. See
* accompanying file Copyright.txt for details.
*
* helloBPReaderHeatMap.cpp : Writes a heat map in a regular 2D mesh,
* values grow from 0 in increments of 1
*
* temperature[gNx, Ny]
* where: gNx = MPI_size_x * Nx
*
* 0 1... | 4,554 | 1,461 |
#include "texturepack.h"
void TexturePack::Bind()
{
//*****BACKGROUND******
glActiveTexture(GL_TEXTURE0 + 0);
glBindTexture(GL_TEXTURE_2D, m_backgroundTexture->GetTexture());
glActiveTexture(GL_TEXTURE0 + 1);
glBindTexture(GL_TEXTURE_2D, m_backgroundTexture->GetTexture()+sizeof(m_backgroundTexture... | 1,930 | 710 |
// Copyright (c) 2018, the Dart project authors. Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
#include "vm/compiler/frontend/constant_reader.h"
namespace dart {
namespace kernel {
#define Z (zone... | 14,145 | 4,109 |
#ifndef _SF_VIEW_INC
#define _SF_VIEW_INC
#include <SFML/Graphics/View.hpp>
value Val_sfView(const sf::View *view, value origin = Val_unit);
#define SfView_val(view) (*(sf::View **)(Data_custom_val(view)))
#endif // _SF_VIEW_INC
| 235 | 106 |
#include "fixed_size_attribute_vector.hpp"
#include <limits>
#include <memory>
#include <sstream>
#include <string>
#include <utility>
#include <vector>
#include "type_cast.hpp"
#include "utils/assert.hpp"
namespace opossum {
template <typename uintX_t>
FixedSizeAttributeVector<uintX_t>::FixedSizeAttributeVector(co... | 1,431 | 450 |
/*
* Copyright 2009-2020 The VOTCA Development Team
* (http://www.votca.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 the License at
*
* h... | 13,464 | 4,755 |
/*
* Copyright 2004-2017 Cray Inc.
* Other additional copyright holders may be indicated within.
*
* The entirety of this work is 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
*
*... | 2,082 | 688 |
/*
* Copyright 2018-2019 NXP.
*
* 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 following disclaimer.
*
* Redist... | 34,817 | 15,799 |
#pragma once
#include <QImage>
#include <QString>
class QWidget;
class QMessageBox;
class QListWidget;
class QTreeWidget;
class QScrollArea;
void selectMatchingOrFirstItem(QListWidget *list, const QString &text = {});
void selectFirstChild(QTreeWidget *tree);
void selectMatchingOrFirstChild(QTreeWidget *list, cons... | 570 | 171 |
//==============================================================================
// Copyright 2003 - 2011 LASMEA UMR 6602 CNRS/Univ. Clermont II
// Copyright 2009 - 2011 LRI UMR 8623 CNRS/Univ Paris Sud XI
//
// Distributed under the Boost Software License, Version 1.0.
// ... | 1,317 | 485 |
// This is the main DLL file.
#pragma once
#include <collection.h>
using namespace Platform;
using namespace Platform::Details;
#define VPX_CODEC_DISABLE_COMPAT 1
#include <vpx/vpx_encoder.h>
#include <vpx/vp8cx.h>
#define vp8cx (vpx_codec_vp8_cx())
#include <vpx/vpx_decoder.h>
#include <vpx/vp8dx.h>
#define vp8d... | 12,027 | 6,125 |
#include "error.hpp"
#include <iostream>
#include <map>
#include <string>
namespace tana {
void default_error_handler(const char *file, int line, const char *message) {
if (log_class == LOG_TYPE::MUTE) {
return;
}
std::string file_name(file);
std::string error_message(message);
std::cerr << "\n*******... | 1,332 | 467 |
#include "gamethread.h"
#include "omegascene.h"
#include "troengame.h"
#include <assert.h>
#include <osgDB/Registry>
using namespace troen;
GameThread* GameThread::instance;
GameThread::GameThread(QThread* thread) : m_gameThread(thread), m_storedLibPaths("")
{
if (m_gameThread == NULL) {
m_gameT... | 1,212 | 427 |
// Copyright 2015 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 <memory>
#include "base/base64url.h"
#include "base/bind.h"
#include "base/macros.h"
#include "chromeos/components/multidevice/fake_secure_messa... | 11,405 | 3,343 |
#include <iostream>
using namespace std;
void MenuEkranı()
{
cout<<"********MENU********"<<endl;
cout<<"1.Bakiye Kontrol"<<endl;
cout<<"2.Para Çekme"<<endl;
cout<<"3.Para Yatırma"<<endl;
cout<<"4.Çıkış"<<endl;
}
int main() {
double bakiye = 1000;
int seçenek;
while(seçenek!=4)
{
MenuEkranı();
... | 1,233 | 604 |
//WinQLRootDeviceEnumerator.cpp
// Copyright Querysoft Limited 2013, 2015, 2017
//
// Permission is hereby granted, free of charge, to any person or organization
// obtaining a copy of the software and accompanying documentation covered by
// this license (the "Software") to use, reproduce, display, distribute,
// exe... | 4,401 | 1,462 |
// MIT License
//
// Copyright (c) 2018 Francisco Ruiz (francisco.ruiz.rayo@gmail.com)
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation ... | 3,786 | 1,170 |
/**
* Copyright (c) 2017-present, Facebook, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable ... | 2,379 | 767 |
// This program demonstrates a union.
#include <iostream>
#include <iomanip>
using namespace std;
union PaySource
{
int hours; // Hours worked
float sales; // Amount of sales
};
int main()
{
PaySource employee1; // Define a union variable
char payType; // To ho... | 1,725 | 530 |
#include <taco/index_notation/transformations.h>
#include <codegen/codegen_c.h>
#include <codegen/codegen_cuda.h>
#include "test.h"
#include "test_tensors.h"
#include "taco/tensor.h"
#include "taco/index_notation/index_notation.h"
#include "codegen/codegen.h"
#include "taco/lower/lower.h"
using namespace taco;
const I... | 23,124 | 9,827 |
#include "changecode.h"
#include "ui_changecode.h"
ChangeCode::ChangeCode(QWidget *parent) :
QDialog(parent),
ui(new Ui::ChangeCode)
{
ui->setupUi(this);
ui->error->setVisible(false);
}
ChangeCode::~ChangeCode()
{
delete ui;
}
void ChangeCode::accept()
{
//check if the code is new
if(ui->f... | 546 | 190 |
// SciTE - Scintilla based Text Editor
/** @file SciTEBuffers.cxx
** Buffers and jobs management.
**/
// Copyright 1998-2010 by Neil Hodgson <neilh@scintilla.org>
// The License.txt file describes the conditions under which this software may be distributed.
#include <stdlib.h>
#include <string.h>
#include <ctype.h>
... | 58,821 | 24,088 |
/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: t; c-basic-offset: 4 -*- vim:set ts=4 sw=4 sts=4 noet: */
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include "ts.h"
#include <cassert>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <fstream>
#include <iostream>
#include <memory>
#include <set>... | 8,448 | 3,465 |
/**
* @file oglplus/imports/blend_file/reader.hpp
* @brief Helper class for .blend file import basic input operations
*
* @author Matus Chochlik
*
* Copyright 2010-2019 Matus Chochlik. Distributed under the Boost
* Software License, Version 1.0. (See accompanying file
* LICENSE_1_0.txt or copy at http://w... | 2,377 | 806 |
#include "Matrix4x4.h"
namespace gmath
{
Matrix4x4::Matrix4x4(
float _m11 /* = 1.0f */, float _m12 /* = 0.0f */, float _m13 /* = 0.0f */, float _m14 /* = 0.0f */,
float _m21 /* = 0.0f */, float _m22 /* = 1.0f */, float _m23 /* = 0.0f */, float _m24 /* = 0.0f */,
float _m31 /* = 0.0f */, float _m32 /* = 0.0f */,... | 2,145 | 1,315 |
// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.
/*============================================================
**
** Source: test1.c
**
** Purpose: Test for WaitForSingleObjectTest. Create two events, one
** with a TRUE and one w... | 3,017 | 874 |
/**
* Copyright (C) 2020-present MongoDB, Inc.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the Server Side Public License, version 1,
* as published by MongoDB, Inc.
*
* This program is distributed in the hope that it will be useful,
* but W... | 3,875 | 1,104 |
//////////////////////////////////////////////////////////////////////////
// SessionImpl.cpp
//
//
//
// Copyright (C) 2014 Microsoft Corp. All Rights Reserved
//////////////////////////////////////////////////////////////////////////
#include "stdafx.h"
#include "NetworkConnectionImpl.h"
#include "SessionImpl.h"
#... | 10,222 | 3,279 |