id
stringlengths
1
3
code_masked
stringlengths
783
188k
target
stringlengths
3
27
600
#ifndef AUTONOMOUS_BICYCLE_PID_H #define AUTONOMOUS_BICYCLE_PID_H #include <time.h> class PID { public: double kp, ki, kd, windupGuard; double setPoint, output, error; double sampleTime; PID() {} PID(double kp, double kd, double ki, double windupGuard) { this->kp = kp; this->ki = ...
deltaTime
601
#include "Perro.h" #include <iostream> // Ejemplo de constructor por defecto con lista inicializadora // Perro::Perro() : edad(0), raza(""), tamanio(""), color("") {} // Ejemplo de constructor por defecto iniciando los atributos en el cuerpo del constructor Perro::Perro() { this->edad = 0; this->raza = ""; ...
aniosExperiencia
602
#include <iostream> #include <string> std::string to_three(int a) { int c = a; std::string res = ""; while (c > 0) { std::string str = std::to_string(c % 3); res += str; c /= 3; } std::string result = ""; for (int i = res.size() - 1; i >= 0; i -= 1) { result += res[i]; } return result; ...
final_result
603
#include <algorithm> #include <array> #include <cstdint> #include <cstdlib> #include <exception> #include <filesystem> #include <fstream> #include <iostream> #include <map> #include <mutex> #include <optional> #include <string> #include <thread> #include <variant> #include <vector> #include "vle.hpp" #include "vle/GbSe...
isGb
604
#pragma once #include <coin/IpJournalist.hpp> #include <Python.h> class PythonJournal : public Ipopt::Journal { public: PythonJournal(Ipopt::EJournalLevel default_level, PyObject *stream) : Journal("PythonJournal", default_level) , stream_(stream) { Py_XINCREF(stream_); } virtual ~PythonJournal() ...
max_len
605
// MyWeatherClock.ino // dt 01DEC2024.. fancy up my CYD clock!! // add barosensor lib from Freetronics // try sparkfun MS5637 lib - barosensor doesn't work with ESP32!! dt 03DEC2024 // // add humidity detector?? dt 06DEC2024 // DHT22??? #include "DHT.h" #include <WiFi.h> #include "time.h" #include "es...
humidval
606
// Created on Fri Nov 08 2024 // © 2024 BLACKHAND Studio. 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 // ...
deleter
607
#include <Time.h> #include <Wire.h> #include <DS1307RTC.h> #include <dht.h> // Pin Definitions #define DHT22_PIN1 2 #define DHT22_PIN2 3 #define readmoistd1 37 #define readmoistd2 36 #define VALVE 44 #define L1 42 #define L2 43 #define L3 45 #define stepm 4 #define dirm 35 const int FAN_PINS[] = {41, 40, 39, 38}; con...
resistance2
608
#include "arc_hybrid_planner/hybrid_planning_interface.hpp" HybridPlanningInterface::HybridPlanningInterface(const rclcpp::Node::SharedPtr& node) : m_node(node), m_planning_group("ur_manipulator") { std::string hybrid_planning_action_name = ""; if (m_node->has_parameter("hybrid_planning_action_name")) { m_node->...
tolerance_angle
609
#include "AimbotMelee.h" #include "../Aimbot.h" #include "../../Simulation/MovementSimulation/MovementSimulation.h" #include "../../Ticks/Ticks.h" #include "../../Visuals/Visuals.h" #include <unordered_set> #include <algorithm> std::vector<Target_t> CAimbotMelee::GetTargets(CTFPlayer* pLocal, CTFWeaponBase* pWeapon) ...
vCurAngle
610
#include <iostream> #include <string> #include <vector> #include <map> #include <unordered_map> #include <limits> #include <algorithm> using namespace std; class Server { private: string serverType; // 服务器型号 int core; // CPU核数 int memory; // 内存大小 int price; // 硬件...
serverNumber
611
// Application.cpp is the file // that holds the class to setup // and initialise the application. // Include headers #include "Application.h" namespace applicationFramework { // Set constants const double Application::FRAME_TIME = 1.0 / Application::FPS * 1000.0; // Milliseconds Application *Application::insta...
theTitle
612
#pragma once #include "Runtime/Core/Math/Vector2.h" #include "Runtime/Function/Render/RenderCamera.h" #include <vector> namespace MarsEngine { class MarsEditor; enum class EditorCommand : unsigned int { camera_left = 1 << 0, // A camera_back = 1 << 1, // S camera_fowa...
new_window_pos
613
/* * pop_model1.cpp -- numerically solve analytic population models with * two components, models used in the paper (in all cases, both * logistic and linear resource regrowth variants) * * 1. Volterra: VOLTERRA_LIN, VOLTERRA_LOG * 2. Volterra, logistic consumers (farmer-soil model): SOIL_LIN, SOIL_LOG * 3. ...
cmin
614
#include "entity.hpp" Entity::Entity() : entitySprite(entityTexture){ initEntity(); } void Entity::initEntity() { tex.size = 16; tex.XIndex = 1; tex.YIndex = 0; sf::Texture* loadedTex = &tm.loadTexture("../assets/tileset.png", false, tex.size, tex.XIndex, tex.YIndex); entityTexture = *loadedTex; entity...
states
615
/* Copyright (C) 2015-2020 <NAME> 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 writing, software di...
counter
616
#pragma once #include <functional> #include <limits> #include <queue> #include <utility> #include <vector> #include "../graph_traits/graph_traits.hpp" namespace graph { template <typename Cost, typename Graph> std::vector<Cost> dijkstra(const Graph& g, int s) { using state = std::pair<Cost, int>; ...
dist
617
/* # Copyright 2024 MangDang (www.mangdang.net) # # 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 ag...
loop_times
618
/* * Copyright (c) 2025 Qualcomm Innovation Center, Inc. All rights reserved. * SPDX-License-Identifier: BSD-3-Clause-Clear */ #include <glib-unix.h> #include <gst/gst.h> #include <glib.h> #define DEFAULT_FILE1 "/opt/video.mp4" #define DEFAULT_FILE2 "/opt/video.mp4" /** * GstAppContext: * @pipeline: Pipeline...
pending
619
// Fill out your copyright notice in the Description page of Project Settings. #include "InventoryBagMock.h" #include "BattleRoyale/core/Utils/Inventory/InventoryArrayItem.h" TScriptInterface<IIInventoryItemInstance> UInventoryBagMock::AddItem(TSubclassOf<UInventoryItemStaticData> itemClass, int value1, int value2)...
max
620
// * * * SPROCKET_HAL_Test * * * // // This software allows testing the SPROCKET1 test pixel, // including performing the role of the SAR logic. String DOCSTRING = "This Arduino is running SPROCKET_HAL_Test v0.11TEST, updated 6/5/2023. Macros: "; //makeinclude GPIO_user.cpp DO NOT MODIFY THIS LINE #include "GPIO_user...
measurements
621
#include "nbody_plugin.h" #include <common/utils.h> #include <map> #include <string> #include <stdexcept> static auto& PluginsMap() { static std::map<std::string, NBodyPlugin*> plugins; return plugins; } NBodyPlugin::NBodyPlugin(const std::string& name) { RegisterPlugin(this, name); } void RegisterPlugin(NB...
plugin_names
622
// Copyright <NAME> 2019. // Distributed under the Boost Software License, Version 1.0. // (See accompanying file LICENSE or copy at // http://www.boost.org/LICENSE_1_0.txt) #include "vgm.h" #include "mapped_file.h" extern "C" { #include <comment.h> #include <xmalloc.h> #include <debug.h> } #inclu...
want
623
/** * Loads csvs with no frills or other bullshit. */ #pragma once #include <cassert> #include <iostream> #include <map> #include <sstream> #include <string> #include <utility> #include <vector> namespace tb { template <typename T = std::string> class TableRow { public: int ncols = row.size(); std::map<std::s...
_rows
624
#include <iostream> #include <functional> #include <vector> //*************************** class Pose3D { // TODO }; class Direction3D { // TODO }; class Duration { // TODO }; class TimePoint { // TODO public: TimePoint operator+=(Duration const&) { // TODO return {}; } ...
copy
625
// -*- mode:C++; tab-width:8; c-basic-offset:2; indent-tabs-mode:t -*- // vim: ts=8 sw=2 smarttab #include "AuthRegistry.h" #include "cephx/CephxAuthorizeHandler.h" #ifdef HAVE_GSSAPI #include "krb/KrbAuthorizeHandler.hpp" #endif #include "none/AuthNoneAuthorizeHandler.h" #include "common/ceph_context.h" #include "co...
allowed_modes
626
#include <iostream> #include "stdlib.h" #include "SplStack.h" using namespace std; int main() { SplStack<int> *p = new SplStack<int>(4); // int 类型的栈 // 测试空栈 p->traverse(); // 测试入栈 for (int i = 0; i < 10; i++) { cout << "push: " << i << endl; p->push(i); } p->tra...
elm
627
#pragma once //#include "zrpc.h" #include <string> #include <msgpack.hpp> #include <iostream> namespace zrpc { namespace detail { template<typename T> inline void pack(const T& value, std::string& buffer) { std::stringstream [MASK] ; msgpack::pack( [MASK] , valu...
sbuffer
628
// TODO: Part 1b #include "Models/FSLogo.h" #include "shaderc/shaderc.h" // needed for compiling shaders at runtime #ifdef _WIN32 // must use MT platform DLL libraries on windows #pragma comment(lib, "shaderc_combined.lib") #endif void PrintLabeledDebugString(const char* label, const char* toPrint) { std::...
uniformPoolSize
629
// /************************************************************* // * ДЗ-2 Примитивная рекурсия (Вариант 2.10) // * Студент: <NAME>, КТбо1-7 // * Программа: Реализует вычисление функции f(x1, x2), // * полученной из базовых функций: // * g(x) = x // * h(x, y, z) = x + y // * по схеме примитивной рекурсии: /...
prev
630
/* * Copyright © 2023 Sietium Semiconductor. * * 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...
sm_id
631
#include "model/Bishop.h" #include "model/Square.h" #include "model/Board.h" Bishop::Bishop(Piece::figure type, bool color) : Piece(type, color) {} Bishop::~Bishop() { } bool Bishop::canMoveTo(SquarePtr startSquare, SquarePtr endSquare, Board &gameboard) { int startRow=(startSquare->getNr()/8+1); int startCo...
endColumn
632
#include "gamescreen.h" #include <QGuiApplication> #include <QScreen> extern byte* screen; GameScreen::GameScreen() { } void GameScreen::draw(QPainter* painter) { for (int i = 0; i < pixel_width; ++i) { for (int j = 0; j < pixel_height; ++j) { auto color = colors[screen[i * pixel_height + j]]; // NOTE: use...
screenWidth
633
// SPDX-License-Identifier: MIT // Copyright (c) 2018-2024, Advanced Micro Devices, Inc. All rights reserved. #include <ck_tile/core.hpp> #include "layernorm2d_fwd.hpp" #include <iostream> #pragma once using S = ck_tile::stream_config; using A = layernorm2d_fwd_args; template <typename DataType_, ck_tile...
grids
634
/* Copyright (c) 2018 vesoft inc. All rights reserved. * * This source code is licensed under Apache 2.0 License, * attached with Common Clause Condition 1.0, found in the LICENSES directory. */ #pragma once #include <s2/s2loop.h> #include <s2/s2polygon.h> #include "common/base/StatusOr.h" #include "common/datat...
latlng
635
#include "StartStopTimer.hpp" void StartStopTimer::init(Callback cb, uint32_t stackDepth, UBaseType_t tskPriority) { TaskParams *p = &_tskParams; _tskPriority = tskPriority; _stackDepth = stackDepth; _tskParams.callback = cb; BaseType_t res = xTaskCreate ( _taskFunction, // Fu...
tsecStop
636
// Fill out your copyright notice in the Description page of Project Settings. #include "VoxelActor.h" const int32 bTriangles[] = { 2, 1, 0, 0, 3, 2 }; const FVector2D bUVs[] = {FVector2D(0.0, 0.0), FVector2D(0.0, 1.0), FVector2D(1.0, 1.0), FVector2D(1.0, 0.0)}; const FVector bNormals0[] = {FVector(0, 0, 1), FVector...
DeltaTime
637
// Homework 2 // Fortune teller program // It will receive some inputs from the user and will tell them which type of // C++ programmer they are. #include <array> #include <iostream> #include <map> #include <string> #include <utility> #include <vector> using std::array; using std::cin; using std::cout; using std::end...
adjective1
638
#include <iostream> #include <chrono> #include <vector> #include <algorithm> using namespace std; #include <Windows.h> int nScreenWidth = 120; int nScreenHeight = 40; float fPlayerX = 8.0f; float fPlayerY = 8.0f; float fPlayerA = 0.0f; int nMapHeight = 16; int nMapWidth = 16; float fFOV = 3.14159f / 4.0f; float f...
tp1
639
#include <iostream> #include <cstdlib> #include <ctime> using namespace std; int main() { // Seed the random number generator with the current time srand(time(nullptr)); // Generate a random number between 1 and 100 int [MASK] = rand() % 100 + 1; // Initialize the user's guess to ...
randomNumber
640
/* Fill-in information from Blynk Device Info here */ #define BLYNK_TEMPLATE_ID "" // The template ID from Blynk IoT platform #define BLYNK_TEMPLATE_NAME "" // The template name from Blynk IoT platform #define BLYNK_AUTH_TOKEN "" // The authentication token for Blynk platform #include <WiFi.h> ...
currentMillis
641
#include "llvm/IR/PassManager.h" #include "llvm/IR/Module.h" #include "llvm/IR/Function.h" #include "llvm/IR/BasicBlock.h" #include "llvm/IR/IRBuilder.h" #include "llvm/IR/Instructions.h" #include "llvm/IR/Constants.h" #include "llvm/IR/LLVMContext.h" #include "llvm/Passes/PassPlugin.h" #include "llvm/Support/raw_ostre...
cfgFile
642
#include <SDL2/SDL.h> #include <SDL2/SDL_ttf.h> #include "Game.hpp" #include "SimpleMenu.hpp" int main() { if (SDL_Init(SDL_INIT_VIDEO) != 0 || TTF_Init() != 0) { SDL_Log("SDL/TTF Init Error: %s", SDL_GetError()); return -1; } SDL_Window* window = SDL_CreateWindow("Digger Menu", SD...
state
643
#include <ESP8266WiFi.h> #include <PubSubClient.h> #include <stdio.h> #include <Adafruit_NeoPixel.h> // Update these with values suitable for your network. const char* ssid = "YOUR_WIFI_SSID"; const char* password = "<PASSWORD>"; const char* mqtt_server = "io.adafruit.com"; WiFiClient espClient; PubSubClient client(...
word_count
644
/******************************************************************************* * Copyright (C) 2024 Intel Corporation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://...
ingress_port
645
// Chromosome.cpp.haplotyped markers for a chromosome #include "Chromosome.h" #include <iostream> using namespace std; // Chromosome(): default constructor Chromosome::Chromosome() {} MarkerSet * Chromosome::getMarkerSet() { return chromosome[position_ms]; } MarkerSet * Chromosome::getMarkerSet(unsigned int pos) ...
ms_end
646
#include <unistd.h> #include "UserThread.h" //#include <stdio.h> void userThread_Resume(ThreadScheduler &schedule , int id) { if(id < 0 || id >= schedule.max_index){ return; }//judge max_index UserThread *t = &(schedule.threads[id]); if (t->state == READY ) { t->state = RUNNING ;//set...
gaptime
647
#include "ConsoleView.h" ConsoleView::ConsoleView(Model *model) : View(model) { _chipsMap[NONE] = "."; _chipsMap[BLACK] = "x"; _chipsMap[RED] = "o"; } void ConsoleView::update(GameState state) { paintField(); if (state == CONTINUES) { std::cout << "next turn" << std::endl; } e...
field
648
#include <GL/glew.h> #include <GLFW/glfw3.h> #include <stdlib.h> #include <stdio.h> #include <iostream> static void error_callback(int error, const char* description) { fputs(description, stderr); } static void key_callback(GLFWwindow* window, int key, int scancode, int action, int mods) { if (key == GLFW_KEY...
buff1
649
module; #include <filesystem> #include <format> #include <memory> #include <mutex> #include <shared_mutex> #include <string> #include <string_view> #include <thirdparty/libgit2/include/git2.h> #include <unordered_map> export module gitkf:git_repository; import :client_exception; import :git_smart_pointer; import :rin...
pBuf
650
#include <Wire.h> #include <LCD.h> #include <LiquidCrystal_I2C.h> #include <EEPROM.h> #include "SoftwareSerial.h" #include <Keypad.h> // Bibliothek für das Keypad #include <Keypad_I2C.h> // Bibliothek für das Keypad über I2C #define PIN_TX 51 #define PIN_RX 53 // ######### INIT SIM / SMS ######### // Cell phone nu...
currentPrice
651
// ============================================================================= // Project: qcomm - Quantum Communication Simulator // File: architecture.cpp // Description: Implementation of architecture and related functions // Author: <NAME> <<EMAIL>> // License: Apache-2.0 license (see LICENSE file for details) //...
config
652
#include "Hexagon1.h" //make the six points in the hexagon Point Hexagon::center(point_of_Hexagon l) { return Point(l.first, l.second); } Point Hexagon::p1(point_of_Hexagon l) { return Point(l.first, l.second-distance); } Point Hexagon::p2(point_of_Hexagon l) { return Point(l.first+sqrt(3.0) * distance/2,l.second-...
interval3
653
// // EulerProblems.cpp // testC // // Created by <NAME> on 16/08/12. // Copyright (c) 2012 <NAME>. All rights reserved. // #include "EulerProblems.h" // // Problems.cpp // testC // // Created by <NAME> on 16/08/12. // Copyright (c) 2012 <NAME>. All rights reserved. // //#include "Problems.h" #if 0 #include <...
temp
654
#include <iostream> #include <string> #include <vector> #include <fstream> #include <sstream> #include <stdlib.h> using namespace std; void check_arguments(int argc, char* argv[]) { string [MASK] = "Usage instructions: "; [MASK] += argv[0]; [MASK] += " path/to/input.txt output.txt"; bool has_valid_arg...
usage_instructions
655
#include <stdio.h> #include <string.h> // C Implementation #define MAX_NODES 5 struct adjacentListTable { int adjacent_list[MAX_NODES]; }; struct graph { int num_nodes; struct adjacentListTable adjacent_list_table[MAX_NODES]; }; void graphInit(struct graph *graph) { graph->num_nodes = 0; for(int...
from
656
#include <stdlib.h> // malloc, free, exit #include <stdio.h> // fprintf, perror, fopen, etc. #include <string.h> // strlen, strcat, memset, strerror #include <errno.h> // errno #include <sys/stat.h> // stat #include <brotli/encode.h> #include <emscripten.h> #include <emscripten/bind.h> using namespace ...
data_ptr
657
/* JOAAT.h - Implementation of the Jenkin's HASH for Arduino. Created by alessandromrc, 27 September 2022. */ #ifndef JOAAT_H_ #define JOAAT_H_ typedef const unsigned char* JOAAT_STR; class JOAAT { private: uint32_t encode(const uint8_t* key, size_t length) { size_t i = 0; uint32_t hash = 0; whil...
checksum1
658
#include "hzpch.h" #include "ImGuiLayer.h" #include "imgui.h" #include "OpenGL/ImGuiOpenGLRenderer.h" #include "GLFW/glfw3.h" #include "Hazel/Application.h" namespace Hazel { ImGuiLayer::ImGuiLayer():Layer("ImguiLayer") { } ImGuiLayer::~ImGuiLayer() { } void ImGuiLayer::OnAttach() { ImGui::CreateConte...
keycode
659
#include <cstring> #include <fstream> #include <iostream> #include <cartridge.h> #include <tools.h> #include <iomanip> #include <cpu.h> #include <sstream> #include <vector> #include <mbc.h> Cartridge::Cartridge() { } const char* ROM_TYPES[0x100] = { nullptr }; bool Cartridge::LoadROM(std::string [MASK] ) { RO...
filename
660
#include <iostream> #include <string> #include <stdio.h> // _fileno #include <io.h> // _get_osfhandle, _setmode #include <fcntl.h> // _O_U16TEXT, _O_U8TEXT #include <windows.h> using namespace std; void utf16() { /** * Using UTF-16 IO, the sink and source are UTF-16 encoded. * -...
fdInput
661
/* * SPDX-License-Identifier: Apache-2.0 */ #include <algorithm> #include <cmath> #include <numeric> #include "onnx/defs/tensor/utils.h" namespace ONNX_NAMESPACE { static const char* Cast_ver9_doc = R"DOC( The operator casts the elements of a given input tensor to a data type specified by the 'to' argument and re...
has_perm_attr
662
#include <stdint.h> #include <iostream> #include <cstring> #include <fstream> #include <chrono> #include <thread> #include "headers/MLX90640_API.h" #define MLX_I2C_ADDR 0x33 int main(){ int [MASK] = 0; static uint16_t eeMLX90640[832]; float emissivity = 1; uint16_t frame[834]; static float image...
state
663
#include "Arduino.h" #include "LRL_Key.h" static int DEFAULT_KEY_PIN = A0; LRL_Key::LRL_Key() { _refreshRate = 10; _keyPin = DEFAULT_KEY_PIN; _prevKey = KEY_NONE; _oldTime = 0; } // Used to categorize button presses based on analog read of input pin static int bmap[6]= {60,200,400,600,800,1024}...
rate
664
// Fill out your copyright notice in the Description page of Project Settings. #include "PlayerBase.h" #include "PaperFlipbookComponent.h" #include "Camera/CameraComponent.h" #include "GameFramework/SpringArmComponent.h" APlayerBase::APlayerBase() : Health(0) { // only allow yaw rotation bUseControllerRotati...
amount
665
// // Created by 朱宇 on 18/08/2017. // char r[] = { 0x43, 0xe3, 0xaf, 0x2a, 0x0d, 0xb9, 0x08, 0x67, 0x50, 0x97, 0x68, 0x77, 0x65, 0x0f, 0x42, 0x6d, 0x21, 0x57, 0xa4, 0x5e, 0x10, 0xde, 0x64, 0x6f, 0xf8, 0x57, 0x19, 0x8b, 0x22, 0x6d, 0xf0, 0xd4, 0xb2, 0x24, 0x34, 0x08, 0xe0, 0x3b,...
verity
666
/* Copyright 2022 The Photon Authors 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 writing, softw...
ptr
667
/*MOTORS FUNCTIONS---------------------------------------------------------------------------------------------------------*/ void speed_right_motor(int right){ /* * Right motor output speed configuration */ if(right >= 0) { digitalWrite(motor_r...
robot_speed
668
#include "PixelStats.h" #define LOG_TAG "pixelstats-system" #include <log/log.h> #include <metricslogger/metrics_logger.h> namespace hardware { namespace google { namespace pixelstats { namespace V1_0 { namespace implementation { using namespace android::metricslogger; PixelStats::PixelStats() :limiter_(kDailyR...
accelPeak
669
#include "Application.h" namespace SandBox { ExampleLayer::ExampleLayer(const char* name /* = "ExampleLayer" */) : Layer(name), m_Camera(-1.6f, 1.6f, -0.9f, 0.9f) { m_CameraPosition = m_Camera.GetPosition(); m_CameraRotation = m_Camera.GetRotation(); // clang-format off ...
uniform_block_layout
670
/* * common.cpp * * Created on: Sep 13, 2019 * Author: siwei */ #include "common.h" #include <unistd.h> #include <fcntl.h> #include <string.h> #include <errno.h> #include <string> #include <sys/stat.h> extern int level; int getfile(const std::string& path, std::string& result) { char buffer[256]; ...
fifoName
671
/* * Copyright 2008-2009 NVIDIA 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 a...
mean
672
#pragma once #include "spdlog/spdlog.h" #include "Core/CoreMacros.h" namespace KEngine { enum class LogVerbosity { Trace, Info, Warning, Error, Critical }; class KENGINE_API Log { public: static void Init(); inline static std::shared_ptr<spdlog::logger>& GetEngineLogger() { return KEngineLogger...
level
673
/****************************************************************** eventQueue class for event notification between threads Features: - command pattern - event queue to notify the comsumer - can be used as blocking or non-blocking mode - client can produce and consume specified event with name - xxx Written by <NAME>...
WaitCompletion
674
#include <gl/glut.h> #include <cg/cg.h> #include <Cg/cgGL.h> #include <stdio.h> int ww = 640, hh = 480; void render(); void reshape(int w, int h); static CGcontext myCgContext; static CGprofile myCgVertexProfile; static CGprofile myCgFragmentProfile; static CGprogram myCgVertexProgram; static CGprogram my...
mvp
675
/* * (C) Copyright 2019-2020 UCAR * * This software is licensed under the terms of the Apache Licence Version 2.0 * which can be obtained at http://www.apache.org/licenses/LICENSE-2.0. */ #include "atlas/field.h" #include "atlas/functionspace.h" #include "atlas/grid.h" #include "atlas/util/Config.h" #include "ec...
key_geo
676
/* * StderrLogger.cpp * * Created on: May 7, 2016 * Author: samuele */ #include "StderrLogger.h" #include <iostream> // for printing on the stderr #include <cstdarg> // for va_list definition #include <cstdio> ...
aMap
677
#pragma once #include <cmath> #include <vector> #include <SDL.h> #define SCREEN_WIDTH 600 #define SCREEN_HEIGHT 600 #define SCREEN_X 400 #define SCREEN_Y 300 float cameraDistance = 20; float scale = 2; float cameraAngle = 0; using namespace std; class Block { private: vector<vector<float>> cubeVertices = { ...
rotatedVerticies
678
#include "RFT_IF_PACKET_Rev1.2.h" #include <string.h> CRT_RFT_IF_PACKET::CRT_RFT_IF_PACKET() { memset(m_rcvd_product_name, 0x00, sizeof(m_rcvd_product_name)); memset(m_rcvd_serial_number, 0x00, sizeof(m_rcvd_serial_number)); memset(m_rcvd_firmware_version, 0x00, sizeof(m_rcvd_firmware_version)); ...
prcs_result
679
#include <Adafruit_NeoPixel.h> #define NEOPIXEL_PIN 6 # define REQUEST_BOARD_STATUS '1' # define REQUEST_CLEAR_BOARD '2' int WHITE_MARGIN = 650; int BLACK_MARGIN = 450; char boardStatus[64]; Adafruit_NeoPixel strip = Adafruit_NeoPixel(64, NEOPIXEL_PIN); int multiplexerPinsValues[16][4] = { ...
val
680
#include <string> #include "GarrysMod/Lua/Interface.h" #include "util/SigScan.h" using namespace GarrysMod; typedef void *(__cdecl *HandleChange_LuaFn)(std::string &dir, std::string &filename, std::string &ext); HandleChange_LuaFn HandleChange_Lua; const char *HandleChange_Lua_Signature = "\x55\x8B\xEC\x81\xEC????\...
filepath
681
#include "Auxiliary_Methods.h" string Auxiliary_Methods:: int_to_string_convert (int number) { ostringstream ss; ss << number; string str = ss.str(); return str; } int Auxiliary_Methods::string_to_int_convert (string text) { std::string str = text; int k; std::istringstream iss(str); i...
number_of_dots
682
/*! * @file * @brief TODO */ #include <egg/core/eggArchive.hpp> #include <rvl/arc/binary_format.h> #include <rvl/dvd/dvd.h> #include <rvl/dvd/dvdFs.h> namespace EGG { bool Archive::sIsArchiveListInitialized; nw4r::ut::List Archive::sArchiveList; Archive::~Archive() { removeList(this); } void Archive::remove...
dvdFileInfo
683
#include "hamming74_top.cc" #include <fmt/format.h> #include <vector> unsigned int encode(unsigned int word) { return (((word & 1) ^ (word & 2) >> 1 ^ (word & 8) >> 3) << 0) | (((word & 1) ^ (word & 4) >> 2 ^ (word & 8) >> 3) << 1) | (((word & 1)) << 2) | (((word & 2) >> 1 ^ (word & 4) >> 2...
enc_success
684
// Copyright 2013 Google Inc. All Rights Reserved. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by appl...
next_random
685
#include<bits/stdc++.h> using namespace std; void Swap(int *x,int *y){ int temp = *y; *y=*x; *x=temp; } vector<int> sortedSquares(vector<int>& nums) { vector<int> [MASK] ; int smallest; f...
sqr
686
/* * Copyright (C) 2018 Open Source Robotics Foundation * * 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 appl...
modelIdentifier
687
#ifndef T_GRAPH_HPP #define T_GRAPH_HPP #include <algorithm> // std::unique,sort,reverse #include "Edge.hpp" namespace TemplateGraph { template <class T> class Edge; // Forward declare Edge template <class T> class Node; template <class T> class Graph { public: ///////////////////////////////////////////////...
output
688
#include <cxxopts.hpp> #include <filesystem> #include <fstream> #include <iostream> #include <shaderc/shaderc.hpp> using namespace shaderc; namespace fs = std::filesystem; class shader_includer : public CompileOptions::IncluderInterface { public: shader_includer(fs::path _base_path) : base_path_(_base_path) {} ...
parse_result
689
#include "ExampleLayer.h" #include <glm/gtc/matrix_transform.hpp> #include <glm/gtc/type_ptr.hpp> #include <imgui/imgui.h> ExampleLayer::ExampleLayer() :Layer("Example"), m_CameraController(1280.0f / 720.f) { m_VertexArray = Shaddock::VertexArray::Create(); float vertices[3 * 7] = { -0.5f, -0.5f, 0.0f, 0.8f, 0.2...
square_layout
690
/** **************************************************************************************** * \mainpage areaTrapezio * * @brief Scrivi un programma che calcola l’area e il perimetro di un trapezio dopo aver letto i dati necessari * Il progetto accetta solo numeri positivi e interi * * @author <NAME> Matias ...
lato2
691
// Author : <NAME> (siddhesh1770) // Problem Name : 7. Reverse Integer (Leetcode) // Email : <EMAIL> // Websit : https://www.siddheshpatil.in // GitHub : https://www.github.com/siddhesh1770 // LinkedIn : https://www.linkedin.com/in/siddhesh1770 class Solution { public: int reverse(int x) { ...
num
692
#include <functional> #include <gtest/gtest.h> #include <dma/base/initializable/CBaseSynchronousInitializable.hpp> static const int INIT_RETURN_CODE = 1; static const int SHUTDOWN_RETURN_CODE = 2; class CClassUnderTest : public DMA::CBaseSynchronousInitializable { protected: virtual DMA::tSyncInitOperationResul...
repetitiveInitResult
693
#include <fmt/format.h> #include <memory_resource> #include <vector> template <typename ItrBegin, typename ItrEnd> void print_line(int offset, ItrBegin begin, const ItrEnd [MASK] ) { fmt::print("(dec) {:02x}: {:3}\n", offset, fmt::join(begin, [MASK] , " ")); fmt::print("(hex) {:02x}: {:02x}\n", offset, fmt:...
end
694
#ifndef AZUIK_CONTAINER_HEAP_HPP #define AZUIK_CONTAINER_HEAP_HPP #include <cstddef> namespace azuik { namespace core { template <class T> class leftist_heap { public: using self_type = leftist_heap; using value_type = T; using reference = T&; ...
oldRoot
695
#include "Audio.h" #include "Log.h" #include "SDL2/SDL.h" #include "SDL2/SDL_mixer.h" Audio::Audio() : Module() { music = NULL; name = "audio"; globalMusicVolume = 20; globalFxVolume = 20; } // Destructor Audio::~Audio() {} // Called before render is available bool Audio::Awake() { LOG("Loading Audio Mixer"); ...
repeat
696
#include "call_thunk.h" #ifdef _WIN32 #include <windows.h> #else #include <sys/mman.h> #ifndef offsetof #define offsetof(s,m) ((size_t)&reinterpret_cast<char const volatile&>((((s*)0)->m))) #endif //offsetof #ifndef _countof #define _countof(_Array) (sizeof(_Array) / sizeof(_Array[0])) #endif //_countof #endif //...
caller
697
/* * Copyright (C) 2018-2020 HERE Europe B.V. * * 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...
pt1
698
#include "loop.hpp" #include <godot_cpp/core/class_db.hpp> #include <godot_cpp/variant/utility_functions.hpp> using namespace godot; #pragma region Registry // Converts pipewire registry event details // into a dictionary to be exposed in godot static void on_registry_event(void *_data, uint32_t id, ...
evt
699
#include <iostream> #include <algorithm> #include <vector> using namespace std; const int mod = 1e9 + 7; const int maxn = 2e5 + 5; long long a[maxn]; int ans = 0; #include <iostream> using namespace std; // 计算Cn-m的函数-动态规划O(nk) // int C_dp(int n, int k) { // std::vector<std::vector<int>> dp(n + 1, std::vector<int...
selected