blob_id
stringlengths
40
40
directory_id
stringlengths
40
40
path
stringlengths
3
264
content_id
stringlengths
40
40
detected_licenses
sequencelengths
0
85
license_type
stringclasses
2 values
repo_name
stringlengths
5
140
snapshot_id
stringlengths
40
40
revision_id
stringlengths
40
40
branch_name
stringclasses
941 values
visit_date
timestamp[us]
revision_date
timestamp[us]
committer_date
timestamp[us]
github_id
int64
3.89k
681M
star_events_count
int64
0
209k
fork_events_count
int64
0
110k
gha_license_id
stringclasses
22 values
gha_event_created_at
timestamp[us]
gha_created_at
timestamp[us]
gha_language
stringclasses
142 values
src_encoding
stringclasses
34 values
language
stringclasses
1 value
is_vendor
bool
1 class
is_generated
bool
2 classes
length_bytes
int64
3
10.4M
extension
stringclasses
121 values
content
stringlengths
3
10.4M
authors
sequencelengths
1
1
author_id
stringlengths
0
158
1e5b25e6e3c0b99a2213a361466046a309d89862
79ace29944e0ebfe344ead990b88e924a84aa86d
/miosix/arch/cortexM7_stm32f7/stm32f746zg_nucleo/interfaces-impl/bsp.cpp
4255b80daaaf96a636c756f851239917c22a2d73
[]
no_license
skyward-er/miosix-kernel
9f75670c1c24db4e25cc9e118283491e7386d32e
7ef13296f6bfdb70b74f54e2f49db848530e126a
refs/heads/master
2023-08-30T20:05:11.514787
2023-08-29T14:09:13
2023-08-29T14:09:13
128,632,628
2
0
null
2018-04-08T11:09:05
2018-04-08T11:09:05
null
UTF-8
C++
false
false
4,420
cpp
/*************************************************************************** * Copyright (C) 2018 by Terraneo Federico * * * * This program is free software; you can redistribute it and/or modify * * it under the terms of the GNU General Public License as published by * * the Free Software Foundation; either version 2 of the License, or * * (at your option) any later version. * * * * This program is distributed in the hope that it will be useful, * * but WITHOUT ANY WARRANTY; without even the implied warranty of * * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * * GNU General Public License for more details. * * * * As a special exception, if other files instantiate templates or use * * macros or inline functions from this file, or you compile this file * * and link it with other works to produce a work based on this file, * * this file does not by itself cause the resulting work to be covered * * by the GNU General Public License. However the source code for this * * file must still be made available in accordance with the GNU General * * Public License. This exception does not invalidate any other reasons * * why a work based on this file might be covered by the GNU General * * Public License. * * * * You should have received a copy of the GNU General Public License * * along with this program; if not, see <http://www.gnu.org/licenses/> * ***************************************************************************/ /*********************************************************************** * bsp.cpp Part of the Miosix Embedded OS. * Board support package, this file initializes hardware. ************************************************************************/ #include "interfaces/bsp.h" #include <inttypes.h> #include <sys/ioctl.h> #include <cstdlib> #include "board_settings.h" #include "config/miosix_settings.h" #include "drivers/sd_stm32f2_f4_f7.h" #include "drivers/serial.h" #include "filesystem/console/console_device.h" #include "filesystem/file_access.h" #include "interfaces/arch_registers.h" #include "interfaces/delays.h" #include "interfaces/portability.h" #include "kernel/kernel.h" #include "kernel/logging.h" #include "kernel/sync.h" namespace miosix { // // Initialization // void IRQbspInit() { // Enable all gpios RCC->AHB1ENR |= RCC_AHB1ENR_GPIOAEN | RCC_AHB1ENR_GPIOBEN | RCC_AHB1ENR_GPIOCEN | RCC_AHB1ENR_GPIODEN | RCC_AHB1ENR_GPIOEEN | RCC_AHB1ENR_GPIOFEN | RCC_AHB1ENR_GPIOHEN; RCC_SYNC(); GPIOA->OSPEEDR = 0xaaaaaaaa; // Default to 50MHz speed for all GPIOS GPIOB->OSPEEDR = 0xaaaaaaaa; GPIOC->OSPEEDR = 0xaaaaaaaa; GPIOD->OSPEEDR = 0xaaaaaaaa; GPIOE->OSPEEDR = 0xaaaaaaaa; GPIOF->OSPEEDR = 0xaaaaaaaa; GPIOH->OSPEEDR = 0xaaaaaaaa; userLed1::mode(Mode::OUTPUT); userLed2::mode(Mode::OUTPUT); userLed3::mode(Mode::OUTPUT); userBtn::mode(Mode::INPUT); ledOn(); delayMs(100); ledOff(); auto tx = Gpio<GPIOD_BASE, 8>::getPin(); tx.alternateFunction(7); auto rx = Gpio<GPIOD_BASE, 9>::getPin(); rx.alternateFunction(7); DefaultConsole::instance().IRQset(intrusive_ref_ptr<Device>( new STM32Serial(3, defaultSerialSpeed, tx, rx))); } void bspInit2() { #ifdef WITH_FILESYSTEM basicFilesystemSetup(SDIODriver::instance()); #endif // WITH_FILESYSTEM } // // Shutdown and reboot // void shutdown() { ioctl(STDOUT_FILENO, IOCTL_SYNC, 0); #ifdef WITH_FILESYSTEM FilesystemManager::instance().umountAll(); #endif // WITH_FILESYSTEM disableInterrupts(); for (;;) ; } void reboot() { ioctl(STDOUT_FILENO, IOCTL_SYNC, 0); #ifdef WITH_FILESYSTEM FilesystemManager::instance().umountAll(); #endif // WITH_FILESYSTEM disableInterrupts(); miosix_private::IRQsystemReboot(); } } // namespace miosix
[ "fede.tft@miosix.org" ]
fede.tft@miosix.org
18b45525ac11b2896865cdb05fe5a4b6b087e890
f7b8c37df7794b3ed5a72080d664cd9e2f309241
/bin/PUReweighter.h
a70423f7c2d9d6226a305ebaa1c6df97e4294a4c
[]
no_license
gdimperi/JECGammaJet
a23eb21ae5e2c0d8dfcd5465f1df6b8d5c97a73d
cbae3c5d6e590157da99f635e3e2f6374698d8da
refs/heads/master
2020-05-27T11:39:02.986176
2014-07-29T09:12:22
2014-07-29T09:12:22
14,828,560
0
0
null
null
null
null
UTF-8
C++
false
false
509
h
#include <string> #include <TH1.h> #include <map> enum class PUProfile : uint8_t { S6, S7, S10 }; class PUReweighter { public: PUReweighter(const std::string& dataFile, const std::string& mcFile); PUReweighter(const std::string& dataFile, PUProfile profile = PUProfile::S10); ~PUReweighter() { delete puHisto; } double weight(float interactions) const; private: void initPUProfiles(); TH1* puHisto; std::map<PUProfile, std::vector<double>> mPUCoefs; };
[ "s.brochet@ipnl.in2p3.fr" ]
s.brochet@ipnl.in2p3.fr
efcd4174dbfe81e4a8d8966b0fa197d0b62bf931
f6d49ca4505f9471fad9aa32aeead6998f431ff1
/flight/bf/eclipse/src/pid_mw.h
05776a127452bdc86f98528707ea53d7dd04477b
[]
no_license
gitarmpit/libarmpit
cefe1963807d1fb9d17ccb6c0e295df32123d287
bf2d2211273306ceb3e021852ef4cf8a1237f05b
refs/heads/master
2023-06-09T04:38:00.977762
2023-06-05T23:23:12
2023-06-05T23:23:12
91,350,561
0
1
null
null
null
null
UTF-8
C++
false
false
1,483
h
#ifndef _PID_MW_H #define _PID_MW_H #include <stdint.h> #include "bf_common.h" struct pidProfile_t { //att ypr uint8_t P[3]; uint8_t I[3]; uint8_t D[3]; uint8_t pidLevel_P; uint8_t pidLevel_I; uint8_t pidLevel_D; uint8_t yawRate; uint8_t rollPitchRate[2]; // uint8_t pidMAG_P; // uint16_t yaw_p_limit; // set P term limit (fixed value was 300) // uint16_t dterm_lpf_hz; // Delta Filter in hz // uint16_t yaw_lpf_hz; // additional yaw filter when yaw axis too noisy // uint8_t deltaMethod; // // uint8_t horizon_tilt_effect; // inclination factor for Horizon mode // uint8_t horizon_tilt_mode; // SAFE or EXPERT // // uint8_t dterm_filter_type; // Filter selection for dterm // uint16_t dterm_notch_hz; // Biquad dterm notch hz // uint16_t dterm_notch_cutoff; // Biquad dterm notch low cutoff // // uint16_t max_angle_inclination; // max inclination allowed in angle (level) mode. default 500 (50 degrees). }; class Pid_mw { private: pidProfile_t* cfg; uint8_t dynP8[3] = {0,0,0}; //TODO uint8_t dynD8[3] = {0,0,0}; int16_t rollPitchTrim[2] = {0, 0};//TODO adjustable from RC public: Pid_mw(pidProfile_t* pidProfile); void pid_mw(int16_t* rcCommand, int16_t* gyroADC, int16_t* attitude, FLIGHT_MODE flightMode, int16_t* axisPID); }; #endif
[ "gitarmpit@gmail.com" ]
gitarmpit@gmail.com
a1ac7862c7044b1e6ae0e59fca2aa01af4fdda59
86033af5864fbd57c5ecbd61cb06e07c6cdc4208
/src/vk/renderer/vk_atmoshere_renderer.cpp
ec2698200e24f644517ed114dc041cdc2f1736d5
[ "MIT" ]
permissive
kuumies/vulkan_capabilities
b6bcbcc932cc5323cfe92bdf74760e45e9705f72
71ab131652861a6ca0061d85da5cfb7f688a14a7
refs/heads/master
2021-09-07T14:31:32.380097
2017-12-21T16:56:33
2017-12-21T16:56:33
109,518,601
0
0
null
null
null
null
UTF-8
C++
false
false
20,657
cpp
/* -------------------------------------------------------------------------- * Antti Jumpponen <kuumies@gmail.com> The implementation of kuu::vk::AtmosphereRenderer class * -------------------------------------------------------------------------- */ #pragma once #include "vk_atmoshere_renderer.h" #define GLM_FORCE_RADIANS #define GLM_FORCE_DEPTH_ZERO_TO_ONE #include <glm/mat4x4.hpp> #include <glm/gtc/matrix_inverse.hpp> #include <glm/gtc/matrix_transform.hpp> #include <glm/gtc/quaternion.hpp> #include <glm/gtx/string_cast.hpp> #include <iostream> #include "../vk_buffer.h" #include "../vk_command.h" #include "../vk_descriptor_set.h" #include "../vk_image.h" #include "../vk_mesh.h" #include "../vk_pipeline.h" #include "../vk_queue.h" #include "../vk_image.h" #include "../vk_image_layout_transition.h" #include "../vk_render_pass.h" #include "../vk_shader_module.h" #include "../vk_texture.h" #include "../../common/mesh.h" namespace kuu { namespace vk { /* -------------------------------------------------------------------------- */ struct AtmosphereRenderer::Impl { // Input Vulkan handles VkPhysicalDevice physicalDevice; VkDevice device; // Graphics queue. uint32_t graphicsQueueFamilyIndex; // Input texture cube std::shared_ptr<TextureCube> textureCube; // Dimensions of the texture cube. VkExtent3D extent; // Format of the texture cube. VkFormat format; // Parameters AtmosphereRenderer::Params params; }; /* -------------------------------------------------------------------------- */ AtmosphereRenderer::AtmosphereRenderer( const VkPhysicalDevice& physicalDevice, const VkDevice& device, const uint32_t& graphicsQueueFamilyIndex) : impl(std::make_shared<Impl>()) { impl->physicalDevice = physicalDevice; impl->device = device; impl->graphicsQueueFamilyIndex = graphicsQueueFamilyIndex; impl->format = VK_FORMAT_R32G32B32A32_SFLOAT; impl->extent = { uint32_t(128), uint32_t(128), uint32_t(1) }; impl->textureCube = std::make_shared<TextureCube>( physicalDevice, device, impl->extent, impl->format, VK_FILTER_LINEAR, VK_FILTER_LINEAR, VK_SAMPLER_ADDRESS_MODE_CLAMP_TO_EDGE, VK_SAMPLER_ADDRESS_MODE_CLAMP_TO_EDGE, VK_SAMPLER_ADDRESS_MODE_CLAMP_TO_EDGE, false); } void AtmosphereRenderer::setLightDir(const glm::vec3& lightDir) { impl->params.lightdir = glm::vec4(lightDir, 1.0); } void AtmosphereRenderer::render() { //-------------------------------------------------------------------------- // Quad mesh in NDC space. std::vector<Vertex> vertices = { { { 1, 1, 0 }, { 1, 1 } }, { {-1, 1, 0 }, { 0, 1 } }, { {-1, -1, 0 }, { 0, 0 } }, { { 1, 1, 0 }, { 1, 1 } }, { {-1, -1, 0 }, { 0, 0 } }, { { 1, -1, 0 }, { 1, 0 } }, }; kuu::Mesh m; for(const Vertex& v : vertices) m.addVertex(v); std::vector<float> vertexVector; for (const Vertex& v : m.vertices) { vertexVector.push_back(v.pos.x); vertexVector.push_back(v.pos.y); vertexVector.push_back(v.pos.z); vertexVector.push_back(v.texCoord.x); vertexVector.push_back(v.texCoord.y); } std::shared_ptr<Mesh> mesh = std::make_shared<Mesh>( impl->physicalDevice, impl->device); mesh->setVertices(vertexVector); mesh->setIndices(m.indices); mesh->addVertexAttributeDescription(0, 0, VK_FORMAT_R32G32B32_SFLOAT, 0); mesh->addVertexAttributeDescription(1, 0, VK_FORMAT_R32G32_SFLOAT, 3 * sizeof(float)); mesh->setVertexBindingDescription(0, 5 * sizeof(float), VK_VERTEX_INPUT_RATE_VERTEX); if (!mesh->create()) return; //-------------------------------------------------------------------------- // Shader modules. const std::string vshFilePath = "shaders/atmosphere.vert.spv"; const std::string fshFilePath = "shaders/atmosphere.frag.spv"; std::shared_ptr<ShaderModule> vshModule = std::make_shared<ShaderModule>(impl->device, vshFilePath); vshModule->setStageName("main"); vshModule->setStage(VK_SHADER_STAGE_VERTEX_BIT); if (!vshModule->create()) return; std::shared_ptr<ShaderModule> fshModule = std::make_shared<ShaderModule>(impl->device, fshFilePath); fshModule->setStageName("main"); fshModule->setStage(VK_SHADER_STAGE_FRAGMENT_BIT); if (!fshModule->create()) return; //-------------------------------------------------------------------------- // Uniform buffer for atmosphere parameters. auto pitchYaw = [](float pitch, float yaw) -> glm::quat { const float pitchRad = glm::radians(pitch); const float yawRad = glm::radians(yaw); glm::vec3 pitchAxis = glm::vec3(1.0f, 0.0f, 0.0f); glm::vec3 yawAxis = glm::vec3(0.0f, 1.0f, 0.0f); glm::quat out; out = glm::angleAxis(yawRad, yawAxis) * out; out = glm::angleAxis(pitchRad, pitchAxis) * out; return out; }; std::vector<glm::quat> faceRotations; faceRotations.push_back(pitchYaw( 0.0f, 90.0f)); // pos x faceRotations.push_back(pitchYaw( 0.0f, -90.0f)); // neg x faceRotations.push_back(pitchYaw(-90.0f, 0.0f)); // pos y faceRotations.push_back(pitchYaw( 90.0f, 0.0f)); // neg y faceRotations.push_back(pitchYaw( 0.0f, 0.0f)); // neg z faceRotations.push_back(pitchYaw( 0.0f, 180.0f)); // pos z std::vector<glm::mat4> viewMatrices; for (const glm::quat& faceRotation : faceRotations) viewMatrices.push_back(glm::mat4_cast(faceRotation)); impl->params.viewport.x = float(impl->extent.width); impl->params.viewport.y = float(impl->extent.height); std::vector<std::shared_ptr<Buffer>> uniformBuffers; for (int f = 0; f < 6; ++f) { std::shared_ptr<Buffer> paramsBuffer = std::make_shared<Buffer>(impl->physicalDevice, impl->device); paramsBuffer->setSize(sizeof(Params)); paramsBuffer->setUsage(VK_BUFFER_USAGE_UNIFORM_BUFFER_BIT); paramsBuffer->setMemoryProperties( VK_MEMORY_PROPERTY_HOST_VISIBLE_BIT | VK_MEMORY_PROPERTY_HOST_COHERENT_BIT); if (!paramsBuffer->create()) return; glm::mat4 projection = glm::perspective(float(M_PI / 2.0), 1.0f, 0.1f, 512.0f); projection[1][1] *= -1; const glm::mat4 invViewMatrix = glm::inverse(viewMatrices[f]); const glm::mat4 invViewNormalMatrix = glm::inverseTranspose(glm::mat3(invViewMatrix)); impl->params.inv_view_rot = invViewNormalMatrix; impl->params.inv_proj = glm::inverse(projection); paramsBuffer->copyHostVisible(&impl->params, paramsBuffer->size()); uniformBuffers.push_back(paramsBuffer); } //-------------------------------------------------------------------------- // Descriptor pool and descriptor sets std::shared_ptr<DescriptorPool> descriptorPool = std::make_shared<DescriptorPool>(impl->device); descriptorPool->addTypeSize(VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER, 6); descriptorPool->setMaxCount(6); if (!descriptorPool->create()) return; std::vector<std::shared_ptr<DescriptorSets>> descriptorSets; for (int f = 0; f < 6; ++f) { std::shared_ptr<DescriptorSets> descriptorSet = std::make_shared<DescriptorSets>(impl->device, descriptorPool->handle()); descriptorSet->addLayoutBinding( 0, VK_DESCRIPTOR_TYPE_UNIFORM_BUFFER, 1, VK_SHADER_STAGE_FRAGMENT_BIT); if (!descriptorSet->create()) return; descriptorSet->writeUniformBuffer( 0, uniformBuffers[f]->handle(), 0, uniformBuffers[f]->size()); descriptorSets.push_back(descriptorSet); } //-------------------------------------------------------------------------- // Render pass // Colorbuffer attachment description VkAttachmentDescription colorAttachment; colorAttachment.flags = 0; colorAttachment.format = impl->format; colorAttachment.samples = VK_SAMPLE_COUNT_1_BIT; colorAttachment.loadOp = VK_ATTACHMENT_LOAD_OP_CLEAR; colorAttachment.storeOp = VK_ATTACHMENT_STORE_OP_STORE; colorAttachment.stencilLoadOp = VK_ATTACHMENT_LOAD_OP_DONT_CARE; colorAttachment.stencilStoreOp = VK_ATTACHMENT_STORE_OP_DONT_CARE; colorAttachment.initialLayout = VK_IMAGE_LAYOUT_UNDEFINED; colorAttachment.finalLayout = VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL; // Reference to first attachment (color) VkAttachmentReference colorAttachmentRef; colorAttachmentRef.attachment = 0; colorAttachmentRef.layout = VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL; // Subpass VkSubpassDescription subpass; subpass.flags = 0; subpass.pipelineBindPoint = VK_PIPELINE_BIND_POINT_GRAPHICS; subpass.inputAttachmentCount = 0; subpass.pInputAttachments = NULL; subpass.colorAttachmentCount = 1; subpass.pColorAttachments = &colorAttachmentRef; subpass.pResolveAttachments = NULL; subpass.pDepthStencilAttachment = NULL; subpass.preserveAttachmentCount = 0; subpass.pPreserveAttachments = NULL; // Subpass dependency VkSubpassDependency dependency; dependency.srcSubpass = VK_SUBPASS_EXTERNAL; dependency.dstSubpass = 0; dependency.srcStageMask = VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT; dependency.dstStageMask = VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT; dependency.srcAccessMask = 0; dependency.dstAccessMask = VK_ACCESS_COLOR_ATTACHMENT_READ_BIT | VK_ACCESS_COLOR_ATTACHMENT_WRITE_BIT; dependency.dependencyFlags = 0; VkRenderPassCreateInfo rpInfo; rpInfo.sType = VK_STRUCTURE_TYPE_RENDER_PASS_CREATE_INFO; rpInfo.pNext = NULL; rpInfo.flags = 0; rpInfo.attachmentCount = 1; rpInfo.pAttachments = &colorAttachment; rpInfo.subpassCount = 1; rpInfo.pSubpasses = &subpass; rpInfo.dependencyCount = 1; rpInfo.pDependencies = &dependency; VkRenderPass renderPass = VK_NULL_HANDLE; VkResult result = vkCreateRenderPass( impl->device, &rpInfo, NULL, &renderPass); if (result != VK_SUCCESS) { std::cerr << __FUNCTION__ << ": render pass creation failed" << std::endl; return; } //-------------------------------------------------------------------------- // Framebuffer Image image(impl->physicalDevice, impl->device); image.setType(VK_IMAGE_TYPE_2D); image.setFormat(impl->format); image.setExtent(impl->extent); image.setUsage(VK_IMAGE_USAGE_COLOR_ATTACHMENT_BIT | VK_IMAGE_USAGE_TRANSFER_SRC_BIT); image.setMemoryProperty(VK_MEMORY_PROPERTY_DEVICE_LOCAL_BIT); image.setImageViewAspect(VK_IMAGE_ASPECT_COLOR_BIT); if (!image.create()) return; std::vector<VkImageView> attachments = { image.imageViewHandle() }; VkFramebufferCreateInfo fbInfo; fbInfo.sType = VK_STRUCTURE_TYPE_FRAMEBUFFER_CREATE_INFO; fbInfo.pNext = NULL; fbInfo.flags = 0; fbInfo.renderPass = renderPass; fbInfo.attachmentCount = uint32_t(attachments.size()); fbInfo.pAttachments = attachments.data(); fbInfo.width = impl->extent.width; fbInfo.height = impl->extent.height; fbInfo.layers = 1; VkFramebuffer framebuffer = VK_NULL_HANDLE; result = vkCreateFramebuffer( impl->device, &fbInfo, NULL, &framebuffer); if (result != VK_SUCCESS) { std::cerr << __FUNCTION__ << ": framebuffer creation failed" << std::endl; return; } //-------------------------------------------------------------------------- // Pipeline VkPipelineColorBlendAttachmentState colorBlend = {}; colorBlend.blendEnable = VK_FALSE; colorBlend.colorWriteMask = 0xf; float blendConstants[4] = { 0, 0, 0, 0 }; std::shared_ptr<Pipeline> pipeline = std::make_shared<Pipeline>(impl->device); pipeline->addShaderStage(vshModule->createInfo()); pipeline->addShaderStage(fshModule->createInfo()); pipeline->setVertexInputState( { mesh->vertexBindingDescription() }, mesh->vertexAttributeDescriptions() ); pipeline->setInputAssemblyState(VK_PRIMITIVE_TOPOLOGY_TRIANGLE_LIST, VK_FALSE); pipeline->setViewportState( { { 0, 0, float(impl->extent.width), float(impl->extent.height), 0, 1 } }, { { { 0, 0 }, { impl->extent.width, impl->extent.height } } } ); pipeline->setRasterizerState( VK_POLYGON_MODE_FILL, VK_CULL_MODE_NONE, VK_FRONT_FACE_COUNTER_CLOCKWISE); pipeline->setMultisampleState(VK_FALSE, VK_SAMPLE_COUNT_1_BIT); pipeline->setDepthStencilState(VK_FALSE, VK_FALSE); pipeline->setColorBlendingState( VK_FALSE, VK_LOGIC_OP_CLEAR, { colorBlend }, blendConstants); std::vector<VkDescriptorSetLayout> descriptorSetLayouts; for (int f = 0; f < 6; ++f) descriptorSetLayouts.push_back(descriptorSets[f]->layoutHandle()); const std::vector<VkPushConstantRange> pushConstantRanges; pipeline->setPipelineLayout(descriptorSetLayouts, pushConstantRanges); pipeline->setDynamicState( { VK_DYNAMIC_STATE_VIEWPORT, VK_DYNAMIC_STATE_SCISSOR } ); pipeline->setRenderPass(renderPass); if (!pipeline->create()) return; //-------------------------------------------------------------------------- // Command pool std::shared_ptr<CommandPool> graphicsCommandPool = std::make_shared<CommandPool>(impl->device); graphicsCommandPool->setQueueFamilyIndex(impl->graphicsQueueFamilyIndex); if (!graphicsCommandPool->create()) return; //-------------------------------------------------------------------------- // Record commands VkCommandBuffer cmdBuf = graphicsCommandPool->allocateBuffer( VK_COMMAND_BUFFER_LEVEL_PRIMARY); VkCommandBufferBeginInfo beginInfo; beginInfo.sType = VK_STRUCTURE_TYPE_COMMAND_BUFFER_BEGIN_INFO; beginInfo.pNext = NULL; beginInfo.flags = VK_COMMAND_BUFFER_USAGE_SIMULTANEOUS_USE_BIT; beginInfo.pInheritanceInfo = NULL; vkBeginCommandBuffer(cmdBuf, &beginInfo); image_layout_transition::record( cmdBuf, image.imageHandle(), VK_IMAGE_ASPECT_COLOR_BIT, VK_IMAGE_LAYOUT_UNDEFINED, VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL); VkImageSubresourceRange subresourceRange = {}; subresourceRange.aspectMask = VK_IMAGE_ASPECT_COLOR_BIT; subresourceRange.levelCount = 1; subresourceRange.layerCount = 6; image_layout_transition::record( cmdBuf, impl->textureCube->image, VK_IMAGE_LAYOUT_UNDEFINED, VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, subresourceRange); std::vector<VkClearValue> clearValues(1); clearValues[0].color = { 0.1f, 0.1f, 0.1f, 1.0f }; for (uint32_t f = 0; f < 6; f++) { VkViewport viewport; viewport.x = 0; viewport.y = 0; viewport.width = float(impl->extent.width); viewport.height = float(impl->extent.height); viewport.minDepth = 0.0f; viewport.maxDepth = 1.0f; vkCmdSetViewport(cmdBuf, 0, 1, &viewport); VkRect2D scissor; scissor.offset = {}; scissor.extent = { impl->extent.width, impl->extent.height }; vkCmdSetScissor(cmdBuf, 0, 1, &scissor); VkRenderPassBeginInfo renderPassInfo; renderPassInfo.sType = VK_STRUCTURE_TYPE_RENDER_PASS_BEGIN_INFO; renderPassInfo.pNext = NULL; renderPassInfo.renderPass = renderPass; renderPassInfo.framebuffer = framebuffer; renderPassInfo.renderArea.offset = { 0, 0 }; renderPassInfo.renderArea.extent = { impl->extent.width, impl->extent.height }; renderPassInfo.clearValueCount = uint32_t(clearValues.size()); renderPassInfo.pClearValues = clearValues.data(); vkCmdBeginRenderPass( cmdBuf, &renderPassInfo, VK_SUBPASS_CONTENTS_INLINE); VkDescriptorSet descriptorHandle = descriptorSets[f]->handle(); vkCmdBindDescriptorSets( cmdBuf, VK_PIPELINE_BIND_POINT_GRAPHICS, pipeline->pipelineLayoutHandle(), 0, 1, &descriptorHandle, 0, NULL); vkCmdBindPipeline( cmdBuf, VK_PIPELINE_BIND_POINT_GRAPHICS, pipeline->handle()); const VkBuffer vertexBuffer = mesh->vertexBufferHandle(); const VkDeviceSize offsets[1] = { 0 }; vkCmdBindVertexBuffers( cmdBuf, 0, 1, &vertexBuffer, offsets); const VkBuffer indexBuffer = mesh->indexBufferHandle(); vkCmdBindIndexBuffer( cmdBuf, indexBuffer, 0, VK_INDEX_TYPE_UINT32); uint32_t indexCount = uint32_t(mesh->indices().size()); vkCmdDrawIndexed( cmdBuf, indexCount, 1, 0, 0, 1); vkCmdEndRenderPass(cmdBuf); image_layout_transition::record( cmdBuf, image.imageHandle(), VK_IMAGE_ASPECT_COLOR_BIT, VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL, VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL); VkImageCopy copyRegion = {}; copyRegion.srcSubresource.aspectMask = VK_IMAGE_ASPECT_COLOR_BIT; copyRegion.srcSubresource.baseArrayLayer = 0; copyRegion.srcSubresource.mipLevel = 0; copyRegion.srcSubresource.layerCount = 1; copyRegion.srcOffset = { 0, 0, 0 }; copyRegion.dstSubresource.aspectMask = VK_IMAGE_ASPECT_COLOR_BIT; copyRegion.dstSubresource.baseArrayLayer = f; copyRegion.dstSubresource.mipLevel = 0; copyRegion.dstSubresource.layerCount = 1; copyRegion.dstOffset = { 0, 0, 0 }; copyRegion.extent = impl->extent; vkCmdCopyImage( cmdBuf, image.imageHandle(), VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, impl->textureCube->image, VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, 1, &copyRegion); // Transform framebuffer color attachment back image_layout_transition::record( cmdBuf, image.imageHandle(), VK_IMAGE_ASPECT_COLOR_BIT, VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, VK_IMAGE_LAYOUT_COLOR_ATTACHMENT_OPTIMAL); } image_layout_transition::record( cmdBuf, impl->textureCube->image, VK_IMAGE_LAYOUT_TRANSFER_DST_OPTIMAL, VK_IMAGE_LAYOUT_SHADER_READ_ONLY_OPTIMAL, subresourceRange); result = vkEndCommandBuffer(cmdBuf); if (result != VK_SUCCESS) { std::cerr << __FUNCTION__ << ": render commands failed" << std::endl; return; } //-------------------------------------------------------------------------- // Render Queue graphicsQueue(impl->device, impl->graphicsQueueFamilyIndex, 0); graphicsQueue.create(); graphicsQueue.submit(cmdBuf, VK_NULL_HANDLE, VK_NULL_HANDLE, VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT); graphicsQueue.waitIdle(); //-------------------------------------------------------------------------- // Clean up vkDestroyFramebuffer( impl->device, framebuffer, NULL); vkDestroyRenderPass( impl->device, renderPass, NULL); } std::shared_ptr<TextureCube> AtmosphereRenderer::textureCube() const { return impl->textureCube; } } // namespace vk } // namespace kuu
[ "kuumies@gmail.com" ]
kuumies@gmail.com
b5158c76501d1933542e92aa0bd9c52119cb52fe
1735fb3c533029b02a89f8f308c2011292a76b36
/lab6/Cube.h
3fa6790553f1549693620bcf05a60e7b3f1ac494
[]
no_license
morozyto/ComputerGraphicsCourse
aa563c44500cf64b2d449d395c3ebf3212294b0e
61b75a60151d10c8d73b34a8d0414b8ddb4ad763
refs/heads/master
2020-03-19T11:48:35.501472
2018-06-07T15:48:56
2018-06-07T15:48:56
136,477,135
0
0
null
null
null
null
UTF-8
C++
false
false
293
h
// // Created by Tony Morozov on 17.05.2018. // #ifndef LAB6_CUBE_H #define LAB6_CUBE_H #include <GLFW/glfw3.h> class Cube { public: Cube(double size); void draw(); private: double size; void draw_edge(double *edge, double* colour, double* normal); }; #endif //LAB6_CUBE_H
[ "moranton@mail.ru" ]
moranton@mail.ru
27a0c9e01e76df99b2da32a0b03c5edcac3c2f10
9d80b2ea287933af57f19d9e3ea422341f1576b8
/include/hx/QuickVec.h
d0cfef0460379abf2813385acb2a10f6d2298653
[]
no_license
larsiusprime/hxcpp
d9329246f24c74c45a516b53f93adf89bd902bf6
c62d762d53b3294998792841f2eff72eac4ce384
refs/heads/master
2021-01-21T09:14:33.965140
2018-05-21T16:43:41
2018-05-21T16:43:41
29,712,187
0
0
null
2015-01-23T02:19:27
2015-01-23T02:19:27
null
UTF-8
C++
false
false
4,011
h
#ifndef HX_QUICKVEC_INCLUDED #define HX_QUICKVEC_INCLUDED #include <stdlib.h> namespace hx { template<typename T> struct QuickVec { int mAlloc; int mSize; T *mPtr; QuickVec() : mPtr(0), mAlloc(0), mSize(0) { } ~QuickVec() { if (mPtr) free(mPtr); } inline void push(const T &inT) { if (mSize+1>mAlloc) { mAlloc = 10 + (mSize*3/2); mPtr = (T *)realloc(mPtr,sizeof(T)*mAlloc); } mPtr[mSize++]=inT; } void setSize(int inSize) { if (inSize>mAlloc) { mAlloc = inSize; mPtr = (T *)realloc(mPtr,sizeof(T)*mAlloc); } mSize = inSize; } bool safeReserveExtra(int inN) { int want = mSize + inN; if (want>mAlloc) { int wantAlloc = 10 + (mSize*3/2); if (wantAlloc<want) wantAlloc = want; T *newBuffer = (T *)malloc( sizeof(T)*wantAlloc ); if (!newBuffer) return false; mAlloc = wantAlloc; if (mPtr) { memcpy(newBuffer, mPtr, mSize*sizeof(T)); free(mPtr); } mPtr = newBuffer; } return true; } inline void pop_back() { --mSize; } inline T &back() { return mPtr[mSize-1]; } inline T pop() { return mPtr[--mSize]; } inline void qerase(int inPos) { --mSize; mPtr[inPos] = mPtr[mSize]; } inline void erase(int inPos) { --mSize; if (mSize>inPos) memmove(mPtr+inPos, mPtr+inPos+1, (mSize-inPos)*sizeof(T)); } void zero() { memset(mPtr,0,mSize*sizeof(T) ); } inline void qerase_val(T inVal) { for(int i=0;i<mSize;i++) if (mPtr[i]==inVal) { --mSize; mPtr[i] = mPtr[mSize]; return; } } inline bool some_left() { return mSize; } inline bool empty() const { return !mSize; } inline void clear() { mSize = 0; } inline int next() { if (mSize+1>=mAlloc) { mAlloc = 10 + (mSize*3/2); mPtr = (T *)realloc(mPtr,sizeof(T)*mAlloc); } return mSize++; } inline int size() const { return mSize; } inline T &operator[](int inIndex) { return mPtr[inIndex]; } inline const T &operator[](int inIndex) const { return mPtr[inIndex]; } private: QuickVec(const QuickVec<T> &); void operator =(const QuickVec<T> &); }; template<typename T> class QuickDeque { struct Slab { T mElems[1024]; }; QuickVec<Slab *> mSpare; QuickVec<Slab *> mActive; int mHeadPos; int mTailPos; Slab *mHead; Slab *mTail; public: QuickDeque() { mHead = mTail = 0; mHeadPos = 1024; mTailPos = 1024; } ~QuickDeque() { for(int i=0;i<mSpare.size();i++) delete mSpare[i]; for(int i=0;i<mActive.size();i++) delete mActive[i]; delete mHead; if (mTail!=mHead) delete mTail; } inline void push(T inObj) { if (mHeadPos<1024) { mHead->mElems[mHeadPos++] = inObj; return; } if (mHead != mTail) mActive.push(mHead); mHead = mSpare.empty() ? new Slab : mSpare.pop(); mHead->mElems[0] = inObj; mHeadPos = 1; } inline bool some_left() { return mHead!=mTail || mHeadPos!=mTailPos; } inline T pop() { if (mTailPos<1024) return mTail->mElems[mTailPos++]; if (mTail) mSpare.push(mTail); if (mActive.empty()) { mTail = mHead; } else { mTail = mActive[0]; mActive.erase(0); } mTailPos = 1; return mTail->mElems[0]; } private: QuickDeque(const QuickDeque<T> &); void operator=(const QuickDeque<T> &); }; } // end namespace hx #endif
[ "gamehaxe@gmail.com" ]
gamehaxe@gmail.com
120ab33b8a3ca77677a7fda7bf3efe0a18aeeb95
1942a0d16bd48962e72aa21fad8d034fa9521a6c
/aws-cpp-sdk-clouddirectory/source/model/CreateDirectoryRequest.cpp
d5e8b5543c548209d6f92feceafd47b23979404a
[ "Apache-2.0", "JSON", "MIT" ]
permissive
yecol/aws-sdk-cpp
1aff09a21cfe618e272c2c06d358cfa0fb07cecf
0b1ea31e593d23b5db49ee39d0a11e5b98ab991e
refs/heads/master
2021-01-20T02:53:53.557861
2018-02-11T11:14:58
2018-02-11T11:14:58
83,822,910
0
1
null
2017-03-03T17:17:00
2017-03-03T17:17:00
null
UTF-8
C++
false
false
1,523
cpp
/* * Copyright 2010-2016 Amazon.com, Inc. or its affiliates. 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. * A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either * express or implied. See the License for the specific language governing * permissions and limitations under the License. */ #include <aws/clouddirectory/model/CreateDirectoryRequest.h> #include <aws/core/utils/json/JsonSerializer.h> #include <aws/core/utils/memory/stl/AWSStringStream.h> #include <utility> using namespace Aws::CloudDirectory::Model; using namespace Aws::Utils::Json; using namespace Aws::Utils; CreateDirectoryRequest::CreateDirectoryRequest() : m_nameHasBeenSet(false), m_schemaArnHasBeenSet(false) { } Aws::String CreateDirectoryRequest::SerializePayload() const { JsonValue payload; if(m_nameHasBeenSet) { payload.WithString("Name", m_name); } return payload.WriteReadable(); } Aws::Http::HeaderValueCollection CreateDirectoryRequest::GetRequestSpecificHeaders() const { Aws::Http::HeaderValueCollection headers; Aws::StringStream ss; if(m_schemaArnHasBeenSet) { ss << m_schemaArn; headers.insert(Aws::Http::HeaderValuePair("x-amz-data-partition", ss.str())); ss.str(""); } return headers; }
[ "henso@amazon.com" ]
henso@amazon.com
e8b9cee410bd147ca1f617c7235d67b8b73d0744
b33a9177edaaf6bf185ef20bf87d36eada719d4f
/qtbase/src/corelib/kernel/qtcore_eval.cpp
60873b56168ca3958373f516545ed2b3d5180187
[ "LicenseRef-scancode-proprietary-license", "LicenseRef-scancode-unknown-license-reference", "LicenseRef-scancode-commercial-license", "LGPL-2.0-or-later", "LGPL-2.1-only", "GFDL-1.3-only", "LicenseRef-scancode-qt-commercial-1.1", "LGPL-3.0-only", "LicenseRef-scancode-qt-company-exception-lgpl-2.1", "GPL-1.0-or-later", "GPL-3.0-only", "BSD-3-Clause", "LGPL-2.1-or-later", "GPL-2.0-only", "Qt-LGPL-exception-1.1", "LicenseRef-scancode-digia-qt-preview", "LicenseRef-scancode-warranty-disclaimer", "LicenseRef-scancode-other-copyleft", "LicenseRef-scancode-generic-exception" ]
permissive
wgnet/wds_qt
ab8c093b8c6eead9adf4057d843e00f04915d987
8db722fd367d2d0744decf99ac7bafaba8b8a3d3
refs/heads/master
2021-04-02T11:07:10.181067
2020-06-02T10:29:03
2020-06-02T10:34:19
248,267,925
1
0
Apache-2.0
2020-04-30T12:16:53
2020-03-18T15:20:38
null
UTF-8
C++
false
false
17,845
cpp
/**************************************************************************** ** ** Copyright (C) 2015 The Qt Company Ltd. ** Contact: http://www.qt.io/licensing/ ** ** This file is part of the QtCore module of the Qt Toolkit. ** ** $QT_BEGIN_LICENSE:LGPL21$ ** Commercial License Usage ** Licensees holding valid commercial Qt licenses may use this file in ** accordance with the commercial license agreement provided with the ** Software or, alternatively, in accordance with the terms contained in ** a written agreement between you and The Qt Company. For licensing terms ** and conditions see http://www.qt.io/terms-conditions. For further ** information use the contact form at http://www.qt.io/contact-us. ** ** GNU Lesser General Public License Usage ** Alternatively, this file may be used under the terms of the GNU Lesser ** General Public License version 2.1 or version 3 as published by the Free ** Software Foundation and appearing in the file LICENSE.LGPLv21 and ** LICENSE.LGPLv3 included in the packaging of this file. Please review the ** following information to ensure the GNU Lesser General Public License ** requirements will be met: https://www.gnu.org/licenses/lgpl.html and ** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. ** ** As a special exception, The Qt Company gives you certain additional ** rights. These rights are described in The Qt Company LGPL Exception ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. ** ** $QT_END_LICENSE$ ** ****************************************************************************/ #include <qcoreevent.h> #include <qdatetime.h> #include <qlibraryinfo.h> #include <qobject.h> #include <qcoreapplication.h> #include <private/qcoreapplication_p.h> #include "stdio.h" #include "stdlib.h" QT_BEGIN_NAMESPACE #include "qconfig_eval.cpp" static const char boilerplate_supported_but_time_limited[] = "\nQt %1 Evaluation License\n" "Copyright (C) 2016 The Qt Company Ltd.\n" "This trial version may only be used for evaluation purposes\n" "and will shut down after 120 minutes.\n" "Registered to:\n" " Licensee: %2\n\n" "The evaluation expires in %4 days\n\n" "Contact http://www.qt.io/contact-us for pricing and purchasing information.\n"; static const char boilerplate_supported[] = "\nQt %1 Evaluation License\n" "Copyright (C) 2016 The Qt Company Ltd.\n" "This trial version may only be used for evaluation purposes\n" "Registered to:\n" " Licensee: %2\n\n" "The evaluation expires in %4 days\n\n" "Contact http://www.qt.io/contact-us for pricing and purchasing information.\n"; static const char boilerplate_expired[] = "This software is using the trial version of the Qt GUI toolkit.\n" "The trial period has expired. If you need more time to\n" "evaluate Qt, or if you have any questions about Qt, contact us\n" "at: http://www.qt.io/contact-us.\n\n"; static const char will_shutdown_1min[] = "\nThe evaluation of Qt will SHUT DOWN in 1 minute.\n" "Contact http://www.qt.io/contact-us for pricing and purchasing information.\n"; static const char will_shutdown_now[] = "\nThe evaluation of Qt has now reached its automatic\n" "timeout and will shut down.\n" "Contact http://www.qt.io/contact-us for pricing and purchasing information.\n"; enum EvaluationStatus { EvaluationNotSupported = 0, EvaluationSupportedButTimeLimited, EvaluationSupported }; static EvaluationStatus qt_eval_is_supported() { const volatile char *const license_key = qt_eval_key_data + 12; // fast fail if (!qt_eval_key_data[0] || !*license_key) return EvaluationNotSupported; // is this an unsupported evaluation? const volatile char *typecode = license_key; int field = 2; for ( ; field && *typecode; ++typecode) if (*typecode == '-') --field; if (!field && typecode[1] == '4' && typecode[2] == 'M') { if (typecode[0] == 'Q') return EvaluationSupportedButTimeLimited; else if (typecode[0] == 'R' || typecode[0] == 'Z') return EvaluationSupported; } return EvaluationNotSupported; } static int qt_eval_days_left() { const volatile char *const expiry_date = qt_eval_expiry_date + 12; QDate today = QDate::currentDate(); QDate lastday = QDate::fromString( QString::fromLatin1(const_cast<const char*>(expiry_date)), Qt::ISODate); return today.daysTo(lastday); } static bool qt_eval_is_expired() { return qt_eval_days_left() < 0; } static QString qt_eval_string() { const char *msg; switch (qt_eval_is_supported()) { case EvaluationSupportedButTimeLimited: msg = boilerplate_supported_but_time_limited; break; case EvaluationSupported: msg = boilerplate_supported; break; default: return QString(); msg = 0; } return QString::fromLatin1(msg) .arg(QLatin1String(QT_VERSION_STR)) .arg(QLibraryInfo::licensee()) .arg(qt_eval_days_left()); } #define WARN_TIMEOUT 60 * 1000 * 119 #define KILL_DELAY 60 * 1000 * 1 class QCoreFuriCuri : public QObject { public: int warn; int kill; QCoreFuriCuri() : QObject(), warn(-1), kill(-1) { if (qt_eval_is_supported() == EvaluationSupportedButTimeLimited) { warn = startTimer(WARN_TIMEOUT); kill = 0; } } void timerEvent(QTimerEvent *e) { if (e->timerId() == warn) { killTimer(warn); fprintf(stderr, "%s\n", will_shutdown_1min); kill = startTimer(KILL_DELAY); } else if (e->timerId() == kill) { fprintf(stderr, "%s\n", will_shutdown_now); QCoreApplication::instance()->quit(); } } }; #if defined(QT_BUILD_CORE_LIB) || defined (QT_BOOTSTRAPPED) void qt_core_eval_init(QCoreApplicationPrivate::Type type) { if (type != QCoreApplicationPrivate::Tty) return; if (!qt_eval_is_supported()) return; if (qt_eval_is_expired()) { fprintf(stderr, "%s\n", boilerplate_expired); exit(0); } else { fprintf(stderr, "%s\n", qPrintable(qt_eval_string())); Q_UNUSED(new QCoreFuriCuri()); } } #endif #ifdef QT_BUILD_WIDGETS_LIB QT_BEGIN_INCLUDE_NAMESPACE #include <qdialog.h> #include <qlabel.h> #include <qlayout.h> #include <qmessagebox.h> #include <qpushbutton.h> #include <qtimer.h> #include <qapplication.h> QT_END_INCLUDE_NAMESPACE static const char * const qtlogo_eval_xpm[] = { /* columns rows colors chars-per-pixel */ "46 55 174 2", " c #002E02", ". c #00370D", "X c #003A0E", "o c #003710", "O c #013C13", "+ c #043E1A", "@ c #084F0A", "# c #0B520C", "$ c #054413", "% c #0C4C17", "& c #07421D", "* c #09451D", "= c #0D491E", "- c #125515", "; c #13541A", ": c #17591B", "> c #1B5C1D", ", c #1F611F", "< c #20621E", "1 c #337B1E", "2 c #0B4521", "3 c #0F4923", "4 c #114B24", "5 c #154D2A", "6 c #175323", "7 c #1C5924", "8 c #1C532F", "9 c #1E5432", "0 c #245936", "q c #265938", "w c #295C3B", "e c #246324", "r c #266823", "t c #2A6C24", "y c #276628", "u c #2D7026", "i c #327427", "p c #367927", "a c #37782A", "s c #397C2A", "d c #2E613E", "f c #336C37", "g c #2F6040", "h c #356545", "j c #3C6B4E", "k c #3F6C51", "l c #406E4F", "z c #406D52", "x c #477457", "c c #497557", "v c #4B7857", "b c #517B5E", "n c #3C8423", "m c #3E812C", "M c #53A61D", "N c #41862C", "B c #458A2D", "V c #498F2D", "C c #479324", "Z c #489226", "A c #4D952C", "S c #478B30", "D c #488C30", "F c #4D9232", "G c #509632", "H c #549A33", "J c #589F35", "K c #56A526", "L c #57A821", "P c #5BAA27", "I c #57A32A", "U c #5CA72E", "Y c #5DAB2A", "T c #5CA336", "R c #60AD2E", "E c #63B12D", "W c #65AF35", "Q c #62A53F", "! c #65AE39", "~ c #66B036", "^ c #6AB437", "/ c #67B138", "( c #6AB339", ") c #6DB838", "_ c #70BA3C", "` c #4D8545", "' c #4E8942", "] c #548851", "[ c #6FAF4A", "{ c #6DB243", "} c #71B546", "| c #70B840", " . c #73B648", ".. c #79BA4E", "X. c #7CBB53", "o. c #598266", "O. c #62886D", "+. c #6A8F75", "@. c #6B9173", "#. c #70937A", "$. c #799F79", "%. c #7BAF66", "&. c #81BD5B", "*. c #85BF60", "=. c #85AC7F", "-. c #8DBA7B", ";. c #87C061", ":. c #8AC364", ">. c #8DC46A", ",. c #90C56E", "<. c #93C771", "1. c #96CA73", "2. c #9ACB7C", "3. c #9FD07D", "4. c #779981", "5. c #7F9F89", "6. c #809F88", "7. c #82A18B", "8. c #86A192", "9. c #8DA994", "0. c #8FA998", "q. c #94AF9B", "w. c #97B991", "e. c #97B19E", "r. c #9DB6A3", "t. c #A3BCA7", "y. c #A6BCAB", "u. c #A9BEB1", "i. c #9ECD81", "p. c #A2CF85", "a. c #A5D284", "s. c #A6D189", "d. c #A9D28E", "f. c #ABD491", "g. c #B1D797", "h. c #B1D699", "j. c #B5D89E", "k. c #ADC5AC", "l. c #B1CAAE", "z. c #B9DAA3", "x. c #BDDDA8", "c. c #ADC1B4", "v. c #B2C6B6", "b. c #B5C6BC", "n. c #B6C9BA", "m. c #BCD1BA", "M. c #C6E1B4", "N. c #CDE5BD", "B. c #C2D2C6", "V. c #CADEC2", "C. c #C6D3CC", "Z. c #C8D7CB", "A. c #CEDAD2", "S. c #D2DDD4", "D. c #D3E9C6", "F. c #D7EBC9", "G. c #D9EBCD", "H. c #DEEED4", "J. c #D6E0D9", "K. c #DAE4DC", "L. c #E0EFD7", "P. c #E5F2DD", "I. c #DFE8E0", "U. c #E4EBE5", "Y. c #E9EFEA", "T. c #EDF4EB", "R. c #F0FAE6", "E. c #F1F8EC", "W. c #EDF0F0", "Q. c #F4F7F3", "!. c #F6F9F4", "~. c #F8FAF7", "^. c #FEFEFE", "/. c None", /* pixels */ "/././././.c h ' Q / W _ &.p././././././././././././././././././././././././././././././././.", "/././.4 O % Z ~ ~ W ~ W R U R R ( X.>.p././././././././././././././././././././././././././.", "/./.. * = J _ ~ ~ ~ ~ ~ / / / / W W U P P U W .;.2././././././././././././././././././././.", "/.= = & a ) W ~ ~ ~ ~ ~ / W / ~ ~ ~ ^ ( ( ^ ~ R R U P Y ~ .;.2././././././././././././././.", "O.O = = T ^ W ~ ~ ~ ~ ~ ~ W W / W ~ ~ ~ ~ ~ ~ ~ ( ( ( ( ~ W Y Y Y Y W { &.1././././././././.", "0 = * 7 ~ ~ ~ ~ ~ ~ ~ ~ ~ / / W ~ ~ ~ ~ ~ ~ ~ ~ W W W ~ ~ ~ ~ ( ( ( W W R U P U W { X.1.f./.", "= = & e ^ W ~ ~ ~ ~ ~ ~ ~ ~ / / ~ ~ ~ ~ ~ ~ ~ ~ W ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ^ ( ( / ~ W R U U Y ", "= = & e ^ W ~ ~ ~ ~ ~ ~ ~ ~ W W ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ W ( W ~ ~ ~ ^ ^ ( ", "= = * e ^ W ~ ~ ~ ~ ~ ~ / W / W ! ( / ~ W ^ ( ( ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ W ~ W W ~ ~ ~ ~ ~ ~ ", "= = & e ^ ! ~ ~ ~ ~ ~ ~ W W ^ _ ~ K Y W W R P Y W ( ~ ~ ~ ~ ~ ~ ~ W / ~ ~ ~ ^ W ~ ~ ~ ~ ~ ~ ", "= = & e ^ W ~ ~ ~ ~ ~ ~ W ) W 1 ` w.V.L.H.D.z.,.~ Y ^ ~ ~ ~ ~ ~ W ~ ~ ~ ( ~ W W ~ ~ ~ ~ ~ ~ ", "= = & e ^ W ~ ~ ~ ~ ~ W ) V = 8.~.^.^.^.^.^.^.^.U.<.Y ~ ~ ~ ~ ~ W W ! ~ Y W ^ W ~ ~ ~ ~ ~ ~ ", "= = & e ^ W ~ ~ ~ ~ W ^ B O u.^.~.^.^.^.^.~.~.^.^.^.h.Y ^ ~ ~ ^ F $ k.R.G.1.Y / ~ ~ ~ ~ ~ ~ ", "= = & e ^ ~ ~ ~ / W ( J X 7.^.~.^.^.^.^.^.^.^.^.^.^.^.s.Y / W ) a 2 U.^.^.d.U ( ~ ~ ~ ~ ~ ~ ", "= = & e ^ W / ~ ~ ~ ^ > w ~.^.^.^.^.^.F.%.v c.^.^.^.^.~.X.W ~ ^ > h ^.^.^.d.P ( ~ ~ ~ ~ ~ ~ ", "= = & e ^ W ~ ~ W ^ H o e.^.^.^.^.^.G.Y E n . y.^.^.^.^.M.Y ( ! $ @.^.~.^.f.U ( / ~ ~ W ~ ~ ", "= = & e ^ W ~ W ! ) t 4 U.^.^.^.^.^.>.U ( _ , 9 ~.^.^.^.~...^ A y.^.~.^.s.M W Y ~ ~ ~ ~ ~ ", "= 3 & e ^ W ~ ( ^ ( $ c ^.^.^.^.^.E.) ~ ~ ^ S o n.^.^.^.^.=.- l.v.Y.^.^.^.M.:.:.X.~ ~ ~ ~ ~ ", "= = & e ^ ! W W ( J X 7.^.^.^.^.^.F.Y ( W ^ T X 6.^.^.~.^.c.. J.^.^.^.^.^.^.^.^.P.~ ~ ~ ~ ~ ", "= = & r ^ W / W ) B o v.^.~.^.^.^.M.U / ~ ~ ! $ o.^.^.^.^.K.* S.^.^.^.^.^.^.^.^.P.~ ~ ~ ~ ~ ", "= = & e ^ ! ~ W ) a + S.^.^.^.^.^.z.P ( W ~ ( % z ^.^.^.^.~.f t.U.^.^.^.^.~.^.^.P.~ ~ ~ ~ ~ ", "* = & e ^ W ~ W ) t 3 Y.^.^.^.^.^.f.P ( ~ ~ ^ ; h ^.^.^.^.^.:.@ j ^.^.^.^.h.{ X.&.~ ~ ~ ~ ~ ", "3 = & e ^ W ~ ~ ^ e 8 Q.^.^.^.^.^.s.P ~ ~ W ^ > 0 ~.^.^.^.^.1.# z ^.^.^.^.d.L W R ~ ~ ~ ~ ~ ", "= = & e ^ W ~ ~ ^ > q ~.^.^.^.^.^.p.U ^ ~ W ) e 9 ~.^.^.^.^.3.# k ^.^.^.^.f.Y ( / ~ ~ ~ ~ ~ ", "= = & e ^ W / W ^ > w ~.^.^.^.^.^.i.Y / ~ W ^ e 8 Q.^.^.^.^.a.# z ^.^.^.^.f.Y / ~ ~ ~ ~ ~ ~ ", "= = & e ^ W / W ^ > w ^.^.^.^.^.^.2.Y / ~ ~ ) e 8 Q.^.^.^.^.s.# z ^.^.^.^.d.P ( ~ ~ ~ ~ ~ ~ ", "= = & e ^ W W W ^ > q ^.^.^.^.^.^.p.Y / ~ ~ ^ e 9 Q.^.^.^.^.a.@ z ^.^.^.^.f.U / ~ ~ ~ ~ ~ ~ ", "= = & e ^ W / W ) 7 9 Q.^.^.^.^.^.a.P / ~ W ) , 9 Q.^.^.^.^.3.# z ^.^.~.^.f.P ^ ~ ~ ~ ~ ~ ~ ", "= = & e ^ W / W ) r 5 T.^.^.^.^.^.d.Y / ~ W ) > q ~.^.^.^.^.1.# k ^.^.^.^.f.Y ( ~ ~ ~ ~ ~ ~ ", "= = & e ^ / / W ) i 2 I.^.^.^.^.^.h.P ( ~ W ( > g ^.^.^.^.^.:.# z ^.^.^.^.f.P / ~ ~ ~ ~ ~ ~ ", "= = & e ( W / W ) m O Z.^.^.^.^.^.x.P / ~ ~ ( ; j ^.^.^.^.~.&.- k ^.^.~.^.f.P / ~ ~ ~ ~ ~ ~ ", "= = & e ( W / W ) F o y.^.~.^.^.^.N.U ( ~ ~ W $ b ^.^.^.^.R._ - k ^.^.^.^.f.Y ( ~ ~ ~ ~ ~ ~ ", "= = & e ^ W ~ ~ ^ J X 4.^.^.^.^.^.L.~ ~ W ^ T X #.^.^.^.^.F.~ ; j ^.^.^.^.f.U ( ~ ~ ~ ~ ~ ~ ", "= = & e ^ ~ ~ ~ / ^ % l ^.^.^.^.^.!. .R ^ ^ G . r.^.~.^.^.j.E : j ^.^.^.^.f.P ) ( ~ ~ ~ ~ ~ ", "= = & e ^ W ~ ~ W ) u = U.^.^.^.^.^.1.Y ! ) a & K.^.^.^.^.;.~ : j ^.^.~.^.z.M I I / ~ ~ W ~ ", "= = & e ( W ~ ~ W ( G . q.^.^.^.^.^.D.U ^ ! X o.^.^.^.^.P.~ ^ > g ^.^.^.^.E.-.$.m.X.W ~ ~ ~ ", "= = & e ^ / ~ ~ ^ ! ( > w ~.^.^.^.^.^.h.T > j T.^.^.~.^.a.Y _ i 3 U.^.^.^.^.^.^.^.X.R ~ ~ ~ ", "= = & e ^ / ~ ~ W W ^ H . 9.^.~.^.^.^.^.K.C.~.^.^.^.^.H.W W ^ T . q.^.~.^.^.^.^.^.X.R ~ ~ ~ ", "= = + e ^ W / ~ W W W ) m + B.^.~.^.^.^.^.^.^.^.^.^.E.X.Y ( W ^ B 6 y.^.^.^.E.D.2.( ~ ~ ~ ~ ", "= = * e ^ ! / ! W ^ W W ) a 4 b.^.^.^.^.^.^.^.^.^.P...Y ( ! W ! ^ W Z [ *.X.{ Y U ~ ~ ~ ~ ~ ", "= = & e ( W ~ ~ W / W / W ) A < +.A.~.^.^.^.^.!.p.W R ~ ~ ~ ~ ~ W / ) E U W W / ^ ~ ~ ~ ~ ~ ", "= = & e ^ W ~ ~ / W / / / W ( _ Z X 6.^.^.^.^.E.W ~ ^ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ / ~ ~ ~ ~ ~ ~ ~ ~ ", "= = & e ^ ~ ~ ~ W W / W ~ ~ ~ ~ ) ; h ^.^.^.^.^.d.M U ~ / ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ W ", "= = & e ^ W ~ ~ ^ W W / ~ ~ ~ W ) p + S.^.^.^.^.~.M.f. .W ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ .", "= = & e ^ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ W ( T O +.^.~.^.^.^.^.^.&.Y ( ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ W ( Y 2.", "= = & e ( W ~ ~ ~ ~ ~ ~ ~ ~ ~ / W ) N + b.^.^.^.^.^.^.&.R ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ W /.", "= = & e ^ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ W ^ N 7 r.W.^.^.^.!.X.W ~ ~ W ~ W ~ ~ ~ ~ ~ ~ / ( ( K p./.", "= = & e ( W ~ ~ W ~ ~ ~ ~ ~ ~ ~ ~ ~ W ( W C Q &.:.X.| ~ ~ ~ ~ W ~ / ~ ( / ( ~ W E U P 1././.", "= = + e ^ / / / ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ W / ) ^ R Y W W ~ ~ ( / ( / W R Y Y U R ( X.,././././.", "= = * e ( / ~ / ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ ~ W W W ! ( ( ( W W E U P Y W ( X.,.d./././././././././.", "= = * e ( W ~ ~ ~ ~ W ! ~ W ~ W ~ ( ( / ^ W W U Y P W ( X.,.d./././././././././././././././.", "8 $ * e ( W ~ ~ ~ ! ( ( ( / ( W R Y Y Y R ( X.>.d./././././././././././././././././././././.", "/.d . y ^ / / / ( W Y Y P P W ( X.>.d./././././././././././././././././././././././././././.", "/./.h : ^ R R R W ( X.<.f./././././././././././././././././././././././././././././././././.", "/././.] _ *.3./././././././././././././././././././././././././././././././././././././././." }; class EvalMessageBox : public QDialog { public: EvalMessageBox(bool expired) { setWindowTitle(QLatin1String(" ")); QString str = expired ? QLatin1String(boilerplate_expired) : qt_eval_string(); str = str.trimmed(); QFrame *border = new QFrame(this); QLabel *pixmap_label = new QLabel(border); pixmap_label->setPixmap(QPixmap(qtlogo_eval_xpm)); pixmap_label->setAlignment(Qt::AlignTop); QLabel *text_label = new QLabel(str, border); QHBoxLayout *pm_and_text_layout = new QHBoxLayout(); pm_and_text_layout->addWidget(pixmap_label); pm_and_text_layout->addWidget(text_label); QVBoxLayout *master_layout = new QVBoxLayout(border); master_layout->addLayout(pm_and_text_layout); QVBoxLayout *border_layout = new QVBoxLayout(this); border_layout->setMargin(0); border_layout->addWidget(border); if (expired) { QPushButton *cmd = new QPushButton(QLatin1String("OK"), border); cmd->setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed); cmd->setDefault(true); QHBoxLayout *button_layout = new QHBoxLayout(); master_layout->addLayout(button_layout); button_layout->addWidget(cmd); connect(cmd, SIGNAL(clicked()), this, SLOT(close())); } else { border->setFrameShape(QFrame::WinPanel); border->setFrameShadow(QFrame::Raised); setParent(parentWidget(), Qt::FramelessWindowHint | Qt::WindowStaysOnTopHint); QTimer::singleShot(7000, this, SLOT(close())); setAttribute(Qt::WA_DeleteOnClose); setAttribute(Qt::WA_QuitOnClose, false); } setFixedSize(sizeHint()); } }; class QGuiFuriCuri : public QCoreFuriCuri { public: void timerEvent(QTimerEvent *e) { if (e->timerId() == warn) { killTimer(warn); QMessageBox::information(0, QLatin1String("Automatic Timeout"), QLatin1String(will_shutdown_1min)); kill = startTimer(KILL_DELAY); } else if (e->timerId() == kill) { killTimer(kill); QMessageBox::information(0, QLatin1String("Automatic Timeout"), QLatin1String(will_shutdown_now)); qApp->quit(); } } }; void qt_gui_eval_init(QCoreApplicationPrivate::Type type) { Q_UNUSED(type); if (!qt_eval_is_supported()) return; if (qt_eval_is_expired()) { EvalMessageBox box(true); box.exec(); ::exit(0); } else { Q_UNUSED(new QGuiFuriCuri()); } } static QString qt_eval_title_prefix() { return QLatin1String("[Qt Evaluation] "); } QString qt_eval_adapt_window_title(const QString &title) { if (!qt_eval_is_supported()) return title; return qt_eval_title_prefix() + title; } void qt_eval_init_widget(QWidget *w) { if (!qt_eval_is_supported()) return; if (w->isTopLevel() && w->windowTitle().isEmpty() && w->windowType() != Qt::Desktop ) { w->setWindowTitle(QLatin1String(" ")); } } #endif QT_END_NAMESPACE
[ "p_pavlov@wargaming.net" ]
p_pavlov@wargaming.net
a44b960c9548c2edda0e775d185032df1b342c89
457e4f3a594fcbfd4bc4926b76f2cabde6438e32
/src/strat_z_vr_scout.h
29e7d270e34f97cbb351d50ddf4115f21dc2efd6
[]
no_license
tscmoo/tsc-bwai
a968f3621356ab47adc708079a3ca0cf9f86892a
6c93fd0877da55b101c8b48a8ac5d7bce60561f6
refs/heads/master
2021-01-10T21:10:41.293712
2015-11-21T23:34:23
2015-11-21T23:34:23
28,252,875
61
8
null
null
null
null
UTF-8
C++
false
false
1,478
h
struct strat_z_vr_scout : strat_z_base { virtual void init() override { sleep_time = 8; scouting::scout_supply = 20; } virtual bool tick() override { if (opening_state == 0) { if (my_resource_depots.size() != 1 || my_workers.size() != 4) opening_state = -1; else { build::add_build_task(0.0, unit_types::drone); build::add_build_task(0.0, unit_types::drone); build::add_build_task(0.0, unit_types::drone); build::add_build_task(0.0, unit_types::drone); build::add_build_task(0.0, unit_types::drone); build::add_build_task(0.0, unit_types::overlord); ++opening_state; } } else if (opening_state != -1) { if (bo_all_done()) { opening_state = -1; } } int scouts = 0; if (start_locations.size() <= 2) { if (current_used_total_supply >= 7) scouts = 1; } else { if (current_used_total_supply >= 6) scouts = 1; if (current_used_total_supply >= 8) scouts = 2; } if ((int)scouting::all_scouts.size() < scouts) { unit*scout_unit = get_best_score(my_workers, [&](unit*u) { if (u->controller->action != unit_controller::action_gather) return std::numeric_limits<double>::infinity(); return 0.0; }, std::numeric_limits<double>::infinity()); if (scout_unit) scouting::add_scout(scout_unit); } if (!players::opponent_player->random) { rm_all_scouts(); } return !players::opponent_player->random; } virtual bool build(buildpred::state&st) override { return false; } };
[ "the.dengus@gmail.com" ]
the.dengus@gmail.com
5284f9400da73d35c19ce552499d80a97464048f
a4f29d2168ba76782ed746b136a4e783bc14ba5c
/VideoSlicer/Main.cpp
467700e70158a545191611f0dde29564c5c05f71
[ "MIT" ]
permissive
daramkun/VideoSlicer
7952f9b3d599c4647d0578fb1165125f5ac45397
5974649ad64cf424bca653868b6147efb382d738
refs/heads/master
2020-03-11T12:43:28.476855
2018-04-30T07:24:34
2018-04-30T07:24:34
130,005,377
0
0
null
null
null
null
UTF-8
C++
false
false
11,647
cpp
#define _CRT_SECURE_NO_WARNINGS #ifdef _DEBUG # define _CRTDBG_MAP_ALLOC # include <cstdlib> # include <crtdbg.h> #endif #include <string> #include <Windows.h> #include <CommCtrl.h> #include <ShlObj.h> #include <atlbase.h> #include <VersionHelpers.h> #include "Resources/resource.h" #include "Video/VideoDecoder.h" #include "Image/ImageEncoder.h" #include "ThreadPool.h" #pragma comment ( lib, "comctl32.lib" ) enum SAVEFILEFORMAT { SFF_PNG = 201, SFF_JPEG_100 = 202, SFF_JPEG_80 = 203, SFF_JPEG_60 = 204, }; std::wstring g_openedVideoFile; std::wstring g_saveTo; bool g_isStarted; double g_progress; HANDLE g_thread; DWORD g_threadId; SAVEFILEFORMAT g_saveFileFormat = SFF_JPEG_100; std::wstring ConvertTimeStamp ( LONGLONG nanosec, LPCWSTR ext ) noexcept { UINT millisec = ( UINT ) ( nanosec / 10000 ); UINT hour = millisec / 1000 / 60 / 60; millisec -= hour * 1000 * 60 * 60; UINT minute = millisec / 1000 / 60; millisec -= minute * 1000 * 60; UINT second = millisec / 1000; millisec -= second * 1000; wchar_t temp [ 256 ]; wsprintf ( temp, TEXT ( "%02dː%02dː%02d˙%03d.%s" ), hour, minute, second, millisec, ext ); return temp; } void ErrorExit ( HWND owner, unsigned exitCode ) { TaskDialog ( owner, nullptr, TEXT ( "오류" ), TEXT ( "오류가 발생했습니다." ), TEXT ( "Windows가 N 또는 KN 에디션이면서 미디어 기능 팩이 설치되어 있지 않거나, 동영상 파일이 잘못된 것으로 보입니다." ), TDCBF_OK_BUTTON, TD_ERROR_ICON, nullptr ); ExitProcess ( exitCode ); } bool EncodingImageToFile ( IVideoSample * readedSample, LONGLONG readedTimeStamp, UINT width, UINT height, UINT stride ) noexcept { CComPtr<IVideoSample> sample; *&sample = readedSample; BYTE * colorBuffer; uint64_t colorBufferLength; if ( FAILED ( sample->Lock ( ( LPVOID* ) &colorBuffer, &colorBufferLength ) ) ) return false; std::wstring filename = ConvertTimeStamp ( readedTimeStamp, g_saveFileFormat == SFF_PNG ? TEXT ( "png" ) : TEXT ( "jpg" ) ); wchar_t outputPath [ MAX_PATH ]; PathCombine ( outputPath, g_saveTo.c_str (), filename.c_str () ); ImageEncoderSettings settings; switch ( g_saveFileFormat ) { case SFF_PNG: settings.codecType = IEC_PNG; settings.settings.png.interlace = false; settings.settings.png.filtering = true; break; case SFF_JPEG_100: settings.codecType = IEC_JPEG; settings.settings.jpeg.quality = 1.0f; settings.settings.jpeg.chromaSubsample = false; break; case SFF_JPEG_80: settings.codecType = IEC_JPEG; settings.settings.jpeg.quality = 0.8f; settings.settings.jpeg.chromaSubsample = true; break; case SFF_JPEG_60: settings.codecType = IEC_JPEG; settings.settings.jpeg.quality = 0.6f; settings.settings.jpeg.chromaSubsample = true; break; } settings.imageProp.width = width; settings.imageProp.height = height; settings.imageProp.stride = stride; if ( FAILED ( SaveImage ( outputPath, &settings, colorBuffer, colorBufferLength ) ) ) { sample->Unlock (); return false; } sample->Unlock (); return true; } DWORD WINAPI DoSushi ( LPVOID ) noexcept { CComPtr<IVideoDecoder> videoDecoder; //if ( FAILED ( CreateMediaFoundationVideoDecoder ( &videoDecoder ) ) ) if ( FAILED ( CreateFFmpegVideoDecoder ( &videoDecoder ) ) ) { ErrorExit ( nullptr, -5 ); return -1; } if ( FAILED ( videoDecoder->Initialize ( g_openedVideoFile.c_str () ) ) ) { ErrorExit ( nullptr, -5 ); return -1; } uint64_t duration; if ( FAILED ( videoDecoder->GetDuration ( &duration ) ) ) { ErrorExit ( nullptr, -5 ); return -1; } uint32_t width, height, stride; if ( FAILED ( videoDecoder->GetVideoSize ( &width, &height, &stride ) ) ) { ErrorExit ( nullptr, -5 ); return -1; } g_progress = 0; g_isStarted = true; { ThreadPool threadPool ( std::thread::hardware_concurrency () ); while ( g_isStarted ) { if ( threadPool.taskSize () >= std::thread::hardware_concurrency () * 4 ) { Sleep ( 1 ); continue; } uint64_t readedTimeStamp = 0; CComPtr<IVideoSample> readedSample; if ( FAILED ( videoDecoder->ReadSample ( &readedSample, &readedTimeStamp ) ) ) continue; if ( nullptr == readedSample ) break; auto result = threadPool.enqueue ( EncodingImageToFile, readedSample.Detach (), readedTimeStamp, width, height, stride ); g_progress = ( readedTimeStamp / 10000 ) / ( double ) ( duration / 10000 ); } } g_progress = 1; return 0; } int WINAPI WinMain ( HINSTANCE hInstance, HINSTANCE, LPSTR, int ) { #ifdef _DEBUG _CrtSetDbgFlag ( _CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK_CHECK_DF ); #endif if ( !IsWindows7OrGreater () ) { MessageBox ( nullptr, TEXT ( "이 프로그램은 Windows 7 이상만 대응하고 있습니다." ), TEXT ( "오류" ), MB_OK ); return -1; } if ( FAILED ( CoInitializeEx ( nullptr, COINIT_APARTMENTTHREADED ) ) ) return -1; HICON hIcon = LoadIcon ( hInstance, MAKEINTRESOURCE ( IDI_MAIN_ICON ) ); TASKDIALOG_BUTTON buttonArray [] = { { 101, TEXT ( "동영상 선택하기" ) }, { 102, TEXT ( "저장할 경로 지정하기" ) }, }; TASKDIALOG_BUTTON radioButtonArray [] = { { 201, TEXT ( "PNG로 저장하기" ) }, { 202, TEXT ( "JPEG로 저장하기(100% 화질)" ) }, { 203, TEXT ( "JPEG로 저장하기(80% 화질)" ) }, { 204, TEXT ( "JPEG로 저장하기(60% 화질)" ) }, }; TASKDIALOGCONFIG mainConfig = { 0, }; mainConfig.cbSize = sizeof ( TASKDIALOGCONFIG ); mainConfig.hInstance = hInstance; mainConfig.hMainIcon = hIcon; mainConfig.dwFlags = TDF_ENABLE_HYPERLINKS | TDF_USE_HICON_MAIN | TDF_USE_COMMAND_LINKS | TDF_SHOW_PROGRESS_BAR | TDF_CALLBACK_TIMER; mainConfig.pszWindowTitle = TEXT ( "영상 회뜨는 프로그램" ); mainConfig.pszMainInstruction = TEXT ( "영상 회 떠드립니다." ); mainConfig.pszContent = TEXT ( "지정된 경로에 선택한 동영상을 회떠서 프레임 하나하나 이미지 파일로 정성스럽게 저장해드립니다. 확인 버튼을 누르면 회 뜨기가 시작됩니다." ); mainConfig.pszFooter = TEXT ( "이 프로그램은 Windows N/KN 에디션에서는 동작하지 않습니다. KN 및 N 에디션에서 구동하려면 아래 링크에서 소프트웨어를 설치해주세요.\n<A HREF=\"https://www.microsoft.com/ko-kr/download/details.aspx?id=16546\">Windows 7용 미디어 기능 팩</A>\n<A HREF=\"https://www.microsoft.com/ko-kr/download/details.aspx?id=40744\">Windows 8.1용 미디어 기능 팩</A>\n<A HREF=\"https://www.microsoft.com/ko-kr/download/details.aspx?id=48231\">Windows 10용 미디어 기능 팩</A>" ); mainConfig.pButtons = buttonArray; mainConfig.cButtons = _countof ( buttonArray ); mainConfig.pRadioButtons = radioButtonArray; mainConfig.cRadioButtons = _countof ( radioButtonArray ); mainConfig.nDefaultRadioButton = 202; mainConfig.dwCommonButtons = TDCBF_OK_BUTTON | TDCBF_CANCEL_BUTTON; mainConfig.pfCallback = [] ( HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam, LONG_PTR lpRefData ) -> HRESULT { switch ( msg ) { case TDN_CREATED: { SendMessage ( hWnd, TDM_ENABLE_BUTTON, IDOK, FALSE ); SendMessage ( hWnd, TDM_ENABLE_BUTTON, 102, FALSE ); } break; case TDN_BUTTON_CLICKED: { if ( wParam == 101 ) { CComPtr<IFileOpenDialog> dialog; if ( FAILED ( CoCreateInstance ( CLSID_FileOpenDialog, nullptr, CLSCTX_ALL, IID_IFileOpenDialog, ( void ** ) &dialog ) ) ) ErrorExit ( nullptr, -3 ); COMDLG_FILTERSPEC fileTypes [] = { { TEXT ( "지원하는 모든 파일(*.mp4;*.m4v;*.avi;*.wmv)" ), TEXT ( "*.mp4;*.m4v;*.avi;*.wmv" ) }, }; dialog->SetFileTypes ( _countof ( fileTypes ), fileTypes ); dialog->SetOptions ( FOS_FILEMUSTEXIST | FOS_FORCEFILESYSTEM | FOS_NOTESTFILECREATE ); if ( FAILED ( dialog->Show ( hWnd ) ) ) return 2; IShellItem * selectedItem; if ( FAILED ( dialog->GetResult ( &selectedItem ) ) ) ErrorExit ( nullptr, -4 ); PWSTR filePath; if ( FAILED ( selectedItem->GetDisplayName ( SIGDN_FILESYSPATH, &filePath ) ) ) { ErrorExit ( nullptr, -4 ); return 0; } ::g_openedVideoFile = filePath; CoTaskMemFree ( filePath ); SendMessage ( hWnd, TDM_ENABLE_BUTTON, 101, FALSE ); SendMessage ( hWnd, TDM_ENABLE_BUTTON, 102, TRUE ); return 1; } else if ( wParam == 102 ) { CComPtr<IFileOpenDialog> dialog; if ( FAILED ( CoCreateInstance ( CLSID_FileOpenDialog, nullptr, CLSCTX_ALL, IID_IFileOpenDialog, ( void ** ) &dialog ) ) ) ErrorExit ( nullptr, -3 ); dialog->SetOptions ( FOS_PATHMUSTEXIST | FOS_PICKFOLDERS | FOS_FORCEFILESYSTEM | FOS_NOTESTFILECREATE ); if ( FAILED ( dialog->Show ( hWnd ) ) ) return 2; IShellItem * selectedItem; if ( FAILED ( dialog->GetResult ( &selectedItem ) ) ) ErrorExit ( nullptr, -4 ); PWSTR filePath; if ( FAILED ( selectedItem->GetDisplayName ( SIGDN_FILESYSPATH, &filePath ) ) ) { ErrorExit ( nullptr, -4 ); return 0; } ::g_saveTo = filePath; CoTaskMemFree ( filePath ); SendMessage ( hWnd, TDM_ENABLE_BUTTON, 102, FALSE ); SendMessage ( hWnd, TDM_ENABLE_BUTTON, IDOK, TRUE ); return 1; } else if ( wParam == IDOK ) { SendMessage ( hWnd, TDM_ENABLE_BUTTON, IDOK, FALSE ); ::g_thread = CreateThread ( nullptr, 0, DoSushi, nullptr, 0, &g_threadId ); return 1; } else if ( wParam == IDCANCEL ) { TASKDIALOGCONFIG askDialog = { 0, }; askDialog.cbSize = sizeof ( TASKDIALOGCONFIG ); askDialog.pszMainIcon = TD_WARNING_ICON; askDialog.hwndParent = hWnd; askDialog.pszWindowTitle = TEXT ( "질문" ); askDialog.pszMainInstruction = TEXT ( "종료하시겠습니까?" ); askDialog.pszContent = TEXT ( "진행 중이던 작업을 모두 잃게 됩니다." ); askDialog.dwCommonButtons = TDCBF_YES_BUTTON | TDCBF_NO_BUTTON; int button; HRESULT hr; if ( FAILED ( hr = TaskDialogIndirect ( &askDialog, &button, nullptr, nullptr ) ) ) return 0; if ( button == IDNO ) return 1; if ( ::g_thread != NULL ) { g_isStarted = false; WaitForSingleObject ( g_thread, INFINITE ); } } } break; case TDN_RADIO_BUTTON_CLICKED: { ::g_saveFileFormat = ( SAVEFILEFORMAT ) wParam; } break; case TDN_HYPERLINK_CLICKED: { ShellExecute ( nullptr, TEXT ( "open" ), ( LPWSTR ) lParam, nullptr, nullptr, SW_SHOW ); } break; case TDN_TIMER: { if ( !::g_isStarted ) return 1; SendMessage ( hWnd, TDM_SET_PROGRESS_BAR_RANGE, 0, MAKELPARAM ( 0, 100 ) ); SendMessage ( hWnd, TDM_SET_PROGRESS_BAR_POS, ( WPARAM ) ( ::g_progress * 100 ), 0 ); if ( abs ( ::g_progress - 1 ) <= FLT_EPSILON ) { TASKDIALOGCONFIG taskDialog = { 0, }; taskDialog.cbSize = sizeof ( TASKDIALOGCONFIG ); taskDialog.pszMainIcon = TD_INFORMATION_ICON; taskDialog.pszWindowTitle = TEXT ( "안내" ); taskDialog.pszMainInstruction = TEXT ( "작업이 완료되었습니다." ); taskDialog.pszContent = TEXT ( "작업이 완료되어 프로그램을 종료합니다." ); taskDialog.dwCommonButtons = TDCBF_OK_BUTTON; SendMessage ( hWnd, TDM_NAVIGATE_PAGE, 0, ( LPARAM ) &taskDialog ); } } break; } return 0; }; if ( FAILED ( TaskDialogIndirect ( &mainConfig, nullptr, nullptr, nullptr ) ) ) return -2; CoUninitialize (); return 0; }
[ "daramkun@live.com" ]
daramkun@live.com
72b14e9a494aed21665075ead044f6a4a037b090
4f737986d3cee71075e8f9adb5e90cc661333284
/usaco/ch3/stamps.cpp
9a51108bdcb8549780d3993b01c68b9d9830682b
[]
no_license
piyushmh/online-judge
ebb977f58ac934439281ef067a9e71e061e8775a
eac7b10922c9aa0022363ee26cd0d2ce81200008
refs/heads/master
2020-12-02T16:30:06.100863
2014-01-25T23:28:08
2014-01-25T23:28:08
null
0
0
null
null
null
null
UTF-8
C++
false
false
1,934
cpp
/* ID: piyushi1 LANG: C++ TASK: stamps */ #include <stdio.h> #include<iostream> #include<algorithm> #include<vector> #include<cstdio> #include<fstream> #include<string> #include<sstream> #include<map> #include<memory.h> #include<queue> #include<set> #include<assert.h> #include<time.h> #include<math.h> #include<cstdlib> //#include"graph.h" // https://github.com/codetrash/algorithms/blob/master/algorithms/src/graph/graph.h using namespace std; typedef vector<int>::iterator vit; typedef pair<int,int> pii; typedef pair<long,long> pll; typedef vector<int> vi; typedef long long ll; #define rep(i,a) repab(i,0,a) #define repab(i,a,b) repabc(i,a,b,1) #define repabc(i,a,b,c) for(int i=a;i<b;i+=c) #define foreach(i,a) for(typeof((a).begin()) i=(a).begin();i!=(a).end();i++) #define FOR(i,a,b) for(int i = a; i<b; i++) #define mod(x) ((x>0)?x:(-x)) //#define SS ({int x;scanf("%d",&x);x;}) #define mp make_pair #define pb push_back #define fill(a,i) (memset(a,i, sizeof(a))) inline int SS(){int x; scanf("%d",&x); return x;} #define EPS 10e-7 #define INF 1000000000 void fileInit(){ #ifdef DEBUG freopen("input.txt","r", stdin); #endif #ifndef DEBUG freopen("stamps.in","r", stdin); freopen("stamps.out","w", stdout); #endif } /* Global variable */ #define MAX 2000001 int K,N; int dp[MAX]; int stamp[55]; /* End */ #define CLOCK int main(){ #ifdef CLOCK int start = clock(); #endif fileInit(); /* Main code begins*/ K = SS(); N = SS(); FOR(i,0,N) stamp[i] = SS(); //Here is a O(k*N*MAX) solution which goes out of memory and time both - http://ideone.com/xbzmx7 // O(MAX*N) dp[0] = 0; FOR(i,1,MAX){ dp[i] = INF; FOR(j,0,N){ if((i-stamp[j])>=0){ dp[i] = min(dp[i], dp[i-stamp[j]]+1); } } } int i; for(i=1; i< MAX; i++) if(dp[i]>K) break; cout<<i-1<<endl; /* Main code ends*/ #ifdef CLOCK int end = clock(); cout<<endl<<((float)(end - start))/CLOCKS_PER_SEC; #endif return 0; }
[ "piyushisnow@gmail.com" ]
piyushisnow@gmail.com
2969a77e5300bac5245759bbeefcb08ac17095aa
99224dbbfcd7558a31851c862fb8c1721703f338
/exercises/sources/exercise09-2/02561-08_09/main-08_09.cpp
f6303a596c47af2d9e1faaf666d407f23f623b8b
[]
no_license
balabanmetin/DTU-02561-OpenGL-ComputerGraphics
2b4c94d20443908171beab6f92c7a9762598f906
f7d723cdc722552a0a27c647d526ae6cab1e6bb2
refs/heads/master
2021-01-23T08:56:27.394096
2014-01-18T13:05:48
2014-01-18T13:05:48
null
0
0
null
null
null
null
UTF-8
C++
false
false
17,433
cpp
// 02561-08-01 / 02561-09-01 #include <iostream> #include <string> #include <algorithm> #include <GL/glew.h> #include <GL/freeglut.h> #include "Angel.h" #include "ObjLoader.h" #include "TextureLoader.h" using namespace std; using namespace Angel; #define RADIAN_TO_DEGREE 57.2957795f int WINDOW_WIDTH = 500; int WINDOW_HEIGHT = 500; int SHADOW_MAP_SIZE = 1024; struct Shader { GLuint shaderProgram; GLuint projectionUniform, modelUniform, viewUniform, lightViewProjectionUniform, normalMatUniform, textureUniform, texture2Uniform, pointLightPosUniform, colorUniform, clipPlaneUniform; GLuint positionAttribute, normalAttribute, textureCoordinateAttribute; }; struct MeshObject { Shader shader; GLuint vertexArrayObject; vector<int> indices; vec4 color; MeshObject():color(1,1,1,1){} MeshObject(Shader shader, GLuint vertexArrayObject, vector<int> indices) :shader(shader),vertexArrayObject(vertexArrayObject),indices(indices),color(1,1,1,1){ } }; vec3 teapotPosition; vec3 lightPosition(0,300,0); int shadow_type = 1; // 0 Flattening, 1 projected bool draw_mirror = 1; // draw mirror bool freeze = false; bool debugShadowMap = false; struct Vertex { vec3 position; vec3 normal; vec2 textureCoordinate; }; MeshObject planeObject; MeshObject teapotObject; float teapotBoundingRadius; GLuint planeTextureId, shadowmapTextureId; GLuint frameBufferObject; // spherical coordinates of camera position (angles in radian) float sphericalPolarAngle = 45; float sphericalElevationAngle = 45; float sphericalRadius = 600; vec2 mousePos; vec4 clipPlane(0,-1,0,0); // forward declaration void loadShader(); void display(); vec3 sphericalToCartesian(float polarAngle, float elevationAngle, float radius); GLuint createVertexBuffer(Vertex* vertices, int vertexCount); string getFrameBufferStatusString(GLenum code); void drawMeshObject(mat4 & projection, mat4 & model, mat4 & view, mat4 & lightViewProjection, MeshObject& meshObject); mat4 getLightProjection() { float d=length(teapotPosition-lightPosition); // cout << d << " " << p << endl; float theta = asin(teapotBoundingRadius/d)*RADIAN_TO_DEGREE; // cout << theta << endl; mat4 perspective = Perspective(2*theta, 1, 0.1, 400. ); return perspective; } mat4 getLightView() { return LookAt(lightPosition, teapotPosition, vec3(0,1,0)); } mat4 getLightViewProjection(){ return getLightProjection() * getLightView(); } void updateProjShadowTexture() { // todo bind framebuffer, set viewport to shadowmap and clear to white glBindFramebuffer(GL_FRAMEBUFFER, frameBufferObject); glViewport(0, 0, SHADOW_MAP_SIZE, SHADOW_MAP_SIZE); glClearColor(1.0, 1.0, 1.0, 1.0); glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT ); vec4 old_color_of_teapot = teapotObject.color; teapotObject.color=vec4(.0 , .0 , .0 , 1.0); mat4 projection = getLightProjection(); mat4 view = getLightView(); mat4 lightViewProjection = getLightViewProjection(); mat4 model = Translate(teapotPosition); drawMeshObject(projection, model, view, lightViewProjection, teapotObject); // todo render black teapot teapotObject.color=old_color_of_teapot; glBindFramebuffer(GL_FRAMEBUFFER, 0); glViewport(0, 0, WINDOW_WIDTH, WINDOW_HEIGHT); // todo release framebuffer, setviewport to window } float computeRadius(vector<vec3> position) { float maxRadius = 0; for (int i=0;i<position.size();i++){ maxRadius = max(maxRadius,length(position[i])); } return maxRadius; } GLuint buildPlaneVertexBuffer() { const int planeSize = 4; Vertex planeData[planeSize] = { { vec3(-200, 0.0, -200 ), vec3(0,1,0), vec2(0,0) }, { vec3(-200, 0.0, 200 ), vec3(0,1,0), vec2(0,1) }, { vec3( 200, 0.0, 200 ), vec3(0,1,0), vec2(1,1) }, { vec3( 200, 0.0, -200 ), vec3(0,1,0), vec2(1,0) } }; return createVertexBuffer(planeData, planeSize); } vector<int> buildPlaneIndices() { vector<int> res; res.push_back(0); res.push_back(1); res.push_back(2); res.push_back(0); res.push_back(2); res.push_back(3); return res; } GLuint buildTexture(int width, int height) { GLuint textureId; // generate texture glGenTextures(1, &textureId); glBindTexture(GL_TEXTURE_2D, textureId); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE); glPixelStorei(GL_UNPACK_ALIGNMENT, 1); GLuint internalFormat = GL_RED; GLuint format = GL_RED; GLuint storageType = GL_UNSIGNED_BYTE; glTexImage2D(GL_TEXTURE_2D, 0, internalFormat, width, height, 0, format, storageType, NULL); glBindTexture(GL_TEXTURE_2D, 0); return textureId; } GLuint buildFrameBufferObject(int width, int height, GLuint textureId) { GLuint framebufferObjectId, renderBufferId; glGenFramebuffers(1, &framebufferObjectId); glGenRenderbuffers(1, &renderBufferId); glBindRenderbuffer(GL_RENDERBUFFER, renderBufferId); glRenderbufferStorage(GL_RENDERBUFFER, GL_DEPTH_COMPONENT24, width, height); glBindFramebuffer(GL_FRAMEBUFFER, framebufferObjectId); glFramebufferTexture2D(GL_FRAMEBUFFER, GL_COLOR_ATTACHMENT0, GL_TEXTURE_2D, textureId, 0); glFramebufferRenderbuffer(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT, GL_RENDERBUFFER, renderBufferId); GLenum frameBufferRes = glCheckFramebufferStatus(GL_FRAMEBUFFER); cout << getFrameBufferStatusString(frameBufferRes)<<endl; glBindFramebuffer(GL_FRAMEBUFFER, 0); return framebufferObjectId; } GLuint createVertexArrayObject(GLuint vertexBuffer, const Shader & shader) { glBindBuffer(GL_ARRAY_BUFFER, vertexBuffer); GLuint vertexArrayObject; glGenVertexArrays(1, &vertexArrayObject); glBindVertexArray(vertexArrayObject); glEnableVertexAttribArray(shader.positionAttribute); glVertexAttribPointer(shader.positionAttribute, 3, GL_FLOAT, GL_FALSE, sizeof(Vertex), (const GLvoid *)0); if (shader.normalAttribute != GL_INVALID_INDEX) { glEnableVertexAttribArray(shader.normalAttribute); glVertexAttribPointer(shader.normalAttribute, 3, GL_FLOAT, GL_FALSE, sizeof(Vertex), (const GLvoid *)sizeof(vec3)); } if (shader.textureCoordinateAttribute != GL_INVALID_INDEX) { glEnableVertexAttribArray(shader.textureCoordinateAttribute); glVertexAttribPointer(shader.textureCoordinateAttribute, 2, GL_FLOAT, GL_FALSE, sizeof(Vertex), (const GLvoid *)(sizeof(vec3)*2)); } return vertexArrayObject; } GLuint createVertexBuffer(Vertex* vertices, int vertexCount) { GLuint vertexBuffer; glGenBuffers(1, &vertexBuffer); glBindBuffer(GL_ARRAY_BUFFER, vertexBuffer); glBufferData(GL_ARRAY_BUFFER, vertexCount * sizeof(Vertex), vertices, GL_STATIC_DRAW); return vertexBuffer; } GLuint loadMesh(char *filename, vector<int> &indices, float scale = 1.0){ vector<vec3> position; vector<vec3> normal; vector<vec2> uv; loadObject(filename,position,indices,normal,uv, scale); Vertex* vertexData = new Vertex[position.size()]; teapotBoundingRadius = computeRadius(position); for (int i = 0; i < position.size(); i++) { vertexData[i].position = position[i]; if (normal.size() > 0){ vertexData[i].normal = normal[i]; } } GLuint vertexBuffer = createVertexBuffer(vertexData, position.size()); delete [] vertexData; return vertexBuffer; } Shader loadShader(const char* vertShader, const char* fragShader) { Shader shader; shader.shaderProgram = InitShader(vertShader, fragShader, "fragColor"); // get uniform locations shader.projectionUniform = glGetUniformLocation(shader.shaderProgram, "projection"); shader.viewUniform = glGetUniformLocation(shader.shaderProgram, "view"); shader.modelUniform = glGetUniformLocation(shader.shaderProgram, "model"); shader.lightViewProjectionUniform = glGetUniformLocation(shader.shaderProgram, "lightViewProjection"); shader.textureUniform = glGetUniformLocation(shader.shaderProgram, "texture1"); shader.texture2Uniform = glGetUniformLocation(shader.shaderProgram, "texture2"); shader.pointLightPosUniform = glGetUniformLocation(shader.shaderProgram, "pointLightPos"); shader.colorUniform = glGetUniformLocation(shader.shaderProgram, "color"); shader.normalMatUniform = glGetUniformLocation(shader.shaderProgram, "normalMat"); shader.clipPlaneUniform = glGetUniformLocation(shader.shaderProgram, "clipPlane"); // get attribute locations shader.positionAttribute = glGetAttribLocation(shader.shaderProgram, "position"); shader.normalAttribute = glGetAttribLocation(shader.shaderProgram, "normal"); shader.textureCoordinateAttribute = glGetAttribLocation(shader.shaderProgram, "textureCoordinate"); return shader; } void drawMeshObject(mat4 & projection, mat4 & model,mat4 & view, mat4 & lightViewProjection, MeshObject& meshObject) { glUseProgram(meshObject.shader.shaderProgram); if (meshObject.shader.projectionUniform != GL_INVALID_INDEX){ glUniformMatrix4fv(meshObject.shader.projectionUniform, 1, GL_TRUE, projection); } if (meshObject.shader.modelUniform != GL_INVALID_INDEX){ glUniformMatrix4fv(meshObject.shader.modelUniform, 1, GL_TRUE, model); } if (meshObject.shader.viewUniform != GL_INVALID_INDEX){ glUniformMatrix4fv(meshObject.shader.viewUniform, 1, GL_TRUE, view); } if (meshObject.shader.lightViewProjectionUniform!= GL_INVALID_INDEX){ glUniformMatrix4fv(meshObject.shader.lightViewProjectionUniform, 1, GL_TRUE, lightViewProjection); } if (meshObject.shader.normalMatUniform != GL_INVALID_INDEX) { mat3 normalMat = Normal(model); glUniformMatrix3fv(meshObject.shader.normalMatUniform, 1, GL_TRUE, normalMat); } if (meshObject.shader.pointLightPosUniform != GL_INVALID_INDEX) { glUniform3fv(meshObject.shader.pointLightPosUniform, 1, lightPosition); } if (meshObject.shader.colorUniform != GL_INVALID_INDEX){ glUniform4fv(meshObject.shader.colorUniform, 1, meshObject.color); } if (meshObject.shader.clipPlaneUniform != GL_INVALID_INDEX){ glUniform4fv(meshObject.shader.clipPlaneUniform, 1, clipPlane); } if (meshObject.shader.textureUniform != GL_INVALID_INDEX){ // bind texture to texture slot 0 and set the uniform value glActiveTexture(GL_TEXTURE0); glBindTexture(GL_TEXTURE_2D, debugShadowMap?shadowmapTextureId:planeTextureId); glUniform1i(meshObject.shader.textureUniform, 0); } if (meshObject.shader.texture2Uniform != GL_INVALID_INDEX){ // bind texture to texture slot 0 and set the uniform value glActiveTexture(GL_TEXTURE1); glBindTexture(GL_TEXTURE_2D, shadowmapTextureId); glUniform1i(meshObject.shader.texture2Uniform, 1); } glBindVertexArray(meshObject.vertexArrayObject); glDrawElements(GL_TRIANGLES, meshObject.indices.size(), GL_UNSIGNED_INT, &meshObject.indices[0]); } void drawMirror(mat4 &projection, mat4 &view) { // todo implement // glEnable (GL_BLEND); // glBlendFunc(GL_ONE_MINUS_DST_ALPHA,GL_DST_ALPHA); mat4 model = Scale (1, -1, 1) * Translate(teapotPosition); lightPosition.y = -lightPosition.y; teapotObject.color-=0.5; drawMeshObject(projection, model, view, getLightViewProjection(),teapotObject); teapotObject.color+=0.5; lightPosition.y = -lightPosition.y; // glDisable(GL_BLEND); } void drawPlane(mat4 projection, mat4 view) { if (draw_mirror == 1) { drawMirror(projection, view); } glEnable (GL_BLEND); glBlendFunc(GL_ONE,GL_ONE); mat4 model; drawMeshObject(projection, model, view, getLightViewProjection(), planeObject); glDisable(GL_BLEND); //glDisable(GL_BLEND); } void display() { // update teapot position static int counter = 42; teapotPosition.x = sin(counter / 180.0f * M_PI) * 120 + cos(counter / 70.0f * M_PI) * 50; teapotPosition.y = cos(counter / 180.0f * M_PI) * 40 + sin(counter / 70.0f * M_PI) * 40; teapotPosition.z = cos(counter / 180.0f * M_PI) * 120 + cos(counter / 70.0f * M_PI) * 50; if (!freeze){ counter++; } if (shadow_type == 1) { updateProjShadowTexture(); } glClearColor(0.0, 0.0, 0.0, 1.0); glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT | GL_STENCIL_BUFFER_BIT); mat4 projection = Perspective(60,WINDOW_WIDTH/(float)WINDOW_HEIGHT,1.5,1000); vec4 eye = sphericalToCartesian(sphericalPolarAngle, sphericalElevationAngle, sphericalRadius); vec4 at(0,0,0,1); vec4 up(0,1,0,0); mat4 view = LookAt(eye, at, up); drawPlane(projection, view); mat4 model = Translate(teapotPosition); drawMeshObject(projection, model, view, getLightViewProjection(),teapotObject); glutSwapBuffers(); Angel::CheckError(); } void reshape(int W, int H) { WINDOW_WIDTH = W; WINDOW_HEIGHT = H; glViewport(0, 0, WINDOW_WIDTH, WINDOW_HEIGHT); } void mouse(int button, int state, int x, int y) { if (state==GLUT_DOWN) { mousePos = vec2(x,y); } } void mouseMovement(int x, int y){ float rotationSpeed = 0.01f; vec2 newMousePos = vec2(x,y); vec2 mousePosDelta = mousePos - newMousePos; sphericalPolarAngle += mousePosDelta.x*rotationSpeed; float rotate89Degrees = 89*DegreesToRadians; sphericalElevationAngle = min(rotate89Degrees,max(-rotate89Degrees,sphericalElevationAngle + mousePosDelta.y*rotationSpeed)); mousePos = vec2(x,y); } void initPlaneTexture(){ const char* imagepath = "textures/xamp23.bmp"; unsigned int width, height; unsigned char * data = loadBMPRaw(imagepath, width, height); // Create one OpenGL texture glGenTextures(1, &planeTextureId); // "Bind" the newly created texture : all future texture functions will modify this texture glBindTexture(GL_TEXTURE_2D, planeTextureId); // Give the image to OpenGL glTexImage2D(GL_TEXTURE_2D, 0,GL_RGB, width, height, 0, GL_BGR, GL_UNSIGNED_BYTE, data); // Trilinear filtering. glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_REPEAT); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_LINEAR_MIPMAP_LINEAR); glGenerateMipmap(GL_TEXTURE_2D); delete[] data; } void initMeshAndShader(){ vector<int> indices; GLuint teapotVertexBuffer = loadMesh("meshes/teapot.obj", indices); Shader shader = loadShader("diffuse.vert", "diffuse.frag"); GLuint vertexArrayObject = createVertexArrayObject(teapotVertexBuffer, shader); teapotObject = MeshObject( shader, vertexArrayObject, indices ); Shader planeShader = loadShader("plane.vert", "plane.frag"); GLuint planeVertexBuffer = buildPlaneVertexBuffer(); planeObject = MeshObject( planeShader, createVertexArrayObject(planeVertexBuffer, planeShader), buildPlaneIndices() ); } void keyPress(unsigned char key, int x, int y) { switch (key){ case '\033': exit(0); break; case 'f': freeze = !freeze; break; case 'd': debugShadowMap = !debugShadowMap; break; case 'm': draw_mirror = !draw_mirror; break; } } void animate(int x) { glutPostRedisplay(); glutTimerFunc(10, animate, 0); } void printMenu(){ // print key menu cout << "Key shortcuts"<<endl; cout << "f - toggle freeze"<<endl; cout << "m - toggle mirror"<<endl; cout << endl<<"Use mouse drag to rotate"<<endl; } int main(int argc, char* argv[]) { glutInit(&argc, argv); glutInitContextVersion(3, 1); glutInitContextFlags(GLUT_FORWARD_COMPATIBLE); glutInitContextProfile(GLUT_CORE_PROFILE); glutSetOption( GLUT_ACTION_ON_WINDOW_CLOSE, GLUT_ACTION_GLUTMAINLOOP_RETURNS ); glutInitDisplayMode(GLUT_RGBA|GLUT_DOUBLE|GLUT_DEPTH|GLUT_STENCIL|GLUT_3_2_CORE_PROFILE); glutCreateWindow("02561-08_09"); glutDisplayFunc(display); glutReshapeFunc(reshape); glutMouseFunc(mouse); glutMotionFunc(mouseMovement); glutTimerFunc(10, animate, 0); glutKeyboardFunc(keyPress); glutReshapeWindow(WINDOW_WIDTH, WINDOW_HEIGHT); Angel::InitOpenGL(); printMenu(); shadowmapTextureId = buildTexture(SHADOW_MAP_SIZE, SHADOW_MAP_SIZE); frameBufferObject = buildFrameBufferObject(SHADOW_MAP_SIZE, SHADOW_MAP_SIZE, shadowmapTextureId); initMeshAndShader(); initPlaneTexture(); glEnable(GL_DEPTH_TEST); Angel::CheckError(); glutMainLoop(); } // Convert from spherical coordinates to cartesian coordinates vec3 sphericalToCartesian(float polarAngle, float elevationAngle, float radius){ float a = radius * cos(elevationAngle); vec3 cart; cart.x = a * cos(polarAngle); cart.y = radius * sin(elevationAngle); cart.z = a * sin(polarAngle); return cart; } string getFrameBufferStatusString(GLenum code){ switch (code){ case GL_FRAMEBUFFER_COMPLETE: return "Framebuffer ok"; case GL_FRAMEBUFFER_UNDEFINED: return "Framebuffer undefined"; case GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT: return "Framebuffer incomplete attachment"; case GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT: return "Framebuffer incomplete missing attachment"; case GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER: return "Framebuffer incomplete read buffer"; case GL_FRAMEBUFFER_UNSUPPORTED: return "Framebuffer unsupported"; case GL_FRAMEBUFFER_INCOMPLETE_MULTISAMPLE: return "Framebuffer incomplete multisample"; case GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER: return "FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER"; case GL_FRAMEBUFFER_INCOMPLETE_FORMATS_EXT: return "FRAMEBUFFER_INCOMPLETE_FORMATS"; default: return "Unknown framebuffer status "; } }
[ "metin.balaban@metu.edu.tr" ]
metin.balaban@metu.edu.tr
f56b9439af9dd772010bbf2e4ef5d976fefba1e1
caa8b85c782206db8bb66acb3457acd0e15dfc3d
/Kuplung/kuplung/rendering/methods/RenderingShadowMapping.cpp
c9baafe7447babcbdc1a4ebdca17d063c3880d60
[ "LicenseRef-scancode-unknown-license-reference", "Unlicense" ]
permissive
supudo/Kuplung
0f2f78b78f0ea14e26bd6e17eda5b90b6b4d76aa
f0e11934fde0675fa531e6dc263bedcc20a5ea1a
refs/heads/master
2021-12-28T16:34:48.787437
2021-12-26T18:24:01
2021-12-26T18:24:01
49,070,720
17
2
null
null
null
null
UTF-8
C++
false
false
54,840
cpp
// // RenderingShadowMapping.cpp // Kuplung // // Created by Sergey Petrov on 12/2/15. // Copyright © 2015 supudo.net. All rights reserved. // #include "RenderingShadowMapping.hpp" #include "kuplung/utilities/imgui/imguizmo/ImGuizmo.h" #include "kuplung/utilities/stb/stb_image_write.h" #include <fstream> #include <glm/gtc/matrix_inverse.hpp> #include <glm/gtc/type_ptr.hpp> #include <glm/gtx/matrix_decompose.hpp> RenderingShadowMapping::RenderingShadowMapping(ObjectsManager& managerObjects) : managerObjects(managerObjects) { this->GLSL_LightSourceNumber_Directional = 0; this->GLSL_LightSourceNumber_Point = 0; this->GLSL_LightSourceNumber_Spot = 0; } RenderingShadowMapping::~RenderingShadowMapping() { // if (this->vboTextureAmbient > 0) // glDeleteBuffers(1, &this->vboTextureAmbient); // if (this->vboTextureDiffuse > 0) // glDeleteBuffers(1, &this->vboTextureDiffuse); // if (this->vboTextureSpecular > 0) // glDeleteBuffers(1, &this->vboTextureSpecular); // if (this->vboTextureSpecularExp > 0) // glDeleteBuffers(1, &this->vboTextureSpecularExp); // if (this->vboTextureDissolve > 0) // glDeleteBuffers(1, &this->vboTextureDissolve); // if (this->vboTextureBump > 0) // glDeleteBuffers(1, &this->vboTextureBump); // if (this->vboTextureDisplacement > 0) // glDeleteBuffers(1, &this->vboTextureDisplacement); GLint maxColorAttachments = 1; glGetIntegerv(GL_MAX_COLOR_ATTACHMENTS, &maxColorAttachments); GLuint colorAttachment; GLenum att = GL_COLOR_ATTACHMENT0; for (colorAttachment = 0; colorAttachment < static_cast<GLuint>(maxColorAttachments); colorAttachment++) { att += colorAttachment; GLint param; GLuint objName; glGetFramebufferAttachmentParameteriv(GL_FRAMEBUFFER, att, GL_FRAMEBUFFER_ATTACHMENT_OBJECT_TYPE, &param); if (GL_RENDERBUFFER == param) { glGetFramebufferAttachmentParameteriv(GL_FRAMEBUFFER, att, GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME, &param); objName = reinterpret_cast<GLuint*>(&param)[0]; glDeleteRenderbuffers(1, &objName); } else if (GL_TEXTURE == param) { glGetFramebufferAttachmentParameteriv(GL_FRAMEBUFFER, att, GL_FRAMEBUFFER_ATTACHMENT_OBJECT_NAME, &param); objName = reinterpret_cast<GLuint*>(&param)[0]; glDeleteTextures(1, &objName); } } glDeleteProgram(this->shaderProgram); glDeleteProgram(this->shaderProgramShadows); for (size_t i = 0; i < this->mfLights_Directional.size(); i++) { this->mfLights_Directional[i].reset(); } for (size_t i = 0; i < this->mfLights_Point.size(); i++) { this->mfLights_Point[i].reset(); } for (size_t i = 0; i < this->mfLights_Spot.size(); i++) { this->mfLights_Spot[i].reset(); } Settings::Instance()->glUtils->CheckForGLErrors(Settings::Instance()->string_format("%s - %s", __FILE__, __func__)); } bool RenderingShadowMapping::init() { this->solidLight = std::make_unique<ModelFace_LightSource_Directional>(); this->GLSL_LightSourceNumber_Directional = 8; this->GLSL_LightSourceNumber_Point = 4; this->GLSL_LightSourceNumber_Spot = 4; bool success = true; success &= this->initShaderProgram(); return success; } bool RenderingShadowMapping::initShaderProgram() { bool success = true; // vertex shader std::string shaderPath = Settings::Instance()->appFolder() + "/shaders/model_face.vert"; std::string shaderSourceVertex = Settings::Instance()->glUtils->readFile(shaderPath.c_str()); const char* shader_vertex = shaderSourceVertex.c_str(); // tessellation control shader shaderPath = Settings::Instance()->appFolder() + "/shaders/model_face.tcs"; std::string shaderSourceTCS = Settings::Instance()->glUtils->readFile(shaderPath.c_str()); const char* shader_tess_control = shaderSourceTCS.c_str(); // tessellation evaluation shader shaderPath = Settings::Instance()->appFolder() + "/shaders/model_face.tes"; std::string shaderSourceTES = Settings::Instance()->glUtils->readFile(shaderPath.c_str()); const char* shader_tess_eval = shaderSourceTES.c_str(); // geometry shader shaderPath = Settings::Instance()->appFolder() + "/shaders/model_face.geom"; std::string shaderSourceGeometry = Settings::Instance()->glUtils->readFile(shaderPath.c_str()); const char* shader_geometry = shaderSourceGeometry.c_str(); // fragment shader - parts std::string shaderSourceFragment; std::vector<std::string> fragFiles = { "vars", "effects", "lights", "shadow_mapping", "mapping", "misc", "pbr" }; for (size_t i = 0; i < fragFiles.size(); i++) { shaderPath = Settings::Instance()->appFolder() + "/shaders/model_face_" + fragFiles[i] + ".frag"; shaderSourceFragment += Settings::Instance()->glUtils->readFile(shaderPath.c_str()); } shaderPath = Settings::Instance()->appFolder() + "/shaders/model_face.frag"; shaderSourceFragment += Settings::Instance()->glUtils->readFile(shaderPath.c_str()); const char* shader_fragment = shaderSourceFragment.c_str(); this->shaderProgram = glCreateProgram(); bool shaderCompilation = true; shaderCompilation &= Settings::Instance()->glUtils->compileShader(this->shaderProgram, GL_VERTEX_SHADER, shader_vertex); shaderCompilation &= Settings::Instance()->glUtils->compileShader(this->shaderProgram, GL_TESS_CONTROL_SHADER, shader_tess_control); shaderCompilation &= Settings::Instance()->glUtils->compileShader(this->shaderProgram, GL_TESS_EVALUATION_SHADER, shader_tess_eval); shaderCompilation &= Settings::Instance()->glUtils->compileShader(this->shaderProgram, GL_GEOMETRY_SHADER, shader_geometry); shaderCompilation &= Settings::Instance()->glUtils->compileShader(this->shaderProgram, GL_FRAGMENT_SHADER, shader_fragment); if (!shaderCompilation) return false; glLinkProgram(this->shaderProgram); GLint programSuccess = GL_TRUE; glGetProgramiv(this->shaderProgram, GL_LINK_STATUS, &programSuccess); if (programSuccess != GL_TRUE) { Settings::Instance()->funcDoLog("[RenderingShadowMapping - initShaders] Error linking program " + std::to_string(this->shaderProgram) + "!"); Settings::Instance()->glUtils->printProgramLog(this->shaderProgram); return success = false; } else { #ifdef Def_Kuplung_OpenGL_4x glPatchParameteri(GL_PATCH_VERTICES, 3); #endif glDetachShader(this->shaderProgramShadows, this->shaderShadowsVertex); glDetachShader(this->shaderProgramShadows, this->shaderShadowsFragment); glDeleteShader(this->shaderShadowsVertex); glDeleteShader(this->shaderShadowsFragment); this->glGS_GeomDisplacementLocation = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "vs_displacementLocation"); this->glTCS_UseCullFace = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "tcs_UseCullFace"); this->glTCS_UseTessellation = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "tcs_UseTessellation"); this->glTCS_TessellationSubdivision = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "tcs_TessellationSubdivision"); this->glFS_AlphaBlending = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_alpha"); this->glFS_CelShading = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_celShading"); this->glFS_CameraPosition = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_cameraPosition"); this->glVS_IsBorder = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "vs_isBorder"); this->glFS_OutlineColor = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_outlineColor"); this->glFS_UIAmbient = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_UIAmbient"); this->glFS_GammaCoeficient = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_gammaCoeficient"); this->glFS_planeClose = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_planeClose"); this->glFS_planeFar = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_planeFar"); this->glFS_showDepthColor = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_showDepthColor"); this->glFS_ShadowPass = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_shadowPass"); this->glFS_DebugShadowTexture = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_debugShadowTexture"); this->glVS_MVPMatrix = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "vs_MVPMatrix"); this->glFS_MMatrix = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_ModelMatrix"); this->glVS_WorldMatrix = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "vs_WorldMatrix"); this->glFS_MVMatrix = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "vs_MVMatrix"); this->glVS_NormalMatrix = glGetUniformLocation(this->shaderProgram, "vs_normalMatrix"); this->glFS_ScreenResX = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_screenResX"); this->glFS_ScreenResY = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_screenResY"); this->glMaterial_ParallaxMapping = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_userParallaxMapping"); this->glVS_shadowModelMatrix = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "shadow_model"); this->glFS_showShadows = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_showShadows"); this->glVS_LightSpaceMatrix = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "shadow_lightSpaceMatrix"); this->glFS_SamplerShadowMap = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "sampler_shadowMap"); this->gl_ModelViewSkin = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_modelViewSkin"); this->glFS_solidSkin_materialColor = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "solidSkin_materialColor"); this->solidLight->gl_InUse = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "solidSkin_Light.inUse"); this->solidLight->gl_Direction = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "solidSkin_Light.direction"); this->solidLight->gl_Ambient = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "solidSkin_Light.ambient"); this->solidLight->gl_Diffuse = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "solidSkin_Light.diffuse"); this->solidLight->gl_Specular = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "solidSkin_Light.specular"); this->solidLight->gl_StrengthAmbient = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "solidSkin_Light.strengthAmbient"); this->solidLight->gl_StrengthDiffuse = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "solidSkin_Light.strengthDiffuse"); this->solidLight->gl_StrengthSpecular = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "solidSkin_Light.strengthSpecular"); // light - directional for (unsigned int i = 0; i < this->GLSL_LightSourceNumber_Directional; i++) { std::unique_ptr<ModelFace_LightSource_Directional> f = std::make_unique<ModelFace_LightSource_Directional>(); f->gl_InUse = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("directionalLights[" + std::to_string(i) + "].inUse").c_str()); f->gl_Direction = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("directionalLights[" + std::to_string(i) + "].direction").c_str()); f->gl_Ambient = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("directionalLights[" + std::to_string(i) + "].ambient").c_str()); f->gl_Diffuse = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("directionalLights[" + std::to_string(i) + "].diffuse").c_str()); f->gl_Specular = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("directionalLights[" + std::to_string(i) + "].specular").c_str()); f->gl_StrengthAmbient = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("directionalLights[" + std::to_string(i) + "].strengthAmbient").c_str()); f->gl_StrengthDiffuse = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("directionalLights[" + std::to_string(i) + "].strengthDiffuse").c_str()); f->gl_StrengthSpecular = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("directionalLights[" + std::to_string(i) + "].strengthSpecular").c_str()); this->mfLights_Directional.push_back(std::move(f)); } // light - point for (unsigned int i = 0; i < this->GLSL_LightSourceNumber_Point; i++) { std::unique_ptr<ModelFace_LightSource_Point> f = std::make_unique<ModelFace_LightSource_Point>(); f->gl_InUse = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("pointLights[" + std::to_string(i) + "].inUse").c_str()); f->gl_Position = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("pointLights[" + std::to_string(i) + "].position").c_str()); f->gl_Constant = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("pointLights[" + std::to_string(i) + "].constant").c_str()); f->gl_Linear = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("pointLights[" + std::to_string(i) + "].linear").c_str()); f->gl_Quadratic = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("pointLights[" + std::to_string(i) + "].quadratic").c_str()); f->gl_Ambient = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("pointLights[" + std::to_string(i) + "].ambient").c_str()); f->gl_Diffuse = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("pointLights[" + std::to_string(i) + "].diffuse").c_str()); f->gl_Specular = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("pointLights[" + std::to_string(i) + "].specular").c_str()); f->gl_StrengthAmbient = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("pointLights[" + std::to_string(i) + "].strengthAmbient").c_str()); f->gl_StrengthDiffuse = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("pointLights[" + std::to_string(i) + "].strengthDiffuse").c_str()); f->gl_StrengthSpecular = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("pointLights[" + std::to_string(i) + "].strengthSpecular").c_str()); this->mfLights_Point.push_back(std::move(f)); } // light - spot for (unsigned int i = 0; i < this->GLSL_LightSourceNumber_Spot; i++) { std::unique_ptr<ModelFace_LightSource_Spot> f = std::make_unique<ModelFace_LightSource_Spot>(); f->gl_InUse = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("spotLights[" + std::to_string(i) + "].inUse").c_str()); f->gl_Position = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("spotLights[" + std::to_string(i) + "].position").c_str()); f->gl_Direction = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("spotLights[" + std::to_string(i) + "].direction").c_str()); f->gl_CutOff = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("spotLights[" + std::to_string(i) + "].cutOff").c_str()); f->gl_OuterCutOff = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("spotLights[" + std::to_string(i) + "].outerCutOff").c_str()); f->gl_Constant = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("spotLights[" + std::to_string(i) + "].constant").c_str()); f->gl_Linear = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("spotLights[" + std::to_string(i) + "].linear").c_str()); f->gl_Quadratic = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("spotLights[" + std::to_string(i) + "].quadratic").c_str()); f->gl_Ambient = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("spotLights[" + std::to_string(i) + "].ambient").c_str()); f->gl_Diffuse = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("spotLights[" + std::to_string(i) + "].diffuse").c_str()); f->gl_Specular = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("spotLights[" + std::to_string(i) + "].specular").c_str()); f->gl_StrengthAmbient = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("spotLights[" + std::to_string(i) + "].strengthAmbient").c_str()); f->gl_StrengthDiffuse = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("spotLights[" + std::to_string(i) + "].strengthDiffuse").c_str()); f->gl_StrengthSpecular = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, ("spotLights[" + std::to_string(i) + "].strengthSpecular").c_str()); this->mfLights_Spot.push_back(std::move(f)); } // material this->glMaterial_Refraction = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.refraction"); this->glMaterial_SpecularExp = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.specularExp"); this->glMaterial_IlluminationModel = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.illumination_model"); this->glMaterial_HeightScale = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.heightScale"); this->glMaterial_Ambient = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.ambient"); this->glMaterial_Diffuse = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.diffuse"); this->glMaterial_Specular = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.specular"); this->glMaterial_Emission = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.emission"); this->glMaterial_SamplerAmbient = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.sampler_ambient"); this->glMaterial_SamplerDiffuse = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.sampler_diffuse"); this->glMaterial_SamplerSpecular = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.sampler_specular"); this->glMaterial_SamplerSpecularExp = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.sampler_specularExp"); this->glMaterial_SamplerDissolve = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.sampler_dissolve"); this->glMaterial_SamplerBump = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.sampler_bump"); this->glMaterial_SamplerDisplacement = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.sampler_displacement"); this->glMaterial_HasTextureAmbient = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.has_texture_ambient"); this->glMaterial_HasTextureDiffuse = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.has_texture_diffuse"); this->glMaterial_HasTextureSpecular = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.has_texture_specular"); this->glMaterial_HasTextureSpecularExp = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.has_texture_specularExp"); this->glMaterial_HasTextureDissolve = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.has_texture_dissolve"); this->glMaterial_HasTextureBump = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.has_texture_bump"); this->glMaterial_HasTextureDisplacement = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "material.has_texture_displacement"); // effects - gaussian blur this->glEffect_GB_W = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "effect_GBlur.gauss_w"); this->glEffect_GB_Radius = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "effect_GBlur.gauss_radius"); this->glEffect_GB_Mode = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "effect_GBlur.gauss_mode"); // effects - bloom this->glEffect_Bloom_doBloom = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "effect_Bloom.doBloom"); this->glEffect_Bloom_WeightA = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "effect_Bloom.bloom_WeightA"); this->glEffect_Bloom_WeightB = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "effect_Bloom.bloom_WeightB"); this->glEffect_Bloom_WeightC = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "effect_Bloom.bloom_WeightC"); this->glEffect_Bloom_WeightD = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "effect_Bloom.bloom_WeightD"); this->glEffect_Bloom_Vignette = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "effect_Bloom.bloom_Vignette"); this->glEffect_Bloom_VignetteAtt = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "effect_Bloom.bloom_VignetteAtt"); // effects - tone mapping this->glEffect_ToneMapping_ACESFilmRec2020 = Settings::Instance()->glUtils->glGetUniform(this->shaderProgram, "fs_ACESFilmRec2020"); } success &= this->initShadows(); success &= this->initShadowsDepth(); Settings::Instance()->glUtils->CheckForGLErrors(Settings::Instance()->string_format("%s - %s", __FILE__, __func__)); return success; } bool RenderingShadowMapping::initShadowsDepth() { bool success = true; success &= this->initShadowsDepthShader(); return success; } bool RenderingShadowMapping::initShadowsDepthShader() { bool result = true; std::string shaderPath = Settings::Instance()->appFolder() + "/shaders/shadows_debug_quad.vert"; std::string shaderSourceVertex = Settings::Instance()->glUtils->readFile(shaderPath.c_str()); const char* shader_vertex = shaderSourceVertex.c_str(); shaderPath = Settings::Instance()->appFolder() + "/shaders/shadows_debug_quad_depth.frag"; std::string shaderSourceFragment = Settings::Instance()->glUtils->readFile(shaderPath.c_str()); const char* shader_fragment = shaderSourceFragment.c_str(); this->shaderProgramDepth = glCreateProgram(); bool shaderCompilation = true; shaderCompilation &= Settings::Instance()->glUtils->compileAndAttachShader(this->shaderProgramDepth, this->shaderDepthVertex, GL_VERTEX_SHADER, shader_vertex); shaderCompilation &= Settings::Instance()->glUtils->compileAndAttachShader(this->shaderProgramDepth, this->shaderDepthFragment, GL_FRAGMENT_SHADER, shader_fragment); if (!shaderCompilation) return false; glLinkProgram(this->shaderProgramDepth); GLint programSuccess = GL_TRUE; glGetProgramiv(this->shaderProgramDepth, GL_LINK_STATUS, &programSuccess); if (programSuccess != GL_TRUE) { Settings::Instance()->funcDoLog("Error linking program " + std::to_string(this->shaderProgramDepth) + "!\n"); Settings::Instance()->glUtils->printProgramLog(this->shaderProgramDepth); return false; } else { this->glDepth_Plane_Close = Settings::Instance()->glUtils->glGetUniformNoWarning(this->shaderProgramDepth, "near_plane"); this->glDepth_Plane_Far = Settings::Instance()->glUtils->glGetUniformNoWarning(this->shaderProgramDepth, "far_plane"); this->glDepth_SamplerTexture = Settings::Instance()->glUtils->glGetUniformNoWarning(this->shaderProgramDepth, "depthMap"); } Settings::Instance()->glUtils->CheckForGLErrors(Settings::Instance()->string_format("%s - %s", __FILE__, __func__)); return result; } bool RenderingShadowMapping::initShadows() { bool success = true; success &= this->initShadowsShader(); success &= this->initShadowsBuffers(); return success; } bool RenderingShadowMapping::initShadowsShader() { bool result = true; std::string shaderPath = Settings::Instance()->appFolder() + "/shaders/shadow_mapping_depth.vert"; std::string shaderSourceVertex = Settings::Instance()->glUtils->readFile(shaderPath.c_str()); const char* shader_vertex = shaderSourceVertex.c_str(); shaderPath = Settings::Instance()->appFolder() + "/shaders/shadow_mapping_depth.frag"; std::string shaderSourceFragment = Settings::Instance()->glUtils->readFile(shaderPath.c_str()); const char* shader_fragment = shaderSourceFragment.c_str(); this->shaderProgramShadows = glCreateProgram(); bool shaderCompilation = true; shaderCompilation &= Settings::Instance()->glUtils->compileAndAttachShader(this->shaderProgramShadows, this->shaderShadowsVertex, GL_VERTEX_SHADER, shader_vertex); shaderCompilation &= Settings::Instance()->glUtils->compileAndAttachShader(this->shaderProgramShadows, this->shaderShadowsFragment, GL_FRAGMENT_SHADER, shader_fragment); if (!shaderCompilation) return false; glLinkProgram(this->shaderProgramShadows); GLint programSuccess = GL_TRUE; glGetProgramiv(this->shaderProgramShadows, GL_LINK_STATUS, &programSuccess); if (programSuccess != GL_TRUE) { Settings::Instance()->funcDoLog("Error linking program " + std::to_string(this->shaderProgramShadows) + "!\n"); Settings::Instance()->glUtils->printProgramLog(this->shaderProgramShadows); return false; } else { this->glShadow_ModelMatrix = Settings::Instance()->glUtils->glGetUniformNoWarning(this->shaderProgramShadows, "shadow_model"); this->glShadow_LightSpaceMatrix = Settings::Instance()->glUtils->glGetUniformNoWarning(this->shaderProgramShadows, "shadow_lightSpaceMatrix"); } Settings::Instance()->glUtils->CheckForGLErrors(Settings::Instance()->string_format("%s - %s", __FILE__, __func__)); return result; } bool RenderingShadowMapping::initShadowsBuffers() { glGenFramebuffers(1, &this->fboDepthMap); glGenTextures(1, &this->vboDepthMap); glBindTexture(GL_TEXTURE_2D, this->vboDepthMap); const int smapWidth = 1024; //Settings::Instance()->SDL_Window_Width; const int smapHeight = 1024; //Settings::Instance()->SDL_Window_Height; glTexImage2D(GL_TEXTURE_2D, 0, GL_DEPTH_COMPONENT, smapWidth, smapHeight, 0, GL_DEPTH_COMPONENT, GL_FLOAT, nullptr); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_BORDER); glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_BORDER); GLfloat borderColor[] = { 1.0, 1.0, 1.0, 1.0 }; glTexParameterfv(GL_TEXTURE_2D, GL_TEXTURE_BORDER_COLOR, borderColor); glBindFramebuffer(GL_FRAMEBUFFER, this->fboDepthMap); glFramebufferTexture2D(GL_FRAMEBUFFER, GL_DEPTH_ATTACHMENT, GL_TEXTURE_2D, this->vboDepthMap, 0); glDrawBuffer(GL_NONE); glReadBuffer(GL_NONE); glBindFramebuffer(GL_FRAMEBUFFER, 0); if (glCheckFramebufferStatus(GL_FRAMEBUFFER) != GL_FRAMEBUFFER_COMPLETE) { Settings::Instance()->funcDoLog("[RenderingShadowMapping] Can't create shadow framebuffer!"); return false; } Settings::Instance()->glUtils->CheckForGLErrors(Settings::Instance()->string_format("%s - %s", __FILE__, __func__)); return true; } void RenderingShadowMapping::render(const std::vector<ModelFaceData*>& meshModelFaces, const int& selectedModel) { this->matrixProjection = this->managerObjects.matrixProjection; this->matrixCamera = this->managerObjects.camera->matrixCamera; this->vecCameraPosition = this->managerObjects.camera->cameraPosition; this->uiAmbientLight = this->managerObjects.Setting_UIAmbientLight; this->renderShadows(meshModelFaces, selectedModel); this->renderModels(false, this->shaderProgram, meshModelFaces, selectedModel); this->renderDepth(); } void RenderingShadowMapping::renderShadows(const std::vector<ModelFaceData*>& meshModelFaces, const int& selectedModel) { if (this->managerObjects.lightSources.size() > 0) { //glm::vec4 vecpos = this->managerObjects.lightSources[0]->matrixModel[3]; //glm::vec3 lightPos = glm::vec3(vecpos.x, vecpos.y, vecpos.z); glm::mat4 lightProjection = glm::ortho(-10.0f, 10.0f, -10.0f, 10.0f, this->managerObjects.Setting_PlaneClose, this->managerObjects.Setting_PlaneFar); // TODO: PVS SA //glm::mat4 matrixLightView = glm::lookAt(lightPos, this->managerObjects.camera->eyeSettings->View_Center, this->managerObjects.camera->eyeSettings->View_Up); glm::mat4 matrixLightView = glm::translate(this->managerObjects.camera->matrixCamera, glm::vec3(-2, 2, 2)); this->matrixLightSpace = lightProjection * matrixLightView; glUseProgram(this->shaderProgramShadows); glViewport(0, 0, Settings::Instance()->SDL_DrawableSize_Width, Settings::Instance()->SDL_DrawableSize_Height); glBindFramebuffer(GL_FRAMEBUFFER, this->fboDepthMap); glClear(GL_DEPTH_BUFFER_BIT); this->renderModels(true, this->shaderProgramShadows, meshModelFaces, selectedModel); // for (size_t i=0; i<meshModelFaces.size(); i++) { // ModelFaceData *mfd = meshModelFaces[i]; // glm::mat4 matrixModel = glm::mat4(1.0); // matrixModel *= this->managerObjects.grid->matrixModel; // // scale // matrixModel = glm::scale(matrixModel, glm::vec3(mfd->scaleX->point, mfd->scaleY->point, mfd->scaleZ->point)); // // translate // matrixModel = glm::translate(matrixModel, glm::vec3(mfd->positionX->point, mfd->positionY->point, mfd->positionZ->point)); // // rotate // matrixModel = glm::translate(matrixModel, glm::vec3(0, 0, 0)); // matrixModel = glm::rotate(matrixModel, glm::radians(mfd->rotateX->point), glm::vec3(1, 0, 0)); // matrixModel = glm::rotate(matrixModel, glm::radians(mfd->rotateY->point), glm::vec3(0, 1, 0)); // matrixModel = glm::rotate(matrixModel, glm::radians(mfd->rotateZ->point), glm::vec3(0, 0, 1)); // matrixModel = glm::translate(matrixModel, glm::vec3(0, 0, 0)); // glUniformMatrix4fv(this->glShadow_LightSpaceMatrix, 1, GL_FALSE, glm::value_ptr(this->matrixLightSpace)); // glUniformMatrix4fv(this->glShadow_ModelMatrix, 1, GL_FALSE, glm::value_ptr(matrixModel)); // mfd->renderModel(true); // } glUseProgram(0); glBindFramebuffer(GL_FRAMEBUFFER, 0); } Settings::Instance()->glUtils->CheckForGLErrors(Settings::Instance()->string_format("%s - %s", __FILE__, __func__)); } void RenderingShadowMapping::renderDepth() { glUseProgram(this->shaderProgramDepth); glUniform1f(this->glDepth_Plane_Close, this->managerObjects.Setting_PlaneClose); glUniform1f(this->glDepth_Plane_Far, this->managerObjects.Setting_PlaneFar); glUniform1i(this->glDepth_SamplerTexture, 0); glActiveTexture(GL_TEXTURE0); glBindTexture(GL_TEXTURE_2D, this->vboDepthMap); if (this->depthQuadVAO == 0) { const GLfloat quadVertices[] = { // Positions // Texture Coords -1.0f, 1.0f, 0.0f, 0.0f, 1.0f, -1.0f, -1.0f, 0.0f, 0.0f, 0.0f, 1.0f, 1.0f, 0.0f, 1.0f, 1.0f, 1.0f, -1.0f, 0.0f, 1.0f, 0.0f, }; // Setup plane VAO glGenVertexArrays(1, &this->depthQuadVAO); glGenBuffers(1, &this->depthQuadVBO); glBindVertexArray(this->depthQuadVAO); glBindBuffer(GL_ARRAY_BUFFER, this->depthQuadVBO); glBufferData(GL_ARRAY_BUFFER, sizeof(quadVertices), &quadVertices, GL_STATIC_DRAW); glEnableVertexAttribArray(0); glVertexAttribPointer(0, 3, GL_FLOAT, GL_FALSE, 5 * sizeof(GLfloat), (GLvoid*)0); glEnableVertexAttribArray(1); glVertexAttribPointer(1, 2, GL_FLOAT, GL_FALSE, 5 * sizeof(GLfloat), (GLvoid*)(3 * sizeof(GLfloat))); } glBindVertexArray(this->depthQuadVAO); glDrawArrays(GL_TRIANGLE_STRIP, 0, 4); glBindVertexArray(0); glUseProgram(0); Settings::Instance()->glUtils->CheckForGLErrors(Settings::Instance()->string_format("%s - %s", __FILE__, __func__)); } void RenderingShadowMapping::renderModels(const bool& isShadowPass, const GLuint& sProgram, const std::vector<ModelFaceData*>& meshModelFaces, const int& selectedModel) { glUseProgram(sProgram); int selectedModelID = -1; for (size_t i = 0; i < meshModelFaces.size(); i++) { ModelFaceData* mfd = meshModelFaces[i]; if (mfd->getOptionsSelected()) selectedModelID = static_cast<int>(i); glm::mat4 matrixModel = glm::mat4(1.0); matrixModel *= this->managerObjects.grid->matrixModel; // scale matrixModel = glm::scale(matrixModel, glm::vec3(mfd->scaleX->point, mfd->scaleY->point, mfd->scaleZ->point)); // translate matrixModel = glm::translate(matrixModel, glm::vec3(mfd->positionX->point, mfd->positionY->point, mfd->positionZ->point)); // rotate matrixModel = glm::translate(matrixModel, glm::vec3(0, 0, 0)); matrixModel = glm::rotate(matrixModel, glm::radians(mfd->rotateX->point), glm::vec3(1, 0, 0)); matrixModel = glm::rotate(matrixModel, glm::radians(mfd->rotateY->point), glm::vec3(0, 1, 0)); matrixModel = glm::rotate(matrixModel, glm::radians(mfd->rotateZ->point), glm::vec3(0, 0, 1)); matrixModel = glm::translate(matrixModel, glm::vec3(0, 0, 0)); // if (this->managerObjects.lightSources.size() > 0) { // this->managerObjects.matrixProjection = this->matrixLightSpace; // this->matrixProjection = this->matrixLightSpace; // glm::vec3 lightPos = glm::vec3(this->managerObjects.lightSources[0]->matrixModel[3].x, this->managerObjects.lightSources[0]->matrixModel[3].y, this->managerObjects.lightSources[0]->matrixModel[3].z); // matrixModel = glm::lookAt(lightPos, glm::vec3(0.0f, 0.0f, 0.0f), glm::vec3(0.0f, -1.0f, 0.0f)); // } mfd->matrixGrid = this->managerObjects.grid->matrixModel; mfd->matrixProjection = this->matrixProjection; mfd->matrixCamera = this->matrixCamera; mfd->matrixModel = matrixModel; mfd->Setting_ModelViewSkin = this->managerObjects.viewModelSkin; mfd->lightSources = this->managerObjects.lightSources; mfd->setOptionsFOV(this->managerObjects.Setting_FOV); mfd->setOptionsOutlineColor(this->managerObjects.Setting_OutlineColor); mfd->setOptionsOutlineThickness(this->managerObjects.Setting_OutlineThickness); mfd->setOptionsSelected(static_cast<int>(i) == selectedModel); glm::mat4 mvpMatrix = this->matrixProjection * this->matrixCamera * matrixModel; if (isShadowPass) mvpMatrix = this->matrixLightSpace; glUniformMatrix4fv(this->glVS_MVPMatrix, 1, GL_FALSE, glm::value_ptr(mvpMatrix)); if (isShadowPass) { glUniformMatrix4fv(this->glVS_shadowModelMatrix, 1, GL_FALSE, glm::value_ptr(matrixModel)); glUniformMatrix4fv(this->glShadow_ModelMatrix, 1, GL_FALSE, glm::value_ptr(matrixModel)); glUniformMatrix4fv(this->glShadow_LightSpaceMatrix, 1, GL_FALSE, glm::value_ptr(this->matrixLightSpace)); } glUniformMatrix4fv(this->glFS_MMatrix, 1, GL_FALSE, glm::value_ptr(matrixModel)); glm::mat4 matrixModelView = this->matrixCamera * matrixModel; glUniformMatrix4fv(this->glFS_MVMatrix, 1, GL_FALSE, glm::value_ptr(matrixModelView)); glm::mat3 matrixNormal = glm::inverseTranspose(glm::mat3(this->matrixCamera * matrixModel)); glUniformMatrix3fv(this->glVS_NormalMatrix, 1, GL_FALSE, glm::value_ptr(matrixNormal)); glm::mat4 matrixWorld = matrixModel; glUniformMatrix4fv(this->glVS_WorldMatrix, 1, GL_FALSE, glm::value_ptr(matrixWorld)); // blending if (mfd->meshModel.ModelMaterial.Transparency < 1.0f || mfd->Setting_Alpha < 1.0f) { glDisable(GL_DEPTH_TEST); glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); glEnable(GL_BLEND); if (mfd->meshModel.ModelMaterial.Transparency < 1.0f) glUniform1f(this->glFS_AlphaBlending, mfd->meshModel.ModelMaterial.Transparency); else glUniform1f(this->glFS_AlphaBlending, mfd->Setting_Alpha); } else { glEnable(GL_DEPTH_TEST); glDepthFunc(GL_LESS); glDisable(GL_BLEND); glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); glUniform1f(this->glFS_AlphaBlending, 1.0); } // shadow pass glUniform1i(this->glFS_ShadowPass, isShadowPass); // depth color float pc = 1.0f; if (this->managerObjects.Setting_PlaneClose >= 1.0f) pc = this->managerObjects.Setting_PlaneClose; glUniform1f(this->glFS_planeClose, pc); glUniform1f(this->glFS_planeFar, this->managerObjects.Setting_PlaneFar / 100.0f); glUniform1i(this->glFS_showDepthColor, this->managerObjects.Setting_Rendering_Depth); glUniform1i(this->glFS_DebugShadowTexture, this->managerObjects.Setting_DebugShadowTexture); // tessellation glUniform1i(this->glTCS_UseCullFace, mfd->Setting_UseCullFace); glUniform1i(this->glTCS_UseTessellation, mfd->Setting_UseTessellation); glUniform1i(this->glTCS_TessellationSubdivision, mfd->Setting_TessellationSubdivision); // cel-shading glUniform1i(this->glFS_CelShading, mfd->Setting_CelShading); // camera position glUniform3f(this->glFS_CameraPosition, this->vecCameraPosition.x, this->vecCameraPosition.y, this->vecCameraPosition.z); // screen size // glUniform1f(this->glFS_ScreenResX, Settings::Instance()->SDL_Window_Width); // glUniform1f(this->glFS_ScreenResY, Settings::Instance()->SDL_Window_Height); glUniform1f(this->glFS_ScreenResX, Settings::Instance()->SDL_DrawableSize_Width); glUniform1f(this->glFS_ScreenResY, Settings::Instance()->SDL_DrawableSize_Height); // Outline color glm::vec4 outline_color = mfd->getOptionsOutlineColor(); glUniform3f(this->glFS_OutlineColor, outline_color.r, outline_color.g, outline_color.b); // ambient color for editor glUniform3f(this->glFS_UIAmbient, this->uiAmbientLight.r, this->uiAmbientLight.g, this->uiAmbientLight.b); // geometry shader displacement glUniform3f(this->glGS_GeomDisplacementLocation, mfd->displaceX->point, mfd->displaceY->point, mfd->displaceZ->point); // mapping glUniform1i(this->glMaterial_ParallaxMapping, mfd->Setting_ParallaxMapping); // gamma correction glUniform1f(this->glFS_GammaCoeficient, this->managerObjects.Setting_GammaCoeficient); // render skin glUniform1i(this->gl_ModelViewSkin, mfd->Setting_ModelViewSkin); glUniform3f(this->glFS_solidSkin_materialColor, mfd->solidLightSkin_MaterialColor.r, mfd->solidLightSkin_MaterialColor.g, mfd->solidLightSkin_MaterialColor.b); glUniform1i(this->solidLight->gl_InUse, 1); glUniform3f(this->solidLight->gl_Direction, this->managerObjects.SolidLight_Direction.x, this->managerObjects.SolidLight_Direction.y, this->managerObjects.SolidLight_Direction.z); glUniform3f(this->solidLight->gl_Ambient, this->managerObjects.SolidLight_Ambient.r, this->managerObjects.SolidLight_Ambient.g, this->managerObjects.SolidLight_Ambient.b); glUniform3f(this->solidLight->gl_Diffuse, this->managerObjects.SolidLight_Diffuse.r, this->managerObjects.SolidLight_Diffuse.g, this->managerObjects.SolidLight_Diffuse.b); glUniform3f(this->solidLight->gl_Specular, this->managerObjects.SolidLight_Specular.r, this->managerObjects.SolidLight_Specular.g, this->managerObjects.SolidLight_Specular.b); glUniform1f(this->solidLight->gl_StrengthAmbient, this->managerObjects.SolidLight_Ambient_Strength); glUniform1f(this->solidLight->gl_StrengthDiffuse, this->managerObjects.SolidLight_Diffuse_Strength); glUniform1f(this->solidLight->gl_StrengthSpecular, this->managerObjects.SolidLight_Specular_Strength); // lights unsigned int lightsCount_Directional = 0; unsigned int lightsCount_Point = 0; unsigned int lightsCount_Spot = 0; for (size_t j = 0; j < mfd->lightSources.size(); j++) { Light* light = mfd->lightSources[j]; assert(light->type == LightSourceType_Directional || light->type == LightSourceType_Point || light->type == LightSourceType_Spot); switch (light->type) { case LightSourceType_Directional: { if (lightsCount_Directional < this->GLSL_LightSourceNumber_Directional) { const ModelFace_LightSource_Directional* f = this->mfLights_Directional[lightsCount_Directional].get(); glUniform1i(f->gl_InUse, 1); // light glUniform3f(f->gl_Direction, light->positionX->point, light->positionY->point, light->positionZ->point); // color const glm::vec3 c_ambient = light->ambient->color; const glm::vec3 c_diffuse = light->diffuse->color; const glm::vec3 c_specular = light->specular->color; glUniform3f(f->gl_Ambient, c_ambient.r, c_ambient.g, c_ambient.b); glUniform3f(f->gl_Diffuse, c_diffuse.r, c_diffuse.g, c_diffuse.b); glUniform3f(f->gl_Specular, c_specular.r, c_specular.g, c_specular.b); // light factors glUniform1f(f->gl_StrengthAmbient, light->ambient->strength); glUniform1f(f->gl_StrengthDiffuse, light->diffuse->strength); glUniform1f(f->gl_StrengthSpecular, light->specular->strength); lightsCount_Directional += 1; } break; } case LightSourceType_Point: { if (lightsCount_Point < this->GLSL_LightSourceNumber_Point) { const ModelFace_LightSource_Point* f = this->mfLights_Point[lightsCount_Point].get(); glUniform1i(f->gl_InUse, 1); // light glm::vec3 vec_pos = glm::vec3(light->matrixModel[3].x, light->matrixModel[3].y, light->matrixModel[3].z); glUniform3f(f->gl_Position, vec_pos.x, vec_pos.y, vec_pos.z); // factors glUniform1f(f->gl_Constant, light->lConstant->point); glUniform1f(f->gl_Linear, light->lLinear->point); glUniform1f(f->gl_Quadratic, light->lQuadratic->point); // color glUniform3f(f->gl_Ambient, light->ambient->color.r, light->ambient->color.g, light->ambient->color.b); glUniform3f(f->gl_Diffuse, light->diffuse->color.r, light->diffuse->color.g, light->diffuse->color.b); glUniform3f(f->gl_Specular, light->specular->color.r, light->specular->color.g, light->specular->color.b); // light factors glUniform1f(f->gl_StrengthAmbient, light->ambient->strength); glUniform1f(f->gl_StrengthDiffuse, light->diffuse->strength); glUniform1f(f->gl_StrengthSpecular, light->specular->strength); lightsCount_Point += 1; } break; } case LightSourceType_Spot: { if (lightsCount_Spot < this->GLSL_LightSourceNumber_Spot) { const ModelFace_LightSource_Spot* f = this->mfLights_Spot[lightsCount_Spot].get(); glUniform1i(f->gl_InUse, 1); // light glUniform3f(f->gl_Direction, light->positionX->point, light->positionY->point, light->positionZ->point); glUniform3f(f->gl_Position, light->matrixModel[3].x, light->matrixModel[3].y, light->matrixModel[3].z); // cutoff glUniform1f(f->gl_CutOff, glm::cos(glm::radians(light->lCutOff->point))); glUniform1f(f->gl_OuterCutOff, glm::cos(glm::radians(light->lOuterCutOff->point))); // factors glUniform1f(f->gl_Constant, light->lConstant->point); glUniform1f(f->gl_Linear, light->lLinear->point); glUniform1f(f->gl_Quadratic, light->lQuadratic->point); // color glUniform3f(f->gl_Ambient, light->ambient->color.r, light->ambient->color.g, light->ambient->color.b); glUniform3f(f->gl_Diffuse, light->diffuse->color.r, light->diffuse->color.g, light->diffuse->color.b); glUniform3f(f->gl_Specular, light->specular->color.r, light->specular->color.g, light->specular->color.b); // light factors glUniform1f(f->gl_StrengthAmbient, light->ambient->strength); glUniform1f(f->gl_StrengthDiffuse, light->diffuse->strength); glUniform1f(f->gl_StrengthSpecular, light->specular->strength); lightsCount_Spot += 1; } break; } } } for (unsigned int j = lightsCount_Directional; j < this->GLSL_LightSourceNumber_Directional; j++) { glUniform1i(this->mfLights_Directional[j]->gl_InUse, 0); } for (unsigned int j = lightsCount_Point; j < this->GLSL_LightSourceNumber_Point; j++) { glUniform1i(this->mfLights_Point[j]->gl_InUse, 0); } for (unsigned int j = lightsCount_Spot; j < this->GLSL_LightSourceNumber_Spot; j++) { glUniform1i(this->mfLights_Spot[j]->gl_InUse, 0); } // material glUniform1f(this->glMaterial_Refraction, mfd->Setting_MaterialRefraction->point); glUniform1f(this->glMaterial_SpecularExp, mfd->Setting_MaterialSpecularExp->point); glUniform1i(this->glMaterial_IlluminationModel, static_cast<GLint>(mfd->materialIlluminationModel)); glUniform1f(this->glMaterial_HeightScale, mfd->displacementHeightScale->point); const glm::vec3 c_Ambient = mfd->materialAmbient->color; const glm::vec3 c_Diffuse = mfd->materialDiffuse->color; const glm::vec3 c_Specular = mfd->materialSpecular->color; const glm::vec3 c_Emission = mfd->materialEmission->color; glUniform3f(this->glMaterial_Ambient, c_Ambient.r, c_Ambient.g, c_Ambient.b); glUniform3f(this->glMaterial_Diffuse, c_Diffuse.r, c_Diffuse.g, c_Diffuse.b); glUniform3f(this->glMaterial_Specular, c_Specular.r, c_Specular.g, c_Specular.b); glUniform3f(this->glMaterial_Emission, c_Emission.r, c_Emission.g, c_Emission.b); if (mfd->vboTextureAmbient > 0 && mfd->meshModel.ModelMaterial.TextureAmbient.UseTexture) { glUniform1i(this->glMaterial_HasTextureAmbient, 1); glUniform1i(this->glMaterial_SamplerAmbient, 0); glActiveTexture(GL_TEXTURE0); glBindTexture(GL_TEXTURE_2D, mfd->vboTextureAmbient); } else glUniform1i(this->glMaterial_HasTextureAmbient, 0); if (mfd->vboTextureDiffuse > 0 && mfd->meshModel.ModelMaterial.TextureDiffuse.UseTexture) { glUniform1i(this->glMaterial_HasTextureDiffuse, 1); glUniform1i(this->glMaterial_SamplerDiffuse, 1); glActiveTexture(GL_TEXTURE1); glBindTexture(GL_TEXTURE_2D, mfd->vboTextureDiffuse); } else glUniform1i(this->glMaterial_HasTextureDiffuse, 0); if (mfd->vboTextureSpecular > 0 && mfd->meshModel.ModelMaterial.TextureSpecular.UseTexture) { glUniform1i(this->glMaterial_HasTextureSpecular, 1); glUniform1i(this->glMaterial_SamplerSpecular, 2); glActiveTexture(GL_TEXTURE2); glBindTexture(GL_TEXTURE_2D, mfd->vboTextureSpecular); } else glUniform1i(this->glMaterial_HasTextureSpecular, 0); if (mfd->vboTextureSpecularExp > 0 && mfd->meshModel.ModelMaterial.TextureSpecularExp.UseTexture) { glUniform1i(this->glMaterial_HasTextureSpecularExp, 1); glUniform1i(this->glMaterial_SamplerSpecularExp, 3); glActiveTexture(GL_TEXTURE3); glBindTexture(GL_TEXTURE_2D, mfd->vboTextureSpecularExp); } else glUniform1i(this->glMaterial_HasTextureSpecularExp, 0); if (mfd->vboTextureDissolve > 0 && mfd->meshModel.ModelMaterial.TextureDissolve.UseTexture) { glUniform1i(this->glMaterial_HasTextureDissolve, 1); glUniform1i(this->glMaterial_SamplerDissolve, 4); glActiveTexture(GL_TEXTURE4); glBindTexture(GL_TEXTURE_2D, mfd->vboTextureDissolve); } else glUniform1i(this->glMaterial_HasTextureDissolve, 0); if (mfd->vboTextureBump > 0 && mfd->meshModel.ModelMaterial.TextureBump.UseTexture) { glUniform1i(this->glMaterial_HasTextureBump, 1); glUniform1i(this->glMaterial_SamplerBump, 5); glActiveTexture(GL_TEXTURE5); glBindTexture(GL_TEXTURE_2D, mfd->vboTextureBump); } else glUniform1i(this->glMaterial_HasTextureBump, 0); if (mfd->vboTextureDisplacement > 0 && mfd->meshModel.ModelMaterial.TextureDisplacement.UseTexture) { glUniform1i(this->glMaterial_HasTextureDisplacement, 1); glUniform1i(this->glMaterial_SamplerDisplacement, 6); glActiveTexture(GL_TEXTURE6); glBindTexture(GL_TEXTURE_2D, mfd->vboTextureDisplacement); } else glUniform1i(this->glMaterial_HasTextureDisplacement, 0); // effects - gaussian blur glUniform1i(this->glEffect_GB_Mode, mfd->Effect_GBlur_Mode - 1); glUniform1f(this->glEffect_GB_W, mfd->Effect_GBlur_Width->point); glUniform1f(this->glEffect_GB_Radius, mfd->Effect_GBlur_Radius->point); // effects - bloom // TODO: Bloom effect glUniform1i(this->glEffect_Bloom_doBloom, mfd->Effect_Bloom_doBloom); glUniform1f(this->glEffect_Bloom_WeightA, mfd->Effect_Bloom_WeightA); glUniform1f(this->glEffect_Bloom_WeightB, mfd->Effect_Bloom_WeightB); glUniform1f(this->glEffect_Bloom_WeightC, mfd->Effect_Bloom_WeightC); glUniform1f(this->glEffect_Bloom_WeightD, mfd->Effect_Bloom_WeightD); glUniform1f(this->glEffect_Bloom_Vignette, mfd->Effect_Bloom_Vignette); glUniform1f(this->glEffect_Bloom_VignetteAtt, mfd->Effect_Bloom_VignetteAtt); // effects - tone mapping glUniform1i(this->glEffect_ToneMapping_ACESFilmRec2020, mfd->Effect_ToneMapping_ACESFilmRec2020); // border glUniform1f(this->glVS_IsBorder, 0.0); glm::mat4 mtxModel; // if (mfd->getOptionsSelected()) { // glDisable(GL_DEPTH_TEST); // glUniform1f(this->glVS_IsBorder, 1.0); // mtxModel = glm::scale(matrixModel, glm::vec3(mfd->getOptionsOutlineThickness())); // mvpMatrix = this->matrixProjection * this->matrixCamera * mtxModel; // glUniformMatrix4fv(this->glVS_MVPMatrix, 1, GL_FALSE, glm::value_ptr(mvpMatrix)); // glUniformMatrix4fv(this->glFS_MMatrix, 1, GL_FALSE, glm::value_ptr(mtxModel)); // mfd->renderModel(true); // glEnable(GL_DEPTH_TEST); // } // model draw glUniform1f(this->glVS_IsBorder, 0.0); mtxModel = glm::scale(matrixModel, glm::vec3(1.0, 1.0, 1.0)); glm::mat4 mvpMatrixDraw = this->matrixProjection * this->matrixCamera * mtxModel; glUniformMatrix4fv(this->glVS_MVPMatrix, 1, GL_FALSE, glm::value_ptr(mvpMatrixDraw)); glUniformMatrix4fv(this->glFS_MMatrix, 1, GL_FALSE, glm::value_ptr(mtxModel)); // shadows glUniform1i(this->glFS_showShadows, mfd->Setting_ShowShadows); glUniformMatrix4fv(this->glShadow_ModelMatrix, 1, GL_FALSE, glm::value_ptr(matrixModel)); glUniformMatrix4fv(this->glShadow_LightSpaceMatrix, 1, GL_FALSE, glm::value_ptr(this->matrixLightSpace)); glUniformMatrix4fv(this->glVS_shadowModelMatrix, 1, GL_FALSE, glm::value_ptr(matrixModel)); glUniformMatrix4fv(this->glVS_LightSpaceMatrix, 1, GL_FALSE, glm::value_ptr(this->matrixLightSpace)); if (!isShadowPass && this->vboDepthMap > 0) { glUniform1i(this->glFS_SamplerShadowMap, 7); glActiveTexture(GL_TEXTURE7); glBindTexture(GL_TEXTURE_2D, this->vboDepthMap); } mfd->vertexSphereVisible = this->managerObjects.Setting_VertexSphere_Visible; mfd->vertexSphereRadius = this->managerObjects.Setting_VertexSphere_Radius; mfd->vertexSphereSegments = this->managerObjects.Setting_VertexSphere_Segments; mfd->vertexSphereColor = this->managerObjects.Setting_VertexSphere_Color; mfd->vertexSphereIsSphere = this->managerObjects.Setting_VertexSphere_IsSphere; mfd->vertexSphereShowWireframes = this->managerObjects.Setting_VertexSphere_ShowWireframes; mfd->renderModel(true); // edit mode wireframe if (mfd->getOptionsSelected() && mfd->Setting_EditMode) { mfd->Setting_Wireframe = true; matrixModel = glm::scale(matrixModel, glm::vec3(mfd->scaleX->point + 0.01f, mfd->scaleY->point + 0.01f, mfd->scaleZ->point + 0.01f)); mvpMatrix = this->matrixProjection * this->matrixCamera * matrixModel; matrixModelView = this->matrixCamera * matrixModel; matrixNormal = glm::inverseTranspose(glm::mat3(this->matrixCamera * matrixModel)); matrixWorld = matrixModel; glUniformMatrix4fv(this->glVS_MVPMatrix, 1, GL_FALSE, glm::value_ptr(mvpMatrix)); glUniformMatrix4fv(this->glFS_MMatrix, 1, GL_FALSE, glm::value_ptr(matrixModel)); glUniformMatrix4fv(this->glFS_MVMatrix, 1, GL_FALSE, glm::value_ptr(matrixModelView)); glUniformMatrix3fv(this->glVS_NormalMatrix, 1, GL_FALSE, glm::value_ptr(matrixNormal)); glUniformMatrix4fv(this->glVS_WorldMatrix, 1, GL_FALSE, glm::value_ptr(matrixWorld)); glUniform1i(this->gl_ModelViewSkin, ViewModelSkin_Solid); //TODO: put in settings glUniform3f(this->glFS_solidSkin_materialColor, 1.0f, 0.522f, 0.0f); mfd->renderModel(true); mfd->Setting_Wireframe = false; } } // edit mode if (this->managerObjects.VertexEditorMode != glm::vec3(0.0) && selectedModelID > -1) { ImGuizmo::Enable(true); ModelFaceData* mfd = meshModelFaces[selectedModelID]; glm::vec4 v0 = glm::vec4(this->managerObjects.VertexEditorMode, 1.0); v0 = mfd->matrixModel * v0; glm::mat4 matrixVertex = mfd->matrixModel; matrixVertex[3] = v0; glm::mat4 mtx = glm::mat4(1.0); ImGuiIO& io = ImGui::GetIO(); ImGuizmo::SetRect(0, 0, io.DisplaySize.x, io.DisplaySize.y); ImGuizmo::Manipulate(glm::value_ptr(this->managerObjects.camera->matrixCamera), glm::value_ptr(this->managerObjects.matrixProjection), ImGuizmo::TRANSLATE, ImGuizmo::WORLD, glm::value_ptr(matrixVertex), glm::value_ptr(mtx)); glm::vec3 scale; glm::quat rotation; glm::vec3 translation; glm::vec3 skew; glm::vec4 perspective; glm::decompose(mtx, scale, rotation, translation, skew, perspective); // glm::vec3 v = this->managerObjects.VertexEditorMode; this->managerObjects.VertexEditorMode.x += translation.x; this->managerObjects.VertexEditorMode.y += -1.0f * translation.y; this->managerObjects.VertexEditorMode.z += translation.z; if (this->managerObjects.Setting_GeometryEditMode == GeometryEditMode_Vertex) mfd->meshModel.vertices[static_cast<size_t>(this->managerObjects.VertexEditorModeID)] = this->managerObjects.VertexEditorMode; else if (this->managerObjects.Setting_GeometryEditMode == GeometryEditMode_Line) { } // else if (this->managerObjects.Setting_GeometryEditMode == GeometryEditMode_Face) { // for (size_t i = 0; i < mfd->meshModel.vertices.size(); i++) { // if (mfd->meshModel.vertices[i] == v) // mfd->meshModel.vertices[i] = v; // } // } // TODO(supudo): not good for drawing... reuploading the buffers again .... should find a better way - immediate draw, GL_STREAM_DRAW? mfd->initBuffers(); mfd->Setting_EditMode = true; } glUseProgram(0); Settings::Instance()->glUtils->CheckForGLErrors(Settings::Instance()->string_format("%s - %s", __FILE__, __func__)); }
[ "supudo@gmail.com" ]
supudo@gmail.com
30eceff069ba72fb4eaaaf9a317778577f7b1a58
6f05f7d5a67b6bb87956a22b988067ec772ba966
/data/test/cpp/72dc1a147801919d91aaadfef457ff2a66d96a37main.cpp
72dc1a147801919d91aaadfef457ff2a66d96a37
[ "MIT" ]
permissive
harshp8l/deep-learning-lang-detection
93b6d24a38081597c610ecf9b1f3b92c7d669be5
2a54293181c1c2b1a2b840ddee4d4d80177efb33
refs/heads/master
2020-04-07T18:07:00.697994
2018-11-29T23:21:23
2018-11-29T23:21:23
158,597,498
0
0
MIT
2018-11-21T19:36:42
2018-11-21T19:36:41
null
UTF-8
C++
false
false
674
cpp
#include <iostream> #include "pctree.h" int main() { std::cout << "Hello, World!\n"; //Test Case int rows = 5, cols = 6; int** sample = new int*[rows]; for(int i=0;i<rows;i++) { sample[i] = new int[cols]; } for(int i=0;i<rows;i++) { for(int j=0;j<cols;j++) { sample[i][j] = 0; } } sample[0][0]=1; sample[0][1]=1; sample[1][1]=1; sample[1][2]=1; sample[2][0]=1; sample[2][1]=1; sample[2][2]=1; sample[2][3]=1; sample[3][3]=1; sample[3][4]=1; sample[3][5]=1; sample[4][0]=1; sample[4][4]=1; sample[4][5]=1; PCtree myTree(sample,rows,cols); return 0; }
[ "aliostad+github@gmail.com" ]
aliostad+github@gmail.com
1c558d2c8f35a499112079d9e3b5cbe60d4f5d93
470399ad42a23dc42bcef0a72e45fd1abd7d6ca1
/source/YoloMouse/Share/Cursor/CursorBindings.cpp
67406296f7afdb22fff4d3510b8cc723fd6a3192
[ "Unlicense" ]
permissive
artisth/YoloMouse
0993998b1adc3fe023add1ee8f2222e3edeeb92b
982ad68a65f17f3926d713283f73ac858b6820e0
refs/heads/master
2022-05-26T17:43:17.692842
2019-08-24T01:05:05
2019-08-24T01:05:05
null
0
0
null
null
null
null
UTF-8
C++
false
false
1,157
cpp
#include <YoloMouse/Share/Cursor/CursorBindings.hpp> namespace Yolomouse { // public //------------------------------------------------------------------------- CursorBindings::CursorBindings() { } CursorBindings::~CursorBindings() { } //------------------------------------------------------------------------- CursorInfo* CursorBindings::GetBinding( Hash hash ) { return _bindings.Get( hash ); } const CursorBindings::BindingMap& CursorBindings::GetBindings() const { return _bindings; } CursorInfo& CursorBindings::GetDefaultBinding() { return _default_binding; } const CursorInfo& CursorBindings::GetDefaultBinding() const { return _default_binding; } //------------------------------------------------------------------------- CursorInfo* CursorBindings::CreateBinding( Hash hash ) { return &_bindings.Set( hash ); } //------------------------------------------------------------------------- Bool CursorBindings::RemoveBinding( Hash hash ) { return _bindings.Remove( hash ); } }
[ "PandaBunnyTeemo@gmail.com" ]
PandaBunnyTeemo@gmail.com
b53f0f2d47db0d54b92ad8ff3a7dce4f183ad115
04d489e9cfac15d77143db91d737ba9ca446d49d
/tests/playermock.hpp
d024e12fd64318c86af8367ee6a2da49b800c141
[]
no_license
Super-Teachers/final_example
cc3ae649783e209a90d7e6bf345bf8b345053a8e
8fca0a6d7942a394acc2f1c43f4c95d80af7fe5d
refs/heads/master
2021-01-25T00:38:15.626379
2017-06-18T12:17:13
2017-06-18T12:17:13
94,684,480
0
0
null
null
null
null
UTF-8
C++
false
false
386
hpp
#ifndef PLAYERMOCK_HPP_FPEWSD05 #define PLAYERMOCK_HPP_FPEWSD05 #include <gmock/gmock.h> #include "playerinterface.hpp" struct PlayerMock : public PlayerInterface { MOCK_METHOD1(play, void(const std::string&)); MOCK_METHOD0(stop, void()); MOCK_METHOD0(initialize, bool()); MOCK_METHOD0(dispatch, void()); }; #endif /* end of include guard: PLAYERMOCK_HPP_FPEWSD05 */
[ "bartosz.taczala@mobica.com" ]
bartosz.taczala@mobica.com
c55404c88b63b87f62826724d899f8e4dbc35b5b
62d96bb01f6442c342944ab6391970a3556c3b12
/Code Source/Metodos.h
a018d67c7bffe3198a007cbb716996cce0b17c73
[]
no_license
SergioEGGit/Project_Scrabble_Game_SEG
8cc33029f74c03aee0a892ecba88a76c691d30e4
31973a47b882970807d05889142688de5cf366b4
refs/heads/master
2023-07-17T06:51:15.713485
2021-08-16T17:30:33
2021-08-16T17:30:33
247,125,747
0
0
null
null
null
null
ISO-8859-1
C++
false
false
3,969
h
//------------------------------------------------------------------------------ #ifndef MetodosH #define MetodosH //------------------------------Librerias--------------------------------------- #include <iostream> #include <stdio.h> #include <conio.h> #include <string> #include <windows.h> #include <fstream> #include <algorithm> #include <functional> #include <cctype> #include <locale> #include <cstring> #include <DiccionarioLDC.h> #include <FichasCola.h> #include <RecorridosLS.h> #include <JugadoresABB.h> #include <FichasLS.h> #include <JugadoresFichasLD.h> #include <MatrizDispersa.h> #include <ScoreBoardLS.h> using namespace std; //------------------------------------------------------------------------------ #endif //-------------------------Definición Variables--------------------------------- namespace Variables { extern int AnchoPantalla; extern int AltoPantalla; extern int OpcionMenu; extern int OpcionJugar; extern int OpcionReporte; extern string RutaArchivo; extern int DimensionTablero; extern string LetraColaFichas; extern int PunteoColaFichas; extern string NombreJugador; extern int ContadorArbol; extern string CadenaArbol; extern string Jugador1; extern string Jugador2; extern bool TerminarJuego; extern int ContadorReccorridos; extern int OpcionOpcionesJuego; extern bool ColaVacia; extern string NombreReporte; }; //--------------------------Definición Métodos---------------------------------- //-----------------------------------Varios---------------------------------- void Color(int Background, int Text); void Fullscreen(); void Resolucion(); void SepararCadenaEliminar(string CadenaEliminar); //------------------------------Menú------------------------------------ void MenuPrincipal(); void MenuJugar(); void MenuReporte(); void MenuOpcionesJuego(); //-----------------------------Marcos----------------------------------- void gotoxy(int x, int y); void MarcoMenu(int Col1, int Col2, int Fil1, int Fil2); void MarcoArchivo(int Col1, int Col2, int Fil1, int Fil2); void MarcoJugar(int Col1, int Col2, int Fil1, int Fil2); void MarcoReportes(int Col1, int Col2, int Fil1, int Fil2); void MarcoSalir(int Col1, int Col2, int Fil1, int Fil2); //---------------------------Leer Archivos------------------------------ void LeerArchivo(MatrizDispersa<string> &MatrizDispersaMD, string RutaArchivo, ListaDLDC &ListaDiccionario, ListaFichas &ListaFichasDT); //-------------------------Generar Fichas------------------------------- void GenerarFichas(ColaFichas &Cabeza, ColaFichas &Cola); //-----------------------------Jugar------------------------------------ void AgregarJugadores(); void LimparMatriz(MatrizDispersa<string> &MatrizDispersaMD, ListaFichas &ListaFichasTD); void Jugar(ListaFichas &ListaFichasTD, ListaDLDC &ListaDiccionario, ScoreBoardLista &ScoreBoard, ArbolABB &Arbol, ListaLS &Lista, ListaLDJ &CabezaJugador1, ListaLDJ &CabezaJugador2, ListaLDJ &ColaJugador1, ListaLDJ &ColaJugador2, ColaFichas &FichasColaCabeza, ColaFichas &FichasColaCola, MatrizDispersa<string> &MatrizDispersaMD, int Contador); //-----------------------------Reportes--------------------------------- void ReporteDiccionario(ListaDLDC &ListaDiccionario); void ReporteColaFichas(ColaFichas &Cabeza); void ReporteArbolPreOrden(ListaLS &Lista); void ReporteArbolInOrden(ListaLS &Lista); void ReporteArbolPostOrden(ListaLS &Lista); void ReporteArbolBinarioBusqueda(ArbolABB &Arbol); void ReporteJugadoresFichas1Reportes(ListaLDJ &Lista); void ReporteJugadoresFichas1Juego(ListaLDJ &Lista); void ReporteJugadoresFichas2Reportes(ListaLDJ &Lista); void ReporteJugadoresFichas2Juego(ListaLDJ &Lista); void ReporteListaSimpleOrdenadaScoreBoard(ScoreBoardLista &ScoreBoard); void ReporteHistorialPuntajes(ScoreBoardLista &ScoreBoard, string Nombre);
[ "sergioeg19@hotmail.com" ]
sergioeg19@hotmail.com
0c47d98bb893911f96ef3b1731a8550c245055de
0ea2037de53a3564ce92b33df3db75229ae2ef5b
/SOURCE/initial/basic/0/nut
c7a613724288a1d6c6d45cefbd4a9733c1596dee
[]
no_license
MasterOfBinary/OpenFOAM-2D-VAWT
0c8377ecb16c824796d9e7404738f4ac17274ef6
1e00a2f7ada7493812c761b454f84e0c2d1d7f29
refs/heads/master
2021-04-09T13:41:54.146390
2016-04-13T05:01:34
2016-04-13T05:01:34
52,127,117
0
0
null
2016-02-20T00:06:51
2016-02-20T00:06:50
null
UTF-8
C++
false
false
1,462
/*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: 3.0.1 | | \\ / A nd | Web: www.OpenFOAM.org | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class volScalarField; location "0"; object nut; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // dimensions [0 2 -1 0 0 0 0]; internalField uniform 1.94e-05; boundaryField { blades { type nutUSpaldingWallFunction; value uniform 0; } farfield { type freestream; freestreamValue uniform 1.94e-05; value uniform 1.94e-05; } ext_interface { type cyclicAMI; value uniform 1.94e-05; } int_interface { type cyclicAMI; value uniform 1.94e-05; } sides { type empty; } } // ************************************************************************* //
[ "vdfriesen@vaughnfriesen.com" ]
vdfriesen@vaughnfriesen.com
5e02cbc618083b839f73543d9b586dba035c28d9
2d359660d5b4f727a54a5492369324ad42e0099f
/cctest/main/startup.cc
420bcfa5782cc7973e750f9d1dba1b8a905a06a4
[ "Apache-2.0" ]
permissive
Saber-hh/cctest
53d7955797e53f6a22dd3adaffcae56da54eca60
809b26109d54fee0988507650bd582a6de0dad0e
refs/heads/master
2020-07-21T19:24:36.204532
2019-09-02T15:57:06
2019-09-02T15:57:06
null
0
0
null
null
null
null
UTF-8
C++
false
false
147
cc
#include "cctest/main/startup.h" namespace cctest { int run_all_tests(int /* argc */, char** /* argv */) { return 0; } } // namespace cctest
[ "horance@outlook.com" ]
horance@outlook.com
b9b4204a1754214bf2b95bcaff8cad2e957c033f
e75cf3fc4e6569583270ac0f3626453c464fe020
/Android/第三方完整APP源码/mogutt/TTServer/cpp/src/msg_server/HttpParserWrapper.h
46cf2d8c4c44322ffdcc8232bf4ac950c5172656
[]
no_license
hailongfeng/zhishiku
c87742e8819c1a234f68f3be48108b244e8a265f
b62bb845a88248855d118bc571634cc94f34efcb
refs/heads/master
2022-12-26T00:00:48.455098
2020-02-26T09:22:05
2020-02-26T09:22:05
133,133,919
1
9
null
2022-12-16T00:35:57
2018-05-12T09:56:41
Java
UTF-8
C++
false
false
1,601
h
// // HttpPdu.h // http_msg_server // // Created by jianqing.du on 13-9-29. // Copyright (c) 2013年 ziteng. All rights reserved. // #ifndef http_msg_server_HttpParserWrapper_h #define http_msg_server_HttpParserWrapper_h #include "util.h" #include "http_parser.h" // extract url and content body from an ajax request class CHttpParserWrapper { public: virtual ~CHttpParserWrapper() {} static CHttpParserWrapper* GetInstance(); void ParseHttpContent(const char* buf, uint32_t len); bool IsReadAll() { return m_read_all; } uint32_t GetTotalLength() { return m_total_length; } string& GetUrl() { return m_url; } string& GetBodyContent() { return m_body_content; } void SetUrl(const char* url, size_t length) { m_url.append(url, length); } void SetBodyContent(const char* content, size_t length) { m_body_content.append(content, length); } void SetTotalLength(uint32_t total_len) { m_total_length = total_len; } void SetReadAll() { m_read_all = true; } static int OnUrl(http_parser* parser, const char *at, size_t length); static int OnHeadersComplete (http_parser* parser); static int OnBody (http_parser* parser, const char *at, size_t length); static int OnMessageComplete (http_parser* parser); private: CHttpParserWrapper(); private: static CHttpParserWrapper* m_instance; http_parser m_http_parser; http_parser_settings m_settings; bool m_read_all; uint32_t m_total_length; string m_url; string m_body_content; }; #endif
[ "no_1hailong@yeah.net" ]
no_1hailong@yeah.net
1f91f088d1b912a373a63e0383403886a85b30cd
677d7c8fd7af9a213675425375ca2f6c127a0950
/lab4-5/Result.cpp
f43dd087127c992850391a7cbc35124169b3e5ca
[]
no_license
MRVolta-Ivan/patterns
2b9aa0239f6ae8803053dee7a68749526dc97e65
7b5a004196543c976ed755942d71f6e4fa6641ee
refs/heads/main
2023-02-22T03:14:49.460246
2021-01-28T12:58:44
2021-01-28T12:58:44
316,947,833
0
0
null
null
null
null
UTF-8
C++
false
false
954
cpp
#include "Result.h" SEOResult::SEOResult() { count_letters = 0; count_word = 0; } SEOResult::SEOResult(int _count_letters, int _count_word, vector<string> _keyword) { count_letters = _count_letters; count_word = _count_word; keyword = _keyword; } int SEOResult::GetCountLetters() { return count_letters; } int SEOResult::GetCountWord() { return count_word; } vector<string> SEOResult::GetKeyword() { return keyword; } OrtoResult::OrtoResult() { } OrtoResult::OrtoResult(vector<string> _mistake_word) { mistake_word = _mistake_word; } vector<string> OrtoResult::GetMistakeWord() { return mistake_word; } CountSymbolResult::CountSymbolResult() { count_letter = 0; count_symbol = 0; } CountSymbolResult::CountSymbolResult(int letter, int symbol) { count_letter = letter; count_symbol = symbol; } int CountSymbolResult::GetCountLetter() { return count_letter; } int CountSymbolResult::GetCountSymbol() { return count_symbol; }
[ "mr.volta0@gmail.com" ]
mr.volta0@gmail.com
855cb613ec23b8f614483779d9e847a115265ee4
a19e90ff9731506909f8f3e9d557b3cddf8a2180
/career_cup/missing_term_in_ap.cc
714aebfdc96cd5aa121569b998f554f6c22dee98
[]
no_license
smfaisal/leetcode_problems
4df81310208578efada54d0c902862f37e857ed5
5a26dae6c774f746bea96f95bc24bacc9df4c384
refs/heads/master
2021-01-22T11:37:52.624298
2015-04-15T23:06:07
2015-04-15T23:06:07
34,022,857
0
0
null
null
null
null
UTF-8
C++
false
false
409
cc
#include <iostream> #include <vector> using namespace std; int main() { int N; vector<int> series; cin >> N; int t; for (int i = 0; i < N; i++) { cin >> t; series.push_back(t); } int min_d = min(series[1]-series[0], series[2]-series[1]); for (int i = 0; i < N-1; i++) { if (series[i+1] != series[i]+min_d) { cout << series[i]+min_d; break; } } return 0; }
[ "faisal@cse.ohio-state.edu" ]
faisal@cse.ohio-state.edu
3f6809e31443008a19162104a06308d945353ea7
a97b9ad50e283b4e930ab59547806eb303b52c6f
/class/4nov_plate_kwSST/310/phi
2ff9429f07d91d8ad1109abdda3d3ab95db46914
[]
no_license
harrisbk/OpenFOAM_run
fdcd4f81bd3205764988ea95c25fd2a5c130841b
9591c98336561bcfb3b7259617b5363aacf48067
refs/heads/master
2016-09-05T08:45:27.965608
2015-11-16T19:08:34
2015-11-16T19:08:34
42,883,543
1
2
null
null
null
null
UTF-8
C++
false
false
236,711
/*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: 2.4.0 | | \\ / A nd | Web: www.OpenFOAM.org | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class surfaceScalarField; location "310"; object phi; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // dimensions [0 3 -1 0 0 0 0]; internalField nonuniform List<scalar> 19800 ( 0.000192365 2.29084e-09 0.000192359 5.3902e-09 0.000192352 7.76588e-09 0.000192342 9.67011e-09 0.000192331 1.12699e-08 0.000192318 1.26715e-08 0.000192304 1.39388e-08 0.000192289 1.51429e-08 0.000192273 1.63013e-08 0.000192255 1.74925e-08 0.000192237 1.86812e-08 0.000192217 2.00028e-08 0.000192195 2.12595e-08 0.000192173 2.27529e-08 0.000192149 2.34982e-08 0.000192125 2.42268e-08 0.000192105 1.95551e-08 0.000192093 1.21144e-08 0.00019213 -3.72063e-08 7.89177e-08 0.000192051 0.000197699 4.64289e-09 0.000197694 1.09261e-08 0.000197686 1.574e-08 0.000197676 1.95996e-08 0.000197664 2.28398e-08 0.000197651 2.56774e-08 0.000197637 2.82418e-08 0.000197622 3.0674e-08 0.000197605 3.30138e-08 0.000197587 3.54092e-08 0.000197568 3.78081e-08 0.000197547 4.04448e-08 0.000197526 4.30177e-08 0.000197502 4.60053e-08 0.000197478 4.80946e-08 0.000197451 5.05836e-08 0.000197423 4.83129e-08 0.000197384 5.03901e-08 0.0001973 4.68099e-08 1.66855e-07 0.000197212 0.000203182 7.05701e-09 0.000203176 1.66078e-08 0.000203168 2.39228e-08 0.000203158 2.97865e-08 0.000203146 3.47055e-08 0.000203133 3.90097e-08 0.000203118 4.28949e-08 0.000203102 4.65719e-08 0.000203085 5.01033e-08 0.000203067 5.37021e-08 0.000203047 5.73041e-08 0.000203027 6.12306e-08 0.000203004 6.51159e-08 0.000202981 6.96014e-08 0.000202956 7.33349e-08 0.000202928 7.81915e-08 0.000202896 8.03629e-08 0.000202855 9.08946e-08 0.000202795 1.0688e-07 1.90525e-07 0.000202772 0.000208817 9.53312e-09 0.000208811 2.24348e-08 0.000208802 3.23126e-08 0.000208792 4.02273e-08 0.00020878 4.68608e-08 0.000208766 5.26575e-08 0.000208751 5.78807e-08 0.000208735 6.28093e-08 0.000208717 6.75292e-08 0.000208699 7.23114e-08 0.000208679 7.70846e-08 0.000208658 8.2237e-08 0.000208636 8.73781e-08 0.000208612 9.32578e-08 0.000208587 9.86609e-08 0.000208559 1.05694e-07 0.000208528 1.118e-07 0.000208493 1.26194e-07 0.000208452 1.47051e-07 2.0166e-07 0.000208441 0.000214607 1.20709e-08 0.000214601 2.84062e-08 0.000214593 4.09071e-08 0.000214582 5.09174e-08 0.00021457 5.92971e-08 0.000214556 6.66069e-08 0.00021454 7.31779e-08 0.000214524 7.93545e-08 0.000214506 8.52452e-08 0.000214487 9.11699e-08 0.000214467 9.70537e-08 0.000214446 1.03328e-07 0.000214424 1.09602e-07 0.000214401 1.1666e-07 0.000214376 1.23474e-07 0.000214349 1.32009e-07 0.000214321 1.40499e-07 0.000214292 1.55296e-07 0.000214264 1.74738e-07 2.09678e-07 0.000214256 0.000220559 1.46697e-08 0.000220553 3.45201e-08 0.000220544 4.97027e-08 0.000220533 6.18503e-08 0.00022052 7.20041e-08 0.000220506 8.08416e-08 0.00022049 8.87619e-08 0.000220474 9.61708e-08 0.000220456 1.03199e-07 0.000220437 1.10203e-07 0.000220417 1.17108e-07 0.000220396 1.24357e-07 0.000220374 1.31575e-07 0.000220351 1.39503e-07 0.000220327 1.47278e-07 0.000220302 1.56486e-07 0.000220277 1.65805e-07 0.000220253 1.7906e-07 0.000220233 1.94629e-07 2.15922e-07 0.000220227 0.000226675 1.73288e-08 0.000226669 4.07742e-08 0.00022666 5.86948e-08 0.000226649 7.30181e-08 0.000226636 8.49693e-08 0.000226621 9.53424e-08 0.000226606 1.04604e-07 0.000226588 1.13217e-07 0.00022657 1.21333e-07 0.000226551 1.29332e-07 0.000226531 1.37137e-07 0.00022651 1.45179e-07 0.000226489 1.53095e-07 0.000226467 1.61519e-07 0.000226444 1.69711e-07 0.000226422 1.78781e-07 0.0002264 1.87649e-07 0.000226381 1.98286e-07 0.000226366 2.09179e-07 2.20791e-07 0.000226362 0.000232961 2.00469e-08 0.000232955 4.71652e-08 0.000232946 6.78776e-08 0.000232934 8.44114e-08 0.000232921 9.81776e-08 0.000232906 1.10087e-07 0.00023289 1.20673e-07 0.000232873 1.30449e-07 0.000232855 1.39584e-07 0.000232836 1.48472e-07 0.000232816 1.5703e-07 0.000232795 1.65649e-07 0.000232774 1.73976e-07 0.000232753 1.82494e-07 0.000232733 1.90541e-07 0.000232713 1.98771e-07 0.000232694 2.06245e-07 0.000232679 2.13754e-07 0.000232668 2.20021e-07 2.2463e-07 0.000232664 0.000239422 2.28226e-08 0.000239415 5.36892e-08 0.000239406 7.72439e-08 0.000239394 9.60185e-08 0.000239381 1.11612e-07 0.000239366 1.2505e-07 0.00023935 1.36932e-07 0.000239332 1.47816e-07 0.000239314 1.57888e-07 0.000239295 1.67537e-07 0.000239275 1.76675e-07 0.000239255 1.85634e-07 0.000239235 1.9406e-07 0.000239215 2.02271e-07 0.000239196 2.09653e-07 0.000239179 2.16485e-07 0.000239163 2.21945e-07 0.00023915 2.2618e-07 0.000239142 2.28236e-07 2.27653e-07 0.000239139 0.000246061 2.56539e-08 0.000246055 6.03412e-08 0.000246045 8.67851e-08 0.000246033 1.07826e-07 0.00024602 1.25252e-07 0.000246005 1.40203e-07 0.000245988 1.53342e-07 0.000245971 1.65267e-07 0.000245952 1.76173e-07 0.000245933 1.86439e-07 0.000245914 1.95966e-07 0.000245895 2.05011e-07 0.000245876 2.13219e-07 0.000245857 2.20745e-07 0.00024584 2.27014e-07 0.000245824 2.32044e-07 0.000245811 2.35136e-07 0.000245801 2.36172e-07 0.000245795 2.34539e-07 2.29999e-07 0.000245792 0.000252885 2.85386e-08 0.000252878 6.71153e-08 0.000252869 9.64913e-08 0.000252857 1.19819e-07 0.000252843 1.39076e-07 0.000252827 1.55515e-07 0.000252811 1.69862e-07 0.000252793 1.82744e-07 0.000252775 1.9437e-07 0.000252757 2.05093e-07 0.000252738 2.14803e-07 0.000252719 2.23677e-07 0.000252701 2.31357e-07 0.000252684 2.37862e-07 0.000252668 2.42661e-07 0.000252655 2.45621e-07 0.000252644 2.46194e-07 0.000252635 2.4422e-07 0.000252631 2.39405e-07 2.31774e-07 0.000252629 0.000259898 3.1474e-08 0.000259891 7.40047e-08 0.000259881 1.06351e-07 0.000259869 1.31979e-07 0.000259855 1.53059e-07 0.00025984 1.70952e-07 0.000259823 1.86445e-07 0.000259806 2.00192e-07 0.000259788 2.12408e-07 0.000259769 2.23416e-07 0.000259751 2.33094e-07 0.000259733 2.41544e-07 0.000259716 2.48408e-07 0.0002597 2.53607e-07 0.000259686 2.56669e-07 0.000259674 2.57408e-07 0.000259665 2.55447e-07 0.000259659 2.50707e-07 0.000259655 2.43166e-07 2.33066e-07 0.000259654 0.000267105 3.44571e-08 0.000267098 8.10014e-08 0.000267088 1.1635e-07 0.000267076 1.44288e-07 0.000267062 1.67174e-07 0.000267046 1.86477e-07 0.00026703 2.03045e-07 0.000267012 2.17549e-07 0.000266995 2.30214e-07 0.000266977 2.41327e-07 0.000266959 2.50759e-07 0.000266942 2.58543e-07 0.000266926 2.64335e-07 0.000266912 2.67997e-07 0.000266899 2.6914e-07 0.000266889 2.676e-07 0.000266881 2.6318e-07 0.000266876 2.55934e-07 0.000266873 2.46056e-07 2.33947e-07 0.000266872 0.000274513 3.74842e-08 0.000274506 8.80964e-08 0.000274495 1.26475e-07 0.000274483 1.56723e-07 0.000274469 1.8139e-07 0.000274453 2.02051e-07 0.000274437 2.1961e-07 0.000274419 2.34756e-07 0.000274402 2.47719e-07 0.000274384 2.58754e-07 0.000274368 2.67727e-07 0.000274351 2.74621e-07 0.000274337 2.79121e-07 0.000274324 2.81073e-07 0.000274313 2.80188e-07 0.000274304 2.76381e-07 0.000274297 2.69629e-07 0.000274293 2.60132e-07 0.000274291 2.48247e-07 2.34479e-07 0.00027429 0.000282125 4.05513e-08 0.000282118 9.52795e-08 0.000282108 1.36708e-07 0.000282095 1.6926e-07 0.000282081 1.95676e-07 0.000282066 2.17631e-07 0.000282049 2.3609e-07 0.000282032 2.51752e-07 0.000282015 2.64857e-07 0.000281998 2.7563e-07 0.000281982 2.83941e-07 0.000281967 2.89745e-07 0.000281953 2.92771e-07 0.000281941 2.92891e-07 0.000281932 2.89932e-07 0.000281924 2.83918e-07 0.000281919 2.7499e-07 0.000281915 2.63483e-07 0.000281914 2.49868e-07 2.34712e-07 0.000281913 0.000289949 4.3654e-08 0.000289942 1.02539e-07 0.000289932 1.47032e-07 0.000289919 1.81874e-07 0.000289905 2.09996e-07 0.000289889 2.33176e-07 0.000289873 2.52431e-07 0.000289856 2.68478e-07 0.000289839 2.81564e-07 0.000289823 2.91894e-07 0.000289808 2.99355e-07 0.000289794 3.03895e-07 0.000289781 3.05306e-07 0.00028977 3.03517e-07 0.000289762 2.98487e-07 0.000289755 2.9036e-07 0.000289751 2.79424e-07 0.000289748 2.66126e-07 0.000289747 2.51016e-07 2.34689e-07 0.000289747 0.00029799 4.67871e-08 0.000297983 1.09863e-07 0.000297972 1.57426e-07 0.00029796 1.94537e-07 0.000297945 2.24316e-07 0.00029793 2.48638e-07 0.000297914 2.68581e-07 0.000297897 2.84874e-07 0.000297881 2.9778e-07 0.000297865 3.07495e-07 0.000297851 3.13934e-07 0.000297838 3.17063e-07 0.000297826 3.16756e-07 0.000297817 3.13025e-07 0.000297809 3.05962e-07 0.000297804 2.95837e-07 0.0002978 2.83062e-07 0.000297798 2.68173e-07 0.000297797 2.51766e-07 2.34445e-07 0.000297798 0.000306254 4.9945e-08 0.000306246 1.17237e-07 0.000306236 1.67869e-07 0.000306223 2.07219e-07 0.000306209 2.38595e-07 0.000306194 2.63973e-07 0.000306178 2.84487e-07 0.000306162 3.00884e-07 0.000306146 3.13452e-07 0.000306131 3.2239e-07 0.000306118 3.27655e-07 0.000306105 3.29255e-07 0.000306095 3.27162e-07 0.000306086 3.21488e-07 0.00030608 3.12458e-07 0.000306075 3.00462e-07 0.000306072 2.86013e-07 0.000306071 2.69711e-07 0.00030607 2.52178e-07 2.34007e-07 0.000306071 0.000314747 5.31218e-08 0.000314739 1.24646e-07 0.000314729 1.78336e-07 0.000314716 2.19888e-07 0.000314702 2.52794e-07 0.000314687 2.79131e-07 0.000314671 3.00095e-07 0.000314656 3.16455e-07 0.000314641 3.28532e-07 0.000314626 3.36541e-07 0.000314614 3.40502e-07 0.000314602 3.40484e-07 0.000314593 3.36568e-07 0.000314586 3.28979e-07 0.00031458 3.18068e-07 0.000314576 3.04332e-07 0.000314574 2.88366e-07 0.000314573 2.70811e-07 0.000314572 2.52298e-07 2.33399e-07 0.000314573 0.000323475 5.63108e-08 0.000323468 1.32074e-07 0.000323457 1.88804e-07 0.000323445 2.32511e-07 0.000323431 2.66872e-07 0.000323416 2.94066e-07 0.000323401 3.15354e-07 0.000323385 3.31536e-07 0.000323371 3.42974e-07 0.000323358 3.49922e-07 0.000323346 3.5247e-07 0.000323335 3.50771e-07 0.000323327 3.45023e-07 0.00032332 3.35568e-07 0.000323315 3.22874e-07 0.000323312 3.07531e-07 0.00032331 2.90194e-07 0.00032331 2.71529e-07 0.00032331 2.52163e-07 2.32641e-07 0.000323311 0.000332446 5.9505e-08 0.000332438 1.39504e-07 0.000332428 1.99246e-07 0.000332415 2.45052e-07 0.000332402 2.80786e-07 0.000332387 3.0873e-07 0.000332372 3.30215e-07 0.000332357 3.4608e-07 0.000332344 3.56744e-07 0.000332331 3.6251e-07 0.00033232 3.6356e-07 0.000332311 3.60143e-07 0.000332303 3.52578e-07 0.000332297 3.41323e-07 0.000332293 3.26952e-07 0.000332291 3.10132e-07 0.000332289 2.91559e-07 0.000332289 2.71912e-07 0.000332289 2.51802e-07 2.31747e-07 0.00033229 0.000341665 6.26966e-08 0.000341658 1.46917e-07 0.000341647 2.09633e-07 0.000341635 2.57475e-07 0.000341621 2.94494e-07 0.000341607 3.23076e-07 0.000341593 3.44629e-07 0.000341579 3.60045e-07 0.000341565 3.69809e-07 0.000341554 3.74293e-07 0.000341543 3.73781e-07 0.000341535 3.6863e-07 0.000341528 3.59281e-07 0.000341523 3.46305e-07 0.00034152 3.30368e-07 0.000341518 3.12194e-07 0.000341517 2.92512e-07 0.000341517 2.71997e-07 0.000341517 2.51242e-07 2.30731e-07 0.000341518 0.00035114 6.58776e-08 0.000351133 1.54293e-07 0.000351123 2.19937e-07 0.00035111 2.69744e-07 0.000351097 3.07951e-07 0.000351083 3.37056e-07 0.000351069 3.58551e-07 0.000351056 3.73391e-07 0.000351043 3.82143e-07 0.000351032 3.85263e-07 0.000351023 3.83146e-07 0.000351015 3.76265e-07 0.000351009 3.65183e-07 0.000351005 3.50573e-07 0.000351002 3.33179e-07 0.000351001 3.13773e-07 0.000351 2.93096e-07 0.000351 2.71816e-07 0.000351001 2.505e-07 2.29602e-07 0.000351002 0.000360878 6.90394e-08 0.000360871 1.61612e-07 0.000360861 2.30127e-07 0.000360848 2.8182e-07 0.000360835 3.21115e-07 0.000360822 3.50626e-07 0.000360808 3.7194e-07 0.000360796 3.86087e-07 0.000360784 3.93728e-07 0.000360774 3.95417e-07 0.000360765 3.91672e-07 0.000360759 3.83083e-07 0.000360753 3.70331e-07 0.00036075 3.54179e-07 0.000360748 3.35438e-07 0.000360746 3.14912e-07 0.000360746 2.93347e-07 0.000360747 2.71395e-07 0.000360747 2.49596e-07 2.2837e-07 0.000360749 0.000370886 7.21733e-08 0.000370879 1.68853e-07 0.000370869 2.40173e-07 0.000370857 2.93665e-07 0.000370844 3.33942e-07 0.000370831 3.63742e-07 0.000370818 3.84755e-07 0.000370806 3.98101e-07 0.000370795 4.04547e-07 0.000370786 4.04759e-07 0.000370778 3.99379e-07 0.000370772 3.8912e-07 0.000370768 3.74769e-07 0.000370765 3.57172e-07 0.000370763 3.37192e-07 0.000370762 3.15652e-07 0.000370762 2.93296e-07 0.000370763 2.70755e-07 0.000370764 2.48541e-07 2.27042e-07 0.000370765 0.000381171 7.52697e-08 0.000381164 1.75993e-07 0.000381154 2.50041e-07 0.000381143 3.05239e-07 0.00038113 3.4639e-07 0.000381118 3.76364e-07 0.000381105 3.96963e-07 0.000381094 4.0941e-07 0.000381084 4.14593e-07 0.000381075 4.13296e-07 0.000381069 4.06292e-07 0.000381063 3.94411e-07 0.00038106 3.7854e-07 0.000381057 3.59596e-07 0.000381056 3.3848e-07 0.000381055 3.16027e-07 0.000381056 2.92969e-07 0.000381057 2.69916e-07 0.000381058 2.47348e-07 2.25624e-07 0.000381059 0.000391742 7.83191e-08 0.000391735 1.8301e-07 0.000391725 2.59701e-07 0.000391714 3.16505e-07 0.000391702 3.58419e-07 0.00039169 3.88451e-07 0.000391678 4.0853e-07 0.000391668 4.19994e-07 0.000391658 4.23859e-07 0.000391651 4.21038e-07 0.000391645 4.12435e-07 0.00039164 3.98991e-07 0.000391637 3.81685e-07 0.000391635 3.61491e-07 0.000391634 3.39338e-07 0.000391634 3.16065e-07 0.000391635 2.92389e-07 0.000391636 2.68893e-07 0.000391637 2.46027e-07 2.24121e-07 0.000391638 0.000402606 8.13117e-08 0.000402599 1.8988e-07 0.000402589 2.69118e-07 0.000402578 3.27424e-07 0.000402567 3.69989e-07 0.000402555 3.9997e-07 0.000402544 4.1943e-07 0.000402535 4.29838e-07 0.000402526 4.32345e-07 0.000402519 4.28e-07 0.000402514 4.17834e-07 0.00040251 4.02895e-07 0.000402507 3.8424e-07 0.000402506 3.62893e-07 0.000402505 3.39799e-07 0.000402506 3.15794e-07 0.000402507 2.91575e-07 0.000402508 2.67699e-07 0.000402509 2.44586e-07 2.22537e-07 0.000402511 0.000413771 8.42373e-08 0.000413764 1.9658e-07 0.000413755 2.78262e-07 0.000413744 3.37959e-07 0.000413733 3.81062e-07 0.000413722 4.10885e-07 0.000413712 4.29638e-07 0.000413703 4.38929e-07 0.000413695 4.40053e-07 0.000413689 4.34198e-07 0.000413684 4.22515e-07 0.000413681 4.06155e-07 0.000413679 3.86241e-07 0.000413678 3.63834e-07 0.000413678 3.39891e-07 0.000413679 3.15236e-07 0.00041368 2.90545e-07 0.000413681 2.66346e-07 0.000413683 2.43032e-07 2.20877e-07 0.000413684 0.000425245 8.70859e-08 0.000425239 2.03087e-07 0.00042523 2.871e-07 0.00042522 3.48074e-07 0.000425209 3.91603e-07 0.000425199 4.21168e-07 0.00042519 4.39135e-07 0.000425181 4.47261e-07 0.000425174 4.46991e-07 0.000425169 4.3965e-07 0.000425165 4.26507e-07 0.000425162 4.08803e-07 0.000425161 3.8772e-07 0.00042516 3.64345e-07 0.00042516 3.39639e-07 0.000425161 3.14411e-07 0.000425163 2.89313e-07 0.000425164 2.64845e-07 0.000425166 2.41372e-07 2.19143e-07 0.000425167 0.000437038 8.98472e-08 0.000437032 2.09378e-07 0.000437023 2.956e-07 0.000437014 3.57734e-07 0.000437004 4.01579e-07 0.000436994 4.30793e-07 0.000436985 4.47905e-07 0.000436978 4.54831e-07 0.000436972 4.53168e-07 0.000436967 4.44375e-07 0.000436964 4.29836e-07 0.000436962 4.1087e-07 0.000436961 3.88706e-07 0.00043696 3.64452e-07 0.000436961 3.39065e-07 0.000436962 3.13336e-07 0.000436964 2.87891e-07 0.000436965 2.63203e-07 0.000436967 2.3961e-07 2.17338e-07 0.000436969 0.000449158 9.25111e-08 0.000449152 2.15428e-07 0.000449144 3.03732e-07 0.000449135 3.66907e-07 0.000449125 4.10961e-07 0.000449117 4.39736e-07 0.000449109 4.55935e-07 0.000449102 4.61638e-07 0.000449096 4.58594e-07 0.000449092 4.48395e-07 0.00044909 4.32528e-07 0.000449088 4.12383e-07 0.000449088 3.89227e-07 0.000449088 3.6418e-07 0.000449089 3.38189e-07 0.00044909 3.12026e-07 0.000449092 2.86291e-07 0.000449093 2.61429e-07 0.000449095 2.37753e-07 2.15464e-07 0.000449097 0.000461614 9.50678e-08 0.000461608 2.21216e-07 0.000461601 3.11466e-07 0.000461592 3.75561e-07 0.000461583 4.1972e-07 0.000461575 4.47978e-07 0.000461568 4.63218e-07 0.000461562 4.67685e-07 0.000461557 4.63284e-07 0.000461554 4.51732e-07 0.000461552 4.34611e-07 0.000461551 4.1337e-07 0.000461551 3.8931e-07 0.000461551 3.63551e-07 0.000461552 3.37031e-07 0.000461554 3.10497e-07 0.000461556 2.84524e-07 0.000461558 2.5953e-07 0.00046156 2.35803e-07 2.13525e-07 0.000461561 0.000474416 9.75073e-08 0.00047441 2.2672e-07 0.000474403 3.18776e-07 0.000474395 3.83669e-07 0.000474387 4.27834e-07 0.000474379 4.55504e-07 0.000474373 4.69747e-07 0.000474367 4.72979e-07 0.000474363 4.67254e-07 0.000474361 4.54408e-07 0.000474359 4.36108e-07 0.000474359 4.13858e-07 0.000474359 3.88977e-07 0.00047436 3.62586e-07 0.000474361 3.35605e-07 0.000474363 3.0876e-07 0.000474365 2.82598e-07 0.000474367 2.57511e-07 0.000474369 2.33764e-07 2.11521e-07 0.000474371 0.000487572 9.98206e-08 0.000487567 2.31919e-07 0.00048756 3.25634e-07 0.000487553 3.91204e-07 0.000487545 4.35281e-07 0.000487538 4.62301e-07 0.000487533 4.75522e-07 0.000487528 4.77529e-07 0.000487525 4.70521e-07 0.000487523 4.56445e-07 0.000487522 4.37047e-07 0.000487522 4.13871e-07 0.000487523 3.88251e-07 0.000487524 3.61303e-07 0.000487526 3.33928e-07 0.000487527 3.06827e-07 0.00048753 2.80521e-07 0.000487532 2.55378e-07 0.000487534 2.31641e-07 2.09455e-07 0.000487536 0.000501094 1.01998e-07 0.000501089 2.36794e-07 0.000501082 3.32017e-07 0.000501075 3.98144e-07 0.000501069 4.42045e-07 0.000501063 4.68362e-07 0.000501058 4.80545e-07 0.000501054 4.81346e-07 0.000501051 4.73102e-07 0.00050105 4.57866e-07 0.000501049 4.3745e-07 0.00050105 4.13431e-07 0.000501051 3.87152e-07 0.000501052 3.59719e-07 0.000501054 3.32013e-07 0.000501057 3.04708e-07 0.000501059 2.78301e-07 0.000501061 2.53136e-07 0.000501063 2.29436e-07 2.07328e-07 0.000501065 0.00051499 1.04033e-07 0.000514985 2.41327e-07 0.00051498 3.37904e-07 0.000514973 4.04469e-07 0.000514967 4.48111e-07 0.000514962 4.73681e-07 0.000514958 4.84819e-07 0.000514954 4.84442e-07 0.000514953 4.75018e-07 0.000514952 4.58694e-07 0.000514952 4.3734e-07 0.000514953 4.12561e-07 0.000514954 3.857e-07 0.000514956 3.57851e-07 0.000514958 3.29872e-07 0.00051496 3.02413e-07 0.000514963 2.75945e-07 0.000514965 2.5079e-07 0.000514967 2.27152e-07 2.05141e-07 0.00051497 0.000529272 1.05916e-07 0.000529267 2.45501e-07 0.000529262 3.43274e-07 0.000529256 4.10163e-07 0.000529251 4.53469e-07 0.000529246 4.78257e-07 0.000529243 4.88353e-07 0.000529241 4.86832e-07 0.000529239 4.76288e-07 0.000529239 4.58952e-07 0.00052924 4.36741e-07 0.000529241 4.11281e-07 0.000529243 3.83912e-07 0.000529245 3.55713e-07 0.000529247 3.27516e-07 0.00052925 2.9995e-07 0.000529252 2.73458e-07 0.000529255 2.48344e-07 0.000529257 2.24791e-07 2.02897e-07 0.000529259 0.000543949 1.0764e-07 0.000543946 2.49301e-07 0.000543941 3.48112e-07 0.000543936 4.15211e-07 0.000543931 4.58113e-07 0.000543927 4.82092e-07 0.000543924 4.91156e-07 0.000543923 4.88534e-07 0.000543922 4.76933e-07 0.000543922 4.5866e-07 0.000543923 4.35674e-07 0.000543925 4.09611e-07 0.000543927 3.81806e-07 0.00054393 3.53318e-07 0.000543932 3.24957e-07 0.000543935 2.97326e-07 0.000543937 2.70848e-07 0.00054394 2.45802e-07 0.000543942 2.22357e-07 2.00597e-07 0.000543945 0.000559034 1.092e-07 0.000559031 2.52715e-07 0.000559027 3.52403e-07 0.000559022 4.19603e-07 0.000559018 4.6204e-07 0.000559015 4.8519e-07 0.000559013 4.9324e-07 0.000559012 4.89565e-07 0.000559012 4.76975e-07 0.000559013 4.57843e-07 0.000559014 4.3416e-07 0.000559016 4.07569e-07 0.000559019 3.79396e-07 0.000559021 3.50679e-07 0.000559024 3.22205e-07 0.000559027 2.94551e-07 0.00055903 2.68118e-07 0.000559032 2.43167e-07 0.000559035 2.19852e-07 1.98242e-07 0.000559037 0.000574537 1.10589e-07 0.000574534 2.55731e-07 0.000574531 3.56137e-07 0.000574527 4.23334e-07 0.000574524 4.65249e-07 0.000574521 4.87558e-07 0.00057452 4.9462e-07 0.00057452 4.89943e-07 0.00057452 4.76433e-07 0.000574521 4.5652e-07 0.000574523 4.32218e-07 0.000574526 4.05174e-07 0.000574528 3.76698e-07 0.000574531 3.47808e-07 0.000574534 3.19268e-07 0.000574537 2.91629e-07 0.00057454 2.65273e-07 0.000574543 2.40443e-07 0.000574545 2.17277e-07 1.95833e-07 0.000574548 0.00059047 1.11804e-07 0.000590468 2.58342e-07 0.000590465 3.59306e-07 0.000590462 4.26399e-07 0.000590459 4.67744e-07 0.000590457 4.89208e-07 0.000590457 4.95312e-07 0.000590457 4.8969e-07 0.000590458 4.75331e-07 0.00059046 4.54713e-07 0.000590462 4.29869e-07 0.000590465 4.02441e-07 0.000590468 3.73726e-07 0.000590471 3.44717e-07 0.000590474 3.16155e-07 0.000590477 2.88569e-07 0.00059048 2.6232e-07 0.000590483 2.37634e-07 0.000590486 2.14635e-07 1.93373e-07 0.000590488 0.000606845 1.12841e-07 0.000606843 2.60541e-07 0.00060684 3.61905e-07 0.000606838 4.28799e-07 0.000606836 4.69531e-07 0.000606835 4.90152e-07 0.000606835 4.95335e-07 0.000606836 4.88826e-07 0.000606838 4.7369e-07 0.00060684 4.52443e-07 0.000606843 4.27131e-07 0.000606846 3.99388e-07 0.000606849 3.70493e-07 0.000606852 3.41416e-07 0.000606856 3.12874e-07 0.000606859 2.85375e-07 0.000606862 2.59261e-07 0.000606865 2.34741e-07 0.000606868 2.11929e-07 1.90861e-07 0.00060687 0.000623674 1.13697e-07 0.000623673 2.62324e-07 0.00062367 3.63933e-07 0.000623669 4.30537e-07 0.000623668 4.70621e-07 0.000623667 4.90406e-07 0.000623668 4.94706e-07 0.000623669 4.87372e-07 0.000623672 4.71532e-07 0.000623674 4.49732e-07 0.000623677 4.24023e-07 0.000623681 3.9603e-07 0.000623684 3.67011e-07 0.000623688 3.37914e-07 0.000623691 3.09433e-07 0.000623695 2.82055e-07 0.000623698 2.56101e-07 0.000623701 2.3177e-07 0.000623703 2.0916e-07 1.883e-07 0.000623706 0.00064097 1.14372e-07 0.000640969 2.63688e-07 0.000640967 3.6539e-07 0.000640966 4.31619e-07 0.000640966 4.71024e-07 0.000640966 4.89986e-07 0.000640967 4.93449e-07 0.000640969 4.85352e-07 0.000640972 4.68879e-07 0.000640975 4.46598e-07 0.000640979 4.20562e-07 0.000640982 3.92382e-07 0.000640986 3.63294e-07 0.00064099 3.34223e-07 0.000640993 3.0584e-07 0.000640997 2.78613e-07 0.000641 2.52846e-07 0.000641003 2.28722e-07 0.000641006 2.0633e-07 1.85692e-07 0.000641008 0.000658745 1.14863e-07 0.000658744 2.64635e-07 0.000658743 3.6628e-07 0.000658743 4.32055e-07 0.000658743 4.70756e-07 0.000658744 4.88913e-07 0.000658746 4.91583e-07 0.000658749 4.82787e-07 0.000658752 4.65752e-07 0.000658755 4.43063e-07 0.000658759 4.16766e-07 0.000658763 3.88458e-07 0.000658767 3.59352e-07 0.000658771 3.30351e-07 0.000658775 3.02102e-07 0.000658778 2.75055e-07 0.000658782 2.49498e-07 0.000658785 2.256e-07 0.000658788 2.03442e-07 1.83037e-07 0.00065879 0.000677014 1.15172e-07 0.000677013 2.65168e-07 0.000677013 3.6661e-07 0.000677013 4.31856e-07 0.000677014 4.69834e-07 0.000677016 4.87206e-07 0.000677018 4.89133e-07 0.000677021 4.79702e-07 0.000677025 4.62175e-07 0.000677029 4.39145e-07 0.000677033 4.12652e-07 0.000677037 3.84272e-07 0.000677041 3.55197e-07 0.000677045 3.26307e-07 0.000677049 2.98226e-07 0.000677053 2.71386e-07 0.000677056 2.46061e-07 0.000677059 2.22408e-07 0.000677062 2.00498e-07 1.80337e-07 0.000677065 0.000695788 1.15301e-07 0.000695788 2.6529e-07 0.000695789 3.66391e-07 0.000695789 4.31038e-07 0.000695791 4.68278e-07 0.000695793 4.84889e-07 0.000695796 4.86122e-07 0.0006958 4.76119e-07 0.000695804 4.58168e-07 0.000695808 4.34864e-07 0.000695813 4.08236e-07 0.000695817 3.79839e-07 0.000695821 3.50842e-07 0.000695826 3.221e-07 0.00069583 2.94219e-07 0.000695833 2.67613e-07 0.000695837 2.42541e-07 0.00069584 2.19149e-07 0.000695843 1.97499e-07 1.77593e-07 0.000695846 0.000715084 1.15251e-07 0.000715084 2.6501e-07 0.000715085 3.65633e-07 0.000715086 4.29617e-07 0.000715089 4.66108e-07 0.000715091 4.81986e-07 0.000715095 4.82575e-07 0.000715099 4.72063e-07 0.000715103 4.53753e-07 0.000715108 4.3024e-07 0.000715113 4.03535e-07 0.000715117 3.75172e-07 0.000715122 3.46295e-07 0.000715126 3.17739e-07 0.000715131 2.90088e-07 0.000715134 2.6374e-07 0.000715138 2.3894e-07 0.000715141 2.15825e-07 0.000715144 1.9445e-07 1.74809e-07 0.000715147 0.000734915 1.15027e-07 0.000734915 2.64335e-07 0.000734916 3.64352e-07 0.000734918 4.27613e-07 0.000734921 4.63348e-07 0.000734925 4.78521e-07 0.000734929 4.78517e-07 0.000734933 4.67556e-07 0.000734938 4.48953e-07 0.000734943 4.25291e-07 0.000734948 3.98565e-07 0.000734953 3.70283e-07 0.000734958 3.41569e-07 0.000734962 3.13232e-07 0.000734966 2.8584e-07 0.00073497 2.59772e-07 0.000734974 2.35264e-07 0.000734977 2.12441e-07 0.00073498 1.91351e-07 1.71984e-07 0.000734983 0.000755295 1.14633e-07 0.000755296 2.63278e-07 0.000755298 3.62564e-07 0.0007553 4.25048e-07 0.000755304 4.60023e-07 0.000755308 4.7452e-07 0.000755312 4.73973e-07 0.000755317 4.62624e-07 0.000755322 4.43788e-07 0.000755328 4.20036e-07 0.000755333 3.9334e-07 0.000755338 3.65187e-07 0.000755343 3.36673e-07 0.000755348 3.08588e-07 0.000755352 2.8148e-07 0.000755356 2.55715e-07 0.00075536 2.31515e-07 0.000755363 2.08998e-07 0.000755366 1.88205e-07 1.69122e-07 0.000755369 0.000776241 1.14072e-07 0.000776242 2.6185e-07 0.000776244 3.60288e-07 0.000776248 4.21944e-07 0.000776251 4.56157e-07 0.000776256 4.70011e-07 0.000776261 4.6897e-07 0.000776266 4.5729e-07 0.000776272 4.3828e-07 0.000776277 4.14493e-07 0.000776283 3.87878e-07 0.000776288 3.59895e-07 0.000776293 3.31618e-07 0.000776298 3.03815e-07 0.000776302 2.77017e-07 0.000776306 2.51574e-07 0.00077631 2.27699e-07 0.000776314 2.05501e-07 0.000776317 1.85015e-07 1.66224e-07 0.00077632 0.000797767 1.13353e-07 0.000797769 2.60065e-07 0.000797772 3.57543e-07 0.000797775 4.18326e-07 0.00079778 4.51779e-07 0.000797785 4.6502e-07 0.00079779 4.63534e-07 0.000797796 4.51578e-07 0.000797802 4.32449e-07 0.000797808 4.0868e-07 0.000797813 3.82192e-07 0.000797819 3.54421e-07 0.000797824 3.26415e-07 0.000797829 2.98922e-07 0.000797833 2.72456e-07 0.000797838 2.47355e-07 0.000797842 2.23819e-07 0.000797845 2.01952e-07 0.000797848 1.81783e-07 1.63292e-07 0.000797851 0.000819891 1.1248e-07 0.000819893 2.57939e-07 0.000819896 3.54352e-07 0.0008199 4.14219e-07 0.000819905 4.46915e-07 0.00081991 4.59575e-07 0.000819916 4.57691e-07 0.000819922 4.45512e-07 0.000819929 4.26318e-07 0.000819935 4.02615e-07 0.00081994 3.76298e-07 0.000819946 3.48775e-07 0.000819951 3.21072e-07 0.000819956 2.93916e-07 0.000819961 2.67804e-07 0.000819965 2.43061e-07 0.000819969 2.1988e-07 0.000819973 1.98355e-07 0.000819976 1.78513e-07 1.60329e-07 0.000819979 0.000842628 1.11461e-07 0.00084263 2.55487e-07 0.000842634 3.50737e-07 0.000842638 4.09651e-07 0.000842644 4.41594e-07 0.00084265 4.53703e-07 0.000842656 4.51466e-07 0.000842662 4.39116e-07 0.000842669 4.19906e-07 0.000842675 3.96316e-07 0.000842681 3.70211e-07 0.000842687 3.42972e-07 0.000842692 3.15601e-07 0.000842697 2.88805e-07 0.000842702 2.63067e-07 0.000842707 2.387e-07 0.000842711 2.15885e-07 0.000842714 1.94714e-07 0.000842717 1.75206e-07 1.57336e-07 0.00084272 0.000865995 1.10303e-07 0.000865998 2.52728e-07 0.000866002 3.46722e-07 0.000866007 4.04649e-07 0.000866013 4.35845e-07 0.000866019 4.47434e-07 0.000866026 4.44886e-07 0.000866032 4.32412e-07 0.000866039 4.13233e-07 0.000866046 3.89799e-07 0.000866052 3.63944e-07 0.000866058 3.37022e-07 0.000866063 3.10011e-07 0.000866069 2.83598e-07 0.000866073 2.58253e-07 0.000866078 2.34275e-07 0.000866082 2.1184e-07 0.000866086 1.91031e-07 0.000866089 1.71866e-07 1.54316e-07 0.000866092 0.000890011 1.09014e-07 0.000890014 2.49678e-07 0.000890018 3.42332e-07 0.000890024 3.9924e-07 0.00089003 4.29696e-07 0.000890036 4.40795e-07 0.000890043 4.37978e-07 0.00089005 4.25423e-07 0.000890057 4.0632e-07 0.000890064 3.83082e-07 0.00089007 3.57513e-07 0.000890077 3.30937e-07 0.000890082 3.04311e-07 0.000890088 2.78303e-07 0.000890092 2.53367e-07 0.000890097 2.29793e-07 0.000890101 2.07748e-07 0.000890105 1.8731e-07 0.000890108 1.68495e-07 1.51271e-07 0.000890111 0.000914692 1.07603e-07 0.000914696 2.46358e-07 0.0009147 3.3759e-07 0.000914706 3.93454e-07 0.000914713 4.23177e-07 0.00091472 4.33813e-07 0.000914727 4.30766e-07 0.000914734 4.18173e-07 0.000914741 3.99186e-07 0.000914748 3.76182e-07 0.000914755 3.5093e-07 0.000914761 3.24729e-07 0.000914767 2.98511e-07 0.000914772 2.72927e-07 0.000914777 2.48415e-07 0.000914782 2.25258e-07 0.000914786 2.03613e-07 0.00091479 1.83556e-07 0.000914793 1.65097e-07 1.48204e-07 0.000914796 0.000940058 1.06077e-07 0.000940062 2.42784e-07 0.000940067 3.32524e-07 0.000940073 3.87317e-07 0.00094008 4.16316e-07 0.000940087 4.26516e-07 0.000940095 4.23275e-07 0.000940102 4.10684e-07 0.00094011 3.91851e-07 0.000940117 3.69114e-07 0.000940123 3.44211e-07 0.00094013 3.1841e-07 0.000940136 2.92621e-07 0.000940141 2.67477e-07 0.000940146 2.43405e-07 0.000940151 2.20675e-07 0.000940155 1.99441e-07 0.000940159 1.79771e-07 0.000940162 1.61674e-07 1.45117e-07 0.000940165 0.000966128 1.04445e-07 0.000966131 2.38977e-07 0.000966137 3.27157e-07 0.000966143 3.80859e-07 0.00096615 4.09141e-07 0.000966158 4.18932e-07 0.000966166 4.1553e-07 0.000966174 4.02976e-07 0.000966181 3.84332e-07 0.000966188 3.61895e-07 0.000966195 3.37367e-07 0.000966202 3.1199e-07 0.000966207 2.86649e-07 0.000966213 2.61963e-07 0.000966218 2.38343e-07 0.000966223 2.16051e-07 0.000966227 1.95235e-07 0.000966231 1.75959e-07 0.000966234 1.5823e-07 1.42013e-07 0.000966237 0.00099292 1.02716e-07 0.000992924 2.34956e-07 0.00099293 3.21516e-07 0.000992936 3.74107e-07 0.000992944 4.01681e-07 0.000992952 4.11086e-07 0.00099296 4.07555e-07 0.000992968 3.95072e-07 0.000992975 3.76649e-07 0.000992983 3.5454e-07 0.00099299 3.30413e-07 0.000992996 3.05479e-07 0.000993002 2.80605e-07 0.000993008 2.5639e-07 0.000993013 2.33234e-07 0.000993017 2.1139e-07 0.000993022 1.90999e-07 0.000993026 1.72123e-07 0.000993029 1.54766e-07 1.38894e-07 0.000993032 0.00102046 1.00898e-07 0.00102046 2.30739e-07 0.00102047 3.15624e-07 0.00102047 3.67089e-07 0.00102048 3.93962e-07 0.00102049 4.03004e-07 0.0010205 3.99374e-07 0.0010205 3.86992e-07 0.00102051 3.68819e-07 0.00102052 3.47064e-07 0.00102053 3.2336e-07 0.00102053 2.9889e-07 0.00102054 2.74498e-07 0.00102055 2.50767e-07 0.00102055 2.28085e-07 0.00102056 2.06697e-07 0.00102056 1.86738e-07 0.00102056 1.68268e-07 0.00102057 1.51287e-07 1.35762e-07 0.00102057 0.00104875 9.89998e-08 0.00104876 2.26345e-07 0.00104876 3.09507e-07 0.00104877 3.5983e-07 0.00104878 3.86012e-07 0.00104879 3.94711e-07 0.0010488 3.91008e-07 0.0010488 3.78756e-07 0.00104881 3.60859e-07 0.00104882 3.39482e-07 0.00104883 3.16221e-07 0.00104883 2.92232e-07 0.00104884 2.68336e-07 0.00104885 2.451e-07 0.00104885 2.22902e-07 0.00104886 2.01977e-07 0.00104886 1.82457e-07 0.00104886 1.64396e-07 0.00104887 1.47796e-07 1.32621e-07 0.00104887 0.00107784 9.70287e-08 0.00107784 2.21793e-07 0.00107785 3.03188e-07 0.00107786 3.52357e-07 0.00107786 3.77856e-07 0.00107787 3.86232e-07 0.00107788 3.8248e-07 0.00107789 3.70382e-07 0.0010779 3.52785e-07 0.00107791 3.31808e-07 0.00107791 3.09008e-07 0.00107792 2.85515e-07 0.00107793 2.62128e-07 0.00107793 2.39398e-07 0.00107794 2.1769e-07 0.00107794 1.97235e-07 0.00107795 1.78158e-07 0.00107795 1.60511e-07 0.00107795 1.44295e-07 1.29472e-07 0.00107796 0.00110773 9.49937e-08 0.00110773 2.17099e-07 0.00110774 2.96689e-07 0.00110775 3.44696e-07 0.00110776 3.69518e-07 0.00110776 3.7759e-07 0.00110777 3.73811e-07 0.00110778 3.6189e-07 0.00110779 3.44614e-07 0.0011078 3.24054e-07 0.0011078 3.01733e-07 0.00110781 2.78749e-07 0.00110782 2.55881e-07 0.00110782 2.33665e-07 0.00110783 2.12457e-07 0.00110783 1.92477e-07 0.00110784 1.73847e-07 0.00110784 1.56617e-07 0.00110784 1.40786e-07 1.26318e-07 0.00110785 0.00113845 9.29015e-08 0.00113845 2.1228e-07 0.00113846 2.90033e-07 0.00113847 3.36868e-07 0.00113847 3.61023e-07 0.00113848 3.68806e-07 0.00113849 3.6502e-07 0.0011385 3.53296e-07 0.00113851 3.3636e-07 0.00113852 3.16236e-07 0.00113852 2.94406e-07 0.00113853 2.71943e-07 0.00113854 2.49604e-07 0.00113854 2.2791e-07 0.00113855 2.07206e-07 0.00113855 1.87706e-07 0.00113856 1.69527e-07 0.00113856 1.52717e-07 0.00113857 1.37274e-07 1.23162e-07 0.00113857 0.00117002 9.07604e-08 0.00117002 2.07354e-07 0.00117003 2.83242e-07 0.00117004 3.28899e-07 0.00117005 3.52393e-07 0.00117006 3.59902e-07 0.00117006 3.56127e-07 0.00117007 3.44618e-07 0.00117008 3.28039e-07 0.00117009 3.08364e-07 0.0011701 2.87038e-07 0.0011701 2.65106e-07 0.00117011 2.43304e-07 0.00117012 2.22138e-07 0.00117012 2.01943e-07 0.00117013 1.82927e-07 0.00117013 1.65202e-07 0.00117013 1.48814e-07 0.00117014 1.33761e-07 1.20006e-07 0.00117014 0.00120246 8.85765e-08 0.00120247 2.02335e-07 0.00120248 2.76333e-07 0.00120248 3.20808e-07 0.00120249 3.43649e-07 0.0012025 3.50898e-07 0.00120251 3.47149e-07 0.00120252 3.35872e-07 0.00120253 3.19664e-07 0.00120254 3.0045e-07 0.00120254 2.79639e-07 0.00120255 2.58247e-07 0.00120256 2.36988e-07 0.00120256 2.16356e-07 0.00120257 1.96675e-07 0.00120257 1.78145e-07 0.00120258 1.60876e-07 0.00120258 1.44912e-07 0.00120258 1.30249e-07 1.16852e-07 0.00120259 0.00123581 8.63572e-08 0.00123582 1.97238e-07 0.00123582 2.69328e-07 0.00123583 3.12617e-07 0.00123584 3.34812e-07 0.00123585 3.41812e-07 0.00123586 3.38104e-07 0.00123587 3.27072e-07 0.00123588 3.11247e-07 0.00123588 2.92506e-07 0.00123589 2.72219e-07 0.0012359 2.51373e-07 0.0012359 2.30664e-07 0.00123591 2.10569e-07 0.00123591 1.91404e-07 0.00123592 1.73363e-07 0.00123592 1.56552e-07 0.00123593 1.41013e-07 0.00123593 1.26741e-07 1.13703e-07 0.00123593 0.00127008 8.4108e-08 0.00127009 1.92076e-07 0.00127009 2.62242e-07 0.0012701 3.04345e-07 0.00127011 3.259e-07 0.00127012 3.32663e-07 0.00127013 3.29007e-07 0.00127014 3.18232e-07 0.00127015 3.02802e-07 0.00127015 2.84542e-07 0.00127016 2.64786e-07 0.00127017 2.44492e-07 0.00127018 2.24337e-07 0.00127018 2.04783e-07 0.00127019 1.86137e-07 0.00127019 1.68587e-07 0.0012702 1.52234e-07 0.0012702 1.3712e-07 0.0012702 1.2324e-07 1.1056e-07 0.00127021 0.0013053 8.18354e-08 0.00130531 1.86862e-07 0.00130532 2.55093e-07 0.00130532 2.96008e-07 0.00130533 3.1693e-07 0.00130534 3.23465e-07 0.00130535 3.19874e-07 0.00130536 3.09365e-07 0.00130537 2.94339e-07 0.00130538 2.76568e-07 0.00130538 2.57348e-07 0.00130539 2.37611e-07 0.0013054 2.18013e-07 0.0013054 1.99003e-07 0.00130541 1.80877e-07 0.00130541 1.63818e-07 0.00130542 1.47925e-07 0.00130542 1.33236e-07 0.00130542 1.19747e-07 1.07425e-07 0.00130543 0.0013415 7.95439e-08 0.00134151 1.81609e-07 0.00134151 2.47895e-07 0.00134152 2.87624e-07 0.00134153 3.07919e-07 0.00134154 3.14235e-07 0.00134155 3.10717e-07 0.00134156 3.00484e-07 0.00134157 2.85868e-07 0.00134157 2.68593e-07 0.00134158 2.49914e-07 0.00134159 2.30737e-07 0.0013416 2.11699e-07 0.0013416 1.93234e-07 0.00134161 1.75629e-07 0.00134161 1.59062e-07 0.00134162 1.43628e-07 0.00134162 1.29364e-07 0.00134162 1.16266e-07 1.04301e-07 0.00134163 0.0013787 7.72394e-08 0.00137871 1.76325e-07 0.00137872 2.40663e-07 0.00137872 2.79207e-07 0.00137873 2.98881e-07 0.00137874 3.04986e-07 0.00137875 3.01549e-07 0.00137876 2.91599e-07 0.00137877 2.774e-07 0.00137878 2.60624e-07 0.00137878 2.4249e-07 0.00137879 2.23876e-07 0.0013788 2.05398e-07 0.0013788 1.87479e-07 0.00137881 1.70395e-07 0.00137881 1.5432e-07 0.00137882 1.39345e-07 0.00137882 1.25505e-07 0.00137882 1.12797e-07 1.01189e-07 0.00137883 0.00141694 7.49251e-08 0.00141694 1.71022e-07 0.00141695 2.33408e-07 0.00141696 2.7077e-07 0.00141697 2.89829e-07 0.00141698 2.95731e-07 0.00141699 2.92381e-07 0.00141699 2.8272e-07 0.001417 2.68942e-07 0.00141701 2.52669e-07 0.00141702 2.35083e-07 0.00141702 2.17033e-07 0.00141703 1.99117e-07 0.00141704 1.81743e-07 0.00141704 1.6518e-07 0.00141705 1.49596e-07 0.00141705 1.35078e-07 0.00141705 1.21662e-07 0.00141706 1.09343e-07 9.80903e-08 0.00141706 0.00145623 7.26063e-08 0.00145624 1.65708e-07 0.00145624 2.26142e-07 0.00145625 2.62326e-07 0.00145626 2.80776e-07 0.00145627 2.8648e-07 0.00145628 2.83223e-07 0.00145629 2.73855e-07 0.0014563 2.60503e-07 0.0014563 2.44736e-07 0.00145631 2.27698e-07 0.00145632 2.10212e-07 0.00145632 1.92858e-07 0.00145633 1.76029e-07 0.00145634 1.59987e-07 0.00145634 1.44892e-07 0.00145634 1.30831e-07 0.00145635 1.17837e-07 0.00145635 1.05905e-07 9.50066e-08 0.00145635 0.00149661 7.02852e-08 0.00149662 1.60389e-07 0.00149663 2.18874e-07 0.00149664 2.53884e-07 0.00149664 2.71731e-07 0.00149665 2.77242e-07 0.00149666 2.74083e-07 0.00149667 2.65013e-07 0.00149668 2.52088e-07 0.00149669 2.36828e-07 0.0014967 2.2034e-07 0.0014967 2.03419e-07 0.00149671 1.86625e-07 0.00149671 1.7034e-07 0.00149672 1.54817e-07 0.00149672 1.4021e-07 0.00149673 1.26604e-07 0.00149673 1.1403e-07 0.00149674 1.02485e-07 9.1939e-08 0.00149674 0.00153812 6.7966e-08 0.00153812 1.55074e-07 0.00153813 2.11613e-07 0.00153814 2.45455e-07 0.00153815 2.62703e-07 0.00153816 2.68026e-07 0.00153817 2.6497e-07 0.00153817 2.56199e-07 0.00153818 2.43704e-07 0.00153819 2.28951e-07 0.0015382 2.13012e-07 0.00153821 1.96655e-07 0.00153821 1.80421e-07 0.00153822 1.64679e-07 0.00153822 1.49673e-07 0.00153823 1.35553e-07 0.00153823 1.224e-07 0.00153823 1.10245e-07 0.00153824 9.90835e-08 8.88883e-08 0.00153824 0.00158077 6.56499e-08 0.00158078 1.49766e-07 0.00158078 2.04365e-07 0.00158079 2.37044e-07 0.0015808 2.53699e-07 0.00158081 2.58839e-07 0.00158082 2.55888e-07 0.00158083 2.47419e-07 0.00158084 2.35354e-07 0.00158085 2.2111e-07 0.00158085 2.05719e-07 0.00158086 1.89925e-07 0.00158087 1.74249e-07 0.00158087 1.59048e-07 0.00158088 1.44556e-07 0.00158088 1.30921e-07 0.00158088 1.18219e-07 0.00158089 1.0648e-07 0.00158089 9.57013e-08 8.58551e-08 0.0015809 0.00162461 6.33401e-08 0.00162461 1.44471e-07 0.00162462 1.97136e-07 0.00162463 2.28658e-07 0.00162464 2.44725e-07 0.00162465 2.49686e-07 0.00162466 2.46842e-07 0.00162467 2.38677e-07 0.00162467 2.27042e-07 0.00162468 2.13305e-07 0.00162469 1.98462e-07 0.0016247 1.83229e-07 0.0016247 1.68109e-07 0.00162471 1.53446e-07 0.00162471 1.39468e-07 0.00162472 1.26315e-07 0.00162472 1.14062e-07 0.00162473 1.02737e-07 0.00162473 9.23388e-08 8.28398e-08 0.00162473 0.00166966 6.10369e-08 0.00166967 1.39191e-07 0.00166967 1.8993e-07 0.00166968 2.20301e-07 0.00166969 2.35784e-07 0.0016697 2.40569e-07 0.00166971 2.37835e-07 0.00166972 2.29974e-07 0.00166973 2.1877e-07 0.00166973 2.0554e-07 0.00166974 1.91242e-07 0.00166975 1.76568e-07 0.00166975 1.62002e-07 0.00166976 1.47876e-07 0.00166977 1.34409e-07 0.00166977 1.21735e-07 0.00166977 1.09928e-07 0.00166978 9.90166e-08 0.00166978 8.89963e-08 7.98425e-08 0.00166978 0.00171596 5.87424e-08 0.00171597 1.33929e-07 0.00171598 1.82748e-07 0.00171599 2.11975e-07 0.00171599 2.26879e-07 0.001716 2.3149e-07 0.00171601 2.28868e-07 0.00171602 2.21312e-07 0.00171603 2.10538e-07 0.00171604 1.97813e-07 0.00171604 1.8406e-07 0.00171605 1.69943e-07 0.00171606 1.55929e-07 0.00171606 1.42337e-07 0.00171607 1.29378e-07 0.00171607 1.17182e-07 0.00171608 1.05819e-07 0.00171608 9.53174e-08 0.00171608 8.56733e-08 7.68629e-08 0.00171609 0.00176355 5.64558e-08 0.00176356 1.28684e-07 0.00176356 1.75592e-07 0.00176357 2.0368e-07 0.00176358 2.18009e-07 0.00176359 2.22451e-07 0.0017636 2.19941e-07 0.00176361 2.1269e-07 0.00176362 2.02346e-07 0.00176362 1.90125e-07 0.00176363 1.76915e-07 0.00176364 1.63353e-07 0.00176364 1.49888e-07 0.00176365 1.36828e-07 0.00176365 1.24374e-07 0.00176366 1.12653e-07 0.00176366 1.01733e-07 0.00176367 9.16391e-08 0.00176367 8.23692e-08 7.39003e-08 0.00176367 0.00181246 5.41782e-08 0.00181246 1.23457e-07 0.00181247 1.68461e-07 0.00181248 1.95415e-07 0.00181249 2.09173e-07 0.0018125 2.13447e-07 0.0018125 2.11051e-07 0.00181251 2.04106e-07 0.00181252 1.94191e-07 0.00181253 1.82473e-07 0.00181254 1.69803e-07 0.00181254 1.56794e-07 0.00181255 1.43877e-07 0.00181255 1.31346e-07 0.00181256 1.19396e-07 0.00181256 1.08148e-07 0.00181257 9.76678e-08 0.00181257 8.79801e-08 0.00181257 7.90827e-08 7.09535e-08 0.00181258 0.00186272 5.19072e-08 0.00186272 1.18243e-07 0.00186273 1.61349e-07 0.00186274 1.87175e-07 0.00186275 2.00366e-07 0.00186276 2.04474e-07 0.00186277 2.02194e-07 0.00186277 1.95555e-07 0.00186278 1.86068e-07 0.00186279 1.74852e-07 0.0018628 1.62722e-07 0.0018628 1.50265e-07 0.00186281 1.37893e-07 0.00186282 1.25889e-07 0.00186282 1.14441e-07 0.00186283 1.03664e-07 0.00186283 9.3622e-08 0.00186283 8.43387e-08 0.00186284 7.58119e-08 6.8021e-08 0.00186284 0.00191438 4.96424e-08 0.00191438 1.13041e-07 0.00191439 1.54253e-07 0.0019144 1.78954e-07 0.0019144 1.91581e-07 0.00191441 1.95526e-07 0.00191442 1.93363e-07 0.00191443 1.8703e-07 0.00191444 1.77972e-07 0.00191445 1.67257e-07 0.00191445 1.55666e-07 0.00191446 1.43759e-07 0.00191447 1.31931e-07 0.00191447 1.20454e-07 0.00191448 1.09506e-07 0.00191448 9.91984e-08 0.00191448 8.95927e-08 0.00191449 8.07121e-08 0.00191449 7.25546e-08 6.51006e-08 0.00191449 0.00196746 4.73802e-08 0.00196747 1.07842e-07 0.00196748 1.47163e-07 0.00196748 1.70742e-07 0.00196749 1.82807e-07 0.0019675 1.86592e-07 0.00196751 1.84547e-07 0.00196752 1.78522e-07 0.00196753 1.69893e-07 0.00196753 1.5968e-07 0.00196754 1.48627e-07 0.00196755 1.3727e-07 0.00196755 1.25985e-07 0.00196756 1.15033e-07 0.00196756 1.04584e-07 0.00196757 9.47453e-08 0.00196757 8.55753e-08 0.00196758 7.70966e-08 0.00196758 6.93076e-08 6.21896e-08 0.00196758 0.00202202 4.51172e-08 0.00202203 1.02637e-07 0.00202204 1.40067e-07 0.00202205 1.62526e-07 0.00202205 1.74031e-07 0.00202206 1.77657e-07 0.00202207 1.75734e-07 0.00202208 1.70019e-07 0.00202209 1.61821e-07 0.0020221 1.52111e-07 0.0020221 1.41597e-07 0.00202211 1.3079e-07 0.00202212 1.20049e-07 0.00202212 1.09621e-07 0.00202213 9.96711e-08 0.00202213 9.03004e-08 0.00202213 8.15653e-08 0.00202214 7.34877e-08 0.00202214 6.60665e-08 5.92839e-08 0.00202214 0.0020781 4.28482e-08 0.0020781 9.74157e-08 0.00207811 1.32949e-07 0.00207812 1.54286e-07 0.00207813 1.65234e-07 0.00207814 1.68704e-07 0.00207815 1.66905e-07 0.00207815 1.61502e-07 0.00207816 1.53738e-07 0.00207817 1.44532e-07 0.00207818 1.3456e-07 0.00207818 1.24304e-07 0.00207819 1.14108e-07 0.00207819 1.04206e-07 0.0020782 9.4756e-08 0.0020782 8.58545e-08 0.00207821 7.75553e-08 0.00207821 6.98797e-08 0.00207821 6.28268e-08 5.638e-08 0.00207822 0.00213573 4.05663e-08 0.00213573 9.21604e-08 0.00213574 1.25787e-07 0.00213575 1.45999e-07 0.00213576 1.5639e-07 0.00213577 1.59708e-07 0.00213577 1.58039e-07 0.00213578 1.52954e-07 0.00213579 1.45628e-07 0.0021358 1.36933e-07 0.00213581 1.27506e-07 0.00213581 1.17805e-07 0.00213582 1.08156e-07 0.00213582 9.87834e-08 0.00213583 8.98342e-08 0.00213583 8.14021e-08 0.00213584 7.3539e-08 0.00213584 6.62655e-08 0.00213584 5.95811e-08 5.34704e-08 0.00213585 0.00219495 3.82624e-08 0.00219496 8.68491e-08 0.00219497 1.18552e-07 0.00219498 1.37632e-07 0.00219498 1.47467e-07 0.00219499 1.50636e-07 0.002195 1.49101e-07 0.00219501 1.44339e-07 0.00219502 1.37458e-07 0.00219503 1.29279e-07 0.00219503 1.20402e-07 0.00219504 1.11261e-07 0.00219505 1.02165e-07 0.00219505 9.33255e-08 0.00219506 8.48824e-08 0.00219506 7.69256e-08 0.00219507 6.95036e-08 0.00219507 6.26363e-08 0.00219507 5.63237e-08 5.05516e-08 0.00219508 0.00225582 3.59244e-08 0.00225583 8.14528e-08 0.00225584 1.11205e-07 0.00225585 1.29144e-07 0.00225585 1.38422e-07 0.00225586 1.41451e-07 0.00225587 1.40061e-07 0.00225588 1.35637e-07 0.00225589 1.29214e-07 0.0022559 1.21563e-07 0.0022559 1.13247e-07 0.00225591 1.04676e-07 0.00225592 9.61389e-08 0.00225592 8.7837e-08 0.00225593 7.99032e-08 0.00225593 7.24217e-08 0.00225594 6.5441e-08 0.00225594 5.89805e-08 0.00225594 5.30407e-08 4.76087e-08 0.00225595 0.00231838 3.35354e-08 0.00231839 7.59307e-08 0.00231839 1.03694e-07 0.0023184 1.20475e-07 0.00231841 1.29195e-07 0.00231842 1.32087e-07 0.00231843 1.30852e-07 0.00231844 1.26773e-07 0.00231845 1.20818e-07 0.00231846 1.13705e-07 0.00231846 1.05962e-07 0.00231847 9.79719e-08 0.00231848 9.00072e-08 0.00231848 8.22563e-08 0.00231849 7.4845e-08 0.00231849 6.78551e-08 0.0023185 6.13292e-08 0.0023185 5.52866e-08 0.0023185 4.97282e-08 4.46429e-08 0.00231851 0.00238267 3.1073e-08 0.00238268 7.02272e-08 0.00238269 9.59463e-08 0.0023827 1.11551e-07 0.00238271 1.19717e-07 0.00238272 1.22493e-07 0.00238273 1.21441e-07 0.00238273 1.17741e-07 0.00238274 1.12286e-07 0.00238275 1.05738e-07 0.00238276 9.85894e-08 0.00238276 9.11968e-08 0.00238277 8.38151e-08 0.00238278 7.6622e-08 0.00238278 6.97364e-08 0.00238279 6.32328e-08 0.00238279 5.71586e-08 0.00238279 5.15324e-08 0.0023828 4.6356e-08 4.16195e-08 0.0023828 0.00244875 2.85044e-08 0.00244876 6.42614e-08 0.00244876 8.78581e-08 0.00244877 1.02254e-07 0.00244878 1.09859e-07 0.00244879 1.12524e-07 0.0024488 1.11663e-07 0.00244881 1.08355e-07 0.00244882 1.03414e-07 0.00244883 9.74527e-08 0.00244884 9.09235e-08 0.00244884 8.41571e-08 0.00244885 7.73897e-08 0.00244886 7.07864e-08 0.00244886 6.4459e-08 0.00244887 5.84832e-08 0.00244887 5.28943e-08 0.00244887 4.7711e-08 0.00244888 4.29366e-08 3.85632e-08 0.00244888 0.00251666 2.57819e-08 0.00251666 5.79163e-08 0.00251667 7.92899e-08 0.00251668 9.24559e-08 0.00251669 9.95296e-08 0.0025167 1.02143e-07 0.00251671 1.0155e-07 0.00251672 9.87096e-08 0.00251673 9.43523e-08 0.00251674 8.90307e-08 0.00251675 8.31584e-08 0.00251675 7.70403e-08 0.00251676 7.08976e-08 0.00251677 6.48863e-08 0.00251677 5.91115e-08 0.00251678 5.36373e-08 0.00251678 4.85154e-08 0.00251679 4.37645e-08 0.00251679 3.93883e-08 3.538e-08 0.00251679 0.00258645 2.28282e-08 0.00258646 5.10089e-08 0.00258646 7.00051e-08 0.00258648 8.18715e-08 0.00258649 8.83844e-08 0.0025865 9.09392e-08 0.00258651 9.06206e-08 0.00258652 8.82686e-08 0.00258653 8.45308e-08 0.00258654 7.99014e-08 0.00258655 7.47522e-08 0.00258655 6.93585e-08 0.00258656 6.39205e-08 0.00258657 5.85801e-08 0.00258657 5.34377e-08 0.00258658 4.85684e-08 0.00258658 4.39937e-08 0.00258659 3.97349e-08 0.00258659 3.57992e-08 3.21837e-08 0.00258659 0.00265818 1.95163e-08 0.00265818 4.32525e-08 0.00265819 5.97578e-08 0.0026582 7.03646e-08 0.00265822 7.64391e-08 0.00265823 7.91021e-08 0.00265824 7.92343e-08 0.00265825 7.75293e-08 0.00265826 7.45347e-08 0.00265827 7.06801e-08 0.00265828 6.62977e-08 0.00265829 6.16411e-08 0.00265829 5.6899e-08 0.0026583 5.2209e-08 0.00265831 4.76636e-08 0.00265831 4.33135e-08 0.00265832 3.92286e-08 0.00265832 3.54284e-08 0.00265832 3.19193e-08 2.86989e-08 0.00265833 0.00273189 1.57222e-08 0.0027319 3.40198e-08 0.00273191 4.77302e-08 0.00273193 5.69274e-08 0.00273194 6.25117e-08 0.00273195 6.52945e-08 0.00273197 6.59364e-08 0.00273198 6.49805e-08 0.00273199 6.28714e-08 0.002732 5.99662e-08 0.00273201 5.65463e-08 0.00273202 5.28294e-08 0.00273203 4.89813e-08 0.00273204 4.51249e-08 0.00273204 4.13563e-08 0.00273205 3.77635e-08 0.00273205 3.43415e-08 0.00273206 3.11202e-08 0.00273206 2.81163e-08 2.53357e-08 0.00273206 0.00280765 1.0754e-08 0.00280766 2.31403e-08 0.00280768 3.41003e-08 0.00280769 4.20302e-08 0.00280771 4.73819e-08 0.00280772 5.05845e-08 0.00280773 5.20191e-08 0.00280775 5.20433e-08 0.00280776 5.09825e-08 0.00280777 4.91215e-08 0.00280778 4.67012e-08 0.00280779 4.39197e-08 0.0028078 4.09353e-08 0.0028078 3.78709e-08 0.00280781 3.48087e-08 0.00280782 3.17802e-08 0.00280782 2.89035e-08 0.00280783 2.62e-08 0.00280783 2.36818e-08 2.13543e-08 0.00280784 0.00288552 0.00288553 0.00288555 0.00288557 0.00288559 0.00288561 0.00288563 0.00288564 0.00288566 0.00288567 0.00288568 0.00288569 0.0028857 0.00288571 0.00288572 0.00288572 0.00288573 0.00288573 0.00288573 0.00288574 0.000191404 6.47854e-07 0.000190925 4.78212e-07 0.00019048 4.45656e-07 0.000190067 4.13071e-07 0.000189666 4.00249e-07 0.000189268 3.98108e-07 0.00018887 3.98753e-07 0.000188469 4.00249e-07 0.000188067 4.01983e-07 0.000187664 4.03516e-07 0.000187259 4.04773e-07 0.000186853 4.05713e-07 0.000186447 4.06441e-07 0.00018604 4.06943e-07 0.000185633 4.07347e-07 0.000185225 4.07617e-07 0.000184817 4.07886e-07 0.000184409 4.08084e-07 0.000184001 4.08354e-07 0.000183592 4.08587e-07 0.000183183 4.08948e-07 0.000182774 4.09287e-07 0.000182364 4.09798e-07 0.000181954 4.10287e-07 0.000181543 4.10988e-07 0.000181131 4.11654e-07 0.000180718 4.12569e-07 0.000180305 4.13428e-07 0.00017989 4.14574e-07 0.000179475 4.15635e-07 0.000179058 4.17023e-07 0.00017864 4.18289e-07 0.00017822 4.19927e-07 0.000177798 4.21397e-07 0.000177375 4.2329e-07 0.00017695 4.24961e-07 0.000176523 4.27111e-07 0.000176094 4.28979e-07 0.000175662 4.31385e-07 0.000175229 4.33444e-07 0.000174793 4.36105e-07 0.000174355 4.38347e-07 0.000173913 4.41257e-07 0.00017347 4.43674e-07 0.000173023 4.46824e-07 0.000172573 4.49408e-07 0.000172121 4.52783e-07 0.000171665 4.55526e-07 0.000171206 4.59105e-07 0.000170744 4.61999e-07 0.000170278 4.65755e-07 0.000169809 4.68791e-07 0.000169337 4.72689e-07 0.000168861 4.7586e-07 0.000168381 4.79856e-07 0.000167898 4.83154e-07 0.000167411 4.87197e-07 0.00016692 4.90611e-07 0.000166425 4.94642e-07 0.000165927 4.98154e-07 0.000165425 5.02117e-07 0.00016492 5.05695e-07 0.00016441 5.09542e-07 0.000163897 5.13126e-07 0.00016338 5.16834e-07 0.00016286 5.20317e-07 0.000162336 5.23917e-07 0.000161809 5.27107e-07 0.000161278 5.30729e-07 0.000160745 5.33298e-07 0.000160207 5.37235e-07 0.000159669 5.38642e-07 0.000159125 5.43468e-07 0.000158582 5.42818e-07 0.000158033 5.49538e-07 0.000157487 5.45505e-07 0.000156932 5.55607e-07 0.000156385 5.46927e-07 0.000155826 5.58585e-07 5.68422e-07 0.000197404 4.56503e-07 0.00019741 4.71571e-07 0.000197376 4.79812e-07 0.000197302 4.87829e-07 0.000197206 4.95539e-07 0.000197101 5.03754e-07 0.000196988 5.11427e-07 0.00019687 5.18586e-07 0.000196746 5.25402e-07 0.000196618 5.31825e-07 0.000196485 5.37899e-07 0.000196347 5.4362e-07 0.000196204 5.4907e-07 0.000196057 5.54223e-07 0.000195905 5.59175e-07 0.000195749 5.63879e-07 0.000195588 5.68454e-07 0.000195424 5.72824e-07 0.000195255 5.77133e-07 0.000195082 5.81271e-07 0.000194906 5.85414e-07 0.000194725 5.89406e-07 0.000194542 5.9347e-07 0.000194355 5.97392e-07 0.000194164 6.01451e-07 0.000193971 6.05364e-07 0.000193774 6.09483e-07 0.000193574 6.13438e-07 0.00019337 6.17672e-07 0.000193164 6.2171e-07 0.000192955 6.26108e-07 0.000192743 6.30262e-07 0.000192528 6.34866e-07 0.000192311 6.39161e-07 0.00019209 6.44009e-07 0.000191866 6.48465e-07 0.00019164 6.53593e-07 0.000191411 6.58225e-07 0.000191178 6.63662e-07 0.000190943 6.6848e-07 0.000190705 6.74257e-07 0.000190464 6.79266e-07 0.00019022 6.85407e-07 0.000189973 6.90609e-07 0.000189723 6.97137e-07 0.00018947 7.02532e-07 0.000189213 7.09464e-07 0.000188954 7.15047e-07 0.00018869 7.22395e-07 0.000188424 7.28161e-07 0.000188154 7.3593e-07 0.000187881 7.4187e-07 0.000187604 7.5006e-07 0.000187323 7.56161e-07 0.000187038 7.64762e-07 0.00018675 7.71009e-07 0.000186458 7.80007e-07 0.000186162 7.86374e-07 0.000185861 7.95751e-07 0.000185557 8.02198e-07 0.000185247 8.11941e-07 0.000184934 8.18404e-07 0.000184615 8.28516e-07 0.000184293 8.34883e-07 0.000183965 8.45411e-07 0.000183634 8.51493e-07 0.000183295 8.62557e-07 0.000182954 8.68049e-07 0.000182605 8.799e-07 0.000182254 8.84312e-07 0.000181894 8.97397e-07 0.000181532 8.9999e-07 0.000181161 9.15046e-07 0.000180789 9.14753e-07 0.000180406 9.32828e-07 0.000180023 9.28484e-07 0.000179628 9.5048e-07 0.000179232 9.42653e-07 0.000178828 9.62828e-07 9.92234e-07 0.000202873 3.5567e-07 0.000202919 4.24863e-07 0.000202937 4.61961e-07 0.000202936 4.89394e-07 0.00020292 5.10811e-07 0.000202895 5.28644e-07 0.000202863 5.44155e-07 0.000202823 5.5814e-07 0.000202777 5.71079e-07 0.000202726 5.8317e-07 0.000202669 5.9458e-07 0.000202608 6.05399e-07 0.000202541 6.15744e-07 0.000202469 6.25642e-07 0.000202393 6.35195e-07 0.000202313 6.44391e-07 0.000202228 6.53337e-07 0.000202139 6.61988e-07 0.000202046 6.70467e-07 0.000201948 6.78694e-07 0.000201847 6.86821e-07 0.000201741 6.94724e-07 0.000201632 7.02599e-07 0.000201519 7.10263e-07 0.000201403 7.17972e-07 0.000201283 7.25472e-07 0.000201159 7.33094e-07 0.000201032 7.40492e-07 0.000200902 7.481e-07 0.000200768 7.55452e-07 0.000200631 7.63113e-07 0.000200491 7.70466e-07 0.000200347 7.78243e-07 0.000200201 7.85636e-07 0.000200051 7.9359e-07 0.000199899 8.01058e-07 0.000199743 8.09246e-07 0.000199584 8.16814e-07 0.000199423 8.25294e-07 0.000199258 8.32983e-07 0.000199091 8.41809e-07 0.00019892 8.49633e-07 0.000198747 8.5886e-07 0.000198571 8.66826e-07 0.000198391 8.76509e-07 0.000198209 8.84619e-07 0.000198024 8.94809e-07 0.000197836 9.03058e-07 0.000197645 9.13808e-07 0.000197451 9.22186e-07 0.000197253 9.33545e-07 0.000197053 9.42032e-07 0.000196849 9.54048e-07 0.000196642 9.62621e-07 0.000196432 9.75338e-07 0.000196219 9.8396e-07 0.000196001 9.97425e-07 0.000195782 1.00605e-06 0.000195557 1.02031e-06 0.00019533 1.02886e-06 0.000195098 1.04398e-06 0.000194864 1.05235e-06 0.000194625 1.06842e-06 0.000194383 1.07645e-06 0.000194135 1.09361e-06 0.000193885 1.10106e-06 0.000193628 1.11952e-06 0.00019337 1.12601e-06 0.000193104 1.14613e-06 0.000192837 1.15111e-06 0.000192561 1.17341e-06 0.000192285 1.17614e-06 0.000191999 1.20133e-06 0.000191713 1.20092e-06 0.000191416 1.22972e-06 0.000191119 1.22574e-06 0.000190811 1.25782e-06 0.0001905 1.25347e-06 0.000190183 1.27979e-06 1.3261e-06 0.000208487 3.09617e-07 0.000208531 3.81559e-07 0.000208562 4.30902e-07 0.000208582 4.68975e-07 0.000208593 4.99679e-07 0.000208597 5.25336e-07 0.000208593 5.47582e-07 0.000208584 5.67485e-07 0.000208569 5.8572e-07 0.00020855 6.02681e-07 0.000208526 6.1865e-07 0.000208497 6.33813e-07 0.000208465 6.48331e-07 0.000208428 6.62289e-07 0.000208387 6.75797e-07 0.000208343 6.88885e-07 0.000208294 7.01649e-07 0.000208242 7.14078e-07 0.000208187 7.26275e-07 0.000208127 7.38191e-07 0.000208064 7.49948e-07 0.000207997 7.61459e-07 0.000207927 7.7288e-07 0.000207853 7.84072e-07 0.000207776 7.95244e-07 0.000207695 8.06189e-07 0.000207611 8.17191e-07 0.000207524 8.27953e-07 0.000207433 8.38858e-07 0.000207339 8.49493e-07 0.000207242 8.60371e-07 0.000207141 8.70927e-07 0.000207037 8.81848e-07 0.000206931 8.92367e-07 0.000206821 9.03399e-07 0.000206708 9.13917e-07 0.000206592 9.2513e-07 0.000206473 9.35677e-07 0.000206351 9.47141e-07 0.000206227 9.57738e-07 0.000206099 9.69526e-07 0.000205968 9.80188e-07 0.000205835 9.92376e-07 0.000205699 1.00311e-06 0.000205559 1.01577e-06 0.000205417 1.02658e-06 0.000205272 1.0398e-06 0.000205125 1.05066e-06 0.000204974 1.06453e-06 0.000204821 1.07543e-06 0.000204664 1.09004e-06 0.000204505 1.10094e-06 0.000204343 1.11637e-06 0.000204179 1.12723e-06 0.00020401 1.14359e-06 0.00020384 1.15434e-06 0.000203666 1.17174e-06 0.000203489 1.18229e-06 0.000203309 1.20086e-06 0.000203127 1.21111e-06 0.00020294 1.23098e-06 0.000202751 1.24077e-06 0.000202557 1.26212e-06 0.000202363 1.27123e-06 0.000202162 1.29431e-06 0.000201961 1.30244e-06 0.000201753 1.32755e-06 0.000201544 1.33428e-06 0.000201328 1.36186e-06 0.000201113 1.36664e-06 0.000200889 1.39723e-06 0.000200666 1.39938e-06 0.000200434 1.43359e-06 0.000200202 1.43256e-06 0.000199961 1.47061e-06 0.00019972 1.46693e-06 0.000199471 1.50715e-06 0.000199217 1.50665e-06 0.00019896 1.53729e-06 1.59795e-06 0.00021428 2.85823e-07 0.000214312 3.49761e-07 0.000214341 4.01093e-07 0.000214367 4.43836e-07 0.000214386 4.79942e-07 0.000214401 5.10978e-07 0.00021441 5.38273e-07 0.000214415 5.62828e-07 0.000214415 5.85346e-07 0.000214411 6.063e-07 0.000214404 6.26039e-07 0.000214393 6.44805e-07 0.000214378 6.62797e-07 0.000214361 6.80142e-07 0.000214339 6.96964e-07 0.000214315 7.13325e-07 0.000214287 7.2932e-07 0.000214256 7.44966e-07 0.000214222 7.60349e-07 0.000214185 7.75453e-07 0.000214145 7.90374e-07 0.000214101 8.05056e-07 0.000214054 8.19622e-07 0.000214004 8.33971e-07 0.000213951 8.48268e-07 0.000213895 8.62355e-07 0.000213836 8.76458e-07 0.000213774 8.9034e-07 0.000213708 9.04317e-07 0.00021364 9.18046e-07 0.000213568 9.31963e-07 0.000213493 9.4558e-07 0.000213416 9.59504e-07 0.000213335 9.73048e-07 0.000213251 9.87046e-07 0.000213165 1.00055e-06 0.000213075 1.01469e-06 0.000212983 1.02818e-06 0.000212887 1.04254e-06 0.000212789 1.05603e-06 0.000212688 1.07069e-06 0.000212584 1.0842e-06 0.000212477 1.09925e-06 0.000212367 1.11276e-06 0.000212255 1.12829e-06 0.00021214 1.14181e-06 0.000212021 1.15793e-06 0.000211901 1.17143e-06 0.000211777 1.18824e-06 0.000211651 1.20168e-06 0.000211521 1.21931e-06 0.00021139 1.23264e-06 0.000211255 1.25123e-06 0.000211118 1.26437e-06 0.000210977 1.28407e-06 0.000210835 1.29693e-06 0.000210688 1.31791e-06 0.00021054 1.33035e-06 0.000210388 1.3528e-06 0.000210235 1.36468e-06 0.000210077 1.38882e-06 0.000209918 1.39992e-06 0.000209754 1.42602e-06 0.000209589 1.43606e-06 0.000209419 1.46445e-06 0.000209248 1.47308e-06 0.000209072 1.50416e-06 0.000208895 1.51092e-06 0.000208712 1.5452e-06 0.000208529 1.54952e-06 0.000208339 1.58755e-06 0.000208149 1.58889e-06 0.000207952 1.63111e-06 0.000207755 1.62926e-06 0.00020755 1.67543e-06 0.000207345 1.67186e-06 0.000207133 1.71906e-06 0.000206918 1.72194e-06 0.000206699 1.75644e-06 1.8279e-06 0.000220241 2.7238e-07 0.000220263 3.27418e-07 0.000220288 3.76392e-07 0.000220312 4.19876e-07 0.000220333 4.58342e-07 0.000220352 4.9251e-07 0.000220367 5.23208e-07 0.000220378 5.51177e-07 0.000220387 5.77008e-07 0.000220392 6.01153e-07 0.000220394 6.23963e-07 0.000220393 6.457e-07 0.000220389 6.66577e-07 0.000220383 6.86747e-07 0.000220373 7.06345e-07 0.000220361 7.25456e-07 0.000220346 7.44175e-07 0.000220329 7.62543e-07 0.000220309 7.80638e-07 0.000220285 7.98467e-07 0.00022026 8.16107e-07 0.000220231 8.33533e-07 0.0002202 8.50838e-07 0.000220166 8.67958e-07 0.000220129 8.85015e-07 0.00022009 9.01898e-07 0.000220047 9.18781e-07 0.000220002 9.35482e-07 0.000219954 9.52252e-07 0.000219904 9.68816e-07 0.00021985 9.85534e-07 0.000219794 1.002e-06 0.000219734 1.01872e-06 0.000219672 1.03512e-06 0.000219607 1.05191e-06 0.00021954 1.06826e-06 0.000219469 1.08519e-06 0.000219396 1.10152e-06 0.00021932 1.11865e-06 0.000219241 1.13496e-06 0.000219159 1.15239e-06 0.000219075 1.16869e-06 0.000218987 1.18649e-06 0.000218897 1.20278e-06 0.000218805 1.22106e-06 0.000218709 1.23731e-06 0.000218611 1.25619e-06 0.00021851 1.27236e-06 0.000218406 1.29197e-06 0.0002183 1.308e-06 0.000218191 1.3285e-06 0.000218079 1.34432e-06 0.000217964 1.36587e-06 0.000217847 1.38138e-06 0.000217727 1.40418e-06 0.000217605 1.41924e-06 0.000217479 1.4435e-06 0.000217352 1.45795e-06 0.000217221 1.48394e-06 0.000217088 1.49755e-06 0.000216951 1.52558e-06 0.000216813 1.53809e-06 0.00021667 1.56849e-06 0.000216527 1.57957e-06 0.000216379 1.61276e-06 0.00021623 1.62198e-06 0.000216075 1.65847e-06 0.000215921 1.66533e-06 0.00021576 1.70567e-06 0.0002156 1.70961e-06 0.000215434 1.75436e-06 0.000215268 1.75494e-06 0.000215094 1.8044e-06 0.000214922 1.80174e-06 0.000214742 1.85525e-06 0.000214562 1.85162e-06 0.000214376 1.90524e-06 0.000214187 1.91078e-06 0.000213994 1.94943e-06 2.02822e-06 0.000226369 2.64815e-07 0.000226385 3.11965e-07 0.000226404 3.56929e-07 0.000226425 3.98936e-07 0.000226446 4.37656e-07 0.000226465 4.73176e-07 0.000226482 5.05848e-07 0.000226497 5.36102e-07 0.00022651 5.6435e-07 0.00022652 5.9095e-07 0.000226528 6.16205e-07 0.000226533 6.4036e-07 0.000226536 6.63621e-07 0.000226537 6.86146e-07 0.000226535 7.08074e-07 0.000226531 7.29502e-07 0.000226525 7.50527e-07 0.000226516 7.71206e-07 0.000226505 7.91612e-07 0.000226492 8.11771e-07 0.000226476 8.31749e-07 0.000226458 8.51541e-07 0.000226438 8.71221e-07 0.000226415 8.90753e-07 0.00022639 9.1023e-07 0.000226362 9.29576e-07 0.000226332 9.48923e-07 0.000226299 9.68138e-07 0.000226264 9.87414e-07 0.000226227 1.00654e-06 0.000226186 1.0258e-06 0.000226143 1.04487e-06 0.000226098 1.06416e-06 0.00022605 1.0832e-06 0.000225999 1.10259e-06 0.000225946 1.12161e-06 0.00022589 1.14115e-06 0.000225831 1.16016e-06 0.00022577 1.17992e-06 0.000225706 1.19894e-06 0.000225639 1.21899e-06 0.00022557 1.23801e-06 0.000225498 1.25844e-06 0.000225423 1.27743e-06 0.000225346 1.29836e-06 0.000225266 1.3173e-06 0.000225184 1.33884e-06 0.000225098 1.35767e-06 0.00022501 1.37997e-06 0.00022492 1.39861e-06 0.000224826 1.42184e-06 0.00022473 1.44021e-06 0.000224632 1.46456e-06 0.000224531 1.48251e-06 0.000224427 1.50822e-06 0.00022432 1.52559e-06 0.000224211 1.55292e-06 0.000224099 1.5695e-06 0.000223984 1.59877e-06 0.000223868 1.61428e-06 0.000223747 1.64586e-06 0.000223625 1.65998e-06 0.0002235 1.6943e-06 0.000223373 1.70663e-06 0.000223241 1.74419e-06 0.000223109 1.75424e-06 0.000222972 1.79562e-06 0.000222834 1.80283e-06 0.000222691 1.84867e-06 0.000222548 1.85248e-06 0.000222399 1.90333e-06 0.000222251 1.90337e-06 0.000222096 1.95946e-06 0.000221942 1.95612e-06 0.00022178 2.01642e-06 0.000221619 2.01265e-06 0.000221452 2.07244e-06 0.000221283 2.07993e-06 0.000221109 2.12332e-06 2.2064e-06 0.000232668 2.60561e-07 0.000232679 3.01269e-07 0.000232694 3.41907e-07 0.000232711 3.81385e-07 0.00023273 4.19049e-07 0.000232749 4.54622e-07 0.000232766 4.88107e-07 0.000232783 5.19661e-07 0.000232798 5.49507e-07 0.000232811 5.77877e-07 0.000232822 6.04996e-07 0.000232831 6.31065e-07 0.000232839 6.5626e-07 0.000232844 6.8073e-07 0.000232847 7.04605e-07 0.000232849 7.27985e-07 0.000232849 7.50966e-07 0.000232846 7.73612e-07 0.000232842 7.95995e-07 0.000232835 8.18151e-07 0.000232827 8.40142e-07 0.000232817 8.61977e-07 0.000232804 8.83718e-07 0.000232789 9.05349e-07 0.000232773 9.26943e-07 0.000232754 9.48451e-07 0.000232733 9.69973e-07 0.00023271 9.91416e-07 0.000232684 1.01293e-06 0.000232656 1.03435e-06 0.000232626 1.0559e-06 0.000232594 1.07732e-06 0.000232559 1.09896e-06 0.000232522 1.12041e-06 0.000232482 1.14218e-06 0.00023244 1.16367e-06 0.000232395 1.18563e-06 0.000232348 1.20717e-06 0.000232299 1.22938e-06 0.000232247 1.25096e-06 0.000232193 1.27349e-06 0.000232135 1.2951e-06 0.000232076 1.31803e-06 0.000232014 1.33964e-06 0.000231949 1.36308e-06 0.000231882 1.38465e-06 0.000231812 1.40873e-06 0.000231739 1.43019e-06 0.000231664 1.45505e-06 0.000231586 1.47631e-06 0.000231506 1.50213e-06 0.000231423 1.52308e-06 0.000231338 1.55008e-06 0.00023125 1.57055e-06 0.000231159 1.599e-06 0.000231066 1.61878e-06 0.00023097 1.64898e-06 0.000230871 1.66783e-06 0.00023077 1.70014e-06 0.000230666 1.71773e-06 0.00023056 1.75259e-06 0.000230451 1.76853e-06 0.000230339 1.80644e-06 0.000230225 1.82026e-06 0.000230108 1.86181e-06 0.000229989 1.87296e-06 0.000229866 1.91881e-06 0.000229742 1.92667e-06 0.000229613 1.97753e-06 0.000229484 1.98152e-06 0.00022935 2.03796e-06 0.000229215 2.03776e-06 0.000229075 2.09996e-06 0.000228935 2.09614e-06 0.000228788 2.16283e-06 0.000228642 2.15889e-06 0.00022849 2.22476e-06 0.000228336 2.23354e-06 0.000228177 2.28236e-06 2.36724e-06 0.000239142 2.58092e-07 0.000239149 2.93743e-07 0.000239161 3.30368e-07 0.000239175 3.66981e-07 0.000239191 4.02881e-07 0.000239208 4.37641e-07 0.000239225 4.7106e-07 0.000239242 5.03101e-07 0.000239258 5.33823e-07 0.000239272 5.63338e-07 0.000239285 5.91781e-07 0.000239297 6.19291e-07 0.000239307 6.46004e-07 0.000239316 6.72044e-07 0.000239323 6.97521e-07 0.000239329 7.22532e-07 0.000239332 7.47163e-07 0.000239334 7.71481e-07 0.000239335 7.95554e-07 0.000239334 8.19426e-07 0.000239331 8.43153e-07 0.000239326 8.66755e-07 0.000239319 8.90287e-07 0.000239311 9.13746e-07 0.000239301 9.37191e-07 0.000239289 9.60595e-07 0.000239274 9.84036e-07 0.000239258 1.00745e-06 0.00023924 1.03095e-06 0.00023922 1.05441e-06 0.000239198 1.07801e-06 0.000239174 1.10156e-06 0.000239148 1.12532e-06 0.000239119 1.14896e-06 0.000239088 1.17291e-06 0.000239055 1.19667e-06 0.00023902 1.22086e-06 0.000238983 1.24474e-06 0.000238943 1.26922e-06 0.0002389 1.2932e-06 0.000238856 1.31805e-06 0.000238809 1.34211e-06 0.00023876 1.36739e-06 0.000238708 1.39151e-06 0.000238653 1.41733e-06 0.000238597 1.44144e-06 0.000238537 1.46792e-06 0.000238476 1.49195e-06 0.000238411 1.51924e-06 0.000238345 1.54309e-06 0.000238275 1.57139e-06 0.000238204 1.59491e-06 0.000238129 1.62443e-06 0.000238052 1.64745e-06 0.000237973 1.67849e-06 0.000237891 1.70076e-06 0.000237806 1.73364e-06 0.000237719 1.75488e-06 0.000237629 1.79002e-06 0.000237537 1.80984e-06 0.000237442 1.84774e-06 0.000237345 1.8657e-06 0.000237244 1.90691e-06 0.000237142 1.92247e-06 0.000237036 1.96767e-06 0.000236929 1.98021e-06 0.000236818 2.03014e-06 0.000236705 2.03899e-06 0.000236589 2.09442e-06 0.000236471 2.09893e-06 0.000236349 2.16051e-06 0.000236226 2.16039e-06 0.000236098 2.22827e-06 0.00023597 2.22422e-06 0.000235835 2.29698e-06 0.000235701 2.29287e-06 0.000235561 2.36485e-06 0.000235421 2.37434e-06 0.000235274 2.42923e-06 2.51396e-06 0.000245794 2.56537e-07 0.000245799 2.88267e-07 0.000245808 3.2142e-07 0.00024582 3.55229e-07 0.000245834 3.89078e-07 0.000245849 4.2252e-07 0.000245865 4.55267e-07 0.000245881 4.87168e-07 0.000245896 5.18168e-07 0.000245911 5.48278e-07 0.000245926 5.77551e-07 0.000245939 6.06064e-07 0.000245951 6.33904e-07 0.000245962 6.6116e-07 0.000245972 6.87921e-07 0.00024598 7.14265e-07 0.000245987 7.40269e-07 0.000245992 7.65995e-07 0.000245996 7.91506e-07 0.000245999 8.16846e-07 0.000246 8.42068e-07 0.000245999 8.67199e-07 0.000245997 8.92285e-07 0.000245994 9.17337e-07 0.000245989 9.42403e-07 0.000245982 9.67471e-07 0.000245973 9.92602e-07 0.000245963 1.01775e-06 0.000245951 1.04301e-06 0.000245937 1.0683e-06 0.000245921 1.09374e-06 0.000245904 1.11919e-06 0.000245884 1.14485e-06 0.000245863 1.17049e-06 0.000245839 1.19641e-06 0.000245813 1.22224e-06 0.000245786 1.24848e-06 0.000245756 1.2745e-06 0.000245724 1.30109e-06 0.00024569 1.32729e-06 0.000245654 1.3543e-06 0.000245615 1.38066e-06 0.000245575 1.40815e-06 0.000245531 1.43463e-06 0.000245486 1.46269e-06 0.000245438 1.48923e-06 0.000245388 1.51799e-06 0.000245336 1.5445e-06 0.000245281 1.57411e-06 0.000245223 1.60048e-06 0.000245164 1.63112e-06 0.000245101 1.65719e-06 0.000245037 1.6891e-06 0.00024497 1.71468e-06 0.0002449 1.74815e-06 0.000244828 1.77296e-06 0.000244753 1.80837e-06 0.000244676 1.83208e-06 0.000244596 1.86986e-06 0.000244514 1.89205e-06 0.000244429 1.93275e-06 0.000244341 1.95292e-06 0.000244251 1.99717e-06 0.000244159 2.0147e-06 0.000244063 2.06324e-06 0.000243966 2.07746e-06 0.000243865 2.1311e-06 0.000243763 2.14125e-06 0.000243656 2.20087e-06 0.000243549 2.20626e-06 0.000243437 2.27256e-06 0.000243325 2.27286e-06 0.000243207 2.34602e-06 0.000243089 2.34202e-06 0.000242965 2.42057e-06 0.000242842 2.41635e-06 0.000242712 2.49445e-06 0.000242583 2.50422e-06 0.000242446 2.56573e-06 2.64878e-06 0.00025263 2.55417e-07 0.000252634 2.8409e-07 0.000252641 3.14332e-07 0.000252651 3.45585e-07 0.000252663 3.77357e-07 0.000252676 4.09245e-07 0.00025269 4.4095e-07 0.000252705 4.72269e-07 0.00025272 5.03083e-07 0.000252735 5.33331e-07 0.00025275 5.63004e-07 0.000252764 5.92121e-07 0.000252777 6.20724e-07 0.000252789 6.48866e-07 0.0002528 6.76608e-07 0.000252811 7.04008e-07 0.00025282 7.31126e-07 0.000252828 7.58017e-07 0.000252835 7.84733e-07 0.00025284 8.11319e-07 0.000252844 8.3782e-07 0.000252847 8.64266e-07 0.000252849 8.907e-07 0.000252849 9.17137e-07 0.000252848 9.43618e-07 0.000252845 9.70144e-07 0.000252841 9.96762e-07 0.000252835 1.02345e-06 0.000252828 1.05027e-06 0.000252819 1.07717e-06 0.000252809 1.10425e-06 0.000252796 1.1314e-06 0.000252782 1.15878e-06 0.000252767 1.18621e-06 0.000252749 1.21393e-06 0.00025273 1.24164e-06 0.000252709 1.26974e-06 0.000252685 1.29773e-06 0.00025266 1.32625e-06 0.000252633 1.35451e-06 0.000252604 1.38351e-06 0.000252572 1.41201e-06 0.000252539 1.44155e-06 0.000252503 1.47026e-06 0.000252466 1.50042e-06 0.000252426 1.52927e-06 0.000252383 1.56017e-06 0.000252339 1.58907e-06 0.000252292 1.62085e-06 0.000252243 1.64967e-06 0.000252192 1.68253e-06 0.000252138 1.7111e-06 0.000252081 1.74527e-06 0.000252023 1.77337e-06 0.000251962 1.80916e-06 0.000251898 1.83651e-06 0.000251832 1.8743e-06 0.000251764 1.90053e-06 0.000251693 1.94078e-06 0.00025162 1.96544e-06 0.000251544 2.00874e-06 0.000251465 2.03126e-06 0.000251384 2.07831e-06 0.000251301 2.09802e-06 0.000251214 2.14961e-06 0.000251126 2.16576e-06 0.000251034 2.2228e-06 0.000250941 2.23456e-06 0.000250844 2.29799e-06 0.000250746 2.3046e-06 0.000250643 2.37523e-06 0.000250539 2.3763e-06 0.000250431 2.45438e-06 0.000250322 2.4507e-06 0.000250208 2.5348e-06 0.000250094 2.53055e-06 0.000249974 2.61479e-06 0.000249853 2.62451e-06 0.000249726 2.69303e-06 2.77331e-06 0.000259655 2.54474e-07 0.000259658 2.80726e-07 0.000259664 3.0855e-07 0.000259672 3.37555e-07 0.000259682 3.67363e-07 0.000259693 3.97641e-07 0.000259706 4.28115e-07 0.00025972 4.58575e-07 0.000259734 4.8887e-07 0.000259749 5.18903e-07 0.000259763 5.48619e-07 0.000259777 5.77995e-07 0.000259791 6.07035e-07 0.000259804 6.35758e-07 0.000259816 6.64197e-07 0.000259828 6.9239e-07 0.000259839 7.20378e-07 0.000259848 7.48204e-07 0.000259857 7.7591e-07 0.000259865 8.03533e-07 0.000259872 8.31113e-07 0.000259877 8.58681e-07 0.000259882 8.86273e-07 0.000259885 9.13907e-07 0.000259887 9.4162e-07 0.000259888 9.69419e-07 0.000259887 9.97343e-07 0.000259885 1.02538e-06 0.000259882 1.05359e-06 0.000259877 1.08192e-06 0.000259871 1.11046e-06 0.000259863 1.13913e-06 0.000259854 1.16805e-06 0.000259843 1.19708e-06 0.000259831 1.22642e-06 0.000259816 1.25583e-06 0.000259801 1.28563e-06 0.000259783 1.31541e-06 0.000259763 1.34571e-06 0.000259742 1.37585e-06 0.000259719 1.40669e-06 0.000259694 1.43718e-06 0.000259667 1.46863e-06 0.000259637 1.49941e-06 0.000259606 1.53154e-06 0.000259573 1.56256e-06 0.000259538 1.59547e-06 0.0002595 1.62663e-06 0.000259461 1.66047e-06 0.000259419 1.69163e-06 0.000259375 1.72658e-06 0.000259328 1.75758e-06 0.000259279 1.79388e-06 0.000259228 1.82447e-06 0.000259175 1.86243e-06 0.000259119 1.89231e-06 0.000259061 1.93233e-06 0.000259001 1.96111e-06 0.000258938 2.00368e-06 0.000258872 2.03086e-06 0.000258805 2.07659e-06 0.000258734 2.10158e-06 0.000258661 2.1512e-06 0.000258586 2.17326e-06 0.000258508 2.22765e-06 0.000258428 2.24595e-06 0.000258345 2.30608e-06 0.000258259 2.31972e-06 0.000258171 2.38664e-06 0.000258081 2.39478e-06 0.000257986 2.46939e-06 0.000257891 2.47155e-06 0.000257791 2.55422e-06 0.000257691 2.55113e-06 0.000257585 2.64053e-06 0.000257479 2.6364e-06 0.000257367 2.72674e-06 0.000257256 2.73618e-06 0.000257137 2.812e-06 2.88873e-06 0.000266873 2.53569e-07 0.000266876 2.77864e-07 0.000266881 3.03676e-07 0.000266888 3.30731e-07 0.000266896 3.58749e-07 0.000266907 3.87467e-07 0.000266918 4.16648e-07 0.000266931 4.46097e-07 0.000266944 4.75661e-07 0.000266957 5.05223e-07 0.000266971 5.34705e-07 0.000266985 5.64057e-07 0.000266999 5.93253e-07 0.000267013 6.22286e-07 0.000267026 6.51165e-07 0.000267038 6.79906e-07 0.00026705 7.08534e-07 0.000267061 7.37077e-07 0.000267071 7.65567e-07 0.000267081 7.94032e-07 0.000267089 8.22505e-07 0.000267097 8.51013e-07 0.000267104 8.79586e-07 0.00026711 9.08246e-07 0.000267114 9.37022e-07 0.000267118 9.65925e-07 0.00026712 9.9499e-07 0.000267121 1.02421e-06 0.000267121 1.05363e-06 0.00026712 1.08323e-06 0.000267117 1.11307e-06 0.000267113 1.14309e-06 0.000267108 1.17339e-06 0.000267101 1.20386e-06 0.000267093 1.23466e-06 0.000267083 1.2656e-06 0.000267072 1.29694e-06 0.000267059 1.32835e-06 0.000267044 1.36026e-06 0.000267028 1.39214e-06 0.00026701 1.42467e-06 0.00026699 1.45698e-06 0.000266969 1.49019e-06 0.000266945 1.5229e-06 0.00026692 1.55686e-06 0.000266892 1.58991e-06 0.000266863 1.6247e-06 0.000266832 1.65799e-06 0.000266799 1.69377e-06 0.000266763 1.72716e-06 0.000266726 1.76409e-06 0.000266686 1.79741e-06 0.000266644 1.83573e-06 0.0002666 1.86873e-06 0.000266553 1.90875e-06 0.000266504 1.94112e-06 0.000266454 1.98324e-06 0.0002664 2.01456e-06 0.000266344 2.05929e-06 0.000266286 2.08904e-06 0.000266226 2.13701e-06 0.000266163 2.16456e-06 0.000266098 2.21655e-06 0.00026603 2.2411e-06 0.000265959 2.29804e-06 0.000265887 2.31869e-06 0.000265811 2.38164e-06 0.000265733 2.39741e-06 0.000265652 2.4675e-06 0.00026557 2.47745e-06 0.000265483 2.55571e-06 0.000265396 2.55927e-06 0.000265304 2.6462e-06 0.000265211 2.64398e-06 0.000265113 2.73843e-06 0.000265015 2.73458e-06 0.000264911 2.83094e-06 0.000264807 2.83997e-06 0.000264696 2.92323e-06 2.99594e-06 0.000274291 2.52632e-07 0.000274294 2.75313e-07 0.000274298 2.99431e-07 0.000274304 3.24802e-07 0.000274312 3.51218e-07 0.000274321 3.78474e-07 0.000274331 4.06378e-07 0.000274342 4.34757e-07 0.000274354 4.63467e-07 0.000274367 4.92391e-07 0.00027438 5.2144e-07 0.000274394 5.50547e-07 0.000274408 5.7967e-07 0.000274421 6.08783e-07 0.000274434 6.37873e-07 0.000274447 6.66942e-07 0.00027446 6.95998e-07 0.000274472 7.25057e-07 0.000274483 7.54136e-07 0.000274494 7.83258e-07 0.000274504 8.12446e-07 0.000274513 8.41723e-07 0.000274522 8.71113e-07 0.00027453 9.00635e-07 0.000274536 9.30316e-07 0.000274542 9.60168e-07 0.000274547 9.90219e-07 0.00027455 1.02047e-06 0.000274553 1.05096e-06 0.000274555 1.08167e-06 0.000274555 1.11266e-06 0.000274554 1.14387e-06 0.000274552 1.1754e-06 0.000274549 1.20716e-06 0.000274544 1.23927e-06 0.000274538 1.27158e-06 0.000274531 1.30431e-06 0.000274522 1.33719e-06 0.000274512 1.37058e-06 0.0002745 1.40403e-06 0.000274487 1.43811e-06 0.000274472 1.4721e-06 0.000274455 1.50693e-06 0.000274436 1.54142e-06 0.000274416 1.57707e-06 0.000274394 1.61201e-06 0.00027437 1.64856e-06 0.000274344 1.68385e-06 0.000274317 1.72143e-06 0.000274287 1.75694e-06 0.000274255 1.79572e-06 0.000274221 1.83127e-06 0.000274186 1.87148e-06 0.000274147 1.90682e-06 0.000274107 1.94877e-06 0.000274065 1.98357e-06 0.000274021 2.02766e-06 0.000273974 2.0615e-06 0.000273925 2.10824e-06 0.000273873 2.14057e-06 0.000273819 2.19063e-06 0.000273763 2.22078e-06 0.000273705 2.27496e-06 0.000273644 2.30209e-06 0.000273581 2.36137e-06 0.000273515 2.38452e-06 0.000273446 2.45003e-06 0.000273376 2.46814e-06 0.000273302 2.54111e-06 0.000273226 2.55313e-06 0.000273147 2.63472e-06 0.000273067 2.63996e-06 0.000272982 2.73084e-06 0.000272896 2.72978e-06 0.000272806 2.829e-06 0.000272715 2.82562e-06 0.000272618 2.92787e-06 0.000272521 2.93648e-06 0.000272417 3.0272e-06 3.09564e-06 0.000281914 2.51631e-07 0.000281917 2.72951e-07 0.000281921 2.95628e-07 0.000281926 3.19537e-07 0.000281933 3.44526e-07 0.000281941 3.7044e-07 0.00028195 3.97122e-07 0.00028196 4.24429e-07 0.000281971 4.52231e-07 0.000281983 4.80418e-07 0.000281996 5.08899e-07 0.000282009 5.37603e-07 0.000282022 5.66476e-07 0.000282035 5.9548e-07 0.000282049 6.24591e-07 0.000282062 6.53796e-07 0.000282075 6.83091e-07 0.000282087 7.12479e-07 0.000282099 7.4197e-07 0.000282111 7.71575e-07 0.000282122 8.01311e-07 0.000282133 8.31195e-07 0.000282143 8.61244e-07 0.000282152 8.91477e-07 0.00028216 9.21913e-07 0.000282168 9.52566e-07 0.000282175 9.83459e-07 0.00028218 1.0146e-06 0.000282185 1.04601e-06 0.000282189 1.07769e-06 0.000282192 1.10968e-06 0.000282194 1.14196e-06 0.000282195 1.17457e-06 0.000282195 1.20747e-06 0.000282193 1.24074e-06 0.000282191 1.27429e-06 0.000282187 1.30827e-06 0.000282181 1.34248e-06 0.000282175 1.3772e-06 0.000282167 1.41207e-06 0.000282157 1.44757e-06 0.000282146 1.48309e-06 0.000282134 1.51941e-06 0.00028212 1.55555e-06 0.000282104 1.59276e-06 0.000282086 1.62945e-06 0.000282067 1.66763e-06 0.000282046 1.70478e-06 0.000282024 1.74405e-06 0.000281999 1.78155e-06 0.000281973 1.82207e-06 0.000281944 1.85973e-06 0.000281914 1.90172e-06 0.000281882 1.93929e-06 0.000281847 1.98306e-06 0.000281811 2.02021e-06 0.000281772 2.06615e-06 0.000281731 2.10245e-06 0.000281689 2.15109e-06 0.000281643 2.18597e-06 0.000281596 2.23797e-06 0.000281546 2.27074e-06 0.000281494 2.32693e-06 0.000281439 2.35672e-06 0.000281382 2.41813e-06 0.000281323 2.4439e-06 0.000281261 2.51174e-06 0.000281197 2.53236e-06 0.00028113 2.60794e-06 0.000281061 2.62226e-06 0.000280989 2.70688e-06 0.000280915 2.71406e-06 0.000280837 2.80857e-06 0.000280758 2.80894e-06 0.000280674 2.91265e-06 0.00028059 2.90997e-06 0.0002805 3.01791e-06 0.00028041 3.02614e-06 0.000280313 3.12423e-06 3.18836e-06 0.000289748 2.50549e-07 0.000289751 2.70704e-07 0.000289754 2.92139e-07 0.000289759 3.14769e-07 0.000289765 3.38488e-07 0.000289772 3.63177e-07 0.00028978 3.88714e-07 0.00028979 4.14979e-07 0.0002898 4.41861e-07 0.000289811 4.69261e-07 0.000289823 4.97092e-07 0.000289836 5.25283e-07 0.000289848 5.53777e-07 0.000289861 5.82528e-07 0.000289874 6.11505e-07 0.000289887 6.40685e-07 0.0002899 6.70056e-07 0.000289913 6.99612e-07 0.000289926 7.29352e-07 0.000289938 7.59282e-07 0.00028995 7.89411e-07 0.000289962 8.1975e-07 0.000289973 8.50311e-07 0.000289983 8.81109e-07 0.000289993 9.12159e-07 0.000290002 9.43474e-07 0.00029001 9.75073e-07 0.000290018 1.00696e-06 0.000290025 1.03917e-06 0.000290031 1.07169e-06 0.000290036 1.10455e-06 0.00029004 1.13774e-06 0.000290043 1.17131e-06 0.000290045 1.20521e-06 0.000290047 1.23953e-06 0.000290047 1.27417e-06 0.000290046 1.30927e-06 0.000290044 1.34467e-06 0.00029004 1.38059e-06 0.000290036 1.41675e-06 0.00029003 1.45353e-06 0.000290022 1.49045e-06 0.000290014 1.52813e-06 0.000290003 1.56576e-06 0.000289992 1.60441e-06 0.000289978 1.64272e-06 0.000289964 1.6824e-06 0.000289947 1.7213e-06 0.000289929 1.76213e-06 0.000289909 1.80149e-06 0.000289887 1.84363e-06 0.000289864 1.88328e-06 0.000289839 1.92694e-06 0.000289811 1.96664e-06 0.000289782 2.01211e-06 0.000289751 2.05152e-06 0.000289718 2.0992e-06 0.000289683 2.13789e-06 0.000289645 2.18829e-06 0.000289606 2.22569e-06 0.000289564 2.27949e-06 0.00028952 2.31487e-06 0.000289474 2.37293e-06 0.000289425 2.4054e-06 0.000289375 2.46877e-06 0.000289321 2.49724e-06 0.000289266 2.56719e-06 0.000289208 2.59045e-06 0.000289147 2.66839e-06 0.000289084 2.6852e-06 0.000289019 2.77256e-06 0.000288951 2.78193e-06 0.00028888 2.87977e-06 0.000288807 2.88181e-06 0.00028873 2.98973e-06 0.000288652 2.98797e-06 0.000288568 3.10137e-06 0.000288485 3.10934e-06 0.000288395 3.2146e-06 3.27456e-06 0.000297799 2.49385e-07 0.000297801 2.68525e-07 0.000297804 2.88875e-07 0.000297809 3.10378e-07 0.000297814 3.3296e-07 0.000297821 3.56534e-07 0.000297829 3.81005e-07 0.000297837 4.06276e-07 0.000297847 4.32254e-07 0.000297857 4.5885e-07 0.000297868 4.85987e-07 0.00029788 5.13596e-07 0.000297892 5.4162e-07 0.000297905 5.70012e-07 0.000297917 5.98736e-07 0.00029793 6.27763e-07 0.000297943 6.57074e-07 0.000297956 6.86657e-07 0.000297969 7.16507e-07 0.000297982 7.46621e-07 0.000297994 7.77002e-07 0.000298006 8.07656e-07 0.000298018 8.38593e-07 0.000298029 8.6982e-07 0.00029804 9.01352e-07 0.00029805 9.33197e-07 0.00029806 9.65372e-07 0.000298069 9.97884e-07 0.000298078 1.03075e-06 0.000298085 1.06398e-06 0.000298092 1.09759e-06 0.000298098 1.13158e-06 0.000298104 1.16598e-06 0.000298108 1.20076e-06 0.000298112 1.23599e-06 0.000298114 1.2716e-06 0.000298116 1.30769e-06 0.000298116 1.34415e-06 0.000298116 1.38115e-06 0.000298114 1.41847e-06 0.000298111 1.45641e-06 0.000298107 1.49458e-06 0.000298102 1.5335e-06 0.000298095 1.5725e-06 0.000298087 1.61247e-06 0.000298077 1.65225e-06 0.000298067 1.69333e-06 0.000298054 1.73382e-06 0.00029804 1.77611e-06 0.000298024 1.8172e-06 0.000298007 1.86085e-06 0.000297988 1.90237e-06 0.000297967 1.94759e-06 0.000297945 1.98929e-06 0.00029792 2.03636e-06 0.000297894 2.07793e-06 0.000297866 2.12723e-06 0.000297836 2.16823e-06 0.000297804 2.22027e-06 0.000297769 2.26013e-06 0.000297733 2.3156e-06 0.000297694 2.35357e-06 0.000297654 2.41334e-06 0.000297611 2.4485e-06 0.000297566 2.51365e-06 0.000297518 2.54489e-06 0.000297469 2.61674e-06 0.000297417 2.64276e-06 0.000297362 2.72282e-06 0.000297305 2.74227e-06 0.000297246 2.8321e-06 0.000297184 2.84386e-06 0.000297119 2.94473e-06 0.000297052 2.9487e-06 0.000296981 3.0605e-06 0.000296909 3.05992e-06 0.000296832 3.17849e-06 0.000296755 3.18637e-06 0.000296671 3.29851e-06 3.35458e-06 0.000306072 2.48138e-07 0.000306074 2.66385e-07 0.000306077 2.85776e-07 0.000306081 3.06277e-07 0.000306087 3.27838e-07 0.000306093 3.50395e-07 0.0003061 3.73878e-07 0.000306108 3.98208e-07 0.000306117 4.23309e-07 0.000306127 4.49106e-07 0.000306137 4.75529e-07 0.000306148 5.02516e-07 0.00030616 5.30012e-07 0.000306172 5.57969e-07 0.000306184 5.8635e-07 0.000306197 6.15124e-07 0.00030621 6.44268e-07 0.000306223 6.73765e-07 0.000306235 7.03604e-07 0.000306248 7.33779e-07 0.000306261 7.64289e-07 0.000306273 7.95135e-07 0.000306286 8.26321e-07 0.000306298 8.57854e-07 0.000306309 8.89744e-07 0.000306321 9.21997e-07 0.000306331 9.54626e-07 0.000306342 9.87639e-07 0.000306351 1.02105e-06 0.00030636 1.05487e-06 0.000306369 1.08911e-06 0.000306377 1.12377e-06 0.000306384 1.15888e-06 0.00030639 1.19442e-06 0.000306396 1.23044e-06 0.0003064 1.2669e-06 0.000306404 1.30387e-06 0.000306407 1.34127e-06 0.000306409 1.37923e-06 0.00030641 1.41757e-06 0.00030641 1.45655e-06 0.000306408 1.49585e-06 0.000306406 1.5359e-06 0.000306402 1.57613e-06 0.000306398 1.6173e-06 0.000306391 1.65843e-06 0.000306384 1.70078e-06 0.000306375 1.74275e-06 0.000306365 1.78638e-06 0.000306353 1.82907e-06 0.00030634 1.87412e-06 0.000306325 1.91738e-06 0.000306308 1.96404e-06 0.00030629 2.00764e-06 0.00030627 2.05619e-06 0.000306248 2.09981e-06 0.000306225 2.15062e-06 0.000306199 2.19384e-06 0.000306172 2.24742e-06 0.000306142 2.28965e-06 0.000306111 2.34667e-06 0.000306078 2.38718e-06 0.000306043 2.44852e-06 0.000306005 2.48637e-06 0.000305965 2.55314e-06 0.000305923 2.58716e-06 0.000305879 2.66073e-06 0.000305832 2.68958e-06 0.000305783 2.77153e-06 0.000305732 2.79377e-06 0.000305678 2.8858e-06 0.000305622 2.90014e-06 0.000305563 3.00373e-06 0.000305502 3.00987e-06 0.000305437 3.12522e-06 0.000305371 3.12607e-06 0.0003053 3.24947e-06 0.000305229 3.2575e-06 0.000305151 3.37617e-06 3.42872e-06 0.000314574 2.46811e-07 0.000314577 2.64263e-07 0.000314579 2.82799e-07 0.000314583 3.02402e-07 0.000314588 3.23039e-07 0.000314594 3.44667e-07 0.000314601 3.67233e-07 0.000314608 3.90677e-07 0.000314616 4.14938e-07 0.000314626 4.39952e-07 0.000314635 4.65659e-07 0.000314646 4.92003e-07 0.000314657 5.18933e-07 0.000314669 5.46404e-07 0.000314681 5.74379e-07 0.000314693 6.02824e-07 0.000314705 6.31716e-07 0.000314718 6.61034e-07 0.000314731 6.90765e-07 0.000314744 7.209e-07 0.000314757 7.51432e-07 0.00031477 7.8236e-07 0.000314782 8.13687e-07 0.000314795 8.45414e-07 0.000314807 8.77548e-07 0.000314819 9.10097e-07 0.00031483 9.43068e-07 0.000314841 9.76469e-07 0.000314852 1.01031e-06 0.000314862 1.0446e-06 0.000314872 1.07936e-06 0.000314881 1.11458e-06 0.00031489 1.15029e-06 0.000314898 1.18648e-06 0.000314905 1.22318e-06 0.000314912 1.26037e-06 0.000314917 1.29811e-06 0.000314922 1.33632e-06 0.000314926 1.37512e-06 0.00031493 1.41438e-06 0.000314932 1.45429e-06 0.000314933 1.49459e-06 0.000314933 1.53565e-06 0.000314933 1.57699e-06 0.000314931 1.61924e-06 0.000314927 1.6616e-06 0.000314923 1.70511e-06 0.000314917 1.74842e-06 0.000314911 1.79328e-06 0.000314902 1.83745e-06 0.000314893 1.88379e-06 0.000314881 1.92866e-06 0.000314869 1.97667e-06 0.000314854 2.02204e-06 0.000314838 2.07197e-06 0.000314821 2.11752e-06 0.000314802 2.16974e-06 0.00031478 2.21506e-06 0.000314758 2.27006e-06 0.000314733 2.31459e-06 0.000314706 2.37304e-06 0.000314678 2.41603e-06 0.000314647 2.47881e-06 0.000314614 2.5193e-06 0.00031458 2.58754e-06 0.000314543 2.62435e-06 0.000314504 2.69946e-06 0.000314462 2.73119e-06 0.000314419 2.81482e-06 0.000314373 2.83994e-06 0.000314325 2.93392e-06 0.000314274 2.951e-06 0.000314221 3.05702e-06 0.000314165 3.06553e-06 0.000314106 3.18412e-06 0.000314046 3.18665e-06 0.000313981 3.31452e-06 0.000313915 3.32296e-06 0.000313844 3.44771e-06 3.49723e-06 0.000323312 2.45408e-07 0.000323314 2.62147e-07 0.000323317 2.79915e-07 0.000323321 2.98706e-07 0.000323325 3.18504e-07 0.000323331 3.39279e-07 0.000323337 3.60994e-07 0.000323344 3.83605e-07 0.000323352 4.07063e-07 0.00032336 4.31317e-07 0.00032337 4.56315e-07 0.00032338 4.82009e-07 0.00032339 5.08353e-07 0.000323402 5.35304e-07 0.000323413 5.62826e-07 0.000323425 5.90888e-07 0.000323437 6.19463e-07 0.00032345 6.48531e-07 0.000323462 6.78075e-07 0.000323475 7.08084e-07 0.000323488 7.3855e-07 0.000323501 7.69469e-07 0.000323514 8.00839e-07 0.000323527 8.32663e-07 0.000323539 8.64943e-07 0.000323552 8.97685e-07 0.000323564 9.30895e-07 0.000323576 9.64581e-07 0.000323587 9.98752e-07 0.000323598 1.03342e-06 0.000323609 1.06858e-06 0.00032362 1.10426e-06 0.000323629 1.14046e-06 0.000323639 1.17719e-06 0.000323647 1.21446e-06 0.000323656 1.25227e-06 0.000323663 1.29066e-06 0.00032367 1.32958e-06 0.000323676 1.36912e-06 0.000323681 1.40917e-06 0.000323685 1.44989e-06 0.000323689 1.49109e-06 0.000323691 1.53304e-06 0.000323693 1.57538e-06 0.000323694 1.6186e-06 0.000323693 1.66206e-06 0.000323692 1.70662e-06 0.000323689 1.75115e-06 0.000323685 1.79714e-06 0.00032368 1.84265e-06 0.000323674 1.89018e-06 0.000323666 1.93654e-06 0.000323657 1.98578e-06 0.000323646 2.03279e-06 0.000323634 2.084e-06 0.00032362 2.13137e-06 0.000323605 2.18489e-06 0.000323588 2.23221e-06 0.000323569 2.28853e-06 0.000323548 2.33524e-06 0.000323526 2.39502e-06 0.000323502 2.44039e-06 0.000323476 2.5045e-06 0.000323448 2.54758e-06 0.000323419 2.61715e-06 0.000323386 2.65673e-06 0.000323352 2.7332e-06 0.000323316 2.76784e-06 0.000323278 2.85295e-06 0.000323237 2.88103e-06 0.000323194 2.97672e-06 0.000323148 2.99668e-06 0.0003231 3.10483e-06 0.00032305 3.11592e-06 0.000322997 3.23738e-06 0.000322941 3.24186e-06 0.000322882 3.37379e-06 0.000322822 3.38293e-06 0.000322757 3.51328e-06 3.56032e-06 0.000332292 2.43933e-07 0.000332294 2.60026e-07 0.000332297 2.77098e-07 0.0003323 2.95153e-07 0.000332304 3.14183e-07 0.00033231 3.34173e-07 0.000332315 3.55097e-07 0.000332322 3.76925e-07 0.00033233 3.99619e-07 0.000332338 4.23139e-07 0.000332347 4.47442e-07 0.000332356 4.72487e-07 0.000332366 4.98234e-07 0.000332377 5.24644e-07 0.000332388 5.51682e-07 0.0003324 5.7932e-07 0.000332412 6.0753e-07 0.000332424 6.36292e-07 0.000332436 6.65587e-07 0.000332449 6.95402e-07 0.000332462 7.25729e-07 0.000332475 7.56561e-07 0.000332488 7.87895e-07 0.000332501 8.1973e-07 0.000332513 8.52069e-07 0.000332526 8.84915e-07 0.000332539 9.18274e-07 0.000332551 9.52151e-07 0.000332563 9.86555e-07 0.000332575 1.02149e-06 0.000332587 1.05697e-06 0.000332598 1.09301e-06 0.000332609 1.1296e-06 0.00033262 1.16676e-06 0.00033263 1.20451e-06 0.000332639 1.24284e-06 0.000332648 1.28178e-06 0.000332656 1.3213e-06 0.000332664 1.36146e-06 0.000332671 1.4022e-06 0.000332677 1.44364e-06 0.000332682 1.48561e-06 0.000332687 1.52835e-06 0.000332691 1.57156e-06 0.000332694 1.61566e-06 0.000332696 1.6601e-06 0.000332697 1.7056e-06 0.000332697 1.75123e-06 0.000332696 1.79823e-06 0.000332693 1.84496e-06 0.00033269 1.89357e-06 0.000332685 1.9413e-06 0.000332679 1.99168e-06 0.000332672 2.0402e-06 0.000332663 2.09259e-06 0.000332653 2.14165e-06 0.000332642 2.19637e-06 0.000332628 2.24557e-06 0.000332614 2.3031e-06 0.000332597 2.3519e-06 0.000332579 2.41289e-06 0.000332559 2.46056e-06 0.000332538 2.52587e-06 0.000332514 2.57147e-06 0.000332489 2.64224e-06 0.000332461 2.68454e-06 0.000332432 2.76223e-06 0.0003324 2.79978e-06 0.000332367 2.88617e-06 0.00033233 2.91726e-06 0.000332293 3.01442e-06 0.000332252 3.03737e-06 0.000332209 3.14737e-06 0.000332164 3.16121e-06 0.000332116 3.2852e-06 0.000332066 3.29188e-06 0.000332013 3.42743e-06 0.000331958 3.4376e-06 0.000331898 3.57302e-06 3.61818e-06 0.00034152 2.42389e-07 0.000341522 2.57894e-07 0.000341525 2.74332e-07 0.000341528 2.91714e-07 0.000341532 3.1004e-07 0.000341537 3.29304e-07 0.000341543 3.49492e-07 0.000341549 3.70583e-07 0.000341556 3.92551e-07 0.000341564 4.15364e-07 0.000341573 4.3899e-07 0.000341582 4.63393e-07 0.000341591 4.88539e-07 0.000341602 5.14395e-07 0.000341612 5.40929e-07 0.000341624 5.68113e-07 0.000341635 5.95921e-07 0.000341647 6.24333e-07 0.000341659 6.5333e-07 0.000341672 6.82897e-07 0.000341685 7.13026e-07 0.000341697 7.43707e-07 0.00034171 7.74937e-07 0.000341723 8.06714e-07 0.000341736 8.39038e-07 0.000341749 8.71911e-07 0.000341762 9.05338e-07 0.000341775 9.39324e-07 0.000341788 9.73876e-07 0.0003418 1.009e-06 0.000341813 1.04471e-06 0.000341825 1.08101e-06 0.000341836 1.1179e-06 0.000341848 1.15541e-06 0.000341859 1.19353e-06 0.000341869 1.23228e-06 0.000341879 1.27167e-06 0.000341889 1.31169e-06 0.000341898 1.35239e-06 0.000341906 1.39371e-06 0.000341914 1.43575e-06 0.000341922 1.4784e-06 0.000341928 1.52182e-06 0.000341934 1.5658e-06 0.000341939 1.61066e-06 0.000341943 1.65597e-06 0.000341946 1.70232e-06 0.000341949 1.74892e-06 0.00034195 1.79683e-06 0.00034195 1.84467e-06 0.00034195 1.89425e-06 0.000341948 1.94322e-06 0.000341945 1.99463e-06 0.00034194 2.04455e-06 0.000341935 2.09801e-06 0.000341928 2.14863e-06 0.00034192 2.20446e-06 0.00034191 2.25541e-06 0.000341899 2.31407e-06 0.000341886 2.36482e-06 0.000341872 2.42693e-06 0.000341856 2.47679e-06 0.000341839 2.54319e-06 0.000341819 2.59122e-06 0.000341798 2.66307e-06 0.000341775 2.70804e-06 0.00034175 2.7868e-06 0.000341722 2.82722e-06 0.000341694 2.91473e-06 0.000341662 2.94884e-06 0.00034163 3.04726e-06 0.000341594 3.07327e-06 0.000341556 3.18485e-06 0.000341516 3.2016e-06 0.000341473 3.32776e-06 0.000341428 3.33688e-06 0.00034138 3.47562e-06 0.00034133 3.48714e-06 0.000341276 3.62705e-06 3.67096e-06 0.000351004 2.40779e-07 0.000351006 2.55745e-07 0.000351009 2.71603e-07 0.000351012 2.88366e-07 0.000351016 3.06043e-07 0.000351021 3.24635e-07 0.000351026 3.44136e-07 0.000351032 3.64534e-07 0.000351039 3.85811e-07 0.000351046 4.07946e-07 0.000351054 4.30914e-07 0.000351063 4.54686e-07 0.000351072 4.79234e-07 0.000351082 5.04529e-07 0.000351093 5.30544e-07 0.000351103 5.57253e-07 0.000351115 5.84632e-07 0.000351126 6.1266e-07 0.000351138 6.4132e-07 0.000351151 6.70596e-07 0.000351163 7.00478e-07 0.000351176 7.30957e-07 0.000351189 7.62027e-07 0.000351202 7.93685e-07 0.000351215 8.25931e-07 0.000351228 8.58766e-07 0.000351241 8.92193e-07 0.000351254 9.26217e-07 0.000351267 9.60844e-07 0.00035128 9.9608e-07 0.000351293 1.03194e-06 0.000351306 1.06842e-06 0.000351318 1.10553e-06 0.00035133 1.14329e-06 0.000351342 1.18171e-06 0.000351354 1.22078e-06 0.000351365 1.26054e-06 0.000351375 1.30096e-06 0.000351386 1.3421e-06 0.000351396 1.3839e-06 0.000351405 1.42646e-06 0.000351414 1.46967e-06 0.000351422 1.51369e-06 0.000351429 1.55832e-06 0.000351436 1.60385e-06 0.000351442 1.64991e-06 0.000351447 1.697e-06 0.000351452 1.74446e-06 0.000351455 1.79319e-06 0.000351458 1.84201e-06 0.00035146 1.89247e-06 0.000351461 1.94255e-06 0.00035146 1.9949e-06 0.000351459 2.04608e-06 0.000351456 2.10053e-06 0.000351452 2.15258e-06 0.000351447 2.20942e-06 0.000351441 2.262e-06 0.000351433 2.32167e-06 0.000351424 2.37427e-06 0.000351413 2.43739e-06 0.000351401 2.48933e-06 0.000351387 2.55672e-06 0.000351371 2.60707e-06 0.000351354 2.67988e-06 0.000351335 2.72744e-06 0.000351315 2.80713e-06 0.000351292 2.85038e-06 0.000351267 2.93884e-06 0.00035124 2.97598e-06 0.000351212 3.07545e-06 0.000351181 3.10459e-06 0.000351148 3.21746e-06 0.000351113 3.23727e-06 0.000351075 3.36523e-06 0.000351035 3.37703e-06 0.000350992 3.51848e-06 0.000350947 3.53171e-06 0.000350899 3.67551e-06 3.71882e-06 0.00036075 2.39106e-07 0.000360753 2.53576e-07 0.000360755 2.68899e-07 0.000360759 2.85092e-07 0.000360762 3.02169e-07 0.000360767 3.20135e-07 0.000360772 3.38993e-07 0.000360778 3.58738e-07 0.000360784 3.7936e-07 0.000360791 4.00845e-07 0.000360799 4.23176e-07 0.000360807 4.4633e-07 0.000360816 4.70285e-07 0.000360826 4.95019e-07 0.000360836 5.20506e-07 0.000360846 5.46725e-07 0.000360857 5.73653e-07 0.000360869 6.01271e-07 0.000360881 6.29563e-07 0.000360893 6.58512e-07 0.000360905 6.88108e-07 0.000360918 7.18341e-07 0.000360931 7.49205e-07 0.000360944 7.80695e-07 0.000360957 8.12811e-07 0.00036097 8.45552e-07 0.000360983 8.78921e-07 0.000360996 9.12921e-07 0.00036101 9.47559e-07 0.000361023 9.82841e-07 0.000361036 1.01877e-06 0.000361049 1.05537e-06 0.000361062 1.09263e-06 0.000361075 1.13057e-06 0.000361087 1.16919e-06 0.0003611 1.20852e-06 0.000361112 1.24855e-06 0.000361123 1.28929e-06 0.000361135 1.33078e-06 0.000361145 1.37298e-06 0.000361156 1.41595e-06 0.000361166 1.45964e-06 0.000361176 1.50415e-06 0.000361184 1.54935e-06 0.000361193 1.59544e-06 0.000361201 1.64215e-06 0.000361208 1.68988e-06 0.000361214 1.7381e-06 0.00036122 1.78754e-06 0.000361225 1.83722e-06 0.000361229 1.88847e-06 0.000361232 1.93954e-06 0.000361234 1.99273e-06 0.000361235 2.04505e-06 0.000361235 2.10038e-06 0.000361234 2.15374e-06 0.000361232 2.2115e-06 0.000361228 2.26557e-06 0.000361224 2.32617e-06 0.000361217 2.38048e-06 0.00036121 2.44452e-06 0.000361201 2.49841e-06 0.000361191 2.56669e-06 0.000361179 2.61927e-06 0.000361166 2.69292e-06 0.00036115 2.74297e-06 0.000361134 2.82347e-06 0.000361115 2.86949e-06 0.000361095 2.95873e-06 0.000361072 2.99889e-06 0.000361048 3.09919e-06 0.000361022 3.1315e-06 0.000360994 3.2454e-06 0.000360963 3.26838e-06 0.00036093 3.3978e-06 0.000360894 3.41249e-06 0.000360857 3.55618e-06 0.000360817 3.57146e-06 0.000360774 3.71854e-06 3.7619e-06 0.000370767 2.37371e-07 0.000370769 2.51383e-07 0.000370772 2.66211e-07 0.000370775 2.81876e-07 0.000370779 2.98395e-07 0.000370783 3.15779e-07 0.000370788 3.34035e-07 0.000370794 3.53164e-07 0.0003708 3.73164e-07 0.000370807 3.94026e-07 0.000370814 4.15741e-07 0.000370822 4.38292e-07 0.000370831 4.61664e-07 0.00037084 4.85837e-07 0.00037085 5.10793e-07 0.00037086 5.3651e-07 0.000370871 5.62972e-07 0.000370882 5.9016e-07 0.000370893 6.18057e-07 0.000370905 6.4665e-07 0.000370917 6.75927e-07 0.00037093 7.05879e-07 0.000370942 7.36498e-07 0.000370955 7.67779e-07 0.000370968 7.9972e-07 0.000370982 8.3232e-07 0.000370995 8.65581e-07 0.000371008 8.99506e-07 0.000371022 9.34101e-07 0.000371035 9.6937e-07 0.000371049 1.00532e-06 0.000371062 1.04196e-06 0.000371076 1.07931e-06 0.000371089 1.11735e-06 0.000371102 1.15613e-06 0.000371115 1.19562e-06 0.000371127 1.23586e-06 0.00037114 1.27685e-06 0.000371152 1.3186e-06 0.000371164 1.36111e-06 0.000371175 1.40442e-06 0.000371187 1.44849e-06 0.000371197 1.49341e-06 0.000371208 1.53907e-06 0.000371217 1.58564e-06 0.000371227 1.6329e-06 0.000371235 1.68118e-06 0.000371243 1.73004e-06 0.000371251 1.7801e-06 0.000371258 1.83054e-06 0.000371264 1.88247e-06 0.000371269 1.93442e-06 0.000371273 1.98835e-06 0.000371276 2.04169e-06 0.000371279 2.09781e-06 0.00037128 2.15235e-06 0.000371281 2.21093e-06 0.00037128 2.26637e-06 0.000371279 2.3278e-06 0.000371275 2.3837e-06 0.000371271 2.44855e-06 0.000371265 2.50427e-06 0.000371259 2.57335e-06 0.00037125 2.62802e-06 0.00037124 2.70241e-06 0.000371229 2.75486e-06 0.000371216 2.83603e-06 0.000371201 2.88475e-06 0.000371185 2.97462e-06 0.000371166 3.01775e-06 0.000371147 3.1187e-06 0.000371124 3.15419e-06 0.0003711 3.26887e-06 0.000371074 3.29512e-06 0.000371046 3.42564e-06 0.000371015 3.44342e-06 0.000370982 3.58887e-06 0.000370947 3.60654e-06 0.000370909 3.75626e-06 3.80032e-06 0.000381061 2.35577e-07 0.000381063 2.49163e-07 0.000381066 2.63532e-07 0.000381069 2.78706e-07 0.000381073 2.94705e-07 0.000381077 3.11544e-07 0.000381082 3.29234e-07 0.000381087 3.47782e-07 0.000381093 3.67191e-07 0.0003811 3.87458e-07 0.000381107 4.08579e-07 0.000381115 4.30544e-07 0.000381123 4.53342e-07 0.000381132 4.7696e-07 0.000381141 5.01382e-07 0.000381151 5.26593e-07 0.000381162 5.52577e-07 0.000381172 5.79317e-07 0.000381184 6.068e-07 0.000381195 6.35013e-07 0.000381207 6.63943e-07 0.00038122 6.93583e-07 0.000381232 7.23923e-07 0.000381245 7.54959e-07 0.000381258 7.86687e-07 0.000381271 8.19107e-07 0.000381285 8.52218e-07 0.000381298 8.86024e-07 0.000381312 9.20528e-07 0.000381325 9.55737e-07 0.000381339 9.91656e-07 0.000381353 1.02829e-06 0.000381366 1.06566e-06 0.00038138 1.10376e-06 0.000381393 1.14261e-06 0.000381407 1.18222e-06 0.00038142 1.2226e-06 0.000381433 1.26375e-06 0.000381446 1.3057e-06 0.000381459 1.34845e-06 0.000381471 1.39202e-06 0.000381483 1.43639e-06 0.000381495 1.48163e-06 0.000381506 1.52766e-06 0.000381517 1.57462e-06 0.000381528 1.62234e-06 0.000381538 1.67108e-06 0.000381548 1.72049e-06 0.000381557 1.77108e-06 0.000381565 1.82217e-06 0.000381573 1.87469e-06 0.00038158 1.9274e-06 0.000381586 1.98198e-06 0.000381592 2.03622e-06 0.000381596 2.09304e-06 0.0003816 2.14864e-06 0.000381603 2.20794e-06 0.000381605 2.26462e-06 0.000381606 2.32679e-06 0.000381605 2.38414e-06 0.000381604 2.44972e-06 0.000381601 2.50714e-06 0.000381598 2.57691e-06 0.000381592 2.63355e-06 0.000381586 2.70858e-06 0.000381578 2.76331e-06 0.000381569 2.84504e-06 0.000381557 2.89636e-06 0.000381545 2.98673e-06 0.00038153 3.03277e-06 0.000381514 3.13418e-06 0.000381496 3.17286e-06 0.000381477 3.28806e-06 0.000381454 3.31765e-06 0.000381431 3.44893e-06 0.000381404 3.46999e-06 0.000381376 3.61672e-06 0.000381346 3.63711e-06 0.000381313 3.78885e-06 3.83421e-06 0.00039164 2.33726e-07 0.000391643 2.46914e-07 0.000391645 2.60854e-07 0.000391648 2.7557e-07 0.000391652 2.91083e-07 0.000391656 3.07411e-07 0.000391661 3.2457e-07 0.000391666 3.42569e-07 0.000391672 3.61415e-07 0.000391678 3.81113e-07 0.000391685 4.01662e-07 0.000391692 4.23058e-07 0.000391701 4.45295e-07 0.000391709 4.68365e-07 0.000391718 4.92255e-07 0.000391728 5.16956e-07 0.000391738 5.42453e-07 0.000391749 5.68734e-07 0.00039176 5.95786e-07 0.000391771 6.23597e-07 0.000391783 6.52158e-07 0.000391795 6.81459e-07 0.000391807 7.11492e-07 0.00039182 7.42252e-07 0.000391833 7.73735e-07 0.000391846 8.05939e-07 0.00039186 8.38864e-07 0.000391873 8.72512e-07 0.000391887 9.06886e-07 0.0003919 9.41991e-07 0.000391914 9.77834e-07 0.000391928 1.01442e-06 0.000391942 1.05176e-06 0.000391956 1.08987e-06 0.00039197 1.12875e-06 0.000391984 1.16841e-06 0.000391997 1.20886e-06 0.000392011 1.25013e-06 0.000392024 1.29221e-06 0.000392038 1.33512e-06 0.000392051 1.37888e-06 0.000392064 1.42348e-06 0.000392076 1.46897e-06 0.000392089 1.5153e-06 0.000392101 1.56257e-06 0.000392113 1.61066e-06 0.000392124 1.65978e-06 0.000392135 1.70964e-06 0.000392145 1.76066e-06 0.000392155 1.8123e-06 0.000392164 1.86532e-06 0.000392173 1.9187e-06 0.000392181 1.97383e-06 0.000392189 2.02886e-06 0.000392195 2.08628e-06 0.000392201 2.14281e-06 0.000392206 2.20275e-06 0.00039221 2.26054e-06 0.000392214 2.32337e-06 0.000392216 2.38203e-06 0.000392217 2.44826e-06 0.000392217 2.50724e-06 0.000392217 2.57761e-06 0.000392214 2.63609e-06 0.000392211 2.71165e-06 0.000392206 2.76854e-06 0.0003922 2.85072e-06 0.000392192 2.90453e-06 0.000392183 2.99526e-06 0.000392172 3.04414e-06 0.00039216 3.14584e-06 0.000392146 3.18768e-06 0.00039213 3.30316e-06 0.000392112 3.33615e-06 0.000392093 3.46786e-06 0.000392071 3.49236e-06 0.000392047 3.63988e-06 0.000392021 3.66332e-06 0.000391994 3.81645e-06 3.86368e-06 0.000402513 2.31818e-07 0.000402515 2.44634e-07 0.000402518 2.58173e-07 0.000402521 2.7246e-07 0.000402524 2.87517e-07 0.000402528 3.03366e-07 0.000402533 3.20022e-07 0.000402538 3.37501e-07 0.000402544 3.55814e-07 0.00040255 3.74967e-07 0.000402556 3.94966e-07 0.000402564 4.15811e-07 0.000402571 4.375e-07 0.00040258 4.6003e-07 0.000402589 4.83393e-07 0.000402598 5.07582e-07 0.000402608 5.32588e-07 0.000402618 5.58399e-07 0.000402629 5.85007e-07 0.00040264 6.12401e-07 0.000402652 6.40572e-07 0.000402664 6.69511e-07 0.000402676 6.99212e-07 0.000402689 7.29669e-07 0.000402701 7.60877e-07 0.000402715 7.92835e-07 0.000402728 8.25542e-07 0.000402741 8.58998e-07 0.000402755 8.93207e-07 0.000402769 9.28173e-07 0.000402783 9.63901e-07 0.000402797 1.0004e-06 0.000402811 1.03767e-06 0.000402825 1.07574e-06 0.000402839 1.1146e-06 0.000402853 1.15426e-06 0.000402867 1.19475e-06 0.000402882 1.23607e-06 0.000402895 1.27823e-06 0.000402909 1.32125e-06 0.000402923 1.36514e-06 0.000402937 1.4099e-06 0.00040295 1.45557e-06 0.000402963 1.50212e-06 0.000402976 1.54964e-06 0.000402989 1.59801e-06 0.000403001 1.64743e-06 0.000403013 1.69766e-06 0.000403025 1.74904e-06 0.000403036 1.80113e-06 0.000403047 1.85457e-06 0.000403057 1.9085e-06 0.000403067 1.9641e-06 0.000403076 2.01981e-06 0.000403084 2.07774e-06 0.000403092 2.13509e-06 0.000403099 2.19558e-06 0.000403105 2.25436e-06 0.000403111 2.31774e-06 0.000403115 2.3776e-06 0.000403119 2.44437e-06 0.000403122 2.50478e-06 0.000403124 2.57566e-06 0.000403124 2.63585e-06 0.000403124 2.71185e-06 0.000403122 2.77076e-06 0.000403119 2.85329e-06 0.000403114 2.90948e-06 0.000403109 3.00044e-06 0.000403101 3.05207e-06 0.000403093 3.15389e-06 0.000403082 3.19884e-06 0.00040307 3.31438e-06 0.000403056 3.35079e-06 0.000403041 3.48261e-06 0.000403023 3.51069e-06 0.000403004 3.65855e-06 0.000402982 3.68532e-06 0.000402959 3.83924e-06 3.88888e-06 0.000413686 2.29854e-07 0.000413689 2.42321e-07 0.000413691 2.55483e-07 0.000413694 2.69367e-07 0.000413698 2.83996e-07 0.000413702 2.99392e-07 0.000413706 3.15575e-07 0.000413711 3.32561e-07 0.000413717 3.50365e-07 0.000413723 3.68998e-07 0.000413729 3.88467e-07 0.000413736 4.08779e-07 0.000413744 4.29935e-07 0.000413752 4.51935e-07 0.00041376 4.74777e-07 0.00041377 4.98457e-07 0.000413779 5.22968e-07 0.000413789 5.48304e-07 0.0004138 5.74457e-07 0.000413811 6.01419e-07 0.000413822 6.29182e-07 0.000413834 6.5774e-07 0.000413846 6.87087e-07 0.000413859 7.17216e-07 0.000413871 7.48124e-07 0.000413884 7.79808e-07 0.000413898 8.12268e-07 0.000413911 8.45503e-07 0.000413925 8.79515e-07 0.000413939 9.14309e-07 0.000413953 9.49889e-07 0.000413967 9.86262e-07 0.000413981 1.02343e-06 0.000413995 1.06142e-06 0.00041401 1.10022e-06 0.000414024 1.13985e-06 0.000414039 1.18032e-06 0.000414053 1.22165e-06 0.000414067 1.26384e-06 0.000414082 1.30691e-06 0.000414096 1.35088e-06 0.00041411 1.39575e-06 0.000414124 1.44154e-06 0.000414138 1.48825e-06 0.000414152 1.53594e-06 0.000414165 1.58454e-06 0.000414178 1.63418e-06 0.000414191 1.6847e-06 0.000414204 1.73636e-06 0.000414216 1.78882e-06 0.000414228 1.84259e-06 0.00041424 1.89698e-06 0.000414251 1.95298e-06 0.000414262 2.00925e-06 0.000414272 2.06762e-06 0.000414281 2.12567e-06 0.00041429 2.18663e-06 0.000414298 2.24627e-06 0.000414306 2.31013e-06 0.000414312 2.37104e-06 0.000414318 2.43828e-06 0.000414323 2.49998e-06 0.000414328 2.57129e-06 0.00041433 2.63304e-06 0.000414333 2.7094e-06 0.000414333 2.77019e-06 0.000414334 2.85297e-06 0.000414332 2.9114e-06 0.00041433 3.00247e-06 0.000414325 3.05675e-06 0.00041432 3.15853e-06 0.000414313 3.20655e-06 0.000414305 3.32193e-06 0.000414294 3.36178e-06 0.000414283 3.49338e-06 0.000414269 3.52515e-06 0.000414255 3.67291e-06 0.000414237 3.70328e-06 0.000414219 3.8574e-06 3.90992e-06 0.000425169 2.27836e-07 0.000425172 2.39973e-07 0.000425175 2.5278e-07 0.000425178 2.66284e-07 0.000425181 2.80509e-07 0.000425185 2.95478e-07 0.000425189 3.11213e-07 0.000425194 3.27732e-07 0.0004252 3.45051e-07 0.000425205 3.63186e-07 0.000425212 3.82146e-07 0.000425218 4.01942e-07 0.000425226 4.2258e-07 0.000425234 4.44062e-07 0.000425242 4.6639e-07 0.000425251 4.89564e-07 0.00042526 5.1358e-07 0.00042527 5.38436e-07 0.000425281 5.64127e-07 0.000425291 5.90646e-07 0.000425303 6.17988e-07 0.000425314 6.46148e-07 0.000425326 6.7512e-07 0.000425338 7.049e-07 0.000425351 7.35484e-07 0.000425364 7.66869e-07 0.000425377 7.99055e-07 0.000425391 8.32041e-07 0.000425404 8.65829e-07 0.000425418 9.00422e-07 0.000425432 9.35824e-07 0.000425447 9.7204e-07 0.000425461 1.00908e-06 0.000425475 1.04695e-06 0.00042549 1.08566e-06 0.000425505 1.12522e-06 0.000425519 1.16564e-06 0.000425534 1.20693e-06 0.000425549 1.24912e-06 0.000425563 1.2922e-06 0.000425578 1.33619e-06 0.000425593 1.38111e-06 0.000425607 1.42698e-06 0.000425622 1.47379e-06 0.000425636 1.5216e-06 0.00042565 1.57035e-06 0.000425664 1.62016e-06 0.000425678 1.67089e-06 0.000425692 1.72277e-06 0.000425705 1.77552e-06 0.000425718 1.82956e-06 0.000425731 1.88432e-06 0.000425743 1.94063e-06 0.000425755 1.99738e-06 0.000425766 2.05609e-06 0.000425777 2.11474e-06 0.000425788 2.17608e-06 0.000425798 2.23647e-06 0.000425807 2.30073e-06 0.000425816 2.36257e-06 0.000425824 2.4302e-06 0.000425831 2.49304e-06 0.000425837 2.5647e-06 0.000425842 2.62788e-06 0.000425847 2.7045e-06 0.00042585 2.76704e-06 0.000425853 2.84996e-06 0.000425854 2.91052e-06 0.000425855 3.00158e-06 0.000425854 3.05839e-06 0.000425852 3.15999e-06 0.000425848 3.21099e-06 0.000425844 3.32601e-06 0.000425836 3.36928e-06 0.000425829 3.50038e-06 0.000425818 3.53594e-06 0.000425808 3.68315e-06 0.000425794 3.71737e-06 0.00042578 3.87114e-06 3.92693e-06 0.000436971 2.25765e-07 0.000436973 2.3759e-07 0.000436976 2.50061e-07 0.000436979 2.63206e-07 0.000436982 2.77049e-07 0.000436986 2.91614e-07 0.000436991 3.06923e-07 0.000436995 3.22997e-07 0.000437001 3.39855e-07 0.000437006 3.57512e-07 0.000437012 3.75984e-07 0.000437019 3.95282e-07 0.000437026 4.15415e-07 0.000437034 4.36391e-07 0.000437042 4.58215e-07 0.000437051 4.80888e-07 0.00043706 5.04412e-07 0.00043707 5.28786e-07 0.00043708 5.54008e-07 0.00043709 5.80076e-07 0.000437101 6.06985e-07 0.000437113 6.34731e-07 0.000437124 6.63312e-07 0.000437137 6.92723e-07 0.000437149 7.22962e-07 0.000437162 7.54026e-07 0.000437175 7.85914e-07 0.000437189 8.18626e-07 0.000437202 8.52163e-07 0.000437216 8.86528e-07 0.00043723 9.21724e-07 0.000437245 9.57756e-07 0.000437259 9.94632e-07 0.000437274 1.03236e-06 0.000437288 1.07094e-06 0.000437303 1.1104e-06 0.000437318 1.15074e-06 0.000437333 1.19196e-06 0.000437348 1.2341e-06 0.000437363 1.27715e-06 0.000437378 1.32114e-06 0.000437393 1.36607e-06 0.000437408 1.41197e-06 0.000437423 1.45883e-06 0.000437438 1.50671e-06 0.000437453 1.55556e-06 0.000437467 1.60548e-06 0.000437482 1.65637e-06 0.000437496 1.7084e-06 0.000437511 1.76136e-06 0.000437524 1.8156e-06 0.000437538 1.87066e-06 0.000437552 1.9272e-06 0.000437565 1.98434e-06 0.000437577 2.04333e-06 0.00043759 2.10248e-06 0.000437602 2.16413e-06 0.000437613 2.22515e-06 0.000437624 2.28973e-06 0.000437634 2.35238e-06 0.000437644 2.42031e-06 0.000437653 2.48418e-06 0.000437661 2.5561e-06 0.000437669 2.62056e-06 0.000437676 2.69737e-06 0.000437681 2.76151e-06 0.000437687 2.84449e-06 0.00043769 2.90702e-06 0.000437694 2.99797e-06 0.000437695 3.0572e-06 0.000437697 3.15848e-06 0.000437695 3.21237e-06 0.000437694 3.32683e-06 0.00043769 3.37351e-06 0.000437687 3.50381e-06 0.00043768 3.54322e-06 0.000437673 3.6895e-06 0.000437663 3.72775e-06 0.000437653 3.88066e-06 3.94006e-06 0.000449099 2.2364e-07 0.000449102 2.35169e-07 0.000449104 2.47323e-07 0.000449107 2.60128e-07 0.000449111 2.73609e-07 0.000449115 2.8779e-07 0.000449119 3.02695e-07 0.000449124 3.18345e-07 0.000449129 3.34761e-07 0.000449134 3.51962e-07 0.00044914 3.69964e-07 0.000449147 3.88781e-07 0.000449154 4.08425e-07 0.000449161 4.28908e-07 0.000449169 4.50235e-07 0.000449178 4.72415e-07 0.000449187 4.9545e-07 0.000449196 5.19342e-07 0.000449206 5.44093e-07 0.000449216 5.69703e-07 0.000449227 5.96169e-07 0.000449238 6.2349e-07 0.00044925 6.51665e-07 0.000449262 6.8069e-07 0.000449275 7.10564e-07 0.000449287 7.41285e-07 0.0004493 7.72853e-07 0.000449314 8.05267e-07 0.000449327 8.38529e-07 0.000449341 8.7264e-07 0.000449355 9.07605e-07 0.00044937 9.43427e-07 0.000449384 9.80112e-07 0.000449399 1.01767e-06 0.000449414 1.0561e-06 0.000449429 1.09543e-06 0.000449444 1.13565e-06 0.000449459 1.17678e-06 0.000449474 1.21884e-06 0.00044949 1.26183e-06 0.000449505 1.30577e-06 0.00044952 1.35067e-06 0.000449536 1.39656e-06 0.000449551 1.44344e-06 0.000449566 1.49134e-06 0.000449582 1.54024e-06 0.000449597 1.59023e-06 0.000449612 1.64121e-06 0.000449627 1.69335e-06 0.000449642 1.74647e-06 0.000449657 1.80085e-06 0.000449671 1.85612e-06 0.000449686 1.91285e-06 0.0004497 1.97028e-06 0.000449714 2.0295e-06 0.000449727 2.08905e-06 0.00044974 2.15093e-06 0.000449753 2.21248e-06 0.000449765 2.27731e-06 0.000449777 2.34065e-06 0.000449789 2.40882e-06 0.000449799 2.47358e-06 0.00044981 2.54569e-06 0.000449819 2.6113e-06 0.000449828 2.68821e-06 0.000449836 2.75381e-06 0.000449843 2.83677e-06 0.000449849 2.90114e-06 0.000449855 2.99188e-06 0.000449859 3.05338e-06 0.000449864 3.15422e-06 0.000449865 3.21089e-06 0.000449867 3.32463e-06 0.000449866 3.37464e-06 0.000449866 3.5039e-06 0.000449862 3.5472e-06 0.000449859 3.69216e-06 0.000449852 3.73461e-06 0.000449847 3.88619e-06 3.94945e-06 0.000461564 2.21464e-07 0.000461566 2.32711e-07 0.000461569 2.44563e-07 0.000461572 2.57044e-07 0.000461575 2.70181e-07 0.000461579 2.83997e-07 0.000461583 2.98516e-07 0.000461588 3.13763e-07 0.000461593 3.29757e-07 0.000461598 3.4652e-07 0.000461604 3.64069e-07 0.000461611 3.82422e-07 0.000461617 4.01593e-07 0.000461625 4.21594e-07 0.000461633 4.42437e-07 0.000461641 4.6413e-07 0.00046165 4.86681e-07 0.000461659 5.10094e-07 0.000461669 5.34372e-07 0.000461679 5.59519e-07 0.000461689 5.85535e-07 0.0004617 6.12421e-07 0.000461712 6.40176e-07 0.000461724 6.68801e-07 0.000461736 6.98293e-07 0.000461749 7.28653e-07 0.000461762 7.59879e-07 0.000461775 7.91974e-07 0.000461789 8.24937e-07 0.000461802 8.58772e-07 0.000461817 8.9348e-07 0.000461831 9.29066e-07 0.000461846 9.65536e-07 0.00046186 1.0029e-06 0.000461875 1.04115e-06 0.00046189 1.08032e-06 0.000461906 1.1204e-06 0.000461921 1.16141e-06 0.000461936 1.20336e-06 0.000461952 1.24626e-06 0.000461968 1.29012e-06 0.000461983 1.33497e-06 0.000461999 1.38082e-06 0.000462015 1.42767e-06 0.000462031 1.47556e-06 0.000462046 1.52447e-06 0.000462062 1.57448e-06 0.000462078 1.62552e-06 0.000462094 1.67771e-06 0.000462109 1.73093e-06 0.000462125 1.7854e-06 0.00046214 1.84083e-06 0.000462155 1.89768e-06 0.00046217 1.95535e-06 0.000462185 2.01471e-06 0.000462199 2.07458e-06 0.000462213 2.13664e-06 0.000462227 2.19862e-06 0.000462241 2.26363e-06 0.000462254 2.32755e-06 0.000462267 2.39589e-06 0.000462279 2.46143e-06 0.000462291 2.53366e-06 0.000462302 2.60028e-06 0.000462313 2.67723e-06 0.000462323 2.74414e-06 0.000462333 2.827e-06 0.000462341 2.89306e-06 0.000462349 2.9835e-06 0.000462355 3.04714e-06 0.000462362 3.14742e-06 0.000462366 3.20676e-06 0.000462371 3.3196e-06 0.000462373 3.3729e-06 0.000462376 3.50088e-06 0.000462375 3.54807e-06 0.000462376 3.69136e-06 0.000462372 3.73813e-06 0.000462371 3.88796e-06 3.95525e-06 0.000474373 2.19235e-07 0.000474376 2.30215e-07 0.000474379 2.41778e-07 0.000474382 2.53951e-07 0.000474385 2.6676e-07 0.000474389 2.80228e-07 0.000474393 2.9438e-07 0.000474398 3.0924e-07 0.000474403 3.24831e-07 0.000474408 3.41173e-07 0.000474414 3.58287e-07 0.00047442 3.76192e-07 0.000474427 3.94903e-07 0.000474434 4.14437e-07 0.000474441 4.34805e-07 0.00047445 4.56021e-07 0.000474458 4.78093e-07 0.000474467 5.01029e-07 0.000474477 5.24836e-07 0.000474487 5.49517e-07 0.000474497 5.75078e-07 0.000474508 6.0152e-07 0.000474519 6.28846e-07 0.000474531 6.57056e-07 0.000474543 6.86151e-07 0.000474556 7.16132e-07 0.000474569 7.46999e-07 0.000474582 7.78754e-07 0.000474595 8.11397e-07 0.000474609 8.44932e-07 0.000474623 8.79361e-07 0.000474638 9.14688e-07 0.000474652 9.50918e-07 0.000474667 9.88058e-07 0.000474682 1.02611e-06 0.000474698 1.06509e-06 0.000474713 1.10501e-06 0.000474728 1.14587e-06 0.000474744 1.18768e-06 0.00047476 1.23047e-06 0.000474776 1.27423e-06 0.000474792 1.31899e-06 0.000474808 1.36477e-06 0.000474824 1.41156e-06 0.00047484 1.45941e-06 0.000474856 1.5083e-06 0.000474872 1.55829e-06 0.000474889 1.60934e-06 0.000474905 1.66155e-06 0.000474921 1.71482e-06 0.000474937 1.76934e-06 0.000474953 1.82488e-06 0.000474969 1.8818e-06 0.000474984 1.93963e-06 0.000475 1.9991e-06 0.000475015 2.05921e-06 0.000475031 2.12138e-06 0.000475046 2.18372e-06 0.00047506 2.24885e-06 0.000475075 2.31325e-06 0.000475089 2.3817e-06 0.000475102 2.44789e-06 0.000475116 2.52018e-06 0.000475128 2.58769e-06 0.000475141 2.66461e-06 0.000475153 2.7327e-06 0.000475164 2.81538e-06 0.000475174 2.88298e-06 0.000475185 2.97305e-06 0.000475193 3.03869e-06 0.000475202 3.1383e-06 0.000475209 3.20018e-06 0.000475216 3.31199e-06 0.000475221 3.36847e-06 0.000475227 3.49496e-06 0.000475229 3.54601e-06 0.000475233 3.68734e-06 0.000475233 3.73849e-06 0.000475234 3.88621e-06 3.95762e-06 0.000487538 2.16956e-07 0.000487541 2.27679e-07 0.000487543 2.38967e-07 0.000487547 2.50846e-07 0.00048755 2.63341e-07 0.000487554 2.76476e-07 0.000487558 2.90278e-07 0.000487562 3.04768e-07 0.000487567 3.19971e-07 0.000487572 3.3591e-07 0.000487578 3.52605e-07 0.000487584 3.70076e-07 0.000487591 3.88342e-07 0.000487598 4.07421e-07 0.000487605 4.27326e-07 0.000487613 4.48073e-07 0.000487622 4.69673e-07 0.000487631 4.92137e-07 0.00048764 5.15474e-07 0.00048765 5.3969e-07 0.00048766 5.64791e-07 0.000487671 5.90784e-07 0.000487682 6.17671e-07 0.000487694 6.45456e-07 0.000487706 6.7414e-07 0.000487718 7.03727e-07 0.000487731 7.34217e-07 0.000487744 7.65612e-07 0.000487757 7.97916e-07 0.000487771 8.3113e-07 0.000487785 8.65257e-07 0.0004878 9.00302e-07 0.000487814 9.3627e-07 0.000487829 9.73165e-07 0.000487844 1.011e-06 0.00048786 1.04977e-06 0.000487875 1.08949e-06 0.000487891 1.13018e-06 0.000487907 1.17184e-06 0.000487923 1.21448e-06 0.000487939 1.25812e-06 0.000487955 1.30276e-06 0.000487971 1.34844e-06 0.000487988 1.39515e-06 0.000488004 1.44293e-06 0.000488021 1.49177e-06 0.000488037 1.54171e-06 0.000488054 1.59274e-06 0.000488071 1.64494e-06 0.000488087 1.69822e-06 0.000488104 1.75274e-06 0.00048812 1.80834e-06 0.000488137 1.8653e-06 0.000488153 1.92323e-06 0.00048817 1.98275e-06 0.000488186 2.04304e-06 0.000488202 2.10529e-06 0.000488218 2.16789e-06 0.000488233 2.23309e-06 0.000488249 2.29789e-06 0.000488264 2.36639e-06 0.000488279 2.43313e-06 0.000488294 2.50542e-06 0.000488308 2.57369e-06 0.000488322 2.65053e-06 0.000488335 2.71966e-06 0.000488348 2.80211e-06 0.00048836 2.8711e-06 0.000488372 2.96072e-06 0.000488383 3.02821e-06 0.000488394 3.12706e-06 0.000488403 3.19136e-06 0.000488413 3.302e-06 0.00048842 3.36156e-06 0.000488428 3.48637e-06 0.000488433 3.54124e-06 0.00048844 3.68033e-06 0.000488443 3.73588e-06 0.000488448 3.88117e-06 3.95672e-06 0.000501068 2.14626e-07 0.00050107 2.25103e-07 0.000501073 2.36127e-07 0.000501076 2.47725e-07 0.00050108 2.5992e-07 0.000501083 2.72737e-07 0.000501087 2.86202e-07 0.000501092 3.00338e-07 0.000501097 3.15169e-07 0.000501102 3.30719e-07 0.000501107 3.4701e-07 0.000501113 3.64063e-07 0.00050112 3.81898e-07 0.000501127 4.00533e-07 0.000501134 4.19987e-07 0.000501142 4.40275e-07 0.00050115 4.61411e-07 0.000501159 4.83408e-07 0.000501168 5.06277e-07 0.000501178 5.30028e-07 0.000501188 5.54669e-07 0.000501198 5.80207e-07 0.000501209 6.06649e-07 0.000501221 6.33999e-07 0.000501233 6.62261e-07 0.000501245 6.91439e-07 0.000501258 7.21536e-07 0.000501271 7.52556e-07 0.000501284 7.84501e-07 0.000501298 8.17374e-07 0.000501312 8.51179e-07 0.000501326 8.8592e-07 0.000501341 9.21602e-07 0.000501356 9.58231e-07 0.000501371 9.95812e-07 0.000501387 1.03435e-06 0.000501402 1.07386e-06 0.000501418 1.11435e-06 0.000501434 1.15583e-06 0.00050145 1.19831e-06 0.000501467 1.24179e-06 0.000501483 1.28631e-06 0.0005015 1.33186e-06 0.000501516 1.37846e-06 0.000501533 1.42614e-06 0.00050155 1.4749e-06 0.000501567 1.52478e-06 0.000501584 1.57576e-06 0.000501601 1.6279e-06 0.000501618 1.68116e-06 0.000501635 1.73567e-06 0.000501652 1.79127e-06 0.000501669 1.84823e-06 0.000501686 1.90623e-06 0.000501703 1.96576e-06 0.00050172 2.02617e-06 0.000501737 2.08844e-06 0.000501754 2.15125e-06 0.00050177 2.21648e-06 0.000501787 2.28158e-06 0.000501803 2.35008e-06 0.000501819 2.41728e-06 0.000501835 2.48953e-06 0.00050185 2.55845e-06 0.000501865 2.63514e-06 0.00050188 2.70518e-06 0.000501894 2.78735e-06 0.000501908 2.8576e-06 0.000501922 2.94671e-06 0.000501934 3.0159e-06 0.000501947 3.11392e-06 0.000501958 3.18048e-06 0.00050197 3.28985e-06 0.00050198 3.35237e-06 0.000501991 3.47534e-06 0.000501998 3.53395e-06 0.000502008 3.67058e-06 0.000502013 3.7305e-06 0.000502021 3.87312e-06 3.95274e-06 0.000514972 2.12247e-07 0.000514975 2.22487e-07 0.000514977 2.33258e-07 0.000514981 2.44585e-07 0.000514984 2.56493e-07 0.000514988 2.69005e-07 0.000514992 2.82146e-07 0.000514996 2.95942e-07 0.000515001 3.10416e-07 0.000515006 3.25592e-07 0.000515012 3.41493e-07 0.000515018 3.58141e-07 0.000515024 3.75557e-07 0.000515031 3.93763e-07 0.000515038 4.12776e-07 0.000515046 4.32614e-07 0.000515054 4.53294e-07 0.000515062 4.7483e-07 0.000515071 4.97236e-07 0.000515081 5.20523e-07 0.000515091 5.44703e-07 0.000515101 5.69784e-07 0.000515112 5.95775e-07 0.000515123 6.22683e-07 0.000515135 6.50513e-07 0.000515147 6.79271e-07 0.00051516 7.08962e-07 0.000515173 7.39589e-07 0.000515186 7.71158e-07 0.0005152 8.03671e-07 0.000515214 8.37134e-07 0.000515228 8.7155e-07 0.000515243 9.06926e-07 0.000515258 9.43265e-07 0.000515273 9.80576e-07 0.000515289 1.01886e-06 0.000515304 1.05814e-06 0.00051532 1.09841e-06 0.000515336 1.13968e-06 0.000515353 1.18197e-06 0.000515369 1.22528e-06 0.000515386 1.26964e-06 0.000515403 1.31504e-06 0.00051542 1.36152e-06 0.000515437 1.40908e-06 0.000515454 1.45773e-06 0.000515471 1.50751e-06 0.000515489 1.55841e-06 0.000515506 1.61048e-06 0.000515523 1.6637e-06 0.000515541 1.71815e-06 0.000515559 1.77373e-06 0.000515576 1.83066e-06 0.000515594 1.88867e-06 0.000515611 1.94819e-06 0.000515629 2.00867e-06 0.000515646 2.07093e-06 0.000515664 2.13388e-06 0.000515681 2.19909e-06 0.000515698 2.26443e-06 0.000515715 2.3329e-06 0.000515732 2.40046e-06 0.000515749 2.47262e-06 0.000515765 2.54209e-06 0.000515782 2.6186e-06 0.000515798 2.68944e-06 0.000515814 2.77127e-06 0.000515829 2.84265e-06 0.000515844 2.93119e-06 0.000515858 3.00193e-06 0.000515873 3.09906e-06 0.000515886 3.16774e-06 0.0005159 3.27575e-06 0.000515911 3.34109e-06 0.000515924 3.4621e-06 0.000515934 3.52433e-06 0.000515946 3.65833e-06 0.000515954 3.72253e-06 0.000515965 3.86229e-06 3.94585e-06 0.000529262 2.09819e-07 0.000529264 2.19831e-07 0.000529267 2.30359e-07 0.00052927 2.41426e-07 0.000529274 2.53056e-07 0.000529277 2.65275e-07 0.000529282 2.78106e-07 0.000529286 2.91574e-07 0.000529291 3.05704e-07 0.000529296 3.20519e-07 0.000529301 3.36043e-07 0.000529307 3.523e-07 0.000529313 3.69311e-07 0.00052932 3.87098e-07 0.000529327 4.05681e-07 0.000529335 4.25079e-07 0.000529343 4.45311e-07 0.000529351 4.66393e-07 0.00052936 4.88341e-07 0.000529369 5.11168e-07 0.000529379 5.34887e-07 0.000529389 5.59509e-07 0.0005294 5.85046e-07 0.000529411 6.11505e-07 0.000529423 6.38895e-07 0.000529435 6.67223e-07 0.000529447 6.96494e-07 0.00052946 7.26716e-07 0.000529473 7.57892e-07 0.000529487 7.90028e-07 0.000529501 8.2313e-07 0.000529515 8.57202e-07 0.00052953 8.9225e-07 0.000529545 9.28279e-07 0.00052956 9.65296e-07 0.000529576 1.00331e-06 0.000529592 1.04232e-06 0.000529608 1.08235e-06 0.000529624 1.1234e-06 0.000529641 1.16547e-06 0.000529657 1.20859e-06 0.000529674 1.25277e-06 0.000529691 1.29801e-06 0.000529708 1.34433e-06 0.000529726 1.39175e-06 0.000529743 1.44027e-06 0.000529761 1.48994e-06 0.000529778 1.54073e-06 0.000529796 1.59271e-06 0.000529814 1.64584e-06 0.000529832 1.70022e-06 0.00052985 1.75575e-06 0.000529868 1.81262e-06 0.000529886 1.87062e-06 0.000529904 1.93009e-06 0.000529922 1.9906e-06 0.00052994 2.05282e-06 0.000529958 2.11585e-06 0.000529976 2.18102e-06 0.000529994 2.24653e-06 0.000530012 2.31493e-06 0.00053003 2.38277e-06 0.000530048 2.45482e-06 0.000530065 2.52473e-06 0.000530083 2.60104e-06 0.0005301 2.67255e-06 0.000530117 2.75402e-06 0.000530133 2.82638e-06 0.00053015 2.91433e-06 0.000530165 2.98648e-06 0.000530182 3.08267e-06 0.000530196 3.15331e-06 0.000530212 3.2599e-06 0.000530225 3.32791e-06 0.000530241 3.44685e-06 0.000530252 3.51257e-06 0.000530267 3.6438e-06 0.000530277 3.71216e-06 0.000530291 3.84892e-06 3.93623e-06 0.000543947 2.07342e-07 0.00054395 2.17134e-07 0.000543953 2.27427e-07 0.000543956 2.38244e-07 0.000543959 2.49608e-07 0.000543963 2.61544e-07 0.000543967 2.74076e-07 0.000543972 2.87229e-07 0.000543976 3.01026e-07 0.000543981 3.15493e-07 0.000543987 3.30653e-07 0.000543992 3.46531e-07 0.000543999 3.63148e-07 0.000544005 3.80528e-07 0.000544012 3.98692e-07 0.00054402 4.1766e-07 0.000544027 4.37453e-07 0.000544036 4.58088e-07 0.000544044 4.79583e-07 0.000544054 5.01953e-07 0.000544063 5.25213e-07 0.000544073 5.49377e-07 0.000544084 5.74456e-07 0.000544095 6.00463e-07 0.000544107 6.27406e-07 0.000544119 6.55294e-07 0.000544131 6.84136e-07 0.000544144 7.13938e-07 0.000544157 7.44708e-07 0.00054417 7.76451e-07 0.000544184 8.09174e-07 0.000544199 8.42883e-07 0.000544213 8.77584e-07 0.000544228 9.13282e-07 0.000544244 9.49985e-07 0.000544259 9.87699e-07 0.000544275 1.02643e-06 0.000544291 1.06619e-06 0.000544308 1.10699e-06 0.000544324 1.14884e-06 0.000544341 1.19174e-06 0.000544358 1.23571e-06 0.000544376 1.28076e-06 0.000544393 1.32691e-06 0.000544411 1.37416e-06 0.000544428 1.42254e-06 0.000544446 1.47206e-06 0.000544464 1.52274e-06 0.000544482 1.57459e-06 0.0005445 1.62763e-06 0.000544519 1.6819e-06 0.000544537 1.73737e-06 0.000544556 1.79415e-06 0.000544574 1.8521e-06 0.000544593 1.9115e-06 0.000544611 1.972e-06 0.00054463 2.03416e-06 0.000544649 2.09723e-06 0.000544667 2.16233e-06 0.000544686 2.22795e-06 0.000544705 2.29625e-06 0.000544723 2.36431e-06 0.000544742 2.43621e-06 0.00054476 2.50649e-06 0.000544778 2.58255e-06 0.000544796 2.65464e-06 0.000544815 2.73572e-06 0.000544832 2.80895e-06 0.00054485 2.89627e-06 0.000544867 2.96969e-06 0.000544885 3.0649e-06 0.000544901 3.13736e-06 0.000544918 3.24247e-06 0.000544933 3.31299e-06 0.00054495 3.4298e-06 0.000544964 3.49885e-06 0.00054498 3.62723e-06 0.000544993 3.69957e-06 0.000545009 3.83327e-06 3.92406e-06 0.00055904 2.04818e-07 0.000559042 2.14398e-07 0.000559045 2.24464e-07 0.000559049 2.35038e-07 0.000559052 2.46145e-07 0.000559056 2.57809e-07 0.00055906 2.70052e-07 0.000559064 2.829e-07 0.000559069 2.96377e-07 0.000559074 3.10507e-07 0.000559079 3.25315e-07 0.000559085 3.40825e-07 0.000559091 3.5706e-07 0.000559097 3.74044e-07 0.000559104 3.91799e-07 0.000559112 4.10347e-07 0.000559119 4.29709e-07 0.000559127 4.49905e-07 0.000559136 4.70953e-07 0.000559145 4.9287e-07 0.000559155 5.15674e-07 0.000559165 5.3938e-07 0.000559175 5.64001e-07 0.000559186 5.89552e-07 0.000559197 6.16042e-07 0.000559209 6.43484e-07 0.000559222 6.71887e-07 0.000559234 7.01259e-07 0.000559247 7.31609e-07 0.000559261 7.62945e-07 0.000559275 7.95273e-07 0.000559289 8.28601e-07 0.000559304 8.62935e-07 0.000559319 8.98283e-07 0.000559334 9.34651e-07 0.00055935 9.72046e-07 0.000559366 1.01048e-06 0.000559382 1.04995e-06 0.000559398 1.09048e-06 0.000559415 1.13207e-06 0.000559432 1.17473e-06 0.000559449 1.21847e-06 0.000559467 1.26332e-06 0.000559484 1.30927e-06 0.000559502 1.35634e-06 0.00055952 1.40455e-06 0.000559538 1.45391e-06 0.000559557 1.50443e-06 0.000559575 1.55616e-06 0.000559594 1.60907e-06 0.000559612 1.66322e-06 0.000559631 1.71859e-06 0.00055965 1.77526e-06 0.000559669 1.83315e-06 0.000559688 1.89245e-06 0.000559707 1.95291e-06 0.000559726 2.01498e-06 0.000559745 2.07806e-06 0.000559765 2.14306e-06 0.000559784 2.20874e-06 0.000559803 2.27693e-06 0.000559822 2.34515e-06 0.000559842 2.41687e-06 0.000559861 2.48744e-06 0.00055988 2.56324e-06 0.000559899 2.63581e-06 0.000559918 2.71648e-06 0.000559937 2.79046e-06 0.000559956 2.87713e-06 0.000559974 2.95169e-06 0.000559993 3.0459e-06 0.00056001 3.12002e-06 0.000560029 3.22363e-06 0.000560046 3.2965e-06 0.000560064 3.41114e-06 0.00056008 3.48333e-06 0.000560098 3.60882e-06 0.000560113 3.68493e-06 0.00056013 3.81554e-06 3.90953e-06 0.00057455 2.02247e-07 0.000574553 2.11621e-07 0.000574556 2.21467e-07 0.000574559 2.31808e-07 0.000574563 2.42666e-07 0.000574566 2.54066e-07 0.000574571 2.6603e-07 0.000574575 2.78583e-07 0.000574579 2.9175e-07 0.000574584 3.05554e-07 0.00057459 3.20021e-07 0.000574595 3.35174e-07 0.000574601 3.51038e-07 0.000574608 3.67637e-07 0.000574615 3.84994e-07 0.000574622 4.03131e-07 0.000574629 4.22071e-07 0.000574638 4.41835e-07 0.000574646 4.62442e-07 0.000574655 4.83912e-07 0.000574664 5.06263e-07 0.000574674 5.29512e-07 0.000574685 5.53676e-07 0.000574695 5.78768e-07 0.000574707 6.04803e-07 0.000574718 6.31792e-07 0.00057473 6.59748e-07 0.000574743 6.8868e-07 0.000574756 7.18599e-07 0.000574769 7.49513e-07 0.000574783 7.81432e-07 0.000574798 8.14362e-07 0.000574812 8.48312e-07 0.000574827 8.8329e-07 0.000574843 9.19303e-07 0.000574858 9.56359e-07 0.000574874 9.94466e-07 0.000574891 1.03363e-06 0.000574907 1.07387e-06 0.000574924 1.11518e-06 0.000574941 1.15758e-06 0.000574959 1.20108e-06 0.000574976 1.24569e-06 0.000574994 1.29142e-06 0.000575012 1.33828e-06 0.00057503 1.3863e-06 0.000575049 1.43548e-06 0.000575067 1.48584e-06 0.000575086 1.5374e-06 0.000575105 1.59017e-06 0.000575124 1.64419e-06 0.000575143 1.69943e-06 0.000575162 1.75598e-06 0.000575182 1.81377e-06 0.000575201 1.87296e-06 0.000575221 1.93336e-06 0.000575241 1.99532e-06 0.00057526 2.05836e-06 0.00057528 2.12325e-06 0.0005753 2.18895e-06 0.00057532 2.257e-06 0.00057534 2.32532e-06 0.00057536 2.39686e-06 0.000575379 2.46765e-06 0.000575399 2.54318e-06 0.000575419 2.61614e-06 0.000575439 2.69638e-06 0.000575459 2.77101e-06 0.000575479 2.85703e-06 0.000575498 2.9326e-06 0.000575518 3.02581e-06 0.000575537 3.10143e-06 0.000575557 3.20354e-06 0.000575575 3.27858e-06 0.000575595 3.39104e-06 0.000575612 3.46617e-06 0.000575632 3.58876e-06 0.000575648 3.6684e-06 0.000575668 3.79596e-06 3.89282e-06 0.000590491 1.9963e-07 0.000590493 2.08804e-07 0.000590497 2.18437e-07 0.0005905 2.28551e-07 0.000590503 2.39168e-07 0.000590507 2.50313e-07 0.000590511 2.62007e-07 0.000590515 2.74275e-07 0.00059052 2.87141e-07 0.000590525 3.0063e-07 0.00059053 3.14765e-07 0.000590536 3.29573e-07 0.000590542 3.45076e-07 0.000590548 3.613e-07 0.000590555 3.78268e-07 0.000590562 3.96003e-07 0.000590569 4.1453e-07 0.000590577 4.33869e-07 0.000590586 4.54042e-07 0.000590595 4.7507e-07 0.000590604 4.96973e-07 0.000590614 5.19768e-07 0.000590624 5.43474e-07 0.000590635 5.68108e-07 0.000590646 5.93683e-07 0.000590657 6.20215e-07 0.000590669 6.47717e-07 0.000590682 6.76201e-07 0.000590695 7.05679e-07 0.000590708 7.3616e-07 0.000590722 7.67655e-07 0.000590736 8.00173e-07 0.000590751 8.33723e-07 0.000590766 8.68313e-07 0.000590781 9.03952e-07 0.000590797 9.40648e-07 0.000590813 9.78411e-07 0.000590829 1.01725e-06 0.000590846 1.05717e-06 0.000590863 1.09818e-06 0.00059088 1.1403e-06 0.000590898 1.18353e-06 0.000590915 1.22788e-06 0.000590933 1.27337e-06 0.000590952 1.32001e-06 0.00059097 1.36781e-06 0.000590989 1.41679e-06 0.000591008 1.46697e-06 0.000591027 1.51835e-06 0.000591046 1.57095e-06 0.000591065 1.62481e-06 0.000591085 1.67991e-06 0.000591105 1.73632e-06 0.000591124 1.79399e-06 0.000591144 1.85305e-06 0.000591164 1.91335e-06 0.000591184 1.97518e-06 0.000591205 2.03817e-06 0.000591225 2.10292e-06 0.000591245 2.16862e-06 0.000591266 2.23651e-06 0.000591286 2.30489e-06 0.000591307 2.37623e-06 0.000591327 2.44717e-06 0.000591348 2.52242e-06 0.000591369 2.59569e-06 0.000591389 2.67551e-06 0.00059141 2.75069e-06 0.000591431 2.83605e-06 0.000591451 2.9125e-06 0.000591472 3.00472e-06 0.000591492 3.08171e-06 0.000591513 3.18231e-06 0.000591532 3.25935e-06 0.000591553 3.36965e-06 0.000591572 3.44751e-06 0.000591594 3.56725e-06 0.000591612 3.65013e-06 0.000591633 3.7747e-06 3.87408e-06 0.000606873 1.96968e-07 0.000606876 2.05947e-07 0.000606879 2.15373e-07 0.000606882 2.25267e-07 0.000606885 2.35651e-07 0.000606889 2.46547e-07 0.000606893 2.57979e-07 0.000606898 2.69971e-07 0.000606902 2.82546e-07 0.000606907 2.95728e-07 0.000606912 3.09542e-07 0.000606918 3.24013e-07 0.000606924 3.39165e-07 0.00060693 3.55024e-07 0.000606937 3.71612e-07 0.000606944 3.88956e-07 0.000606951 4.07077e-07 0.000606959 4.26e-07 0.000606967 4.45746e-07 0.000606976 4.66338e-07 0.000606985 4.87796e-07 0.000606995 5.1014e-07 0.000607005 5.33391e-07 0.000607016 5.57565e-07 0.000607027 5.8268e-07 0.000607038 6.08752e-07 0.00060705 6.35795e-07 0.000607062 6.63823e-07 0.000607075 6.9285e-07 0.000607088 7.22888e-07 0.000607102 7.53947e-07 0.000607116 7.86038e-07 0.000607131 8.19172e-07 0.000607146 8.53358e-07 0.000607161 8.88605e-07 0.000607177 9.24923e-07 0.000607193 9.6232e-07 0.000607209 1.00081e-06 0.000607226 1.04039e-06 0.000607243 1.08108e-06 0.000607261 1.12289e-06 0.000607278 1.16583e-06 0.000607296 1.20991e-06 0.000607315 1.25514e-06 0.000607333 1.30153e-06 0.000607352 1.3491e-06 0.000607371 1.39786e-06 0.00060739 1.44782e-06 0.000607409 1.499e-06 0.000607429 1.55142e-06 0.000607448 1.6051e-06 0.000607468 1.66003e-06 0.000607488 1.71629e-06 0.000607508 1.77381e-06 0.000607529 1.83273e-06 0.000607549 1.89291e-06 0.00060757 1.9546e-06 0.00060759 2.01749e-06 0.000607611 2.08211e-06 0.000607632 2.14775e-06 0.000607653 2.21548e-06 0.000607674 2.28387e-06 0.000607695 2.355e-06 0.000607717 2.42605e-06 0.000607738 2.50101e-06 0.000607759 2.57452e-06 0.000607781 2.65392e-06 0.000607802 2.72955e-06 0.000607824 2.81427e-06 0.000607845 2.89149e-06 0.000607867 2.98272e-06 0.000607887 3.06093e-06 0.00060791 3.16006e-06 0.00060793 3.23892e-06 0.000607953 3.3471e-06 0.000607973 3.42745e-06 0.000607996 3.54441e-06 0.000608015 3.63025e-06 0.000608038 3.75195e-06 3.85348e-06 0.000623709 1.94261e-07 0.000623712 2.03051e-07 0.000623715 2.12275e-07 0.000623718 2.21955e-07 0.000623722 2.32112e-07 0.000623725 2.42768e-07 0.000623729 2.53946e-07 0.000623734 2.65668e-07 0.000623738 2.7796e-07 0.000623743 2.90845e-07 0.000623748 3.04346e-07 0.000623754 3.1849e-07 0.00062376 3.33301e-07 0.000623766 3.48803e-07 0.000623773 3.65021e-07 0.00062378 3.81981e-07 0.000623787 3.99705e-07 0.000623795 4.18219e-07 0.000623803 4.37545e-07 0.000623812 4.57707e-07 0.000623821 4.78725e-07 0.00062383 5.00623e-07 0.00062384 5.2342e-07 0.000623851 5.47136e-07 0.000623861 5.7179e-07 0.000623873 5.97398e-07 0.000623885 6.23979e-07 0.000623897 6.51546e-07 0.00062391 6.80114e-07 0.000623923 7.09698e-07 0.000623936 7.4031e-07 0.00062395 7.71962e-07 0.000623965 8.04666e-07 0.00062398 8.38432e-07 0.000623995 8.7327e-07 0.000624011 9.09191e-07 0.000624027 9.46205e-07 0.000624044 9.84321e-07 0.00062406 1.02355e-06 0.000624078 1.0639e-06 0.000624095 1.10538e-06 0.000624113 1.14801e-06 0.000624131 1.19178e-06 0.000624149 1.23673e-06 0.000624168 1.28285e-06 0.000624187 1.33016e-06 0.000624206 1.37867e-06 0.000624226 1.4284e-06 0.000624245 1.47937e-06 0.000624265 1.53158e-06 0.000624285 1.58506e-06 0.000624305 1.63981e-06 0.000624326 1.69589e-06 0.000624346 1.75325e-06 0.000624367 1.812e-06 0.000624388 1.87204e-06 0.000624409 1.93357e-06 0.00062443 1.99635e-06 0.000624451 2.0608e-06 0.000624473 2.12637e-06 0.000624494 2.19393e-06 0.000624516 2.26229e-06 0.000624538 2.33321e-06 0.000624559 2.40431e-06 0.000624582 2.47898e-06 0.000624603 2.55267e-06 0.000624626 2.63165e-06 0.000624648 2.70765e-06 0.00062467 2.79174e-06 0.000624692 2.86962e-06 0.000624715 2.9599e-06 0.000624737 3.03918e-06 0.00062476 3.13689e-06 0.000624781 3.21737e-06 0.000624805 3.32351e-06 0.000624826 3.40612e-06 0.00062485 3.5204e-06 0.000624872 3.60888e-06 0.000624896 3.72784e-06 3.83116e-06 0.000641011 1.91512e-07 0.000641014 2.00116e-07 0.000641017 2.09144e-07 0.000641021 2.18615e-07 0.000641024 2.28551e-07 0.000641028 2.38973e-07 0.000641032 2.49903e-07 0.000641036 2.61365e-07 0.000641041 2.73381e-07 0.000641046 2.85976e-07 0.000641051 2.99173e-07 0.000641056 3.12999e-07 0.000641062 3.27476e-07 0.000641068 3.42631e-07 0.000641075 3.58488e-07 0.000641082 3.75071e-07 0.000641089 3.92407e-07 0.000641097 4.1052e-07 0.000641105 4.29433e-07 0.000641114 4.4917e-07 0.000641122 4.69755e-07 0.000641132 4.91209e-07 0.000641142 5.13556e-07 0.000641152 5.36816e-07 0.000641163 5.61008e-07 0.000641174 5.86152e-07 0.000641186 6.12266e-07 0.000641198 6.39367e-07 0.000641211 6.67472e-07 0.000641224 6.96594e-07 0.000641237 7.26749e-07 0.000641251 7.5795e-07 0.000641266 7.9021e-07 0.000641281 8.23541e-07 0.000641296 8.57955e-07 0.000641312 8.93462e-07 0.000641328 9.30073e-07 0.000641344 9.67799e-07 0.000641361 1.00665e-06 0.000641379 1.04664e-06 0.000641396 1.08777e-06 0.000641414 1.13006e-06 0.000641432 1.17352e-06 0.000641451 1.21815e-06 0.00064147 1.26398e-06 0.000641489 1.31101e-06 0.000641508 1.35926e-06 0.000641528 1.40874e-06 0.000641548 1.45946e-06 0.000641568 1.51144e-06 0.000641588 1.56471e-06 0.000641609 1.61925e-06 0.00064163 1.67513e-06 0.000641651 1.73231e-06 0.000641672 1.79087e-06 0.000641693 1.85075e-06 0.000641715 1.91211e-06 0.000641736 1.97476e-06 0.000641758 2.03903e-06 0.00064178 2.10449e-06 0.000641802 2.17186e-06 0.000641824 2.24016e-06 0.000641846 2.31086e-06 0.000641869 2.38197e-06 0.000641891 2.45634e-06 0.000641914 2.53016e-06 0.000641937 2.60872e-06 0.000641959 2.68502e-06 0.000641983 2.7685e-06 0.000642005 2.84694e-06 0.000642029 2.93629e-06 0.000642052 3.01652e-06 0.000642076 3.11285e-06 0.000642098 3.19478e-06 0.000642123 3.29896e-06 0.000642145 3.38358e-06 0.00064217 3.49532e-06 0.000642193 3.58611e-06 0.000642218 3.7025e-06 3.80724e-06 0.000658793 1.8872e-07 0.000658796 1.97144e-07 0.000658799 2.0598e-07 0.000658803 2.15247e-07 0.000658806 2.24967e-07 0.00065881 2.35161e-07 0.000658814 2.4585e-07 0.000658818 2.57057e-07 0.000658823 2.68805e-07 0.000658828 2.81118e-07 0.000658833 2.9402e-07 0.000658838 3.07534e-07 0.000658844 3.21687e-07 0.00065885 3.36502e-07 0.000658857 3.52005e-07 0.000658864 3.68222e-07 0.000658871 3.85177e-07 0.000658879 4.02896e-07 0.000658887 4.21402e-07 0.000658895 4.40722e-07 0.000658904 4.60878e-07 0.000658913 4.81894e-07 0.000658923 5.03794e-07 0.000658933 5.26599e-07 0.000658944 5.50331e-07 0.000658955 5.7501e-07 0.000658967 6.00656e-07 0.000658979 6.27287e-07 0.000658991 6.54921e-07 0.000659004 6.83575e-07 0.000659018 7.13265e-07 0.000659032 7.44004e-07 0.000659046 7.75809e-07 0.000659061 8.08692e-07 0.000659076 8.42665e-07 0.000659092 8.77742e-07 0.000659108 9.13934e-07 0.000659125 9.51251e-07 0.000659142 9.89706e-07 0.000659159 1.02931e-06 0.000659177 1.07007e-06 0.000659195 1.112e-06 0.000659213 1.15512e-06 0.000659232 1.19943e-06 0.000659251 1.24494e-06 0.00065927 1.29167e-06 0.00065929 1.33963e-06 0.00065931 1.38883e-06 0.00065933 1.43929e-06 0.00065935 1.49102e-06 0.000659371 1.54404e-06 0.000659392 1.59837e-06 0.000659413 1.65402e-06 0.000659434 1.71099e-06 0.000659456 1.76935e-06 0.000659478 1.82905e-06 0.000659499 1.89022e-06 0.000659521 1.9527e-06 0.000659544 2.01679e-06 0.000659566 2.08212e-06 0.000659589 2.14928e-06 0.000659611 2.2175e-06 0.000659634 2.28796e-06 0.000659657 2.35905e-06 0.00065968 2.43313e-06 0.000659703 2.50702e-06 0.000659727 2.58517e-06 0.00065975 2.6617e-06 0.000659774 2.74458e-06 0.000659798 2.82348e-06 0.000659822 2.91195e-06 0.000659846 2.99298e-06 0.00065987 3.088e-06 0.000659894 3.1712e-06 0.000659919 3.27352e-06 0.000659943 3.3599e-06 0.000659969 3.46926e-06 0.000659993 3.56204e-06 0.00066002 3.67603e-06 3.78186e-06 0.000677068 1.85888e-07 0.000677071 1.94134e-07 0.000677074 2.02782e-07 0.000677077 2.11851e-07 0.000677081 2.2136e-07 0.000677085 2.31331e-07 0.000677089 2.41785e-07 0.000677093 2.52744e-07 0.000677098 2.64231e-07 0.000677103 2.76268e-07 0.000677108 2.88881e-07 0.000677113 3.02092e-07 0.000677119 3.15928e-07 0.000677125 3.30412e-07 0.000677131 3.45569e-07 0.000677138 3.61427e-07 0.000677145 3.78008e-07 0.000677153 3.9534e-07 0.000677161 4.13448e-07 0.000677169 4.32355e-07 0.000677178 4.52088e-07 0.000677187 4.72671e-07 0.000677197 4.94127e-07 0.000677207 5.16481e-07 0.000677218 5.39754e-07 0.000677229 5.63968e-07 0.00067724 5.89145e-07 0.000677252 6.15303e-07 0.000677265 6.42463e-07 0.000677278 6.70642e-07 0.000677291 6.99859e-07 0.000677305 7.30128e-07 0.000677319 7.61466e-07 0.000677334 7.93889e-07 0.000677349 8.27408e-07 0.000677365 8.62039e-07 0.000677381 8.97794e-07 0.000677398 9.34686e-07 0.000677415 9.72726e-07 0.000677432 1.01193e-06 0.00067745 1.0523e-06 0.000677468 1.09385e-06 0.000677486 1.1366e-06 0.000677505 1.18056e-06 0.000677525 1.22573e-06 0.000677544 1.27213e-06 0.000677564 1.31978e-06 0.000677584 1.36869e-06 0.000677604 1.41886e-06 0.000677625 1.47032e-06 0.000677646 1.52308e-06 0.000677667 1.57715e-06 0.000677689 1.63257e-06 0.00067771 1.68931e-06 0.000677732 1.74745e-06 0.000677754 1.80695e-06 0.000677777 1.8679e-06 0.000677799 1.9302e-06 0.000677822 1.99408e-06 0.000677845 2.05926e-06 0.000677868 2.12621e-06 0.000677891 2.19431e-06 0.000677915 2.26453e-06 0.000677938 2.33555e-06 0.000677962 2.40933e-06 0.000677986 2.48325e-06 0.00067801 2.561e-06 0.000678034 2.63769e-06 0.000678058 2.72e-06 0.000678083 2.79927e-06 0.000678108 2.88689e-06 0.000678132 2.96861e-06 0.000678158 3.06239e-06 0.000678182 3.14668e-06 0.000678208 3.24725e-06 0.000678233 3.33515e-06 0.00067826 3.44227e-06 0.000678286 3.53674e-06 0.000678313 3.6485e-06 3.7551e-06 0.000695849 1.83016e-07 0.000695852 1.91089e-07 0.000695855 1.99553e-07 0.000695858 2.08427e-07 0.000695862 2.1773e-07 0.000695866 2.27484e-07 0.00069587 2.37708e-07 0.000695874 2.48424e-07 0.000695879 2.59655e-07 0.000695884 2.71424e-07 0.000695889 2.83755e-07 0.000695894 2.9667e-07 0.0006959 3.10195e-07 0.000695906 3.24355e-07 0.000695912 3.39175e-07 0.000695919 3.5468e-07 0.000695926 3.70896e-07 0.000695934 3.87848e-07 0.000695942 4.05563e-07 0.00069595 4.24065e-07 0.000695959 4.4338e-07 0.000695968 4.63534e-07 0.000695977 4.84552e-07 0.000695987 5.06457e-07 0.000695998 5.29273e-07 0.000696009 5.53023e-07 0.00069602 5.77729e-07 0.000696032 6.03413e-07 0.000696044 6.30096e-07 0.000696057 6.57796e-07 0.000696071 6.86532e-07 0.000696084 7.16323e-07 0.000696099 7.47186e-07 0.000696113 7.79136e-07 0.000696129 8.12189e-07 0.000696144 8.4636e-07 0.000696161 8.81663e-07 0.000696177 9.18111e-07 0.000696194 9.55718e-07 0.000696212 9.94495e-07 0.000696229 1.03446e-06 0.000696248 1.07561e-06 0.000696266 1.11797e-06 0.000696285 1.16156e-06 0.000696305 1.20637e-06 0.000696324 1.25243e-06 0.000696344 1.29974e-06 0.000696365 1.34832e-06 0.000696385 1.39819e-06 0.000696406 1.44935e-06 0.000696428 1.50183e-06 0.000696449 1.55563e-06 0.000696471 1.61078e-06 0.000696493 1.66728e-06 0.000696515 1.72517e-06 0.000696538 1.78444e-06 0.00069656 1.84516e-06 0.000696583 1.90726e-06 0.000696607 1.97092e-06 0.00069663 2.03592e-06 0.000696654 2.10264e-06 0.000696677 2.17059e-06 0.000696701 2.24056e-06 0.000696725 2.31149e-06 0.00069675 2.38497e-06 0.000696774 2.45886e-06 0.000696799 2.53622e-06 0.000696823 2.613e-06 0.000696849 2.69476e-06 0.000696874 2.77432e-06 0.000696899 2.86114e-06 0.000696925 2.94341e-06 0.000696951 3.03603e-06 0.000696976 3.12124e-06 0.000697003 3.22018e-06 0.000697029 3.30936e-06 0.000697057 3.41442e-06 0.000697084 3.51025e-06 0.000697112 3.61997e-06 3.72704e-06 0.00071515 1.80105e-07 0.000715153 1.88008e-07 0.000715156 1.96292e-07 0.00071516 2.04975e-07 0.000715163 2.14077e-07 0.000715167 2.23617e-07 0.000715171 2.33616e-07 0.000715176 2.44096e-07 0.00071518 2.55077e-07 0.000715185 2.66584e-07 0.00071519 2.78638e-07 0.000715196 2.91264e-07 0.000715201 3.04486e-07 0.000715207 3.18329e-07 0.000715214 3.32818e-07 0.000715221 3.47977e-07 0.000715228 3.63834e-07 0.000715235 3.80414e-07 0.000715243 3.97742e-07 0.000715251 4.15845e-07 0.00071526 4.34749e-07 0.000715269 4.54479e-07 0.000715278 4.75062e-07 0.000715288 4.96522e-07 0.000715299 5.18883e-07 0.000715309 5.42171e-07 0.000715321 5.66408e-07 0.000715333 5.91616e-07 0.000715345 6.17818e-07 0.000715358 6.45035e-07 0.000715371 6.73286e-07 0.000715385 7.02591e-07 0.000715399 7.32969e-07 0.000715413 7.64438e-07 0.000715429 7.97013e-07 0.000715444 8.30711e-07 0.00071546 8.65547e-07 0.000715477 9.01536e-07 0.000715494 9.38692e-07 0.000715511 9.77028e-07 0.000715529 1.01656e-06 0.000715548 1.05729e-06 0.000715566 1.09925e-06 0.000715586 1.14243e-06 0.000715605 1.18687e-06 0.000715625 1.23255e-06 0.000715645 1.27951e-06 0.000715666 1.32775e-06 0.000715687 1.37728e-06 0.000715708 1.42812e-06 0.000715729 1.48029e-06 0.000715751 1.5338e-06 0.000715773 1.58866e-06 0.000715796 1.64489e-06 0.000715818 1.70252e-06 0.000715841 1.76154e-06 0.000715864 1.82201e-06 0.000715888 1.88388e-06 0.000715911 1.9473e-06 0.000715935 2.01209e-06 0.000715959 2.07857e-06 0.000715984 2.14634e-06 0.000716008 2.21606e-06 0.000716033 2.28685e-06 0.000716058 2.36003e-06 0.000716083 2.43385e-06 0.000716108 2.51083e-06 0.000716133 2.58765e-06 0.000716159 2.66888e-06 0.000716185 2.74865e-06 0.000716211 2.83471e-06 0.000716237 2.91742e-06 0.000716264 3.00894e-06 0.000716291 3.0949e-06 0.000716319 3.19233e-06 0.000716345 3.28257e-06 0.000716374 3.38574e-06 0.000716402 3.48263e-06 0.000716431 3.59049e-06 3.69775e-06 0.000734986 1.77159e-07 0.000734989 1.84894e-07 0.000734993 1.93001e-07 0.000734996 2.01497e-07 0.000735 2.10401e-07 0.000735004 2.19732e-07 0.000735008 2.29511e-07 0.000735012 2.39759e-07 0.000735017 2.50496e-07 0.000735022 2.61745e-07 0.000735027 2.7353e-07 0.000735032 2.85872e-07 0.000735038 2.98798e-07 0.000735044 3.1233e-07 0.00073505 3.26494e-07 0.000735057 3.41315e-07 0.000735064 3.56819e-07 0.000735071 3.73033e-07 0.000735079 3.89981e-07 0.000735087 4.07691e-07 0.000735096 4.26189e-07 0.000735105 4.45501e-07 0.000735114 4.65653e-07 0.000735124 4.86672e-07 0.000735134 5.08582e-07 0.000735145 5.31409e-07 0.000735156 5.55176e-07 0.000735168 5.79909e-07 0.00073518 6.05629e-07 0.000735193 6.32359e-07 0.000735206 6.6012e-07 0.00073522 6.88934e-07 0.000735234 7.1882e-07 0.000735248 7.49797e-07 0.000735263 7.81883e-07 0.000735279 8.15096e-07 0.000735295 8.49452e-07 0.000735312 8.84967e-07 0.000735329 9.21656e-07 0.000735346 9.59533e-07 0.000735364 9.98613e-07 0.000735383 1.03891e-06 0.000735401 1.08044e-06 0.000735421 1.12321e-06 0.00073544 1.16723e-06 0.00073546 1.21252e-06 0.000735481 1.2591e-06 0.000735501 1.30697e-06 0.000735523 1.35615e-06 0.000735544 1.40665e-06 0.000735566 1.45849e-06 0.000735588 1.51168e-06 0.00073561 1.56623e-06 0.000735633 1.62216e-06 0.000735656 1.67951e-06 0.000735679 1.73825e-06 0.000735703 1.79845e-06 0.000735727 1.86007e-06 0.000735751 1.92323e-06 0.000735775 1.98779e-06 0.0007358 2.05401e-06 0.000735825 2.12158e-06 0.00073585 2.19102e-06 0.000735875 2.26165e-06 0.0007359 2.33452e-06 0.000735926 2.40824e-06 0.000735952 2.48484e-06 0.000735978 2.56164e-06 0.000736004 2.64236e-06 0.000736031 2.72225e-06 0.000736058 2.80759e-06 0.000736085 2.89064e-06 0.000736113 2.98114e-06 0.00073614 3.06769e-06 0.000736168 3.16372e-06 0.000736196 3.25479e-06 0.000736226 3.35623e-06 0.000736254 3.45392e-06 0.000736285 3.56007e-06 3.66729e-06 0.000755372 1.74177e-07 0.000755375 1.81748e-07 0.000755379 1.89681e-07 0.000755382 1.97993e-07 0.000755386 2.06702e-07 0.00075539 2.15829e-07 0.000755394 2.25392e-07 0.000755398 2.35412e-07 0.000755403 2.45909e-07 0.000755408 2.56907e-07 0.000755413 2.68427e-07 0.000755418 2.80492e-07 0.000755424 2.93126e-07 0.00075543 3.06354e-07 0.000755436 3.202e-07 0.000755443 3.34689e-07 0.00075545 3.49848e-07 0.000755457 3.65701e-07 0.000755465 3.82276e-07 0.000755473 3.99599e-07 0.000755481 4.17696e-07 0.00075549 4.36594e-07 0.000755499 4.56321e-07 0.000755509 4.76902e-07 0.000755519 4.98364e-07 0.00075553 5.20732e-07 0.000755541 5.44032e-07 0.000755553 5.68289e-07 0.000755565 5.93526e-07 0.000755578 6.19767e-07 0.000755591 6.47035e-07 0.000755604 6.75353e-07 0.000755618 7.0474e-07 0.000755633 7.35218e-07 0.000755648 7.66805e-07 0.000755664 7.99522e-07 0.00075568 8.33384e-07 0.000755696 8.68411e-07 0.000755713 9.04617e-07 0.000755731 9.4202e-07 0.000755749 9.80633e-07 0.000755767 1.02047e-06 0.000755786 1.06155e-06 0.000755805 1.10388e-06 0.000755825 1.14748e-06 0.000755845 1.19236e-06 0.000755866 1.23853e-06 0.000755887 1.28601e-06 0.000755908 1.33481e-06 0.00075593 1.38494e-06 0.000755952 1.43642e-06 0.000755974 1.48927e-06 0.000755997 1.54349e-06 0.00075602 1.59911e-06 0.000756044 1.65614e-06 0.000756067 1.71458e-06 0.000756091 1.77449e-06 0.000756115 1.83584e-06 0.00075614 1.89871e-06 0.000756165 1.96302e-06 0.00075619 2.02896e-06 0.000756215 2.09631e-06 0.000756241 2.16546e-06 0.000756266 2.23589e-06 0.000756292 2.30845e-06 0.000756319 2.38202e-06 0.000756345 2.45823e-06 0.000756372 2.53496e-06 0.000756399 2.61519e-06 0.000756426 2.69513e-06 0.000756454 2.77979e-06 0.000756482 2.86306e-06 0.00075651 2.95261e-06 0.000756538 3.03961e-06 0.000756568 3.13436e-06 0.000756596 3.22604e-06 0.000756627 3.3259e-06 0.000756656 3.42413e-06 0.000756688 3.52873e-06 3.6357e-06 0.000776323 1.71163e-07 0.000776326 1.78571e-07 0.000776329 1.86332e-07 0.000776333 1.94463e-07 0.000776337 2.02982e-07 0.000776341 2.11908e-07 0.000776345 2.21258e-07 0.000776349 2.31055e-07 0.000776354 2.41318e-07 0.000776359 2.52069e-07 0.000776364 2.63329e-07 0.000776369 2.75122e-07 0.000776375 2.87471e-07 0.000776381 3.004e-07 0.000776387 3.13934e-07 0.000776393 3.28097e-07 0.0007764 3.42915e-07 0.000776408 3.58415e-07 0.000776415 3.74622e-07 0.000776423 3.91563e-07 0.000776432 4.09265e-07 0.000776441 4.27756e-07 0.00077645 4.47061e-07 0.00077646 4.67209e-07 0.00077647 4.88226e-07 0.00077648 5.10139e-07 0.000776491 5.32973e-07 0.000776503 5.56754e-07 0.000776515 5.81508e-07 0.000776527 6.07259e-07 0.00077654 6.34031e-07 0.000776554 6.61847e-07 0.000776568 6.9073e-07 0.000776582 7.20701e-07 0.000776597 7.51782e-07 0.000776613 7.83992e-07 0.000776629 8.1735e-07 0.000776646 8.51875e-07 0.000776663 8.87585e-07 0.00077668 9.24496e-07 0.000776698 9.62624e-07 0.000776717 1.00199e-06 0.000776736 1.0426e-06 0.000776755 1.08447e-06 0.000776775 1.12762e-06 0.000776795 1.17206e-06 0.000776816 1.2178e-06 0.000776837 1.26487e-06 0.000776859 1.31327e-06 0.000776881 1.36301e-06 0.000776903 1.41411e-06 0.000776926 1.46659e-06 0.000776949 1.52046e-06 0.000776972 1.57573e-06 0.000776996 1.63242e-06 0.00077702 1.69055e-06 0.000777044 1.75014e-06 0.000777069 1.81118e-06 0.000777094 1.87375e-06 0.000777119 1.93778e-06 0.000777144 2.00343e-06 0.00077717 2.07052e-06 0.000777196 2.13937e-06 0.000777223 2.20957e-06 0.000777249 2.2818e-06 0.000777276 2.35518e-06 0.000777303 2.43101e-06 0.000777331 2.50763e-06 0.000777358 2.58737e-06 0.000777386 2.66729e-06 0.000777415 2.7513e-06 0.000777443 2.8347e-06 0.000777472 2.92337e-06 0.000777501 3.01065e-06 0.000777531 3.10423e-06 0.000777561 3.19632e-06 0.000777592 3.29477e-06 0.000777623 3.39328e-06 0.000777655 3.49647e-06 3.603e-06 0.000797854 1.68117e-07 0.000797857 1.75365e-07 0.000797861 1.82957e-07 0.000797864 1.9091e-07 0.000797868 1.99242e-07 0.000797872 2.07969e-07 0.000797876 2.17111e-07 0.000797881 2.26689e-07 0.000797885 2.36721e-07 0.00079789 2.47229e-07 0.000797895 2.58235e-07 0.0007979 2.69761e-07 0.000797906 2.8183e-07 0.000797912 2.94465e-07 0.000797918 3.07692e-07 0.000797925 3.21535e-07 0.000797932 3.3602e-07 0.000797939 3.51171e-07 0.000797947 3.67016e-07 0.000797955 3.83582e-07 0.000797963 4.00894e-07 0.000797972 4.18982e-07 0.000797981 4.37871e-07 0.000797991 4.5759e-07 0.000798001 4.78165e-07 0.000798011 4.99625e-07 0.000798022 5.21995e-07 0.000798034 5.45302e-07 0.000798045 5.69573e-07 0.000798058 5.94832e-07 0.000798071 6.21106e-07 0.000798084 6.48418e-07 0.000798098 6.76791e-07 0.000798113 7.0625e-07 0.000798128 7.36816e-07 0.000798143 7.6851e-07 0.000798159 8.01353e-07 0.000798176 8.35365e-07 0.000798193 8.70564e-07 0.00079821 9.06969e-07 0.000798228 9.44597e-07 0.000798247 9.83464e-07 0.000798266 1.02359e-06 0.000798285 1.06498e-06 0.000798305 1.10766e-06 0.000798326 1.15164e-06 0.000798346 1.19694e-06 0.000798368 1.24357e-06 0.000798389 1.29154e-06 0.000798412 1.34086e-06 0.000798434 1.39156e-06 0.000798457 1.44365e-06 0.00079848 1.49714e-06 0.000798504 1.55204e-06 0.000798528 1.60837e-06 0.000798553 1.66615e-06 0.000798577 1.7254e-06 0.000798602 1.78612e-06 0.000798628 1.84836e-06 0.000798653 1.91209e-06 0.000798679 1.97741e-06 0.000798706 2.04422e-06 0.000798732 2.11275e-06 0.000798759 2.18269e-06 0.000798786 2.25458e-06 0.000798814 2.32774e-06 0.000798842 2.40318e-06 0.00079887 2.47963e-06 0.000798898 2.55889e-06 0.000798927 2.63873e-06 0.000798956 2.72212e-06 0.000798985 2.80555e-06 0.000799015 2.89339e-06 0.000799045 2.98084e-06 0.000799076 3.07333e-06 0.000799106 3.16566e-06 0.000799138 3.26281e-06 0.00079917 3.3614e-06 0.000799203 3.46329e-06 3.56922e-06 0.000819982 1.65041e-07 0.000819986 1.72132e-07 0.000819989 1.79558e-07 0.000819992 1.87335e-07 0.000819996 1.95481e-07 0.00082 2.04014e-07 0.000820004 2.12951e-07 0.000820009 2.22313e-07 0.000820013 2.32118e-07 0.000820018 2.42388e-07 0.000820023 2.53144e-07 0.000820029 2.64407e-07 0.000820034 2.76201e-07 0.00082004 2.88548e-07 0.000820046 3.01474e-07 0.000820053 3.15002e-07 0.00082006 3.29158e-07 0.000820067 3.43967e-07 0.000820075 3.59456e-07 0.000820082 3.75651e-07 0.000820091 3.92579e-07 0.0008201 4.10268e-07 0.000820109 4.28746e-07 0.000820118 4.4804e-07 0.000820128 4.68178e-07 0.000820139 4.89188e-07 0.00082015 5.11096e-07 0.000820161 5.33931e-07 0.000820173 5.57719e-07 0.000820185 5.82487e-07 0.000820198 6.0826e-07 0.000820211 6.35065e-07 0.000820225 6.62926e-07 0.00082024 6.91866e-07 0.000820254 7.21911e-07 0.00082027 7.53081e-07 0.000820286 7.85399e-07 0.000820302 8.18886e-07 0.000820319 8.53563e-07 0.000820337 8.89447e-07 0.000820355 9.26559e-07 0.000820373 9.64915e-07 0.000820392 1.00453e-06 0.000820412 1.04543e-06 0.000820432 1.08762e-06 0.000820453 1.13112e-06 0.000820474 1.17595e-06 0.000820495 1.22211e-06 0.000820517 1.26963e-06 0.000820539 1.31852e-06 0.000820562 1.36879e-06 0.000820585 1.42046e-06 0.000820609 1.47354e-06 0.000820633 1.52805e-06 0.000820657 1.584e-06 0.000820682 1.6414e-06 0.000820707 1.70029e-06 0.000820733 1.76065e-06 0.000820758 1.82254e-06 0.000820784 1.88594e-06 0.000820811 1.95092e-06 0.000820838 2.01741e-06 0.000820865 2.0856e-06 0.000820892 2.15526e-06 0.00082092 2.22679e-06 0.000820948 2.29969e-06 0.000820977 2.37474e-06 0.000821005 2.45097e-06 0.000821034 2.52976e-06 0.000821064 2.60945e-06 0.000821094 2.69225e-06 0.000821124 2.77561e-06 0.000821154 2.86267e-06 0.000821185 2.95016e-06 0.000821217 3.04165e-06 0.000821248 3.13405e-06 0.000821281 3.23001e-06 0.000821314 3.32849e-06 0.000821348 3.42917e-06 3.53438e-06 0.000842724 1.61939e-07 0.000842727 1.68873e-07 0.00084273 1.76135e-07 0.000842734 1.83739e-07 0.000842738 1.91703e-07 0.000842742 2.00044e-07 0.000842746 2.08779e-07 0.00084275 2.17928e-07 0.000842755 2.27511e-07 0.00084276 2.37546e-07 0.000842765 2.48055e-07 0.00084277 2.59061e-07 0.000842776 2.70584e-07 0.000842782 2.82648e-07 0.000842788 2.95277e-07 0.000842794 3.08496e-07 0.000842801 3.22328e-07 0.000842808 3.368e-07 0.000842816 3.51938e-07 0.000842824 3.67767e-07 0.000842832 3.84316e-07 0.000842841 4.01612e-07 0.00084285 4.19683e-07 0.000842859 4.38557e-07 0.000842869 4.58261e-07 0.000842879 4.78824e-07 0.00084289 5.00274e-07 0.000842901 5.22638e-07 0.000842913 5.45945e-07 0.000842926 5.70221e-07 0.000842938 5.95494e-07 0.000842952 6.21789e-07 0.000842965 6.49133e-07 0.00084298 6.77551e-07 0.000842995 7.07068e-07 0.00084301 7.37707e-07 0.000843026 7.69492e-07 0.000843042 8.02444e-07 0.000843059 8.36586e-07 0.000843077 8.71937e-07 0.000843095 9.08518e-07 0.000843113 9.46347e-07 0.000843132 9.85443e-07 0.000843152 1.02582e-06 0.000843172 1.06751e-06 0.000843193 1.11051e-06 0.000843214 1.15484e-06 0.000843235 1.20052e-06 0.000843258 1.24757e-06 0.00084328 1.29599e-06 0.000843303 1.34581e-06 0.000843326 1.39703e-06 0.00084335 1.44968e-06 0.000843375 1.50377e-06 0.000843399 1.55931e-06 0.000843424 1.61631e-06 0.00084345 1.67481e-06 0.000843476 1.73479e-06 0.000843502 1.79631e-06 0.000843529 1.85934e-06 0.000843556 1.92397e-06 0.000843583 1.99011e-06 0.00084361 2.05794e-06 0.000843638 2.12728e-06 0.000843667 2.19843e-06 0.000843695 2.27104e-06 0.000843725 2.34568e-06 0.000843754 2.42166e-06 0.000843784 2.49997e-06 0.000843814 2.57945e-06 0.000843844 2.66166e-06 0.000843875 2.74489e-06 0.000843906 2.83121e-06 0.000843938 2.91861e-06 0.00084397 3.00917e-06 0.000844003 3.10149e-06 0.000844037 3.19636e-06 0.000844071 3.29456e-06 0.000844106 3.39411e-06 3.49848e-06 0.000866095 1.58811e-07 0.000866098 1.65591e-07 0.000866102 1.7269e-07 0.000866105 1.80124e-07 0.000866109 1.87908e-07 0.000866113 1.96059e-07 0.000866117 2.04596e-07 0.000866122 2.13536e-07 0.000866126 2.22898e-07 0.000866131 2.32703e-07 0.000866136 2.4297e-07 0.000866142 2.53721e-07 0.000866147 2.64978e-07 0.000866153 2.76764e-07 0.000866159 2.89101e-07 0.000866166 3.02014e-07 0.000866173 3.15528e-07 0.00086618 3.29668e-07 0.000866187 3.4446e-07 0.000866195 3.59929e-07 0.000866203 3.76104e-07 0.000866212 3.93012e-07 0.000866221 4.1068e-07 0.00086623 4.29138e-07 0.00086624 4.48412e-07 0.00086625 4.68532e-07 0.000866261 4.89526e-07 0.000866272 5.11422e-07 0.000866284 5.34249e-07 0.000866296 5.58034e-07 0.000866309 5.82805e-07 0.000866322 6.0859e-07 0.000866336 6.35415e-07 0.00086635 6.63307e-07 0.000866365 6.92291e-07 0.00086638 7.22392e-07 0.000866396 7.53636e-07 0.000866412 7.86044e-07 0.000866429 8.1964e-07 0.000866447 8.54446e-07 0.000866465 8.90482e-07 0.000866483 9.27769e-07 0.000866503 9.66327e-07 0.000866522 1.00617e-06 0.000866542 1.04733e-06 0.000866563 1.0898e-06 0.000866584 1.13362e-06 0.000866606 1.1788e-06 0.000866628 1.22535e-06 0.000866651 1.27328e-06 0.000866674 1.32263e-06 0.000866698 1.37338e-06 0.000866722 1.42557e-06 0.000866746 1.47921e-06 0.000866771 1.53432e-06 0.000866797 1.59089e-06 0.000866823 1.64897e-06 0.000866849 1.70855e-06 0.000866876 1.76967e-06 0.000866903 1.83231e-06 0.00086693 1.89655e-06 0.000866958 1.96232e-06 0.000866986 2.02977e-06 0.000867015 2.09875e-06 0.000867043 2.16951e-06 0.000867073 2.24179e-06 0.000867102 2.31601e-06 0.000867132 2.39168e-06 0.000867163 2.46951e-06 0.000867194 2.54873e-06 0.000867225 2.63037e-06 0.000867256 2.71338e-06 0.000867289 2.79899e-06 0.000867321 2.8862e-06 0.000867354 2.9759e-06 0.000867388 3.06799e-06 0.000867422 3.16185e-06 0.000867457 3.25962e-06 0.000867493 3.3581e-06 3.46153e-06 0.000890114 1.5566e-07 0.000890118 1.62288e-07 0.000890121 1.69226e-07 0.000890125 1.76491e-07 0.000890128 1.84097e-07 0.000890132 1.92062e-07 0.000890137 2.00402e-07 0.000890141 2.09136e-07 0.000890146 2.18282e-07 0.000890151 2.27859e-07 0.000890156 2.37888e-07 0.000890161 2.48389e-07 0.000890167 2.59383e-07 0.000890172 2.70894e-07 0.000890179 2.82945e-07 0.000890185 2.95557e-07 0.000890192 3.08758e-07 0.000890199 3.2257e-07 0.000890206 3.3702e-07 0.000890214 3.52135e-07 0.000890222 3.6794e-07 0.000890231 3.84464e-07 0.00089024 4.01735e-07 0.000890249 4.1978e-07 0.000890259 4.38629e-07 0.000890269 4.58309e-07 0.00089028 4.7885e-07 0.000890291 5.0028e-07 0.000890303 5.22628e-07 0.000890315 5.45923e-07 0.000890327 5.70193e-07 0.00089034 5.95466e-07 0.000890354 6.21771e-07 0.000890368 6.49133e-07 0.000890383 6.7758e-07 0.000890398 7.07139e-07 0.000890414 7.37833e-07 0.00089043 7.69689e-07 0.000890447 8.0273e-07 0.000890465 8.36979e-07 0.000890483 8.72458e-07 0.000890501 9.09189e-07 0.00089052 9.47192e-07 0.00089054 9.86488e-07 0.00089056 1.0271e-06 0.000890581 1.06903e-06 0.000890602 1.11232e-06 0.000890624 1.15696e-06 0.000890647 1.20299e-06 0.00089067 1.25042e-06 0.000890693 1.29926e-06 0.000890717 1.34952e-06 0.000890741 1.40123e-06 0.000890766 1.45439e-06 0.000890791 1.50903e-06 0.000890817 1.56516e-06 0.000890843 1.62279e-06 0.00089087 1.68194e-06 0.000890897 1.74262e-06 0.000890924 1.80485e-06 0.000890952 1.86867e-06 0.00089098 1.93405e-06 0.000891009 2.00108e-06 0.000891038 2.06969e-06 0.000891068 2.14003e-06 0.000891097 2.21194e-06 0.000891128 2.28572e-06 0.000891158 2.36105e-06 0.000891189 2.4384e-06 0.000891221 2.51729e-06 0.000891253 2.59837e-06 0.000891285 2.68108e-06 0.000891318 2.76601e-06 0.000891351 2.85294e-06 0.000891386 2.9418e-06 0.00089142 3.03355e-06 0.000891455 3.12646e-06 0.000891491 3.22367e-06 0.000891528 3.32112e-06 3.42353e-06 0.000914799 1.52489e-07 0.000914802 1.58965e-07 0.000914806 1.65745e-07 0.00091481 1.72843e-07 0.000914813 1.80274e-07 0.000914817 1.88054e-07 0.000914822 1.96201e-07 0.000914826 2.04731e-07 0.000914831 2.13663e-07 0.000914836 2.23016e-07 0.000914841 2.32809e-07 0.000914846 2.43063e-07 0.000914852 2.538e-07 0.000914857 2.6504e-07 0.000914863 2.76807e-07 0.00091487 2.89124e-07 0.000914877 3.02015e-07 0.000914884 3.15505e-07 0.000914891 3.29618e-07 0.000914899 3.44382e-07 0.000914907 3.59823e-07 0.000914916 3.75968e-07 0.000914924 3.92845e-07 0.000914934 4.10483e-07 0.000914943 4.28909e-07 0.000914954 4.48154e-07 0.000914964 4.68245e-07 0.000914975 4.89211e-07 0.000914987 5.11083e-07 0.000914999 5.33889e-07 0.000915011 5.57658e-07 0.000915024 5.82419e-07 0.000915038 6.08201e-07 0.000915052 6.35031e-07 0.000915067 6.62938e-07 0.000915082 6.91948e-07 0.000915098 7.22088e-07 0.000915114 7.53384e-07 0.000915131 7.8586e-07 0.000915148 8.19542e-07 0.000915166 8.54452e-07 0.000915185 8.90614e-07 0.000915204 9.28049e-07 0.000915224 9.66777e-07 0.000915244 1.00682e-06 0.000915265 1.0482e-06 0.000915286 1.09093e-06 0.000915308 1.13503e-06 0.000915331 1.18051e-06 0.000915354 1.2274e-06 0.000915377 1.27571e-06 0.000915401 1.32546e-06 0.000915426 1.37666e-06 0.000915451 1.42933e-06 0.000915476 1.48348e-06 0.000915502 1.53912e-06 0.000915529 1.59628e-06 0.000915556 1.65496e-06 0.000915583 1.71519e-06 0.000915611 1.77698e-06 0.00091564 1.84035e-06 0.000915668 1.9053e-06 0.000915698 1.9719e-06 0.000915727 2.04009e-06 0.000915757 2.10999e-06 0.000915788 2.1815e-06 0.000915818 2.25482e-06 0.00091585 2.32976e-06 0.000915882 2.40661e-06 0.000915914 2.48514e-06 0.000915946 2.56564e-06 0.00091598 2.64799e-06 0.000916013 2.73225e-06 0.000916047 2.81881e-06 0.000916082 2.90689e-06 0.000916118 2.99818e-06 0.000916154 3.09018e-06 0.000916191 3.18671e-06 0.000916229 3.28315e-06 3.38449e-06 0.000940168 1.49299e-07 0.000940172 1.55626e-07 0.000940175 1.62249e-07 0.000940179 1.69181e-07 0.000940183 1.76438e-07 0.000940187 1.84037e-07 0.000940191 1.91992e-07 0.000940195 2.00321e-07 0.0009402 2.09042e-07 0.000940205 2.18174e-07 0.00094021 2.27735e-07 0.000940215 2.37746e-07 0.000940221 2.48228e-07 0.000940226 2.59201e-07 0.000940233 2.70689e-07 0.000940239 2.82714e-07 0.000940246 2.953e-07 0.000940253 3.08471e-07 0.00094026 3.22252e-07 0.000940268 3.3667e-07 0.000940276 3.5175e-07 0.000940284 3.6752e-07 0.000940293 3.84009e-07 0.000940302 4.01243e-07 0.000940312 4.19251e-07 0.000940322 4.38063e-07 0.000940333 4.57707e-07 0.000940344 4.78214e-07 0.000940355 4.99611e-07 0.000940367 5.2193e-07 0.00094038 5.45199e-07 0.000940393 5.69448e-07 0.000940406 5.94707e-07 0.00094042 6.21003e-07 0.000940435 6.48366e-07 0.00094045 6.76824e-07 0.000940465 7.06403e-07 0.000940482 7.37132e-07 0.000940499 7.69037e-07 0.000940516 8.02141e-07 0.000940534 8.36472e-07 0.000940553 8.72051e-07 0.000940572 9.08903e-07 0.000940591 9.4705e-07 0.000940612 9.86512e-07 0.000940633 1.02731e-06 0.000940654 1.06947e-06 0.000940676 1.113e-06 0.000940699 1.15792e-06 0.000940722 1.20425e-06 0.000940746 1.25201e-06 0.00094077 1.30122e-06 0.000940795 1.35188e-06 0.00094082 1.40402e-06 0.000940846 1.45765e-06 0.000940872 1.51279e-06 0.000940899 1.56945e-06 0.000940926 1.62764e-06 0.000940954 1.68739e-06 0.000940982 1.7487e-06 0.000941011 1.8116e-06 0.00094104 1.87609e-06 0.00094107 1.94222e-06 0.0009411 2.00996e-06 0.000941131 2.0794e-06 0.000941162 2.15048e-06 0.000941193 2.22331e-06 0.000941225 2.29783e-06 0.000941258 2.37416e-06 0.00094129 2.45227e-06 0.000941324 2.53219e-06 0.000941358 2.61412e-06 0.000941392 2.69772e-06 0.000941427 2.78382e-06 0.000941463 2.87113e-06 0.000941499 2.96187e-06 0.000941536 3.05299e-06 0.000941574 3.14875e-06 0.000941613 3.2442e-06 3.3444e-06 0.00096624 1.46094e-07 0.000966244 1.52272e-07 0.000966247 1.58739e-07 0.000966251 1.65508e-07 0.000966255 1.72594e-07 0.000966259 1.80012e-07 0.000966263 1.87777e-07 0.000966268 1.95908e-07 0.000966272 2.04421e-07 0.000966277 2.13334e-07 0.000966282 2.22666e-07 0.000966287 2.32437e-07 0.000966293 2.42667e-07 0.000966299 2.53378e-07 0.000966305 2.6459e-07 0.000966311 2.76327e-07 0.000966318 2.88611e-07 0.000966325 3.01468e-07 0.000966332 3.14922e-07 0.00096634 3.28997e-07 0.000966348 3.43722e-07 0.000966356 3.59121e-07 0.000966365 3.75225e-07 0.000966374 3.92059e-07 0.000966384 4.09654e-07 0.000966394 4.28037e-07 0.000966404 4.47238e-07 0.000966415 4.67286e-07 0.000966427 4.88212e-07 0.000966439 5.10045e-07 0.000966451 5.32815e-07 0.000966464 5.56553e-07 0.000966477 5.81287e-07 0.000966491 6.07048e-07 0.000966506 6.33865e-07 0.000966521 6.61767e-07 0.000966536 6.90782e-07 0.000966553 7.20938e-07 0.000966569 7.52262e-07 0.000966587 7.84782e-07 0.000966605 8.18522e-07 0.000966623 8.53508e-07 0.000966642 8.89765e-07 0.000966662 9.27314e-07 0.000966682 9.6618e-07 0.000966703 1.00638e-06 0.000966725 1.04795e-06 0.000966747 1.09089e-06 0.00096677 1.13522e-06 0.000966793 1.18098e-06 0.000966817 1.22816e-06 0.000966841 1.2768e-06 0.000966866 1.3269e-06 0.000966892 1.37849e-06 0.000966918 1.43158e-06 0.000966944 1.48618e-06 0.000966972 1.54231e-06 0.000966999 1.59998e-06 0.000967027 1.65921e-06 0.000967056 1.72002e-06 0.000967085 1.78242e-06 0.000967115 1.84642e-06 0.000967145 1.91206e-06 0.000967176 1.97932e-06 0.000967207 2.04826e-06 0.000967238 2.11887e-06 0.000967271 2.1912e-06 0.000967303 2.26525e-06 0.000967336 2.34105e-06 0.00096737 2.41869e-06 0.000967404 2.49803e-06 0.000967439 2.57947e-06 0.000967474 2.66241e-06 0.00096751 2.74798e-06 0.000967546 2.83453e-06 0.000967584 2.92463e-06 0.000967622 3.01489e-06 0.000967661 3.10979e-06 0.000967701 3.20425e-06 3.30326e-06 0.000993035 1.42874e-07 0.000993039 1.48906e-07 0.000993042 1.55219e-07 0.000993046 1.61826e-07 0.00099305 1.68741e-07 0.000993054 1.75981e-07 0.000993058 1.8356e-07 0.000993062 1.91494e-07 0.000993067 1.99801e-07 0.000993072 2.08498e-07 0.000993077 2.17604e-07 0.000993082 2.27138e-07 0.000993088 2.3712e-07 0.000993094 2.4757e-07 0.0009931 2.5851e-07 0.000993106 2.69963e-07 0.000993113 2.8195e-07 0.00099312 2.94496e-07 0.000993127 3.07626e-07 0.000993135 3.21364e-07 0.000993143 3.35736e-07 0.000993151 3.5077e-07 0.00099316 3.66492e-07 0.000993169 3.82931e-07 0.000993178 4.00115e-07 0.000993188 4.18073e-07 0.000993199 4.36834e-07 0.00099321 4.56428e-07 0.000993221 4.76884e-07 0.000993233 4.98234e-07 0.000993245 5.20507e-07 0.000993258 5.43733e-07 0.000993271 5.67943e-07 0.000993285 5.93168e-07 0.0009933 6.19437e-07 0.000993314 6.4678e-07 0.00099333 6.75225e-07 0.000993346 7.04803e-07 0.000993363 7.35542e-07 0.00099338 7.67468e-07 0.000993398 8.00609e-07 0.000993417 8.34991e-07 0.000993436 8.70639e-07 0.000993456 9.07579e-07 0.000993476 9.45833e-07 0.000993497 9.85424e-07 0.000993518 1.02638e-06 0.000993541 1.06871e-06 0.000993563 1.11244e-06 0.000993587 1.15759e-06 0.000993611 1.20418e-06 0.000993635 1.25223e-06 0.00099366 1.30174e-06 0.000993686 1.35275e-06 0.000993713 1.40527e-06 0.000993739 1.4593e-06 0.000993767 1.51488e-06 0.000993795 1.572e-06 0.000993823 1.63069e-06 0.000993852 1.69096e-06 0.000993882 1.75283e-06 0.000993912 1.81631e-06 0.000993943 1.88142e-06 0.000993974 1.94818e-06 0.000994006 2.0166e-06 0.000994038 2.0867e-06 0.00099407 2.15849e-06 0.000994104 2.23204e-06 0.000994137 2.30728e-06 0.000994172 2.3844e-06 0.000994207 2.46314e-06 0.000994242 2.54405e-06 0.000994278 2.62631e-06 0.000994315 2.71129e-06 0.000994352 2.79708e-06 0.00099439 2.88647e-06 0.000994429 2.97586e-06 0.000994469 3.06985e-06 0.00099451 3.1633e-06 3.26108e-06 0.00102057 1.39644e-07 0.00102058 1.4553e-07 0.00102058 1.5169e-07 0.00102058 1.58136e-07 0.00102059 1.64884e-07 0.00102059 1.71947e-07 0.0010206 1.7934e-07 0.0010206 1.8708e-07 0.0010206 1.95184e-07 0.00102061 2.03668e-07 0.00102061 2.1255e-07 0.00102062 2.2185e-07 0.00102063 2.31586e-07 0.00102063 2.41779e-07 0.00102064 2.52451e-07 0.00102064 2.63622e-07 0.00102065 2.75316e-07 0.00102066 2.87556e-07 0.00102066 3.00365e-07 0.00102067 3.13769e-07 0.00102068 3.27793e-07 0.00102069 3.42465e-07 0.0010207 3.5781e-07 0.00102071 3.73857e-07 0.00102072 3.90635e-07 0.00102073 4.08171e-07 0.00102074 4.26495e-07 0.00102075 4.45637e-07 0.00102076 4.65627e-07 0.00102077 4.86495e-07 0.00102078 5.08272e-07 0.00102079 5.30988e-07 0.00102081 5.54675e-07 0.00102082 5.79363e-07 0.00102084 6.05082e-07 0.00102085 6.31864e-07 0.00102087 6.59737e-07 0.00102088 6.88732e-07 0.0010209 7.18878e-07 0.00102092 7.50204e-07 0.00102093 7.82737e-07 0.00102095 8.16505e-07 0.00102097 8.51534e-07 0.00102099 8.87851e-07 0.00102101 9.25479e-07 0.00102103 9.64443e-07 0.00102105 1.00477e-06 0.00102108 1.04647e-06 0.0010211 1.08958e-06 0.00102112 1.1341e-06 0.00102115 1.18007e-06 0.00102117 1.2275e-06 0.0010212 1.27641e-06 0.00102122 1.32682e-06 0.00102125 1.37873e-06 0.00102128 1.43218e-06 0.0010213 1.48716e-06 0.00102133 1.54371e-06 0.00102136 1.60183e-06 0.00102139 1.66153e-06 0.00102142 1.72284e-06 0.00102145 1.78577e-06 0.00102148 1.85033e-06 0.00102151 1.91653e-06 0.00102155 1.9844e-06 0.00102158 2.05396e-06 0.00102161 2.12519e-06 0.00102165 2.1982e-06 0.00102168 2.27285e-06 0.00102172 2.34942e-06 0.00102175 2.42753e-06 0.00102179 2.50785e-06 0.00102182 2.58942e-06 0.00102186 2.67375e-06 0.0010219 2.75877e-06 0.00102194 2.84739e-06 0.00102198 2.93591e-06 0.00102202 3.02891e-06 0.00102206 3.12135e-06 3.21786e-06 0.00104887 1.36405e-07 0.00104888 1.42147e-07 0.00104888 1.48155e-07 0.00104888 1.54442e-07 0.00104889 1.61023e-07 0.00104889 1.67911e-07 0.0010489 1.75121e-07 0.0010489 1.82669e-07 0.00104891 1.90571e-07 0.00104891 1.98844e-07 0.00104892 2.07505e-07 0.00104892 2.16573e-07 0.00104893 2.26067e-07 0.00104893 2.36007e-07 0.00104894 2.46413e-07 0.00104894 2.57306e-07 0.00104895 2.6871e-07 0.00104896 2.80646e-07 0.00104897 2.93139e-07 0.00104897 3.06213e-07 0.00104898 3.19893e-07 0.00104899 3.34206e-07 0.001049 3.49178e-07 0.00104901 3.64837e-07 0.00104902 3.81212e-07 0.00104903 3.9833e-07 0.00104904 4.1622e-07 0.00104905 4.34914e-07 0.00104906 4.5444e-07 0.00104907 4.74829e-07 0.00104908 4.96112e-07 0.00104909 5.18319e-07 0.00104911 5.41483e-07 0.00104912 5.65633e-07 0.00104914 5.90802e-07 0.00104915 6.1702e-07 0.00104917 6.44318e-07 0.00104918 6.72727e-07 0.0010492 7.02275e-07 0.00104922 7.32994e-07 0.00104923 7.64912e-07 0.00104925 7.98057e-07 0.00104927 8.32456e-07 0.00104929 8.68138e-07 0.00104931 9.05127e-07 0.00104933 9.43448e-07 0.00104935 9.83127e-07 0.00104938 1.02419e-06 0.0010494 1.06665e-06 0.00104942 1.11053e-06 0.00104945 1.15586e-06 0.00104947 1.20265e-06 0.0010495 1.25092e-06 0.00104952 1.3007e-06 0.00104955 1.35199e-06 0.00104958 1.40481e-06 0.00104961 1.45919e-06 0.00104963 1.51512e-06 0.00104966 1.57264e-06 0.00104969 1.63175e-06 0.00104972 1.69247e-06 0.00104975 1.75481e-06 0.00104979 1.81878e-06 0.00104982 1.88441e-06 0.00104985 1.95169e-06 0.00104988 2.02067e-06 0.00104992 2.09131e-06 0.00104995 2.16373e-06 0.00104999 2.23777e-06 0.00105002 2.31374e-06 0.00105006 2.3912e-06 0.0010501 2.47089e-06 0.00105013 2.55175e-06 0.00105017 2.63537e-06 0.00105021 2.71961e-06 0.00105025 2.80739e-06 0.00105029 2.89502e-06 0.00105033 2.98698e-06 0.00105038 3.07838e-06 3.17359e-06 0.00107796 1.3316e-07 0.00107796 1.38758e-07 0.00107797 1.44616e-07 0.00107797 1.50746e-07 0.00107797 1.57161e-07 0.00107798 1.63876e-07 0.00107798 1.70905e-07 0.00107799 1.78262e-07 0.00107799 1.85965e-07 0.001078 1.94029e-07 0.001078 2.02471e-07 0.00107801 2.1131e-07 0.00107801 2.20564e-07 0.00107802 2.30253e-07 0.00107802 2.40396e-07 0.00107803 2.51015e-07 0.00107804 2.62132e-07 0.00107804 2.73769e-07 0.00107805 2.85949e-07 0.00107806 2.98696e-07 0.00107807 3.12035e-07 0.00107807 3.25993e-07 0.00107808 3.40596e-07 0.00107809 3.55871e-07 0.0010781 3.71846e-07 0.00107811 3.88549e-07 0.00107812 4.0601e-07 0.00107813 4.24257e-07 0.00107814 4.43322e-07 0.00107815 4.63234e-07 0.00107817 4.84025e-07 0.00107818 5.05725e-07 0.00107819 5.28366e-07 0.00107821 5.5198e-07 0.00107822 5.76598e-07 0.00107823 6.02251e-07 0.00107825 6.28971e-07 0.00107827 6.56789e-07 0.00107828 6.85736e-07 0.0010783 7.15843e-07 0.00107832 7.47138e-07 0.00107834 7.79651e-07 0.00107835 8.13412e-07 0.00107837 8.48447e-07 0.00107839 8.84784e-07 0.00107842 9.22449e-07 0.00107844 9.61468e-07 0.00107846 1.00186e-06 0.00107848 1.04366e-06 0.00107851 1.08688e-06 0.00107853 1.13155e-06 0.00107856 1.17768e-06 0.00107858 1.22529e-06 0.00107861 1.27441e-06 0.00107863 1.32505e-06 0.00107866 1.37723e-06 0.00107869 1.43096e-06 0.00107872 1.48626e-06 0.00107875 1.54314e-06 0.00107878 1.60162e-06 0.00107881 1.66172e-06 0.00107884 1.72344e-06 0.00107887 1.78679e-06 0.00107891 1.85181e-06 0.00107894 1.91847e-06 0.00107897 1.98684e-06 0.00107901 2.05686e-06 0.00107904 2.12866e-06 0.00107908 2.20205e-06 0.00107911 2.27738e-06 0.00107915 2.35416e-06 0.00107919 2.43316e-06 0.00107923 2.5133e-06 0.00107927 2.59616e-06 0.00107931 2.67959e-06 0.00107935 2.76648e-06 0.00107939 2.85321e-06 0.00107943 2.94408e-06 0.00107948 3.03441e-06 3.12829e-06 0.00110785 1.29911e-07 0.00110785 1.35367e-07 0.00110786 1.41075e-07 0.00110786 1.47049e-07 0.00110787 1.53301e-07 0.00110787 1.59844e-07 0.00110787 1.66693e-07 0.00110788 1.73862e-07 0.00110788 1.81367e-07 0.00110789 1.89224e-07 0.00110789 1.9745e-07 0.0011079 2.06062e-07 0.0011079 2.15079e-07 0.00110791 2.24519e-07 0.00110792 2.34403e-07 0.00110792 2.44751e-07 0.00110793 2.55583e-07 0.00110793 2.66923e-07 0.00110794 2.78794e-07 0.00110795 2.91218e-07 0.00110796 3.0422e-07 0.00110797 3.17827e-07 0.00110797 3.32064e-07 0.00110798 3.46958e-07 0.00110799 3.62537e-07 0.001108 3.78829e-07 0.00110801 3.95863e-07 0.00110802 4.13668e-07 0.00110803 4.32274e-07 0.00110805 4.51712e-07 0.00110806 4.72012e-07 0.00110807 4.93207e-07 0.00110808 5.15327e-07 0.0011081 5.38404e-07 0.00110811 5.6247e-07 0.00110813 5.87558e-07 0.00110814 6.13698e-07 0.00110816 6.40923e-07 0.00110817 6.69264e-07 0.00110819 6.98753e-07 0.00110821 7.29419e-07 0.00110823 7.61293e-07 0.00110824 7.94406e-07 0.00110826 8.28785e-07 0.00110828 8.64458e-07 0.00110831 9.01454e-07 0.00110833 9.39797e-07 0.00110835 9.79515e-07 0.00110837 1.02063e-06 0.0011084 1.06317e-06 0.00110842 1.10715e-06 0.00110845 1.1526e-06 0.00110847 1.19953e-06 0.0011085 1.24797e-06 0.00110853 1.29793e-06 0.00110855 1.34943e-06 0.00110858 1.40249e-06 0.00110861 1.45713e-06 0.00110864 1.51335e-06 0.00110867 1.57117e-06 0.0011087 1.63061e-06 0.00110873 1.69168e-06 0.00110877 1.75438e-06 0.0011088 1.81875e-06 0.00110883 1.88476e-06 0.00110887 1.95248e-06 0.0011089 2.02184e-06 0.00110894 2.09298e-06 0.00110897 2.1657e-06 0.00110901 2.24035e-06 0.00110905 2.31642e-06 0.00110909 2.39469e-06 0.00110913 2.47407e-06 0.00110917 2.55612e-06 0.00110921 2.63872e-06 0.00110925 2.72467e-06 0.00110929 2.81046e-06 0.00110934 2.90021e-06 0.00110938 2.98943e-06 3.08195e-06 0.00113857 1.26661e-07 0.00113857 1.31975e-07 0.00113858 1.37535e-07 0.00113858 1.43354e-07 0.00113859 1.49443e-07 0.00113859 1.55816e-07 0.00113859 1.62487e-07 0.0011386 1.6947e-07 0.0011386 1.76779e-07 0.00113861 1.84432e-07 0.00113861 1.92443e-07 0.00113862 2.00831e-07 0.00113862 2.09613e-07 0.00113863 2.18807e-07 0.00113864 2.28434e-07 0.00113864 2.38513e-07 0.00113865 2.49065e-07 0.00113865 2.60111e-07 0.00113866 2.71675e-07 0.00113867 2.83779e-07 0.00113868 2.96448e-07 0.00113869 3.09707e-07 0.00113869 3.23581e-07 0.0011387 3.38098e-07 0.00113871 3.53285e-07 0.00113872 3.69169e-07 0.00113873 3.85779e-07 0.00113874 4.03144e-07 0.00113875 4.21295e-07 0.00113876 4.40261e-07 0.00113878 4.60073e-07 0.00113879 4.80764e-07 0.0011388 5.02364e-07 0.00113882 5.24905e-07 0.00113883 5.4842e-07 0.00113884 5.72941e-07 0.00113886 5.985e-07 0.00113888 6.2513e-07 0.00113889 6.52861e-07 0.00113891 6.81728e-07 0.00113893 7.1176e-07 0.00113894 7.42988e-07 0.00113896 7.75444e-07 0.00113898 8.09157e-07 0.001139 8.44156e-07 0.00113902 8.8047e-07 0.00113905 9.18125e-07 0.00113907 9.57149e-07 0.00113909 9.97566e-07 0.00113912 1.0394e-06 0.00113914 1.08268e-06 0.00113916 1.12742e-06 0.00113919 1.17365e-06 0.00113922 1.22139e-06 0.00113924 1.27064e-06 0.00113927 1.32145e-06 0.0011393 1.37381e-06 0.00113933 1.42774e-06 0.00113936 1.48327e-06 0.00113939 1.54041e-06 0.00113942 1.59916e-06 0.00113946 1.65954e-06 0.00113949 1.72156e-06 0.00113952 1.78525e-06 0.00113956 1.85057e-06 0.00113959 1.91761e-06 0.00113963 1.98628e-06 0.00113966 2.05672e-06 0.0011397 2.12873e-06 0.00113974 2.20265e-06 0.00113978 2.27798e-06 0.00113981 2.35548e-06 0.00113985 2.43407e-06 0.0011399 2.51526e-06 0.00113994 2.59701e-06 0.00113998 2.68197e-06 0.00114002 2.76679e-06 0.00114007 2.85537e-06 0.00114011 2.94346e-06 3.03458e-06 0.00117014 1.23411e-07 0.00117015 1.28585e-07 0.00117015 1.33999e-07 0.00117015 1.39664e-07 0.00117016 1.45592e-07 0.00117016 1.51796e-07 0.00117017 1.5829e-07 0.00117017 1.65088e-07 0.00117018 1.72203e-07 0.00117018 1.79653e-07 0.00117018 1.87452e-07 0.00117019 1.95618e-07 0.0011702 2.04167e-07 0.0011702 2.13119e-07 0.00117021 2.22491e-07 0.00117021 2.32304e-07 0.00117022 2.42577e-07 0.00117023 2.53334e-07 0.00117023 2.64594e-07 0.00117024 2.76381e-07 0.00117025 2.8872e-07 0.00117026 3.01634e-07 0.00117027 3.15149e-07 0.00117027 3.29292e-07 0.00117028 3.44089e-07 0.00117029 3.59568e-07 0.0011703 3.75758e-07 0.00117031 3.92687e-07 0.00117032 4.10384e-07 0.00117034 4.28881e-07 0.00117035 4.48208e-07 0.00117036 4.68397e-07 0.00117037 4.89478e-07 0.00117039 5.11485e-07 0.0011704 5.34449e-07 0.00117041 5.58403e-07 0.00117043 5.83379e-07 0.00117045 6.09411e-07 0.00117046 6.36531e-07 0.00117048 6.64771e-07 0.0011705 6.94163e-07 0.00117051 7.2474e-07 0.00117053 7.56532e-07 0.00117055 7.8957e-07 0.00117057 8.23885e-07 0.00117059 8.59504e-07 0.00117062 8.96458e-07 0.00117064 9.34774e-07 0.00117066 9.74477e-07 0.00117069 1.01559e-06 0.00117071 1.05815e-06 0.00117074 1.10217e-06 0.00117076 1.14767e-06 0.00117079 1.19467e-06 0.00117082 1.2432e-06 0.00117084 1.29328e-06 0.00117087 1.34491e-06 0.0011709 1.39813e-06 0.00117093 1.45293e-06 0.00117096 1.50934e-06 0.001171 1.56737e-06 0.00117103 1.62704e-06 0.00117106 1.68834e-06 0.00117109 1.75131e-06 0.00117113 1.81592e-06 0.00117116 1.88224e-06 0.0011712 1.95017e-06 0.00117124 2.01988e-06 0.00117128 2.09115e-06 0.00117131 2.1643e-06 0.00117135 2.23886e-06 0.00117139 2.31554e-06 0.00117143 2.39331e-06 0.00117148 2.4736e-06 0.00117152 2.55445e-06 0.00117156 2.63839e-06 0.00117161 2.72221e-06 0.00117165 2.80957e-06 0.0011717 2.8965e-06 2.9862e-06 0.00120259 1.20164e-07 0.00120259 1.25199e-07 0.0012026 1.30467e-07 0.0012026 1.3598e-07 0.00120261 1.41748e-07 0.00120261 1.47785e-07 0.00120261 1.54104e-07 0.00120262 1.60718e-07 0.00120262 1.67642e-07 0.00120263 1.7489e-07 0.00120263 1.82479e-07 0.00120264 1.90425e-07 0.00120264 1.98744e-07 0.00120265 2.07454e-07 0.00120265 2.16575e-07 0.00120266 2.26124e-07 0.00120267 2.36123e-07 0.00120267 2.46591e-07 0.00120268 2.57551e-07 0.00120269 2.69025e-07 0.0012027 2.81036e-07 0.0012027 2.93608e-07 0.00120271 3.06768e-07 0.00120272 3.2054e-07 0.00120273 3.34951e-07 0.00120274 3.50029e-07 0.00120275 3.65801e-07 0.00120276 3.82296e-07 0.00120277 3.99544e-07 0.00120278 4.17574e-07 0.00120279 4.36418e-07 0.00120281 4.56106e-07 0.00120282 4.7667e-07 0.00120283 4.98143e-07 0.00120285 5.20556e-07 0.00120286 5.43943e-07 0.00120288 5.68337e-07 0.00120289 5.93769e-07 0.00120291 6.20275e-07 0.00120292 6.47885e-07 0.00120294 6.76634e-07 0.00120296 7.06553e-07 0.00120298 7.37674e-07 0.001203 7.7003e-07 0.00120302 8.0365e-07 0.00120304 8.38565e-07 0.00120306 8.74805e-07 0.00120308 9.12399e-07 0.00120311 9.51373e-07 0.00120313 9.91754e-07 0.00120316 1.03357e-06 0.00120318 1.07684e-06 0.00120321 1.12159e-06 0.00120323 1.16785e-06 0.00120326 1.21562e-06 0.00120329 1.26494e-06 0.00120332 1.31583e-06 0.00120335 1.36829e-06 0.00120338 1.42234e-06 0.00120341 1.478e-06 0.00120344 1.53528e-06 0.00120348 1.59419e-06 0.00120351 1.65475e-06 0.00120354 1.71696e-06 0.00120358 1.78082e-06 0.00120361 1.84637e-06 0.00120365 1.91355e-06 0.00120369 1.98248e-06 0.00120373 2.05296e-06 0.00120377 2.12532e-06 0.00120381 2.19906e-06 0.00120385 2.27489e-06 0.00120389 2.35179e-06 0.00120393 2.43115e-06 0.00120397 2.51106e-06 0.00120402 2.59393e-06 0.00120406 2.67671e-06 0.00120411 2.76284e-06 0.00120416 2.84856e-06 2.93681e-06 0.00123594 1.16923e-07 0.00123594 1.2182e-07 0.00123594 1.26943e-07 0.00123595 1.32304e-07 0.00123595 1.37914e-07 0.00123596 1.43785e-07 0.00123596 1.4993e-07 0.00123596 1.56362e-07 0.00123597 1.63096e-07 0.00123597 1.70146e-07 0.00123598 1.77526e-07 0.00123598 1.85253e-07 0.00123599 1.93344e-07 0.001236 2.01816e-07 0.001236 2.10687e-07 0.00123601 2.19976e-07 0.00123601 2.29701e-07 0.00123602 2.39885e-07 0.00123603 2.50547e-07 0.00123603 2.6171e-07 0.00123604 2.73397e-07 0.00123605 2.85631e-07 0.00123606 2.98438e-07 0.00123607 3.11842e-07 0.00123608 3.25871e-07 0.00123609 3.4055e-07 0.0012361 3.55907e-07 0.00123611 3.71972e-07 0.00123612 3.88772e-07 0.00123613 4.06339e-07 0.00123614 4.24701e-07 0.00123615 4.43891e-07 0.00123616 4.6394e-07 0.00123618 4.84881e-07 0.00123619 5.06744e-07 0.00123621 5.29564e-07 0.00123622 5.53374e-07 0.00123624 5.78207e-07 0.00123625 6.04095e-07 0.00123627 6.31073e-07 0.00123629 6.59174e-07 0.00123631 6.8843e-07 0.00123632 7.18875e-07 0.00123634 7.5054e-07 0.00123636 7.83458e-07 0.00123638 8.17659e-07 0.00123641 8.53174e-07 0.00123643 8.90032e-07 0.00123645 9.28262e-07 0.00123648 9.67891e-07 0.0012365 1.00895e-06 0.00123653 1.05145e-06 0.00123655 1.09544e-06 0.00123658 1.14092e-06 0.00123661 1.18792e-06 0.00123663 1.23646e-06 0.00123666 1.28656e-06 0.00123669 1.33824e-06 0.00123673 1.39151e-06 0.00123676 1.44639e-06 0.00123679 1.50288e-06 0.00123682 1.56102e-06 0.00123686 1.62078e-06 0.00123689 1.68221e-06 0.00123693 1.74528e-06 0.00123696 1.81004e-06 0.001237 1.87641e-06 0.00123704 1.94453e-06 0.00123708 2.0142e-06 0.00123712 2.08571e-06 0.00123716 2.1586e-06 0.0012372 2.23353e-06 0.00123724 2.30954e-06 0.00123728 2.38791e-06 0.00123733 2.46686e-06 0.00123737 2.54862e-06 0.00123742 2.63033e-06 0.00123747 2.71517e-06 0.00123752 2.79965e-06 2.88642e-06 0.00127021 1.1369e-07 0.00127021 1.18449e-07 0.00127022 1.23429e-07 0.00127022 1.28639e-07 0.00127022 1.34092e-07 0.00127023 1.39798e-07 0.00127023 1.45771e-07 0.00127024 1.52023e-07 0.00127024 1.58568e-07 0.00127025 1.6542e-07 0.00127025 1.72594e-07 0.00127026 1.80105e-07 0.00127026 1.8797e-07 0.00127027 1.96206e-07 0.00127027 2.04829e-07 0.00127028 2.13859e-07 0.00127028 2.23315e-07 0.00127029 2.33216e-07 0.0012703 2.43583e-07 0.00127031 2.54438e-07 0.00127031 2.65804e-07 0.00127032 2.77702e-07 0.00127033 2.90159e-07 0.00127034 3.03199e-07 0.00127035 3.16848e-07 0.00127036 3.31132e-07 0.00127037 3.46078e-07 0.00127038 3.61714e-07 0.00127039 3.78071e-07 0.0012704 3.95175e-07 0.00127041 4.1306e-07 0.00127042 4.31754e-07 0.00127043 4.51289e-07 0.00127045 4.71698e-07 0.00127046 4.93013e-07 0.00127048 5.15267e-07 0.00127049 5.38493e-07 0.00127051 5.62724e-07 0.00127052 5.87994e-07 0.00127054 6.14337e-07 0.00127056 6.41787e-07 0.00127057 6.70376e-07 0.00127059 7.00139e-07 0.00127061 7.31107e-07 0.00127063 7.63314e-07 0.00127065 7.96791e-07 0.00127068 8.3157e-07 0.0012707 8.67681e-07 0.00127072 9.05153e-07 0.00127074 9.44016e-07 0.00127077 9.84296e-07 0.00127079 1.02602e-06 0.00127082 1.06921e-06 0.00127085 1.1139e-06 0.00127088 1.1601e-06 0.0012709 1.20784e-06 0.00127093 1.25714e-06 0.00127096 1.30801e-06 0.001271 1.36046e-06 0.00127103 1.41453e-06 0.00127106 1.47021e-06 0.00127109 1.52753e-06 0.00127113 1.58648e-06 0.00127116 1.64708e-06 0.0012712 1.70932e-06 0.00127124 1.77325e-06 0.00127127 1.83879e-06 0.00127131 1.90606e-06 0.00127135 1.97487e-06 0.00127139 2.04549e-06 0.00127143 2.1175e-06 0.00127147 2.19149e-06 0.00127152 2.26656e-06 0.00127156 2.34391e-06 0.00127161 2.42185e-06 0.00127165 2.50247e-06 0.0012717 2.58306e-06 0.00127175 2.6666e-06 0.0012718 2.74979e-06 2.83505e-06 0.00130543 1.10465e-07 0.00130543 1.15088e-07 0.00130544 1.19926e-07 0.00130544 1.24987e-07 0.00130545 1.30283e-07 0.00130545 1.35827e-07 0.00130545 1.41629e-07 0.00130546 1.47702e-07 0.00130546 1.5406e-07 0.00130547 1.60716e-07 0.00130547 1.67685e-07 0.00130548 1.74982e-07 0.00130548 1.82623e-07 0.00130549 1.90624e-07 0.00130549 1.99003e-07 0.0013055 2.07777e-07 0.00130551 2.16965e-07 0.00130551 2.26586e-07 0.00130552 2.36661e-07 0.00130553 2.47211e-07 0.00130553 2.58257e-07 0.00130554 2.69824e-07 0.00130555 2.81934e-07 0.00130556 2.94612e-07 0.00130557 3.07884e-07 0.00130558 3.21775e-07 0.00130559 3.36313e-07 0.0013056 3.51524e-07 0.00130561 3.67439e-07 0.00130562 3.84085e-07 0.00130563 4.01493e-07 0.00130564 4.19693e-07 0.00130566 4.38717e-07 0.00130567 4.58596e-07 0.00130568 4.79364e-07 0.0013057 5.01052e-07 0.00130571 5.23694e-07 0.00130573 5.47323e-07 0.00130574 5.71974e-07 0.00130576 5.9768e-07 0.00130578 6.24475e-07 0.00130579 6.52394e-07 0.00130581 6.81469e-07 0.00130583 7.11735e-07 0.00130585 7.43223e-07 0.00130587 7.75969e-07 0.00130589 8.10002e-07 0.00130592 8.45354e-07 0.00130594 8.82056e-07 0.00130596 9.20137e-07 0.00130599 9.59626e-07 0.00130601 1.00055e-06 0.00130604 1.04294e-06 0.00130607 1.08681e-06 0.0013061 1.13219e-06 0.00130612 1.1791e-06 0.00130615 1.22756e-06 0.00130618 1.27759e-06 0.00130622 1.32921e-06 0.00130625 1.38244e-06 0.00130628 1.43727e-06 0.00130631 1.49374e-06 0.00130635 1.55184e-06 0.00130638 1.61159e-06 0.00130642 1.67297e-06 0.00130646 1.73603e-06 0.0013065 1.80069e-06 0.00130654 1.86707e-06 0.00130658 1.93498e-06 0.00130662 2.00469e-06 0.00130666 2.07576e-06 0.0013067 2.14878e-06 0.00130674 2.22287e-06 0.00130679 2.29917e-06 0.00130683 2.37605e-06 0.00130688 2.45549e-06 0.00130693 2.53492e-06 0.00130698 2.61712e-06 0.00130703 2.69899e-06 2.78273e-06 0.00134163 1.07252e-07 0.00134163 1.1174e-07 0.00134164 1.16436e-07 0.00134164 1.21349e-07 0.00134164 1.26491e-07 0.00134165 1.31872e-07 0.00134165 1.37504e-07 0.00134166 1.434e-07 0.00134166 1.49573e-07 0.00134166 1.56035e-07 0.00134167 1.62801e-07 0.00134167 1.69886e-07 0.00134168 1.77305e-07 0.00134169 1.85073e-07 0.00134169 1.93209e-07 0.0013417 2.01729e-07 0.0013417 2.10651e-07 0.00134171 2.19995e-07 0.00134172 2.29781e-07 0.00134172 2.40028e-07 0.00134173 2.50758e-07 0.00134174 2.61995e-07 0.00134175 2.73761e-07 0.00134176 2.86081e-07 0.00134177 2.98978e-07 0.00134177 3.1248e-07 0.00134178 3.26612e-07 0.00134179 3.41402e-07 0.00134181 3.56877e-07 0.00134182 3.73067e-07 0.00134183 3.90001e-07 0.00134184 4.0771e-07 0.00134185 4.26224e-07 0.00134187 4.45576e-07 0.00134188 4.65796e-07 0.00134189 4.8692e-07 0.00134191 5.08978e-07 0.00134192 5.32005e-07 0.00134194 5.56036e-07 0.00134196 5.81103e-07 0.00134197 6.07242e-07 0.00134199 6.34486e-07 0.00134201 6.62869e-07 0.00134203 6.92427e-07 0.00134205 7.23191e-07 0.00134207 7.55196e-07 0.00134209 7.88474e-07 0.00134211 8.23057e-07 0.00134214 8.58977e-07 0.00134216 8.96263e-07 0.00134218 9.34946e-07 0.00134221 9.75053e-07 0.00134224 1.01661e-06 0.00134226 1.05965e-06 0.00134229 1.10419e-06 0.00134232 1.15025e-06 0.00134235 1.19785e-06 0.00134238 1.24702e-06 0.00134241 1.29778e-06 0.00134244 1.35013e-06 0.00134248 1.40409e-06 0.00134251 1.45968e-06 0.00134255 1.51689e-06 0.00134258 1.57575e-06 0.00134262 1.63623e-06 0.00134266 1.69839e-06 0.0013427 1.76214e-06 0.00134274 1.82759e-06 0.00134278 1.89457e-06 0.00134282 1.96332e-06 0.00134286 2.03342e-06 0.0013429 2.10543e-06 0.00134295 2.1785e-06 0.00134299 2.25369e-06 0.00134304 2.32949e-06 0.00134309 2.40771e-06 0.00134314 2.48595e-06 0.00134319 2.56677e-06 0.00134324 2.64729e-06 2.72947e-06 0.00137883 1.04051e-07 0.00137883 1.08405e-07 0.00137884 1.1296e-07 0.00137884 1.17727e-07 0.00137885 1.22715e-07 0.00137885 1.27935e-07 0.00137885 1.334e-07 0.00137886 1.3912e-07 0.00137886 1.45108e-07 0.00137887 1.51378e-07 0.00137887 1.57943e-07 0.00137888 1.64817e-07 0.00137888 1.72016e-07 0.00137889 1.79554e-07 0.00137889 1.87449e-07 0.0013789 1.95717e-07 0.00137891 2.04376e-07 0.00137891 2.13446e-07 0.00137892 2.22944e-07 0.00137893 2.32891e-07 0.00137893 2.43308e-07 0.00137894 2.54217e-07 0.00137895 2.65642e-07 0.00137896 2.77606e-07 0.00137897 2.90132e-07 0.00137898 3.03247e-07 0.00137899 3.16976e-07 0.001379 3.31347e-07 0.00137901 3.46386e-07 0.00137902 3.62122e-07 0.00137903 3.78585e-07 0.00137904 3.95804e-07 0.00137905 4.13811e-07 0.00137907 4.32636e-07 0.00137908 4.52312e-07 0.00137909 4.72871e-07 0.00137911 4.94347e-07 0.00137912 5.16772e-07 0.00137914 5.40181e-07 0.00137916 5.64609e-07 0.00137917 5.90088e-07 0.00137919 6.16655e-07 0.00137921 6.44343e-07 0.00137923 6.73187e-07 0.00137925 7.03221e-07 0.00137927 7.34478e-07 0.00137929 7.66993e-07 0.00137931 8.00797e-07 0.00137934 8.35924e-07 0.00137936 8.72403e-07 0.00137938 9.10265e-07 0.00137941 9.4954e-07 0.00137944 9.90255e-07 0.00137946 1.03244e-06 0.00137949 1.07611e-06 0.00137952 1.1213e-06 0.00137955 1.16803e-06 0.00137958 1.21631e-06 0.00137961 1.26617e-06 0.00137964 1.31762e-06 0.00137968 1.37067e-06 0.00137971 1.42535e-06 0.00137975 1.48164e-06 0.00137978 1.53958e-06 0.00137982 1.59913e-06 0.00137986 1.66035e-06 0.0013799 1.72315e-06 0.00137994 1.78764e-06 0.00137998 1.85364e-06 0.00138002 1.92139e-06 0.00138006 1.99049e-06 0.00138011 2.06144e-06 0.00138015 2.13345e-06 0.0013802 2.20752e-06 0.00138025 2.28218e-06 0.0013803 2.35915e-06 0.00138034 2.43615e-06 0.0013804 2.51557e-06 0.00138045 2.59469e-06 2.67529e-06 0.00141706 1.00865e-07 0.00141707 1.05086e-07 0.00141707 1.09502e-07 0.00141707 1.14122e-07 0.00141708 1.18958e-07 0.00141708 1.24019e-07 0.00141709 1.29317e-07 0.00141709 1.34862e-07 0.0014171 1.40668e-07 0.0014171 1.46747e-07 0.0014171 1.53112e-07 0.00141711 1.59778e-07 0.00141712 1.66758e-07 0.00141712 1.74068e-07 0.00141713 1.81724e-07 0.00141713 1.89742e-07 0.00141714 1.98141e-07 0.00141714 2.06937e-07 0.00141715 2.1615e-07 0.00141716 2.258e-07 0.00141717 2.35906e-07 0.00141717 2.46491e-07 0.00141718 2.57577e-07 0.00141719 2.69188e-07 0.0014172 2.81346e-07 0.00141721 2.94077e-07 0.00141722 3.07406e-07 0.00141723 3.2136e-07 0.00141724 3.35965e-07 0.00141725 3.5125e-07 0.00141726 3.67244e-07 0.00141727 3.83976e-07 0.00141728 4.01477e-07 0.0014173 4.19778e-07 0.00141731 4.3891e-07 0.00141733 4.58907e-07 0.00141734 4.798e-07 0.00141735 5.01623e-07 0.00141737 5.24411e-07 0.00141739 5.48198e-07 0.0014174 5.73017e-07 0.00141742 5.98904e-07 0.00141744 6.25893e-07 0.00141746 6.54019e-07 0.00141748 6.83317e-07 0.0014175 7.13821e-07 0.00141752 7.45564e-07 0.00141754 7.7858e-07 0.00141757 8.12903e-07 0.00141759 8.48563e-07 0.00141762 8.85591e-07 0.00141764 9.24019e-07 0.00141767 9.63874e-07 0.00141769 1.00518e-06 0.00141772 1.04797e-06 0.00141775 1.09227e-06 0.00141778 1.13809e-06 0.00141781 1.18547e-06 0.00141784 1.2344e-06 0.00141788 1.28493e-06 0.00141791 1.33705e-06 0.00141794 1.39078e-06 0.00141798 1.44612e-06 0.00141802 1.5031e-06 0.00141805 1.56169e-06 0.00141809 1.62193e-06 0.00141813 1.68375e-06 0.00141817 1.74724e-06 0.00141821 1.81223e-06 0.00141826 1.87894e-06 0.0014183 1.94699e-06 0.00141834 2.01685e-06 0.00141839 2.08776e-06 0.00141844 2.16065e-06 0.00141849 2.23415e-06 0.00141853 2.30984e-06 0.00141858 2.38556e-06 0.00141864 2.46354e-06 0.00141869 2.54123e-06 2.62022e-06 0.00145636 9.76945e-08 0.00145636 1.01783e-07 0.00145636 1.0606e-07 0.00145637 1.10537e-07 0.00145637 1.15221e-07 0.00145638 1.20124e-07 0.00145638 1.25256e-07 0.00145638 1.30628e-07 0.00145639 1.36253e-07 0.00145639 1.42143e-07 0.0014564 1.4831e-07 0.0014564 1.54768e-07 0.00145641 1.61532e-07 0.00145641 1.68615e-07 0.00145642 1.76035e-07 0.00145643 1.83806e-07 0.00145643 1.91945e-07 0.00145644 2.00471e-07 0.00145644 2.09402e-07 0.00145645 2.18756e-07 0.00145646 2.28554e-07 0.00145647 2.38817e-07 0.00145647 2.49567e-07 0.00145648 2.60827e-07 0.00145649 2.72619e-07 0.0014565 2.84969e-07 0.00145651 2.97901e-07 0.00145652 3.1144e-07 0.00145653 3.25615e-07 0.00145654 3.40451e-07 0.00145655 3.55979e-07 0.00145656 3.72226e-07 0.00145658 3.89224e-07 0.00145659 4.07002e-07 0.0014566 4.25592e-07 0.00145662 4.45027e-07 0.00145663 4.65339e-07 0.00145665 4.86561e-07 0.00145666 5.08727e-07 0.00145668 5.31871e-07 0.0014567 5.56029e-07 0.00145671 5.81233e-07 0.00145673 6.07521e-07 0.00145675 6.34925e-07 0.00145677 6.63482e-07 0.00145679 6.93226e-07 0.00145681 7.24191e-07 0.00145683 7.56412e-07 0.00145686 7.89921e-07 0.00145688 8.2475e-07 0.00145691 8.60933e-07 0.00145693 8.98499e-07 0.00145696 9.37478e-07 0.00145699 9.77899e-07 0.00145701 1.01979e-06 0.00145704 1.06317e-06 0.00145707 1.10807e-06 0.0014571 1.1545e-06 0.00145714 1.2025e-06 0.00145717 1.25207e-06 0.0014572 1.30322e-06 0.00145724 1.35598e-06 0.00145727 1.41035e-06 0.00145731 1.46634e-06 0.00145735 1.52392e-06 0.00145739 1.58315e-06 0.00145743 1.64395e-06 0.00145747 1.70641e-06 0.00145751 1.77035e-06 0.00145755 1.83598e-06 0.0014576 1.90295e-06 0.00145764 1.97168e-06 0.00145769 2.04146e-06 0.00145773 2.11314e-06 0.00145778 2.18542e-06 0.00145783 2.25979e-06 0.00145788 2.3342e-06 0.00145794 2.41072e-06 0.00145799 2.48694e-06 2.5643e-06 0.00149674 9.45407e-08 0.00149674 9.84978e-08 0.00149675 1.02638e-07 0.00149675 1.06971e-07 0.00149676 1.11505e-07 0.00149676 1.16251e-07 0.00149676 1.21218e-07 0.00149677 1.26419e-07 0.00149677 1.31865e-07 0.00149678 1.37566e-07 0.00149678 1.43537e-07 0.00149679 1.4979e-07 0.00149679 1.56338e-07 0.0014968 1.63197e-07 0.0014968 1.70382e-07 0.00149681 1.77907e-07 0.00149681 1.8579e-07 0.00149682 1.94048e-07 0.00149683 2.02698e-07 0.00149683 2.11759e-07 0.00149684 2.21252e-07 0.00149685 2.31195e-07 0.00149686 2.41612e-07 0.00149687 2.52523e-07 0.00149687 2.63953e-07 0.00149688 2.75924e-07 0.00149689 2.8846e-07 0.0014969 3.01589e-07 0.00149691 3.15335e-07 0.00149692 3.29725e-07 0.00149693 3.44789e-07 0.00149695 3.60554e-07 0.00149696 3.7705e-07 0.00149697 3.94307e-07 0.00149698 4.12357e-07 0.001497 4.31231e-07 0.00149701 4.50963e-07 0.00149703 4.71584e-07 0.00149704 4.93128e-07 0.00149706 5.15631e-07 0.00149708 5.39125e-07 0.00149709 5.63646e-07 0.00149711 5.89229e-07 0.00149713 6.15909e-07 0.00149715 6.43721e-07 0.00149717 6.72699e-07 0.00149719 7.0288e-07 0.00149722 7.34296e-07 0.00149724 7.66983e-07 0.00149726 8.00972e-07 0.00149729 8.36297e-07 0.00149731 8.72989e-07 0.00149734 9.11078e-07 0.00149737 9.50593e-07 0.00149739 9.91563e-07 0.00149742 1.03401e-06 0.00149745 1.07796e-06 0.00149748 1.12344e-06 0.00149752 1.17047e-06 0.00149755 1.21906e-06 0.00149758 1.26922e-06 0.00149762 1.32098e-06 0.00149765 1.37433e-06 0.00149769 1.4293e-06 0.00149773 1.48586e-06 0.00149777 1.54404e-06 0.00149781 1.60379e-06 0.00149785 1.66517e-06 0.00149789 1.72803e-06 0.00149794 1.79255e-06 0.00149798 1.85839e-06 0.00149803 1.92595e-06 0.00149807 1.99455e-06 0.00149812 2.06499e-06 0.00149817 2.13603e-06 0.00149822 2.20904e-06 0.00149827 2.2821e-06 0.00149833 2.35712e-06 0.00149838 2.43186e-06 2.50755e-06 0.00153824 9.14045e-08 0.00153825 9.52312e-08 0.00153825 9.92352e-08 0.00153825 1.03425e-07 0.00153826 1.0781e-07 0.00153826 1.124e-07 0.00153827 1.17205e-07 0.00153827 1.22236e-07 0.00153827 1.27503e-07 0.00153828 1.33018e-07 0.00153828 1.38794e-07 0.00153829 1.44843e-07 0.00153829 1.51178e-07 0.0015383 1.57815e-07 0.0015383 1.64766e-07 0.00153831 1.72048e-07 0.00153832 1.79676e-07 0.00153832 1.87667e-07 0.00153833 1.96039e-07 0.00153834 2.0481e-07 0.00153834 2.13999e-07 0.00153835 2.23625e-07 0.00153836 2.33711e-07 0.00153837 2.44277e-07 0.00153838 2.55345e-07 0.00153839 2.6694e-07 0.00153839 2.79085e-07 0.0015384 2.91804e-07 0.00153841 3.05124e-07 0.00153843 3.19071e-07 0.00153844 3.33673e-07 0.00153845 3.48958e-07 0.00153846 3.64954e-07 0.00153847 3.81693e-07 0.00153849 3.99204e-07 0.0015385 4.1752e-07 0.00153851 4.36672e-07 0.00153853 4.56693e-07 0.00153854 4.77616e-07 0.00153856 4.99476e-07 0.00153858 5.22307e-07 0.00153859 5.46142e-07 0.00153861 5.71019e-07 0.00153863 5.96971e-07 0.00153865 6.24034e-07 0.00153867 6.52243e-07 0.00153869 6.81633e-07 0.00153872 7.12238e-07 0.00153874 7.44094e-07 0.00153876 7.77234e-07 0.00153879 8.11691e-07 0.00153881 8.47496e-07 0.00153884 8.84681e-07 0.00153887 9.23277e-07 0.00153889 9.63309e-07 0.00153892 1.00481e-06 0.00153895 1.04779e-06 0.00153898 1.09229e-06 0.00153902 1.13833e-06 0.00153905 1.18591e-06 0.00153908 1.23506e-06 0.00153912 1.28579e-06 0.00153916 1.3381e-06 0.00153919 1.39202e-06 0.00153923 1.44751e-06 0.00153927 1.50462e-06 0.00153931 1.56327e-06 0.00153935 1.62355e-06 0.0015394 1.68529e-06 0.00153944 1.74866e-06 0.00153948 1.81334e-06 0.00153953 1.8797e-06 0.00153958 1.94709e-06 0.00153963 2.01625e-06 0.00153968 2.086e-06 0.00153973 2.15763e-06 0.00153978 2.2293e-06 0.00153984 2.3028e-06 0.00153989 2.376e-06 2.45002e-06 0.0015809 8.82865e-08 0.0015809 9.19838e-08 0.0015809 9.58525e-08 0.00158091 9.99011e-08 0.00158091 1.04138e-07 0.00158092 1.08574e-07 0.00158092 1.13217e-07 0.00158092 1.18078e-07 0.00158093 1.23169e-07 0.00158093 1.28499e-07 0.00158094 1.34081e-07 0.00158094 1.39928e-07 0.00158095 1.46052e-07 0.00158095 1.52467e-07 0.00158096 1.59187e-07 0.00158096 1.66227e-07 0.00158097 1.73603e-07 0.00158098 1.8133e-07 0.00158098 1.89426e-07 0.00158099 1.97908e-07 0.001581 2.06795e-07 0.001581 2.16107e-07 0.00158101 2.25864e-07 0.00158102 2.36087e-07 0.00158103 2.46797e-07 0.00158104 2.58018e-07 0.00158105 2.69773e-07 0.00158106 2.82086e-07 0.00158107 2.94982e-07 0.00158108 3.08488e-07 0.00158109 3.22631e-07 0.0015811 3.37437e-07 0.00158111 3.52937e-07 0.00158113 3.69159e-07 0.00158114 3.86134e-07 0.00158115 4.03892e-07 0.00158117 4.22466e-07 0.00158118 4.41887e-07 0.0015812 4.6219e-07 0.00158121 4.83407e-07 0.00158123 5.05574e-07 0.00158125 5.28723e-07 0.00158126 5.52891e-07 0.00158128 5.78113e-07 0.0015813 6.04423e-07 0.00158132 6.31858e-07 0.00158134 6.60453e-07 0.00158137 6.90241e-07 0.00158139 7.2126e-07 0.00158141 7.53541e-07 0.00158144 7.87119e-07 0.00158146 8.22027e-07 0.00158149 8.58296e-07 0.00158152 8.95957e-07 0.00158155 9.35038e-07 0.00158157 9.75567e-07 0.0015816 1.01757e-06 0.00158164 1.06107e-06 0.00158167 1.10609e-06 0.0015817 1.15264e-06 0.00158174 1.20075e-06 0.00158177 1.25043e-06 0.00158181 1.30167e-06 0.00158185 1.35451e-06 0.00158188 1.40891e-06 0.00158192 1.4649e-06 0.00158196 1.52244e-06 0.00158201 1.58157e-06 0.00158205 1.64215e-06 0.00158209 1.70435e-06 0.00158214 1.76783e-06 0.00158219 1.83296e-06 0.00158223 1.89909e-06 0.00158228 1.96694e-06 0.00158233 2.03537e-06 0.00158239 2.10558e-06 0.00158244 2.17583e-06 0.00158249 2.24779e-06 0.00158255 2.31943e-06 2.39174e-06 0.00162473 8.51871e-08 0.00162474 8.8756e-08 0.00162474 9.24904e-08 0.00162474 9.63985e-08 0.00162475 1.00489e-07 0.00162475 1.04771e-07 0.00162476 1.09254e-07 0.00162476 1.13947e-07 0.00162476 1.18862e-07 0.00162477 1.24009e-07 0.00162477 1.29399e-07 0.00162478 1.35045e-07 0.00162478 1.40959e-07 0.00162479 1.47155e-07 0.00162479 1.53645e-07 0.0016248 1.60445e-07 0.00162481 1.6757e-07 0.00162481 1.75035e-07 0.00162482 1.82857e-07 0.00162483 1.91053e-07 0.00162483 1.99641e-07 0.00162484 2.0864e-07 0.00162485 2.1807e-07 0.00162486 2.27952e-07 0.00162487 2.38307e-07 0.00162487 2.49157e-07 0.00162488 2.60524e-07 0.00162489 2.72433e-07 0.0016249 2.84909e-07 0.00162491 2.97976e-07 0.00162492 3.11661e-07 0.00162494 3.25992e-07 0.00162495 3.40997e-07 0.00162496 3.56704e-07 0.00162497 3.73143e-07 0.00162499 3.90346e-07 0.001625 4.08343e-07 0.00162502 4.27166e-07 0.00162503 4.46849e-07 0.00162505 4.67424e-07 0.00162506 4.88926e-07 0.00162508 5.11388e-07 0.0016251 5.34846e-07 0.00162512 5.59336e-07 0.00162514 5.84891e-07 0.00162516 6.11548e-07 0.00162518 6.39342e-07 0.0016252 6.68308e-07 0.00162522 6.98482e-07 0.00162525 7.29897e-07 0.00162527 7.62588e-07 0.0016253 7.96588e-07 0.00162532 8.31929e-07 0.00162535 8.68642e-07 0.00162538 9.06757e-07 0.00162541 9.46302e-07 0.00162544 9.87303e-07 0.00162547 1.02978e-06 0.0016255 1.07377e-06 0.00162554 1.11927e-06 0.00162557 1.16631e-06 0.00162561 1.21491e-06 0.00162564 1.26506e-06 0.00162568 1.31679e-06 0.00162572 1.37006e-06 0.00162576 1.42492e-06 0.0016258 1.4813e-06 0.00162584 1.53926e-06 0.00162589 1.59866e-06 0.00162593 1.65964e-06 0.00162598 1.72189e-06 0.00162602 1.78575e-06 0.00162607 1.8506e-06 0.00162612 1.9171e-06 0.00162617 1.98417e-06 0.00162623 2.05294e-06 0.00162628 2.12174e-06 0.00162634 2.19212e-06 0.00162639 2.26217e-06 2.33276e-06 0.00166979 8.21063e-08 0.00166979 8.55476e-08 0.00166979 8.91486e-08 0.0016698 9.29174e-08 0.0016698 9.68621e-08 0.0016698 1.00992e-07 0.00166981 1.05315e-07 0.00166981 1.09842e-07 0.00166982 1.14582e-07 0.00166982 1.19547e-07 0.00166983 1.24747e-07 0.00166983 1.30193e-07 0.00166984 1.35899e-07 0.00166984 1.41877e-07 0.00166985 1.48139e-07 0.00166985 1.54701e-07 0.00166986 1.61577e-07 0.00166986 1.68782e-07 0.00166987 1.76332e-07 0.00166988 1.84243e-07 0.00166989 1.92534e-07 0.00166989 2.01223e-07 0.0016699 2.10329e-07 0.00166991 2.19872e-07 0.00166992 2.29873e-07 0.00166993 2.40354e-07 0.00166993 2.51337e-07 0.00166994 2.62844e-07 0.00166995 2.74901e-07 0.00166996 2.87531e-07 0.00166998 3.00762e-07 0.00166999 3.14619e-07 0.00167 3.29131e-07 0.00167001 3.44325e-07 0.00167002 3.60232e-07 0.00167004 3.7688e-07 0.00167005 3.94302e-07 0.00167007 4.12528e-07 0.00167008 4.31591e-07 0.0016701 4.51524e-07 0.00167011 4.72362e-07 0.00167013 4.94137e-07 0.00167015 5.16884e-07 0.00167017 5.40639e-07 0.00167019 5.65437e-07 0.00167021 5.91313e-07 0.00167023 6.18302e-07 0.00167025 6.46441e-07 0.00167027 6.75764e-07 0.0016703 7.06306e-07 0.00167032 7.38102e-07 0.00167035 7.71185e-07 0.00167037 8.05587e-07 0.0016704 8.41341e-07 0.00167043 8.78476e-07 0.00167046 9.17021e-07 0.00167049 9.57003e-07 0.00167052 9.98448e-07 0.00167055 1.04138e-06 0.00167059 1.08581e-06 0.00167062 1.13177e-06 0.00167066 1.17926e-06 0.00167069 1.22829e-06 0.00167073 1.27888e-06 0.00167077 1.33101e-06 0.00167081 1.3847e-06 0.00167085 1.43989e-06 0.00167089 1.49665e-06 0.00167094 1.55483e-06 0.00167098 1.61456e-06 0.00167103 1.67555e-06 0.00167108 1.73811e-06 0.00167113 1.80165e-06 0.00167118 1.86677e-06 0.00167123 1.93246e-06 0.00167128 1.99975e-06 0.00167134 2.06707e-06 0.00167139 2.13585e-06 0.00167145 2.20428e-06 2.27313e-06 0.00171609 7.90437e-08 0.00171609 8.23583e-08 0.0017161 8.5827e-08 0.0017161 8.94573e-08 0.0017161 9.32573e-08 0.00171611 9.72354e-08 0.00171611 1.014e-07 0.00171611 1.05762e-07 0.00171612 1.10329e-07 0.00171612 1.15113e-07 0.00171613 1.20124e-07 0.00171613 1.25372e-07 0.00171614 1.30871e-07 0.00171614 1.36632e-07 0.00171615 1.42669e-07 0.00171615 1.48994e-07 0.00171616 1.55623e-07 0.00171617 1.62569e-07 0.00171617 1.69849e-07 0.00171618 1.77478e-07 0.00171619 1.85473e-07 0.00171619 1.93854e-07 0.0017162 2.02638e-07 0.00171621 2.11845e-07 0.00171622 2.21495e-07 0.00171623 2.31609e-07 0.00171624 2.42208e-07 0.00171625 2.53316e-07 0.00171626 2.64956e-07 0.00171627 2.77153e-07 0.00171628 2.89931e-07 0.00171629 3.03317e-07 0.0017163 3.17338e-07 0.00171631 3.32021e-07 0.00171632 3.47396e-07 0.00171634 3.63492e-07 0.00171635 3.8034e-07 0.00171637 3.9797e-07 0.00171638 4.16415e-07 0.0017164 4.35707e-07 0.00171641 4.5588e-07 0.00171643 4.76967e-07 0.00171645 4.99003e-07 0.00171647 5.22022e-07 0.00171649 5.4606e-07 0.00171651 5.71152e-07 0.00171653 5.97334e-07 0.00171655 6.24641e-07 0.00171657 6.53108e-07 0.0017166 6.82771e-07 0.00171662 7.13664e-07 0.00171665 7.45821e-07 0.00171667 7.79274e-07 0.0017167 8.14057e-07 0.00171673 8.502e-07 0.00171676 8.87733e-07 0.00171679 9.26682e-07 0.00171682 9.67074e-07 0.00171685 1.00893e-06 0.00171688 1.05227e-06 0.00171692 1.09712e-06 0.00171696 1.14349e-06 0.00171699 1.19138e-06 0.00171703 1.2408e-06 0.00171707 1.29176e-06 0.00171711 1.34425e-06 0.00171715 1.39824e-06 0.00171719 1.45376e-06 0.00171724 1.51069e-06 0.00171728 1.56915e-06 0.00171733 1.62885e-06 0.00171738 1.69008e-06 0.00171743 1.75227e-06 0.00171748 1.81599e-06 0.00171753 1.88026e-06 0.00171758 1.94606e-06 0.00171764 2.01186e-06 0.0017177 2.07902e-06 0.00171776 2.14581e-06 2.2129e-06 0.00176367 7.59987e-08 0.00176368 7.91875e-08 0.00176368 8.25246e-08 0.00176368 8.60173e-08 0.00176369 8.96735e-08 0.00176369 9.35013e-08 0.0017637 9.75093e-08 0.0017637 1.01706e-07 0.0017637 1.06102e-07 0.00176371 1.10706e-07 0.00176371 1.15528e-07 0.00176372 1.20581e-07 0.00176372 1.25874e-07 0.00176373 1.3142e-07 0.00176373 1.37232e-07 0.00176374 1.43323e-07 0.00176375 1.49705e-07 0.00176375 1.56395e-07 0.00176376 1.63406e-07 0.00176376 1.70755e-07 0.00176377 1.78457e-07 0.00176378 1.86531e-07 0.00176379 1.94995e-07 0.00176379 2.03867e-07 0.0017638 2.13168e-07 0.00176381 2.22917e-07 0.00176382 2.33136e-07 0.00176383 2.43847e-07 0.00176384 2.55073e-07 0.00176385 2.66838e-07 0.00176386 2.79165e-07 0.00176387 2.92082e-07 0.00176388 3.05614e-07 0.0017639 3.19789e-07 0.00176391 3.34634e-07 0.00176392 3.50179e-07 0.00176394 3.66454e-07 0.00176395 3.8349e-07 0.00176397 4.01317e-07 0.00176398 4.19969e-07 0.001764 4.39478e-07 0.00176401 4.59877e-07 0.00176403 4.812e-07 0.00176405 5.03483e-07 0.00176407 5.2676e-07 0.00176409 5.51066e-07 0.00176411 5.76437e-07 0.00176413 6.02908e-07 0.00176416 6.30515e-07 0.00176418 6.59293e-07 0.0017642 6.89276e-07 0.00176423 7.20499e-07 0.00176426 7.52996e-07 0.00176428 7.86798e-07 0.00176431 8.21938e-07 0.00176434 8.58444e-07 0.00176437 8.96346e-07 0.0017644 9.3567e-07 0.00176443 9.76438e-07 0.00176447 1.01867e-06 0.0017645 1.06239e-06 0.00176454 1.10761e-06 0.00176458 1.15434e-06 0.00176461 1.20258e-06 0.00176465 1.25233e-06 0.00176469 1.30361e-06 0.00176474 1.35636e-06 0.00176478 1.41063e-06 0.00176482 1.46628e-06 0.00176487 1.52344e-06 0.00176492 1.58182e-06 0.00176496 1.64169e-06 0.00176501 1.7025e-06 0.00176507 1.7648e-06 0.00176512 1.82762e-06 0.00176517 1.8919e-06 0.00176523 1.95617e-06 0.00176529 2.02169e-06 0.00176534 2.08681e-06 2.15213e-06 0.00181258 7.29701e-08 0.00181258 7.60338e-08 0.00181259 7.92401e-08 0.00181259 8.25962e-08 0.00181259 8.61095e-08 0.0018126 8.97879e-08 0.0018126 9.36396e-08 0.00181261 9.76733e-08 0.00181261 1.01898e-07 0.00181261 1.06323e-07 0.00181262 1.10959e-07 0.00181262 1.15816e-07 0.00181263 1.20906e-07 0.00181263 1.26238e-07 0.00181264 1.31827e-07 0.00181264 1.37684e-07 0.00181265 1.43822e-07 0.00181266 1.50257e-07 0.00181266 1.57001e-07 0.00181267 1.64071e-07 0.00181268 1.71482e-07 0.00181268 1.79251e-07 0.00181269 1.87397e-07 0.0018127 1.95937e-07 0.00181271 2.0489e-07 0.00181272 2.14277e-07 0.00181273 2.24117e-07 0.00181273 2.34433e-07 0.00181274 2.45247e-07 0.00181275 2.56581e-07 0.00181277 2.68461e-07 0.00181278 2.8091e-07 0.00181279 2.93955e-07 0.0018128 3.07623e-07 0.00181281 3.21941e-07 0.00181283 3.36937e-07 0.00181284 3.52641e-07 0.00181285 3.69083e-07 0.00181287 3.86295e-07 0.00181289 4.04307e-07 0.0018129 4.23152e-07 0.00181292 4.42863e-07 0.00181294 4.63474e-07 0.00181295 4.8502e-07 0.00181297 5.07534e-07 0.00181299 5.31052e-07 0.00181301 5.5561e-07 0.00181304 5.81242e-07 0.00181306 6.07984e-07 0.00181308 6.35872e-07 0.00181311 6.64939e-07 0.00181313 6.95222e-07 0.00181316 7.26754e-07 0.00181319 7.59566e-07 0.00181321 7.93693e-07 0.00181324 8.29163e-07 0.00181327 8.66005e-07 0.0018133 9.04246e-07 0.00181334 9.43911e-07 0.00181337 9.85022e-07 0.00181341 1.0276e-06 0.00181344 1.07165e-06 0.00181348 1.11719e-06 0.00181352 1.16423e-06 0.00181356 1.21276e-06 0.0018136 1.2628e-06 0.00181364 1.31429e-06 0.00181368 1.36727e-06 0.00181373 1.42163e-06 0.00181377 1.47745e-06 0.00181382 1.53449e-06 0.00181387 1.59298e-06 0.00181392 1.6524e-06 0.00181397 1.71324e-06 0.00181402 1.7746e-06 0.00181408 1.83734e-06 0.00181414 1.90004e-06 0.00181419 1.96391e-06 0.00181425 2.02735e-06 2.09088e-06 0.00186284 6.99563e-08 0.00186285 7.28956e-08 0.00186285 7.59719e-08 0.00186285 7.91921e-08 0.00186286 8.25633e-08 0.00186286 8.60932e-08 0.00186286 8.97896e-08 0.00186287 9.36609e-08 0.00186287 9.77159e-08 0.00186288 1.01964e-07 0.00186288 1.06414e-07 0.00186288 1.11077e-07 0.00186289 1.15963e-07 0.00186289 1.21083e-07 0.0018629 1.2645e-07 0.00186291 1.32075e-07 0.00186291 1.37971e-07 0.00186292 1.44151e-07 0.00186292 1.5063e-07 0.00186293 1.57423e-07 0.00186294 1.64544e-07 0.00186294 1.7201e-07 0.00186295 1.7984e-07 0.00186296 1.88049e-07 0.00186297 1.96657e-07 0.00186298 2.05683e-07 0.00186299 2.15147e-07 0.001863 2.2507e-07 0.00186301 2.35473e-07 0.00186302 2.4638e-07 0.00186303 2.57813e-07 0.00186304 2.69797e-07 0.00186305 2.82357e-07 0.00186306 2.9552e-07 0.00186307 3.09312e-07 0.00186309 3.23761e-07 0.0018631 3.38895e-07 0.00186311 3.54745e-07 0.00186313 3.71342e-07 0.00186315 3.88715e-07 0.00186316 4.06897e-07 0.00186318 4.25921e-07 0.0018632 4.45819e-07 0.00186321 4.66627e-07 0.00186323 4.88378e-07 0.00186325 5.11106e-07 0.00186327 5.34848e-07 0.0018633 5.59639e-07 0.00186332 5.85513e-07 0.00186334 6.12506e-07 0.00186337 6.40654e-07 0.00186339 6.6999e-07 0.00186342 7.0055e-07 0.00186344 7.32365e-07 0.00186347 7.65469e-07 0.0018635 7.99892e-07 0.00186353 8.35663e-07 0.00186356 8.72811e-07 0.0018636 9.11358e-07 0.00186363 9.5133e-07 0.00186367 9.92742e-07 0.0018637 1.03561e-06 0.00186374 1.07995e-06 0.00186378 1.12577e-06 0.00186382 1.17306e-06 0.00186386 1.22183e-06 0.0018639 1.27204e-06 0.00186394 1.32372e-06 0.00186399 1.37676e-06 0.00186403 1.43124e-06 0.00186408 1.48691e-06 0.00186413 1.544e-06 0.00186418 1.60199e-06 0.00186423 1.66137e-06 0.00186429 1.72124e-06 0.00186434 1.78242e-06 0.0018644 1.84355e-06 0.00186446 1.90575e-06 0.00186452 1.96749e-06 2.02922e-06 0.0019145 6.69549e-08 0.0019145 6.97705e-08 0.0019145 7.27174e-08 0.00191451 7.58024e-08 0.00191451 7.90323e-08 0.00191451 8.24143e-08 0.00191452 8.59563e-08 0.00191452 8.9666e-08 0.00191453 9.35521e-08 0.00191453 9.76233e-08 0.00191454 1.01889e-07 0.00191454 1.06359e-07 0.00191455 1.11043e-07 0.00191455 1.15952e-07 0.00191456 1.21098e-07 0.00191456 1.26492e-07 0.00191457 1.32146e-07 0.00191457 1.38074e-07 0.00191458 1.4429e-07 0.00191459 1.50806e-07 0.00191459 1.57639e-07 0.0019146 1.64805e-07 0.00191461 1.72319e-07 0.00191462 1.80199e-07 0.00191462 1.88464e-07 0.00191463 1.97131e-07 0.00191464 2.0622e-07 0.00191465 2.15752e-07 0.00191466 2.25747e-07 0.00191467 2.36227e-07 0.00191468 2.47216e-07 0.00191469 2.58736e-07 0.0019147 2.70814e-07 0.00191472 2.83473e-07 0.00191473 2.9674e-07 0.00191474 3.10643e-07 0.00191476 3.2521e-07 0.00191477 3.4047e-07 0.00191478 3.56452e-07 0.0019148 3.73187e-07 0.00191482 3.90707e-07 0.00191483 4.09044e-07 0.00191485 4.2823e-07 0.00191487 4.483e-07 0.00191489 4.69287e-07 0.00191491 4.91225e-07 0.00191493 5.1415e-07 0.00191495 5.38096e-07 0.00191497 5.63099e-07 0.001915 5.89195e-07 0.00191502 6.16418e-07 0.00191505 6.44803e-07 0.00191507 6.74384e-07 0.0019151 7.05195e-07 0.00191513 7.37269e-07 0.00191516 7.70636e-07 0.00191519 8.05327e-07 0.00191522 8.41369e-07 0.00191525 8.78787e-07 0.00191528 9.17607e-07 0.00191532 9.57844e-07 0.00191535 9.9952e-07 0.00191539 1.04264e-06 0.00191543 1.08722e-06 0.00191547 1.13325e-06 0.00191551 1.18074e-06 0.00191555 1.22965e-06 0.0019156 1.28001e-06 0.00191564 1.33171e-06 0.00191569 1.38482e-06 0.00191574 1.43911e-06 0.00191579 1.49478e-06 0.00191584 1.55134e-06 0.00191589 1.60924e-06 0.00191594 1.6676e-06 0.001916 1.72722e-06 0.00191605 1.78675e-06 0.00191611 1.84727e-06 0.00191617 1.9073e-06 1.96723e-06 0.00196759 6.39634e-08 0.00196759 6.66557e-08 0.00196759 6.94739e-08 0.0019676 7.24242e-08 0.0019676 7.55133e-08 0.0019676 7.87483e-08 0.00196761 8.21364e-08 0.00196761 8.56854e-08 0.00196761 8.94033e-08 0.00196762 9.32986e-08 0.00196762 9.73804e-08 0.00196763 1.01658e-07 0.00196763 1.06141e-07 0.00196764 1.1084e-07 0.00196764 1.15766e-07 0.00196765 1.2093e-07 0.00196766 1.26345e-07 0.00196766 1.32022e-07 0.00196767 1.37974e-07 0.00196767 1.44216e-07 0.00196768 1.50762e-07 0.00196769 1.57628e-07 0.0019677 1.64829e-07 0.0019677 1.72382e-07 0.00196771 1.80304e-07 0.00196772 1.88614e-07 0.00196773 1.9733e-07 0.00196774 2.06472e-07 0.00196775 2.1606e-07 0.00196776 2.26116e-07 0.00196777 2.36662e-07 0.00196778 2.47721e-07 0.00196779 2.59317e-07 0.0019678 2.71474e-07 0.00196782 2.84219e-07 0.00196783 2.97578e-07 0.00196784 3.11579e-07 0.00196786 3.26249e-07 0.00196787 3.41618e-07 0.00196789 3.57717e-07 0.0019679 3.74576e-07 0.00196792 3.92226e-07 0.00196794 4.107e-07 0.00196796 4.30032e-07 0.00196797 4.50254e-07 0.00196799 4.71401e-07 0.00196802 4.93507e-07 0.00196804 5.16608e-07 0.00196806 5.40738e-07 0.00196808 5.65933e-07 0.00196811 5.92227e-07 0.00196813 6.19656e-07 0.00196816 6.48255e-07 0.00196818 6.78056e-07 0.00196821 7.09092e-07 0.00196824 7.41396e-07 0.00196827 7.74998e-07 0.0019683 8.09925e-07 0.00196834 8.46205e-07 0.00196837 8.8386e-07 0.00196841 9.22912e-07 0.00196844 9.63378e-07 0.00196848 1.00527e-06 0.00196852 1.04859e-06 0.00196856 1.09335e-06 0.0019686 1.13955e-06 0.00196864 1.18714e-06 0.00196868 1.23617e-06 0.00196873 1.28651e-06 0.00196878 1.33825e-06 0.00196882 1.39114e-06 0.00196887 1.44537e-06 0.00196892 1.50049e-06 0.00196898 1.55689e-06 0.00196903 1.61374e-06 0.00196909 1.67178e-06 0.00196914 1.72972e-06 0.0019692 1.78855e-06 0.00196926 1.84685e-06 1.90497e-06 0.00202215 6.09775e-08 0.00202215 6.35469e-08 0.00202215 6.62366e-08 0.00202216 6.90527e-08 0.00202216 7.20016e-08 0.00202216 7.50899e-08 0.00202217 7.83247e-08 0.00202217 8.17134e-08 0.00202218 8.52638e-08 0.00202218 8.8984e-08 0.00202218 9.28827e-08 0.00202219 9.69687e-08 0.00202219 1.01252e-07 0.0020222 1.05741e-07 0.0020222 1.10449e-07 0.00202221 1.15384e-07 0.00202222 1.20559e-07 0.00202222 1.25986e-07 0.00202223 1.31677e-07 0.00202223 1.37646e-07 0.00202224 1.43906e-07 0.00202225 1.50473e-07 0.00202226 1.57361e-07 0.00202226 1.64588e-07 0.00202227 1.7217e-07 0.00202228 1.80124e-07 0.00202229 1.88468e-07 0.0020223 1.97222e-07 0.00202231 2.06405e-07 0.00202232 2.16038e-07 0.00202233 2.26143e-07 0.00202234 2.36742e-07 0.00202235 2.47858e-07 0.00202236 2.59515e-07 0.00202238 2.71739e-07 0.00202239 2.84556e-07 0.0020224 2.97991e-07 0.00202242 3.12073e-07 0.00202243 3.26831e-07 0.00202245 3.42294e-07 0.00202246 3.58492e-07 0.00202248 3.75457e-07 0.0020225 3.9322e-07 0.00202252 4.11813e-07 0.00202253 4.31271e-07 0.00202255 4.51626e-07 0.00202257 4.72913e-07 0.0020226 4.95167e-07 0.00202262 5.18422e-07 0.00202264 5.42713e-07 0.00202267 5.68077e-07 0.00202269 5.94546e-07 0.00202272 6.22157e-07 0.00202274 6.50943e-07 0.00202277 6.80937e-07 0.0020228 7.12171e-07 0.00202283 7.44677e-07 0.00202286 7.78482e-07 0.0020229 8.13614e-07 0.00202293 8.50097e-07 0.00202296 8.87952e-07 0.002023 9.27198e-07 0.00202304 9.67845e-07 0.00202308 1.00991e-06 0.00202312 1.05338e-06 0.00202316 1.09827e-06 0.0020232 1.14454e-06 0.00202324 1.19222e-06 0.00202329 1.24119e-06 0.00202334 1.29154e-06 0.00202338 1.34302e-06 0.00202343 1.39583e-06 0.00202349 1.44948e-06 0.00202354 1.50439e-06 0.00202359 1.55972e-06 0.00202365 1.61619e-06 0.0020237 1.67252e-06 0.00202376 1.72967e-06 0.00202382 1.78625e-06 1.84256e-06 0.00207822 5.79936e-08 0.00207822 6.04404e-08 0.00207823 6.30021e-08 0.00207823 6.56843e-08 0.00207823 6.84933e-08 0.00207824 7.14353e-08 0.00207824 7.45173e-08 0.00207825 7.77462e-08 0.00207825 8.11295e-08 0.00207825 8.4675e-08 0.00207826 8.8391e-08 0.00207826 9.22861e-08 0.00207827 9.63694e-08 0.00207827 1.0065e-07 0.00207828 1.05139e-07 0.00207828 1.09846e-07 0.00207829 1.14783e-07 0.0020783 1.1996e-07 0.0020783 1.25391e-07 0.00207831 1.31087e-07 0.00207832 1.37062e-07 0.00207832 1.43331e-07 0.00207833 1.49909e-07 0.00207834 1.56811e-07 0.00207835 1.64053e-07 0.00207835 1.71652e-07 0.00207836 1.79626e-07 0.00207837 1.87993e-07 0.00207838 1.96773e-07 0.00207839 2.05985e-07 0.0020784 2.1565e-07 0.00207841 2.2579e-07 0.00207843 2.36427e-07 0.00207844 2.47586e-07 0.00207845 2.5929e-07 0.00207846 2.71565e-07 0.00207848 2.84437e-07 0.00207849 2.97932e-07 0.0020785 3.1208e-07 0.00207852 3.26908e-07 0.00207854 3.42447e-07 0.00207855 3.58726e-07 0.00207857 3.75778e-07 0.00207859 3.93634e-07 0.00207861 4.12327e-07 0.00207863 4.3189e-07 0.00207865 4.52357e-07 0.00207867 4.73762e-07 0.00207869 4.96141e-07 0.00207871 5.19528e-07 0.00207874 5.43958e-07 0.00207876 5.69465e-07 0.00207879 5.96086e-07 0.00207882 6.23852e-07 0.00207885 6.52799e-07 0.00207887 6.82959e-07 0.0020789 7.14362e-07 0.00207894 7.47038e-07 0.00207897 7.81015e-07 0.002079 8.16319e-07 0.00207904 8.52969e-07 0.00207907 8.90987e-07 0.00207911 9.30384e-07 0.00207915 9.71174e-07 0.00207919 1.01335e-06 0.00207923 1.05693e-06 0.00207927 1.10187e-06 0.00207932 1.14819e-06 0.00207936 1.19579e-06 0.00207941 1.24475e-06 0.00207946 1.29482e-06 0.00207951 1.34618e-06 0.00207956 1.39838e-06 0.00207961 1.4518e-06 0.00207967 1.50561e-06 0.00207972 1.56051e-06 0.00207978 1.61524e-06 0.00207984 1.67071e-06 0.0020799 1.72557e-06 1.78007e-06 0.00213585 5.50039e-08 0.00213585 5.73282e-08 0.00213586 5.97618e-08 0.00213586 6.23102e-08 0.00213586 6.49793e-08 0.00213587 6.77752e-08 0.00213587 7.07044e-08 0.00213587 7.37736e-08 0.00213588 7.699e-08 0.00213588 8.03611e-08 0.00213589 8.38948e-08 0.00213589 8.75993e-08 0.0021359 9.14834e-08 0.0021359 9.55562e-08 0.00213591 9.98273e-08 0.00213591 1.04307e-07 0.00213592 1.09005e-07 0.00213593 1.13934e-07 0.00213593 1.19105e-07 0.00213594 1.24529e-07 0.00213594 1.30221e-07 0.00213595 1.36193e-07 0.00213596 1.4246e-07 0.00213597 1.49038e-07 0.00213598 1.55942e-07 0.00213598 1.63187e-07 0.00213599 1.70792e-07 0.002136 1.78773e-07 0.00213601 1.8715e-07 0.00213602 1.95942e-07 0.00213603 2.05168e-07 0.00213604 2.14851e-07 0.00213605 2.25011e-07 0.00213607 2.35673e-07 0.00213608 2.46858e-07 0.00213609 2.58593e-07 0.00213611 2.70902e-07 0.00213612 2.83812e-07 0.00213613 2.97351e-07 0.00213615 3.11545e-07 0.00213617 3.26425e-07 0.00213618 3.42021e-07 0.0021362 3.58362e-07 0.00213622 3.75481e-07 0.00213624 3.93409e-07 0.00213626 4.1218e-07 0.00213628 4.31827e-07 0.0021363 4.52384e-07 0.00213632 4.73885e-07 0.00213634 4.96366e-07 0.00213637 5.1986e-07 0.00213639 5.44404e-07 0.00213642 5.70031e-07 0.00213645 5.96775e-07 0.00213647 6.24672e-07 0.0021365 6.53752e-07 0.00213653 6.84049e-07 0.00213657 7.15592e-07 0.0021366 7.48409e-07 0.00213663 7.82527e-07 0.00213667 8.17968e-07 0.0021367 8.54752e-07 0.00213674 8.92892e-07 0.00213678 9.32404e-07 0.00213682 9.73282e-07 0.00213686 1.01554e-06 0.0021369 1.05914e-06 0.00213695 1.10411e-06 0.00213699 1.15034e-06 0.00213704 1.1979e-06 0.00213709 1.24656e-06 0.00213714 1.29649e-06 0.00213719 1.34724e-06 0.00213724 1.39917e-06 0.0021373 1.45148e-06 0.00213735 1.50482e-06 0.00213741 1.55797e-06 0.00213747 1.61178e-06 0.00213753 1.66492e-06 1.71763e-06 0.00219508 5.20054e-08 0.00219508 5.42072e-08 0.00219508 5.65127e-08 0.00219509 5.89273e-08 0.00219509 6.14566e-08 0.0021951 6.41064e-08 0.0021951 6.68829e-08 0.0021951 6.97925e-08 0.00219511 7.28422e-08 0.00219511 7.60389e-08 0.00219512 7.93903e-08 0.00219512 8.29044e-08 0.00219513 8.65893e-08 0.00219513 9.04539e-08 0.00219514 9.45075e-08 0.00219514 9.87595e-08 0.00219515 1.0322e-07 0.00219515 1.079e-07 0.00219516 1.12811e-07 0.00219517 1.17964e-07 0.00219517 1.23372e-07 0.00219518 1.29048e-07 0.00219519 1.35006e-07 0.0021952 1.4126e-07 0.0021952 1.47826e-07 0.00219521 1.54718e-07 0.00219522 1.61954e-07 0.00219523 1.69551e-07 0.00219524 1.77526e-07 0.00219525 1.85898e-07 0.00219526 1.94687e-07 0.00219527 2.03913e-07 0.00219528 2.13597e-07 0.00219529 2.23762e-07 0.00219531 2.3443e-07 0.00219532 2.45625e-07 0.00219533 2.57373e-07 0.00219535 2.69699e-07 0.00219536 2.82629e-07 0.00219538 2.9619e-07 0.00219539 3.10412e-07 0.00219541 3.25324e-07 0.00219543 3.40955e-07 0.00219545 3.57337e-07 0.00219546 3.74501e-07 0.00219548 3.9248e-07 0.0021955 4.11307e-07 0.00219553 4.31015e-07 0.00219555 4.51638e-07 0.00219557 4.73211e-07 0.0021956 4.95769e-07 0.00219562 5.19347e-07 0.00219565 5.43979e-07 0.00219567 5.69699e-07 0.0021957 5.96542e-07 0.00219573 6.24542e-07 0.00219576 6.53729e-07 0.00219579 6.84135e-07 0.00219583 7.15789e-07 0.00219586 7.48718e-07 0.00219589 7.82945e-07 0.00219593 8.18492e-07 0.00219597 8.55372e-07 0.00219601 8.93603e-07 0.00219605 9.33181e-07 0.00219609 9.7412e-07 0.00219613 1.01638e-06 0.00219618 1.06e-06 0.00219622 1.10486e-06 0.00219627 1.15103e-06 0.00219632 1.1983e-06 0.00219637 1.24681e-06 0.00219642 1.29612e-06 0.00219647 1.34659e-06 0.00219652 1.39741e-06 0.00219658 1.44922e-06 0.00219664 1.5008e-06 0.0021967 1.55299e-06 0.00219676 1.60443e-06 1.65535e-06 0.00225595 4.89821e-08 0.00225595 5.10607e-08 0.00225596 5.32375e-08 0.00225596 5.55178e-08 0.00225596 5.79068e-08 0.00225597 6.041e-08 0.00225597 6.30333e-08 0.00225597 6.5783e-08 0.00225598 6.86655e-08 0.00225598 7.16876e-08 0.00225599 7.48566e-08 0.00225599 7.81799e-08 0.002256 8.16657e-08 0.002256 8.53221e-08 0.00225601 8.91581e-08 0.00225601 9.31829e-08 0.00225602 9.74062e-08 0.00225602 1.01838e-07 0.00225603 1.0649e-07 0.00225604 1.11372e-07 0.00225604 1.16497e-07 0.00225605 1.21877e-07 0.00225606 1.27526e-07 0.00225607 1.33457e-07 0.00225607 1.39685e-07 0.00225608 1.46225e-07 0.00225609 1.53093e-07 0.0022561 1.60305e-07 0.00225611 1.67879e-07 0.00225612 1.75833e-07 0.00225613 1.84185e-07 0.00225614 1.92955e-07 0.00225615 2.02164e-07 0.00225617 2.11834e-07 0.00225618 2.21986e-07 0.00225619 2.32643e-07 0.00225621 2.4383e-07 0.00225622 2.55572e-07 0.00225623 2.67894e-07 0.00225625 2.80824e-07 0.00225627 2.94389e-07 0.00225628 3.08618e-07 0.0022563 3.2354e-07 0.00225632 3.39186e-07 0.00225634 3.55586e-07 0.00225636 3.72773e-07 0.00225638 3.90779e-07 0.0022564 4.09638e-07 0.00225642 4.29383e-07 0.00225644 4.50049e-07 0.00225647 4.7167e-07 0.00225649 4.9428e-07 0.00225652 5.17916e-07 0.00225655 5.4261e-07 0.00225657 5.68399e-07 0.0022566 5.95315e-07 0.00225663 6.23391e-07 0.00225667 6.52658e-07 0.0022567 6.83147e-07 0.00225673 7.14885e-07 0.00225677 7.47897e-07 0.0022568 7.82205e-07 0.00225684 8.17826e-07 0.00225688 8.54777e-07 0.00225692 8.93055e-07 0.00225696 9.32678e-07 0.002257 9.7361e-07 0.00225705 1.01588e-06 0.00225709 1.05938e-06 0.00225714 1.10418e-06 0.00225719 1.15006e-06 0.00225724 1.19717e-06 0.00225729 1.24508e-06 0.00225734 1.29411e-06 0.0022574 1.34348e-06 0.00225745 1.3938e-06 0.00225751 1.44385e-06 0.00225757 1.49444e-06 0.00225763 1.54421e-06 1.59339e-06 0.00231851 4.59367e-08 0.00231851 4.78919e-08 0.00231852 4.994e-08 0.00231852 5.20857e-08 0.00231852 5.43341e-08 0.00231853 5.66905e-08 0.00231853 5.91605e-08 0.00231853 6.17498e-08 0.00231854 6.44649e-08 0.00231854 6.7312e-08 0.00231855 7.02981e-08 0.00231855 7.34304e-08 0.00231856 7.67164e-08 0.00231856 8.01642e-08 0.00231857 8.37821e-08 0.00231857 8.7579e-08 0.00231858 9.15642e-08 0.00231858 9.57473e-08 0.00231859 1.00139e-07 0.0023186 1.04749e-07 0.0023186 1.0959e-07 0.00231861 1.14674e-07 0.00231862 1.20013e-07 0.00231863 1.25621e-07 0.00231864 1.31512e-07 0.00231864 1.37699e-07 0.00231865 1.44199e-07 0.00231866 1.51028e-07 0.00231867 1.582e-07 0.00231868 1.65735e-07 0.00231869 1.73651e-07 0.0023187 1.81966e-07 0.00231871 1.907e-07 0.00231873 1.99873e-07 0.00231874 2.09509e-07 0.00231875 2.19628e-07 0.00231877 2.30255e-07 0.00231878 2.41413e-07 0.00231879 2.53129e-07 0.00231881 2.65427e-07 0.00231883 2.78335e-07 0.00231884 2.91881e-07 0.00231886 3.06094e-07 0.00231888 3.21003e-07 0.0023189 3.36639e-07 0.00231892 3.53034e-07 0.00231894 3.7022e-07 0.00231896 3.88229e-07 0.00231898 4.07095e-07 0.002319 4.26853e-07 0.00231903 4.47536e-07 0.00231905 4.69179e-07 0.00231908 4.91817e-07 0.00231911 5.15485e-07 0.00231914 5.40218e-07 0.00231916 5.6605e-07 0.0023192 5.93014e-07 0.00231923 6.21142e-07 0.00231926 6.50465e-07 0.00231929 6.81013e-07 0.00231933 7.12809e-07 0.00231936 7.45882e-07 0.0023194 7.80244e-07 0.00231944 8.15919e-07 0.00231948 8.52903e-07 0.00231952 8.91218e-07 0.00231957 9.30828e-07 0.00231961 9.71763e-07 0.00231965 1.01392e-06 0.0023197 1.05737e-06 0.00231975 1.10189e-06 0.0023198 1.14764e-06 0.00231985 1.19417e-06 0.0023199 1.24181e-06 0.00231996 1.28978e-06 0.00232001 1.33866e-06 0.00232007 1.38723e-06 0.00232013 1.43629e-06 0.00232019 1.48444e-06 1.5319e-06 0.0023828 4.28318e-08 0.00238281 4.4662e-08 0.00238281 4.65796e-08 0.00238281 4.85893e-08 0.00238282 5.06957e-08 0.00238282 5.29039e-08 0.00238283 5.52191e-08 0.00238283 5.7647e-08 0.00238283 6.01935e-08 0.00238284 6.28647e-08 0.00238284 6.56671e-08 0.00238285 6.86076e-08 0.00238285 7.16934e-08 0.00238286 7.49322e-08 0.00238286 7.83319e-08 0.00238287 8.19009e-08 0.00238287 8.56481e-08 0.00238288 8.95828e-08 0.00238289 9.37149e-08 0.00238289 9.80545e-08 0.0023829 1.02613e-07 0.00238291 1.07401e-07 0.00238292 1.12431e-07 0.00238292 1.17716e-07 0.00238293 1.23269e-07 0.00238294 1.29105e-07 0.00238295 1.35237e-07 0.00238296 1.41682e-07 0.00238297 1.48454e-07 0.00238298 1.55571e-07 0.00238299 1.63051e-07 0.002383 1.70911e-07 0.00238301 1.7917e-07 0.00238302 1.8785e-07 0.00238304 1.9697e-07 0.00238305 2.06552e-07 0.00238306 2.16619e-07 0.00238308 2.27195e-07 0.00238309 2.38303e-07 0.00238311 2.49971e-07 0.00238312 2.62222e-07 0.00238314 2.75086e-07 0.00238316 2.8859e-07 0.00238318 3.02764e-07 0.0023832 3.17637e-07 0.00238322 3.3324e-07 0.00238324 3.49606e-07 0.00238326 3.66766e-07 0.00238328 3.84753e-07 0.0023833 4.03602e-07 0.00238333 4.23347e-07 0.00238335 4.44022e-07 0.00238338 4.65663e-07 0.00238341 4.88304e-07 0.00238343 5.11982e-07 0.00238346 5.36729e-07 0.00238349 5.62581e-07 0.00238353 5.8957e-07 0.00238356 6.17728e-07 0.00238359 6.47087e-07 0.00238363 6.77672e-07 0.00238366 7.09511e-07 0.0023837 7.42621e-07 0.00238374 7.77025e-07 0.00238378 8.12725e-07 0.00238382 8.49743e-07 0.00238386 8.88046e-07 0.00238391 9.27667e-07 0.00238395 9.68507e-07 0.002384 1.01064e-06 0.00238405 1.05383e-06 0.0023841 1.09826e-06 0.00238415 1.14346e-06 0.0023842 1.18978e-06 0.00238425 1.2364e-06 0.00238431 1.28393e-06 0.00238436 1.33109e-06 0.00238442 1.37871e-06 0.00238448 1.42529e-06 1.47109e-06 0.00244888 3.96962e-08 0.00244889 4.14014e-08 0.00244889 4.31886e-08 0.00244889 4.5062e-08 0.0024489 4.70262e-08 0.0024489 4.90858e-08 0.00244891 5.1246e-08 0.00244891 5.35119e-08 0.00244891 5.58892e-08 0.00244892 5.83836e-08 0.00244892 6.10014e-08 0.00244893 6.3749e-08 0.00244893 6.66334e-08 0.00244894 6.96616e-08 0.00244894 7.28414e-08 0.00244895 7.61806e-08 0.00244896 7.96877e-08 0.00244896 8.33715e-08 0.00244897 8.72414e-08 0.00244897 9.13072e-08 0.00244898 9.5579e-08 0.00244899 1.00069e-07 0.002449 1.04789e-07 0.002449 1.0975e-07 0.00244901 1.14965e-07 0.00244902 1.20447e-07 0.00244903 1.2621e-07 0.00244904 1.3227e-07 0.00244905 1.3864e-07 0.00244906 1.45338e-07 0.00244907 1.5238e-07 0.00244908 1.59784e-07 0.00244909 1.67568e-07 0.00244911 1.75751e-07 0.00244912 1.84354e-07 0.00244913 1.93398e-07 0.00244915 2.02904e-07 0.00244916 2.12896e-07 0.00244917 2.23397e-07 0.00244919 2.34431e-07 0.00244921 2.46025e-07 0.00244922 2.58206e-07 0.00244924 2.71e-07 0.00244926 2.84437e-07 0.00244928 2.98545e-07 0.0024493 3.13355e-07 0.00244932 3.28899e-07 0.00244934 3.45208e-07 0.00244936 3.62316e-07 0.00244939 3.80256e-07 0.00244941 3.99061e-07 0.00244944 4.18768e-07 0.00244946 4.39411e-07 0.00244949 4.61025e-07 0.00244952 4.83646e-07 0.00244955 5.0731e-07 0.00244958 5.3205e-07 0.00244961 5.57902e-07 0.00244964 5.84898e-07 0.00244968 6.13071e-07 0.00244971 6.42448e-07 0.00244975 6.7306e-07 0.00244979 7.04925e-07 0.00244982 7.3807e-07 0.00244986 7.72498e-07 0.00244991 8.08236e-07 0.00244995 8.45252e-07 0.00244999 8.83585e-07 0.00245004 9.23136e-07 0.00245008 9.63988e-07 0.00245013 1.0059e-06 0.00245018 1.04907e-06 0.00245023 1.093e-06 0.00245028 1.13809e-06 0.00245034 1.18344e-06 0.00245039 1.22973e-06 0.00245045 1.27559e-06 0.0024505 1.32187e-06 0.00245056 1.367e-06 1.41122e-06 0.0025168 3.64289e-08 0.0025168 3.80058e-08 0.0025168 3.96595e-08 0.00251681 4.13938e-08 0.00251681 4.3213e-08 0.00251681 4.51216e-08 0.00251682 4.71243e-08 0.00251682 4.92262e-08 0.00251683 5.14326e-08 0.00251683 5.37488e-08 0.00251684 5.61808e-08 0.00251684 5.87348e-08 0.00251685 6.14173e-08 0.00251685 6.4235e-08 0.00251686 6.71953e-08 0.00251686 7.03056e-08 0.00251687 7.35741e-08 0.00251688 7.70091e-08 0.00251688 8.06195e-08 0.00251689 8.44147e-08 0.0025169 8.84045e-08 0.0025169 9.25983e-08 0.00251691 9.70078e-08 0.00251692 1.01645e-07 0.00251693 1.06522e-07 0.00251694 1.11652e-07 0.00251695 1.17047e-07 0.00251696 1.22722e-07 0.00251697 1.28692e-07 0.00251698 1.34971e-07 0.00251699 1.41577e-07 0.002517 1.48525e-07 0.00251701 1.55834e-07 0.00251702 1.63523e-07 0.00251704 1.7161e-07 0.00251705 1.80116e-07 0.00251706 1.89062e-07 0.00251708 1.98471e-07 0.00251709 2.08365e-07 0.00251711 2.18768e-07 0.00251712 2.29705e-07 0.00251714 2.41203e-07 0.00251716 2.53287e-07 0.00251718 2.65987e-07 0.0025172 2.79331e-07 0.00251722 2.93349e-07 0.00251724 3.08071e-07 0.00251726 3.2353e-07 0.00251728 3.39758e-07 0.0025173 3.56788e-07 0.00251733 3.74655e-07 0.00251735 3.93393e-07 0.00251738 4.13038e-07 0.00251741 4.33626e-07 0.00251744 4.55192e-07 0.00251747 4.77772e-07 0.0025175 5.01403e-07 0.00251753 5.2612e-07 0.00251756 5.51957e-07 0.0025176 5.78948e-07 0.00251763 6.07123e-07 0.00251767 6.36515e-07 0.00251771 6.67145e-07 0.00251774 6.99044e-07 0.00251778 7.32216e-07 0.00251783 7.66694e-07 0.00251787 8.02448e-07 0.00251791 8.39526e-07 0.00251796 8.77826e-07 0.00251801 9.17447e-07 0.00251805 9.5814e-07 0.0025181 1.00012e-06 0.00251815 1.04287e-06 0.0025182 1.08682e-06 0.00251826 1.13103e-06 0.00251831 1.17622e-06 0.00251836 1.2209e-06 0.00251842 1.26604e-06 0.00251848 1.30981e-06 1.35257e-06 0.0025866 3.31549e-08 0.0025866 3.46048e-08 0.0025866 3.61256e-08 0.00258661 3.77212e-08 0.00258661 3.93956e-08 0.00258662 4.11531e-08 0.00258662 4.29982e-08 0.00258662 4.49353e-08 0.00258663 4.69696e-08 0.00258663 4.91061e-08 0.00258664 5.13505e-08 0.00258664 5.37084e-08 0.00258665 5.61861e-08 0.00258665 5.87898e-08 0.00258666 6.15265e-08 0.00258666 6.44031e-08 0.00258667 6.74274e-08 0.00258668 7.0607e-08 0.00258668 7.39506e-08 0.00258669 7.74667e-08 0.0025867 8.11646e-08 0.00258671 8.50567e-08 0.00258671 8.91528e-08 0.00258672 9.34627e-08 0.00258673 9.79982e-08 0.00258674 1.02771e-07 0.00258675 1.07795e-07 0.00258676 1.13081e-07 0.00258677 1.18646e-07 0.00258678 1.24503e-07 0.00258679 1.30668e-07 0.0025868 1.37157e-07 0.00258681 1.43987e-07 0.00258682 1.51176e-07 0.00258684 1.58743e-07 0.00258685 1.66707e-07 0.00258687 1.75088e-07 0.00258688 1.83909e-07 0.00258689 1.93191e-07 0.00258691 2.02958e-07 0.00258693 2.13234e-07 0.00258694 2.24045e-07 0.00258696 2.35416e-07 0.00258698 2.47375e-07 0.002587 2.59951e-07 0.00258702 2.73172e-07 0.00258704 2.87069e-07 0.00258706 3.01674e-07 0.00258709 3.1702e-07 0.00258711 3.33138e-07 0.00258713 3.50063e-07 0.00258716 3.67831e-07 0.00258719 3.86477e-07 0.00258721 4.06037e-07 0.00258724 4.26548e-07 0.00258727 4.48046e-07 0.0025873 4.70569e-07 0.00258734 4.94153e-07 0.00258737 5.18835e-07 0.0025874 5.44651e-07 0.00258744 5.71632e-07 0.00258747 5.99814e-07 0.00258751 6.29222e-07 0.00258755 6.59891e-07 0.00258759 6.91827e-07 0.00258763 7.25071e-07 0.00258768 7.59595e-07 0.00258772 7.95458e-07 0.00258777 8.32555e-07 0.00258781 8.71005e-07 0.00258786 9.10546e-07 0.00258791 9.51431e-07 0.00258796 9.93102e-07 0.00258801 1.03606e-06 0.00258806 1.07926e-06 0.00258811 1.12357e-06 0.00258817 1.16727e-06 0.00258822 1.21151e-06 0.00258828 1.25419e-06 1.29571e-06 0.00265833 2.95831e-08 0.00265833 3.09008e-08 0.00265834 3.22848e-08 0.00265834 3.37383e-08 0.00265835 3.5265e-08 0.00265835 3.68691e-08 0.00265835 3.85545e-08 0.00265836 4.03258e-08 0.00265836 4.21875e-08 0.00265837 4.41445e-08 0.00265837 4.62021e-08 0.00265838 4.83657e-08 0.00265839 5.0641e-08 0.00265839 5.30341e-08 0.0026584 5.55514e-08 0.0026584 5.81998e-08 0.00265841 6.09862e-08 0.00265842 6.39184e-08 0.00265842 6.70042e-08 0.00265843 7.02521e-08 0.00265844 7.3671e-08 0.00265845 7.72671e-08 0.00265845 8.10517e-08 0.00265846 8.50366e-08 0.00265847 8.92327e-08 0.00265848 9.36514e-08 0.00265849 9.83049e-08 0.0026585 1.03206e-07 0.00265851 1.08368e-07 0.00265852 1.13804e-07 0.00265853 1.19531e-07 0.00265854 1.25562e-07 0.00265856 1.31916e-07 0.00265857 1.38607e-07 0.00265858 1.45656e-07 0.00265859 1.5308e-07 0.00265861 1.60899e-07 0.00265862 1.69134e-07 0.00265864 1.77806e-07 0.00265865 1.86939e-07 0.00265867 1.96555e-07 0.00265869 2.0668e-07 0.00265871 2.17339e-07 0.00265873 2.28558e-07 0.00265875 2.40367e-07 0.00265877 2.52793e-07 0.00265879 2.65866e-07 0.00265881 2.79618e-07 0.00265883 2.94082e-07 0.00265886 3.09289e-07 0.00265888 3.25274e-07 0.00265891 3.42073e-07 0.00265893 3.59721e-07 0.00265896 3.78256e-07 0.00265899 3.97713e-07 0.00265902 4.18132e-07 0.00265905 4.39551e-07 0.00265908 4.62008e-07 0.00265912 4.85541e-07 0.00265915 5.10188e-07 0.00265919 5.35985e-07 0.00265922 5.6297e-07 0.00265926 5.91171e-07 0.0026593 6.20628e-07 0.00265934 6.51353e-07 0.00265938 6.83391e-07 0.00265943 7.1672e-07 0.00265947 7.51412e-07 0.00265951 7.87359e-07 0.00265956 8.24708e-07 0.00265961 8.63178e-07 0.00265966 9.03079e-07 0.00265971 9.4379e-07 0.00265976 9.85938e-07 0.00265981 1.0283e-06 0.00265986 1.07201e-06 0.00265991 1.11495e-06 0.00265996 1.15872e-06 0.00266002 1.20038e-06 1.24096e-06 0.00273207 2.61463e-08 0.00273207 2.73346e-08 0.00273207 2.85829e-08 0.00273208 2.98948e-08 0.00273208 3.12738e-08 0.00273209 3.27235e-08 0.00273209 3.42477e-08 0.00273209 3.58506e-08 0.0027321 3.75364e-08 0.0027321 3.93096e-08 0.00273211 4.1175e-08 0.00273211 4.31377e-08 0.00273212 4.52029e-08 0.00273213 4.73762e-08 0.00273213 4.96637e-08 0.00273214 5.20715e-08 0.00273214 5.46061e-08 0.00273215 5.72747e-08 0.00273216 6.00844e-08 0.00273216 6.30429e-08 0.00273217 6.61584e-08 0.00273218 6.94453e-08 0.00273219 7.29111e-08 0.0027322 7.65633e-08 0.00273221 8.04123e-08 0.00273221 8.44689e-08 0.00273222 8.87447e-08 0.00273223 9.32517e-08 0.00273224 9.80026e-08 0.00273226 1.03011e-07 0.00273227 1.08291e-07 0.00273228 1.13857e-07 0.00273229 1.19725e-07 0.0027323 1.25911e-07 0.00273232 1.32433e-07 0.00273233 1.39309e-07 0.00273234 1.46557e-07 0.00273236 1.54198e-07 0.00273238 1.62253e-07 0.00273239 1.70744e-07 0.00273241 1.79693e-07 0.00273243 1.89125e-07 0.00273244 1.99064e-07 0.00273246 2.09538e-07 0.00273248 2.20573e-07 0.0027325 2.32197e-07 0.00273252 2.44441e-07 0.00273255 2.57336e-07 0.00273257 2.70913e-07 0.00273259 2.85205e-07 0.00273262 3.00247e-07 0.00273265 3.16074e-07 0.00273267 3.32723e-07 0.0027327 3.50231e-07 0.00273273 3.68636e-07 0.00273276 3.87977e-07 0.00273279 4.08294e-07 0.00273282 4.29627e-07 0.00273286 4.52017e-07 0.00273289 4.75504e-07 0.00273293 5.00126e-07 0.00273296 5.25927e-07 0.002733 5.52937e-07 0.00273304 5.81202e-07 0.00273308 6.1074e-07 0.00273312 6.41604e-07 0.00273317 6.73777e-07 0.00273321 7.07345e-07 0.00273326 7.42202e-07 0.0027333 7.78524e-07 0.00273335 8.16014e-07 0.0027334 8.5505e-07 0.00273345 8.94944e-07 0.0027335 9.36479e-07 0.00273355 9.78241e-07 0.0027336 1.02168e-06 0.00273365 1.06424e-06 0.0027337 1.10808e-06 0.00273375 1.14963e-06 1.19009e-06 0.00280784 2.20847e-08 0.00280784 2.31476e-08 0.00280785 2.42662e-08 0.00280785 2.54433e-08 0.00280786 2.66819e-08 0.00280786 2.79853e-08 0.00280787 2.93572e-08 0.00280787 3.08013e-08 0.00280788 3.23215e-08 0.00280788 3.3922e-08 0.00280789 3.56074e-08 0.00280789 3.73822e-08 0.0028079 3.92514e-08 0.00280791 4.12204e-08 0.00280791 4.32947e-08 0.00280792 4.54802e-08 0.00280793 4.77834e-08 0.00280793 5.02109e-08 0.00280794 5.27698e-08 0.00280795 5.5468e-08 0.00280796 5.83137e-08 0.00280796 6.13065e-08 0.00280797 6.44589e-08 0.00280798 6.77841e-08 0.00280799 7.12917e-08 0.002808 7.4992e-08 0.00280801 7.88959e-08 0.00280802 8.30148e-08 0.00280803 8.73608e-08 0.00280804 9.19466e-08 0.00280805 9.67856e-08 0.00280807 1.01892e-07 0.00280808 1.07281e-07 0.00280809 1.12968e-07 0.0028081 1.18969e-07 0.00280812 1.25302e-07 0.00280813 1.31985e-07 0.00280815 1.39038e-07 0.00280816 1.46481e-07 0.00280818 1.54334e-07 0.0028082 1.62621e-07 0.00280821 1.71365e-07 0.00280823 1.80589e-07 0.00280825 1.90321e-07 0.00280827 2.00586e-07 0.00280829 2.11413e-07 0.00280831 2.22831e-07 0.00280834 2.34871e-07 0.00280836 2.47564e-07 0.00280838 2.60944e-07 0.00280841 2.75045e-07 0.00280844 2.89903e-07 0.00280846 3.05554e-07 0.00280849 3.22038e-07 0.00280852 3.39392e-07 0.00280855 3.57659e-07 0.00280858 3.76877e-07 0.00280862 3.97091e-07 0.00280865 4.18342e-07 0.00280868 4.40675e-07 0.00280872 4.64131e-07 0.00280876 4.88756e-07 0.0028088 5.14588e-07 0.00280883 5.41677e-07 0.00280888 5.70048e-07 0.00280892 5.99762e-07 0.00280896 6.30812e-07 0.002809 6.63293e-07 0.00280905 6.97115e-07 0.0028091 7.3247e-07 0.00280914 7.69074e-07 0.00280919 8.07346e-07 0.00280924 8.46582e-07 0.00280929 8.87695e-07 0.00280934 9.29118e-07 0.00280939 9.72713e-07 0.00280943 1.01528e-06 0.00280948 1.06012e-06 0.00280953 1.10111e-06 1.14303e-06 0.00288574 0.00288574 0.00288575 0.00288575 0.00288576 0.00288576 0.00288576 0.00288577 0.00288577 0.00288578 0.00288578 0.00288579 0.00288579 0.0028858 0.00288581 0.00288581 0.00288582 0.00288582 0.00288583 0.00288584 0.00288585 0.00288585 0.00288586 0.00288587 0.00288588 0.00288589 0.0028859 0.00288591 0.00288592 0.00288593 0.00288594 0.00288595 0.00288597 0.00288598 0.00288599 0.00288601 0.00288602 0.00288603 0.00288605 0.00288607 0.00288608 0.0028861 0.00288612 0.00288614 0.00288616 0.00288618 0.0028862 0.00288622 0.00288625 0.00288627 0.0028863 0.00288632 0.00288635 0.00288638 0.00288641 0.00288644 0.00288647 0.0028865 0.00288654 0.00288657 0.00288661 0.00288665 0.00288669 0.00288673 0.00288677 0.00288681 0.00288685 0.0028869 0.00288694 0.00288699 0.00288703 0.00288708 0.00288713 0.00288718 0.00288723 0.00288728 0.00288732 0.00288737 0.00288741 ) ; boundaryField { inlet { type calculated; value nonuniform List<scalar> 100 ( -0.000192367 -0.000197702 -0.000203184 -0.000208819 -0.00021461 -0.000220561 -0.000226678 -0.000232964 -0.000239425 -0.000246064 -0.000252888 -0.000259901 -0.000267108 -0.000274516 -0.000282128 -0.000289952 -0.000297993 -0.000306257 -0.00031475 -0.000323478 -0.000332449 -0.000341668 -0.000351143 -0.000360881 -0.000370889 -0.000381174 -0.000391745 -0.000402609 -0.000413774 -0.000425248 -0.000437041 -0.000449161 -0.000461617 -0.000474418 -0.000487575 -0.000501096 -0.000514992 -0.000529274 -0.000543951 -0.000559036 -0.000574539 -0.000590472 -0.000606846 -0.000623675 -0.000640971 -0.000658746 -0.000677014 -0.000695789 -0.000715084 -0.000734914 -0.000755295 -0.00077624 -0.000797767 -0.00081989 -0.000842627 -0.000865994 -0.00089001 -0.000914691 -0.000940057 -0.000966126 -0.000992918 -0.00102045 -0.00104875 -0.00107784 -0.00110773 -0.00113844 -0.00117002 -0.00120246 -0.00123581 -0.00127008 -0.0013053 -0.0013415 -0.0013787 -0.00141693 -0.00145623 -0.00149661 -0.00153812 -0.00158077 -0.00162461 -0.00166966 -0.00171596 -0.00176355 -0.00181245 -0.00186272 -0.00191437 -0.00196746 -0.00202202 -0.0020781 -0.00213573 -0.00219495 -0.00225582 -0.00231838 -0.00238267 -0.00244875 -0.00251665 -0.00258645 -0.00265817 -0.00273189 -0.00280765 -0.00288551 ) ; } outlet { type calculated; value nonuniform List<scalar> 100 ( 0.000155258 0.000178404 0.00018985 0.000198688 0.000206469 0.000213794 0.000220931 0.000228016 0.000235127 0.000242311 0.000249602 0.000257021 0.000264588 0.000272317 0.000280221 0.000288308 0.000296591 0.000305077 0.000313775 0.000322694 0.00033184 0.000341224 0.000350851 0.000360731 0.000370871 0.000381279 0.000391964 0.000402934 0.000414197 0.000425763 0.00043764 0.000449838 0.000462365 0.000475232 0.000488449 0.000502025 0.000515972 0.0005303 0.000545021 0.000560145 0.000575685 0.000591652 0.000608059 0.000624918 0.000642242 0.000660045 0.00067834 0.00069714 0.00071646 0.000736315 0.000756719 0.000777688 0.000799237 0.000821383 0.000844142 0.00086753 0.000891566 0.000916268 0.000941653 0.000967742 0.000994553 0.00102211 0.00105042 0.00107952 0.00110943 0.00114016 0.00117175 0.00120421 0.00123757 0.00127185 0.00130708 0.00134329 0.0013805 0.00141875 0.00145805 0.00149844 0.00153995 0.00158261 0.00162645 0.00167151 0.00171782 0.00176541 0.00181431 0.00186458 0.00191624 0.00196933 0.00202389 0.00207996 0.00213759 0.00219682 0.00225769 0.00232025 0.00238454 0.00245062 0.00251854 0.00258833 0.00266007 0.0027338 0.00280958 0.00288745 ) ; } wall { type calculated; value nonuniform List<scalar> 100 ( 0 7.54782e-09 1.57214e-08 2.27302e-08 2.81853e-08 3.21295e-08 3.47107e-08 3.61105e-08 3.65242e-08 3.61443e-08 3.515e-08 3.37011e-08 3.19353e-08 2.99676e-08 2.7904e-08 2.58626e-08 2.38061e-08 2.17874e-08 1.98441e-08 1.79995e-08 1.8669e-08 1.96075e-08 2.05948e-08 2.16343e-08 2.27287e-08 2.38811e-08 2.50945e-08 2.63723e-08 2.77181e-08 2.91354e-08 3.06283e-08 3.22009e-08 3.38575e-08 3.56028e-08 3.74418e-08 3.93797e-08 4.1422e-08 4.35746e-08 4.5844e-08 4.82367e-08 5.07601e-08 5.3435e-08 5.62654e-08 5.92545e-08 6.24113e-08 6.57456e-08 6.92676e-08 7.29879e-08 7.6918e-08 8.107e-08 8.54566e-08 9.00913e-08 9.49882e-08 1.00162e-07 1.0563e-07 1.11406e-07 1.17511e-07 1.23961e-07 1.30776e-07 1.37978e-07 1.45587e-07 1.53626e-07 1.6212e-07 1.71093e-07 1.80572e-07 1.90584e-07 2.01159e-07 2.12327e-07 2.24119e-07 2.3657e-07 2.49713e-07 2.63584e-07 2.78221e-07 2.93664e-07 3.09951e-07 3.27126e-07 3.45231e-07 3.6431e-07 3.84409e-07 4.05575e-07 4.27853e-07 4.51293e-07 4.7594e-07 5.01848e-07 5.29052e-07 5.57618e-07 5.87556e-07 6.18966e-07 6.51785e-07 6.86205e-07 7.21994e-07 7.59561e-07 7.9829e-07 8.39093e-07 8.80513e-07 9.24538e-07 9.67964e-07 1.01496e-06 1.05877e-06 1.10635e-06 ) ; } center { type symmetry; value uniform 0; } plate { type calculated; value uniform 0; } defaultFaces { type empty; value nonuniform 0(); } } // ************************************************************************* //
[ "brennankharris@gmail.com" ]
brennankharris@gmail.com
2a835182855c3a1f12a042cc97e8b534f510b9d4
de322ee3c27143b8c9b0d2a043bbe6b9366bd7aa
/ARMY.cpp
48c62d39589ba10dea67b43437d5d1f6db846fb8
[]
no_license
trivedipankaj/Spoj
a413688060cdcf735fc5cd84d865ddca0caf727b
9dd6705a2ebf716a485b880d8b2021990ead0c59
refs/heads/master
2021-01-11T11:09:09.909414
2014-08-15T18:14:02
2014-08-15T18:14:02
22,998,578
0
1
null
null
null
null
UTF-8
C++
false
false
864
cpp
#include<iostream> #include<vector> #include<algorithm> #include <cstdio> using namespace std; main(){ int c; scanf("%d",&c); while(c--){ int n,m; scanf("%d %d",&n,&m); int g[n],mg[m]; for(int i=0; i<n;i++) scanf("%d",&g[i]); for(int i=0; i<m;i++) scanf("%d",&mg[i]); sort(g,g+n); sort(mg,mg+m); int i=0,j=0; while( i<n && j<m){ if(g[i] < mg[j]) i++; else if(g[i] >= mg[j]) j++; } if(i==n) cout<<"MechaGodzilla\n"; else cout<<"Godzilla\n"; } }
[ "trivedi.pankaj8@gmail.com" ]
trivedi.pankaj8@gmail.com
a4b6951e292a0705dfc8529ae56d22bc23702f06
4aad3dadb1f630ec091d98f748f79bd379f5d479
/SDLAppTest/main.cpp
2b120483443eb0cc99ca9a194d27330c31aa15e3
[]
no_license
eriksvedang/SDLAppTest
9e3b186d8d94fc408ab5f2dbbaad39c653a0b78e
60abf0c4eaf71a0b7754cc31e8af4cb135b1c990
refs/heads/master
2021-03-12T19:36:48.977873
2015-04-29T07:19:47
2015-04-29T07:19:47
33,505,311
0
1
null
null
null
null
UTF-8
C++
false
false
3,191
cpp
#include <iostream> #include <GL/glew.h> #include <SDL2/SDL.h> #include <SDL2/SDL_image.h> #include "Boilerplate.h" #include "ShaderLoader.h" #include "ResourcePath.h" #include "VboHelper.h" void game3() { Boilerplate::App app = Boilerplate::start(480, 480, "Game 3"); GLuint program = ShaderLoader::createProgram(getResourcePath("triangle.v", "glsl"), getResourcePath("triangle.f", "glsl")); float data[] = { -0.8, 0.8, 0, 1, 0, 1, 0.8, 0.9, 0, 1, 1, 0, 0.0, -0.8, 0, 0, 1, 1, -0.7, -0.7, 0, 1, 0, 1, 0.7, -0.7, 0, 1, 1, 0, 0.0, 0.7, 0, 0, 1, 1 }; float data2[] = { -0.2, 0.8, 0, 1, 0, 1, 0.8, 0.2, 0, 1, 1, 0, 0.0, -0.8, 0, 0, 1, 1, -0.7, -0.7, 0, 1, 0, 1, 0.2, -0.7, 0, 1, 1, 0, 0.0, 0.2, 0, 0, 1, 1 }; GLuint vao1, vao2; glGenVertexArrays(1, &vao1); glGenVertexArrays(1, &vao2); glBindVertexArray(vao1); GLuint vbo = VboHelper::makeVbo(sizeof(data), data); GLint attribute_coord3d = ShaderLoader::getAttribute(program, "coord3d"); GLint attribute_color = ShaderLoader::getAttribute(program, "v_color"); GLint uniform_translate = glGetUniformLocation(program, "translate"); glBindBuffer(GL_ARRAY_BUFFER, vbo); glEnableVertexAttribArray(attribute_coord3d); glEnableVertexAttribArray(attribute_color); glVertexAttribPointer(attribute_coord3d, 3, GL_FLOAT, GL_FALSE, sizeof(float) * 6, 0); glVertexAttribPointer(attribute_color, 3, GL_FLOAT, GL_FALSE, sizeof(float) * 6, (GLvoid*)(sizeof(float) * 3)); // VAO 2 glBindVertexArray(vao2); GLuint vbo2 = VboHelper::makeVbo(sizeof(data2), data2); glBindBuffer(GL_ARRAY_BUFFER, vbo2); glEnableVertexAttribArray(attribute_coord3d); glEnableVertexAttribArray(attribute_color); glVertexAttribPointer(attribute_coord3d, 3, GL_FLOAT, GL_FALSE, sizeof(float) * 6, 0); glVertexAttribPointer(attribute_color, 3, GL_FLOAT, GL_FALSE, sizeof(float) * 6, (GLvoid*)(sizeof(float) * 3)); //glDisableVertexAttribArray(attribute_coord3d); //glDisableVertexAttribArray(attribute_color); glEnable(GL_BLEND); glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); glClearColor(0.9, 1.0, 0.98, 1.0); app.render = [&]() { glUseProgram(program); glClear(GL_COLOR_BUFFER_BIT); glBindVertexArray(vao1); glUniform3f(uniform_translate, 0.0, 0.0, 0.0); glDrawArrays(GL_TRIANGLES, 0, 6); glBindVertexArray(vao2); glUniform3f(uniform_translate, 0.5, 0.0, 0.0); glDrawArrays(GL_TRIANGLES, 0, 6); glUniform3f(uniform_translate, 0.6, 0.0, 0.0); glDrawArrays(GL_TRIANGLES, 0, 6); glUniform3f(uniform_translate, 0.7, 0.0, 0.0); glDrawArrays(GL_TRIANGLES, 0, 6); }; app.tick = [&](float dt) { }; Boilerplate::loop(app); Boilerplate::stop(app); } int main() { game3(); }
[ "erik.svedang@gmail.com" ]
erik.svedang@gmail.com
798b10d9d3bcecc62387d27ef8977b414d2cb2e8
a5d4e67e63919d97f017ff905566f56a0c06e58e
/Game.h
538684dbc256aea41ad39f8f182a9209dcda4b44
[]
no_license
LexSheyn/SFML_01
3821b56a05947902162bc20d0809927a4df5db76
65fe86ce909d5825e70a4bda59a09c9abb2da165
refs/heads/master
2023-07-19T06:54:23.754897
2021-09-20T10:53:37
2021-09-20T10:53:37
408,406,200
0
0
null
null
null
null
UTF-8
C++
false
false
1,524
h
#pragma once #include <iostream> #include <vector> #include <ctime> #include <sstream> #include <SFML/Graphics.hpp> #include <SFML/System.hpp> #include <SFML/Window.hpp> #include <SFML/Audio.hpp> #include <SFML/Network.hpp> /* Class that acts like a game engine. Wrapper class. */ class Game { private: //Variables //Window sf::RenderWindow* window; sf::VideoMode videoMode; sf::Event ev; //Mouse positions sf::Vector2i mousePosWindow; sf::Vector2f mousePosView; //Resoueces sf::Font font; sf::Font fontPoints; sf::Font fontHealth; //Text sf::Text uiText; sf::Text uiTextPoints; sf::Text uiTextHealth; //Colors sf::Color color; sf::Color VeryHard; sf::Color Hard; sf::Color Medium; sf::Color Easy; sf::Color VeryEasy; //Game logic bool endGame; unsigned points; int health; float enemySize; float enemySpawnTimer; float enemySpawnTimerMax; int maxEnemies; bool mouseHeld; //Game objects std::vector<sf::RectangleShape> enemies; sf::RectangleShape enemy; //Private functions void InitVariables(); void InitWindow(); void InitFonts(); void InitText(); void InitEnemies(); public: //Constructors and Distructors Game(); virtual ~Game(); //Accessors const bool running() const; const bool getEndGame() const; //Functions void spawnEnemy(); void pollEvents(); void updateMousePositions(); void updateText(); void updateEnemies(); void update(); void renderText(sf::RenderTarget& target); void renderEnemies(sf::RenderTarget& target); void render(); };
[ "tiadec@gmail.com" ]
tiadec@gmail.com
9aa4f6c69d0f77ee3aa735b931a5a7c5d3503f0a
4bea57e631734f8cb1c230f521fd523a63c1ff23
/projects/openfoam/programming/AutoCase/cases/cavity/test/case/0/dsmcSigmaTcRMax
2660010326c7aa19bddcab433144277087c7aedd
[]
no_license
andytorrestb/cfal
76217f77dd43474f6b0a7eb430887e8775b78d7f
730fb66a3070ccb3e0c52c03417e3b09140f3605
refs/heads/master
2023-07-04T01:22:01.990628
2021-08-01T15:36:17
2021-08-01T15:36:17
294,183,829
1
0
null
null
null
null
UTF-8
C++
false
false
1,207
/*--------------------------------*- C++ -*----------------------------------*\ | ========= | | | \\ / F ield | OpenFOAM: The Open Source CFD Toolbox | | \\ / O peration | Version: v2012 | | \\ / A nd | Website: www.openfoam.com | | \\/ M anipulation | | \*---------------------------------------------------------------------------*/ FoamFile { version 2.0; format ascii; class volScalarField; location "0"; object dsmcSigmaTcRMax; } // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // dimensions [0 3 -1 0 0 0 0]; internalField uniform 2.30575378384293e-16; boundaryField { inlet { type zeroGradient; } outlet { type zeroGradient; } wall { type zeroGradient; } frontAndBack { type empty; } } // ************************************************************************* //
[ "andytorrestb@gmail.com" ]
andytorrestb@gmail.com
17f16ef3317cc383730b0d904cacae9334246626
d6b4bdf418ae6ab89b721a79f198de812311c783
/tcss/include/tencentcloud/tcss/v20201101/model/DescribeNetworkFirewallPolicyListRequest.h
fcb42cf7095ea887ded35309f657811cbd2ca44c
[ "Apache-2.0" ]
permissive
TencentCloud/tencentcloud-sdk-cpp-intl-en
d0781d461e84eb81775c2145bacae13084561c15
d403a6b1cf3456322bbdfb462b63e77b1e71f3dc
refs/heads/master
2023-08-21T12:29:54.125071
2023-08-21T01:12:39
2023-08-21T01:12:39
277,769,407
2
0
null
null
null
null
UTF-8
C++
false
false
7,675
h
/* * Copyright (c) 2017-2019 THL A29 Limited, a Tencent company. 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 applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ #ifndef TENCENTCLOUD_TCSS_V20201101_MODEL_DESCRIBENETWORKFIREWALLPOLICYLISTREQUEST_H_ #define TENCENTCLOUD_TCSS_V20201101_MODEL_DESCRIBENETWORKFIREWALLPOLICYLISTREQUEST_H_ #include <string> #include <vector> #include <map> #include <tencentcloud/core/AbstractModel.h> #include <tencentcloud/tcss/v20201101/model/ComplianceFilters.h> namespace TencentCloud { namespace Tcss { namespace V20201101 { namespace Model { /** * DescribeNetworkFirewallPolicyList request structure. */ class DescribeNetworkFirewallPolicyListRequest : public AbstractModel { public: DescribeNetworkFirewallPolicyListRequest(); ~DescribeNetworkFirewallPolicyListRequest() = default; std::string ToJsonString() const; /** * 获取Cluster ID * @return ClusterId Cluster ID * */ std::string GetClusterId() const; /** * 设置Cluster ID * @param _clusterId Cluster ID * */ void SetClusterId(const std::string& _clusterId); /** * 判断参数 ClusterId 是否已赋值 * @return ClusterId 是否已赋值 * */ bool ClusterIdHasBeenSet() const; /** * 获取Offset * @return Offset Offset * */ uint64_t GetOffset() const; /** * 设置Offset * @param _offset Offset * */ void SetOffset(const uint64_t& _offset); /** * 判断参数 Offset 是否已赋值 * @return Offset 是否已赋值 * */ bool OffsetHasBeenSet() const; /** * 获取Maximum number of records per query * @return Limit Maximum number of records per query * */ uint64_t GetLimit() const; /** * 设置Maximum number of records per query * @param _limit Maximum number of records per query * */ void SetLimit(const uint64_t& _limit); /** * 判断参数 Limit 是否已赋值 * @return Limit 是否已赋值 * */ bool LimitHasBeenSet() const; /** * 获取Name - String Name. Valid values: `ClusterName`, `ClusterId`, `ClusterType`, `Region`, `ClusterCheckMode`, `ClusterAutoCheck`. * @return Filters Name - String Name. Valid values: `ClusterName`, `ClusterId`, `ClusterType`, `Region`, `ClusterCheckMode`, `ClusterAutoCheck`. * */ std::vector<ComplianceFilters> GetFilters() const; /** * 设置Name - String Name. Valid values: `ClusterName`, `ClusterId`, `ClusterType`, `Region`, `ClusterCheckMode`, `ClusterAutoCheck`. * @param _filters Name - String Name. Valid values: `ClusterName`, `ClusterId`, `ClusterType`, `Region`, `ClusterCheckMode`, `ClusterAutoCheck`. * */ void SetFilters(const std::vector<ComplianceFilters>& _filters); /** * 判断参数 Filters 是否已赋值 * @return Filters 是否已赋值 * */ bool FiltersHasBeenSet() const; /** * 获取Sorting field * @return By Sorting field * */ std::string GetBy() const; /** * 设置Sorting field * @param _by Sorting field * */ void SetBy(const std::string& _by); /** * 判断参数 By 是否已赋值 * @return By 是否已赋值 * */ bool ByHasBeenSet() const; /** * 获取Sorting order. Valid values: `asc`, `desc`. * @return Order Sorting order. Valid values: `asc`, `desc`. * */ std::string GetOrder() const; /** * 设置Sorting order. Valid values: `asc`, `desc`. * @param _order Sorting order. Valid values: `asc`, `desc`. * */ void SetOrder(const std::string& _order); /** * 判断参数 Order 是否已赋值 * @return Order 是否已赋值 * */ bool OrderHasBeenSet() const; private: /** * Cluster ID */ std::string m_clusterId; bool m_clusterIdHasBeenSet; /** * Offset */ uint64_t m_offset; bool m_offsetHasBeenSet; /** * Maximum number of records per query */ uint64_t m_limit; bool m_limitHasBeenSet; /** * Name - String Name. Valid values: `ClusterName`, `ClusterId`, `ClusterType`, `Region`, `ClusterCheckMode`, `ClusterAutoCheck`. */ std::vector<ComplianceFilters> m_filters; bool m_filtersHasBeenSet; /** * Sorting field */ std::string m_by; bool m_byHasBeenSet; /** * Sorting order. Valid values: `asc`, `desc`. */ std::string m_order; bool m_orderHasBeenSet; }; } } } } #endif // !TENCENTCLOUD_TCSS_V20201101_MODEL_DESCRIBENETWORKFIREWALLPOLICYLISTREQUEST_H_
[ "tencentcloudapi@tencent.com" ]
tencentcloudapi@tencent.com
ecfdeb0fd1b628e3486f7745319db3a98084724b
6a070489af967c0434589854621316e0615b7f84
/360/2lab360/reference/threadp.cpp
97b23becc09c76201cd1a253fb1d55367558e1b5
[]
no_license
jbelyeu/old_class_code
5fbfcfc0687bb8a9e16234eace72db61b31e3287
6a3afb5d795b7d6aca5e6885394f84f0a5a141ee
refs/heads/master
2021-01-10T08:55:34.728873
2016-03-30T23:25:19
2016-03-30T23:25:19
54,907,018
0
0
null
null
null
null
UTF-8
C++
false
false
1,631
cpp
#include <stdio.h> #include <iostream> #include <unistd.h> #include <queue> #include <pthread.h> #include <semaphore.h> using namespace std; struct threadInfo { int threadID; int stuff; double dubStuff; }; const int THREADS = 20; sem_t mutex; //mutual exclusion sem_t space_on_q; sem_t num_of_tasks; queue<int > tasks; void* serve(void* pointer) { // for the consumer threads to do struct threadInfo* myInfo = (struct threadInfo* ) pointer; while ( 1 ) { sem_wait(&num_of_tasks); //while there are no tasks, wait //wait for queue to be available sem_wait(&mutex); cout << "I am thread: " << myInfo->threadID << endl; int thing = tasks.front(); tasks.pop(); cout << "things to do : " << thing << endl; sem_post(&mutex); //let go of queue sem_post(&space_on_q); //read request //parse headers //get file //write response to client //close() socket } } int main(int argc, char* argv[]) { cout << "main" << endl; struct threadInfo* myThreads[THREADS]; pthread_t threads [THREADS]; sem_init(&space_on_q, 0, 100); sem_init(&num_of_tasks, 0, 0); sem_init(&mutex, 0, 1); for (int i = 0; i < THREADS; ++i) { sem_wait(&mutex); cout << "creating thread " << i << endl; myThreads[i]->threadID = i; pthread_create(&threads[i], NULL, serve, &myThreads); sem_post(&mutex); } int counter = 0; while(1) { sem_wait(&space_on_q); //limits the number of requests allowed, down to queue size //this is where the producer works sem_wait(&mutex); tasks.push(counter); sem_post(&mutex); sem_post(&num_of_tasks); //there is a task now counter++; } }
[ "jbelyeu@colorado.cs.byu.edu" ]
jbelyeu@colorado.cs.byu.edu
ab482049ac26297e1c8275a5e1849136e7268dec
af21605135880c64243458beea3def0e01789427
/light_clap/light_clap/adc_funcs.ino
325fc469c1c5d2412677b81c4b8780e5ef17eb94
[]
no_license
YuriiMytiai/arduino
193b5c891a1d85288857aa8aff9a8b1f8292c601
cf303c130ad7a07f13634e3d0429107fb274b5be
refs/heads/master
2021-04-05T16:41:27.555709
2018-03-18T08:16:59
2018-03-18T08:16:59
125,252,850
0
0
null
null
null
null
UTF-8
C++
false
false
591
ino
double calc_RMS(int len) { // len max value - 1024 double sqr_sum = 0; double U_ref = 0.707; double U_value; for (int i = 0 ; i < len ; i++) { // save some samples while(!(ADCSRA & 0x10)); // wait for adc to be ready ADCSRA = 0xf5; // restart adc byte low = ADCL; // fetch adc data (low byte) byte high = ADCH; // fetch adc data (high byte) int value = (high << 8) | low; // combine the two bytes U_value = (double) value / 1024 * 5; sqr_sum += U_value * U_value; } double sqr_mean = sqr_sum / len; double sqrt_val = sqrt(sqr_mean); return 10 * log10(sqrt_val / U_ref); }
[ "yuriimytiai@gmail.com" ]
yuriimytiai@gmail.com
e760ccf03e140751e3552000ca2ab9674eb6eba5
cf018101493315ac53e3e6f6ebb446e63373e921
/GameDev/Animation.h
0292d9d1230380f19a51c7177f1e48b87e1872e7
[]
no_license
RavinSG/GameDev
cedbd8dd8ea93fed35149716a936a1a7eec38404
cdcd12d5c1ced9450a2ea4ceabb21766c25fa69c
refs/heads/master
2023-02-20T10:27:35.114697
2021-01-25T07:43:45
2021-01-25T07:43:45
330,348,843
0
0
null
null
null
null
UTF-8
C++
false
false
668
h
#pragma once #include <vector> struct FrameData { int id; int x; int y; int width; int height; float displayTimeSeconds; }; enum class FacingDirection { None, Left, Right }; class Animation { public: Animation(FacingDirection direction); void AddFrame(int textureID, int x, int y, int width, int height, float frameTIme); const FrameData* GetCurrentFrame() const; bool UpdateFrame(float deltaTime); void Reset(); void SetDirection(FacingDirection direction); FacingDirection GetDirection() const; private: void IncrmentFrame(); std::vector<FrameData> frames; int CurrentFrameIndex; float CurrentFrameTime; FacingDirection direction; };
[ "ravinsg@gmail.com" ]
ravinsg@gmail.com
1ebdacbbc0938820f6317cde1638966e378809fe
d8b79e34892ec47f9874eb7eaaa9ce7a2fa835df
/4.16派生类多继承/main.cpp
006c98e6cfc1c41c0539c1ccae5c77daf892c393
[]
no_license
hjq562004191/Cpp-Demo
368ec9aa55e63bd65e47b98595c6f11003736665
0792c3becdd8ea9f81fa40d17bc360b22294a099
refs/heads/master
2020-05-01T16:52:23.495206
2019-07-01T09:22:43
2019-07-01T09:22:43
177,584,431
0
0
null
null
null
null
GB18030
C++
false
false
2,786
cpp
#include <iostream> #include <string.h> using namespace std; class employee { protected: string name; int individualEmpNo; int grade; float accumPay; int employeeNo; public: employee(string s,int i,int g,float a , int e){ name = s; individualEmpNo = i; grade = g; accumPay = a; employeeNo = e; } employee(){} void show(){ cout<<"name:"<<name<<"\nindividualEmpNo:"<<individualEmpNo<<endl; cout<<"grade:"<<grade<<"\naccumPay:"<<accumPay<<"\nemployeeNo:"<<employeeNo<<endl; } }; class technician:public employee{ protected: float hourlyRate; int workHours; public: technician(string s,int i,int g,float a , int e,float h,int w):employee(s,i,g,a,e){ name = s; individualEmpNo = i; accumPay = a + w*h; employeeNo = e; hourlyRate = h; workHours = w; grade = g; } void pay(){ cout<<"technician工资:"<<workHours*hourlyRate<<endl; } void displayStatus(){ cout<<"technician状态:\n"; show(); } }; class manager:public employee{ protected: float monthlyPay; public: manager( string s,int i,int g,float a , int e,float m):employee(s,i,g,a,e){ monthlyPay = m; } manager(float m){ monthlyPay = m; } void pay(){ cout<<"manager工资:"<<monthlyPay <<endl; } void displayStatus(){ cout<<"manager状态:\n"; show(); } }; class salesman:public employee{ protected: float CommRate; float sales; public: salesman(string s,int i,int g,float a , int e,float comm,float sale):employee(s,i,g,a,e){ CommRate = comm; sales = sale; } salesman(float comm,float sale){ CommRate = comm; sales = sale; } void pay(){ cout<<"salesman工资:"<<CommRate * sales<<endl; } void displayStatus(){ cout<<"salesman状态:\n"; show(); } }; class salesmanager:public manager,salesman,employee{ public: salesmanager(string s,int i,int g,float a , int e,float comm,float sale,float m):manager(m),salesman(comm,sale),employee(s,i,g,a,e){ } void pay(){ cout<<"salesmanager工资:"<<manager::monthlyPay + salesman::sales * salesman::CommRate<<endl; } void displayStatus(){ cout<<"salesmanager状态:\n"; manager::show(); } }; int main(){ technician t("销售员",1001,10,2000,1,10,5); t.pay(); t.displayStatus(); cout<<endl; manager m("经理",1002,5,5000,2,10000); m.pay(); m.displayStatus(); cout<<endl; salesman s("销售员",1003,20,3000,3,20,16); s.pay(); s.displayStatus(); cout<<endl; salesmanager sm("销售经理",1004,30,6000,4,30,20,10000); sm.pay(); sm.displayStatus(); return 0; }
[ "562004191@qq.com" ]
562004191@qq.com
4448d6f851a2b1bc6248479e2a125f47dcdf9569
2c7387c7b72fcfd14961cdb5d3b6be0633e6ab29
/Lab_2/MiniDictionaryTest/DictionaryTest.cpp
5a3d24968c90ffcc3a554dc2d8f0abf2cf75a6e0
[]
no_license
Relz/OOP
90e2757078b152263d64b8c7478ac37276a252c0
b31fb5dba16f4e564b8999c8e162323ecdd99403
refs/heads/master
2020-07-28T08:35:29.439160
2017-01-18T19:06:42
2017-01-18T19:06:42
67,879,402
0
0
null
null
null
null
WINDOWS-1251
C++
false
false
3,844
cpp
#include "stdafx.h" #include "..\MiniDictionary\Dictionary.h" // Проверка наличия слова с переводом в словаре bool IsWordExistsInDictionary(wstring const& word, wstring const& requiredTranslate, map<wstring, wstring> const& dictionary) { vector<wstring> translates; if (FindWordInDictionary(word, dictionary, translates)) { return (translates[0] == requiredTranslate); } return false; } // Функция ReadDictionaryFromFile BOOST_AUTO_TEST_SUITE(FindWordInDictionary_function) // Находит в словаре значение по ключу BOOST_AUTO_TEST_CASE(return_value_by_key_in_dictionary) { map<wstring, wstring> dictionary = { { L"кот", L"cat" },{ L"яблоко", L"apple" } }; BOOST_CHECK(IsWordExistsInDictionary(L"кот", L"cat", dictionary)); BOOST_CHECK(IsWordExistsInDictionary(L"яблоко", L"apple", dictionary)); } // Находит в словаре ключ по значению BOOST_AUTO_TEST_CASE(return_key_by_value_in_dictionary) { map<wstring, wstring> dictionary = { { L"кот", L"cat" },{ L"яблоко", L"apple" } }; BOOST_CHECK(IsWordExistsInDictionary(L"cat", L"кот", dictionary)); BOOST_CHECK(IsWordExistsInDictionary(L"apple", L"яблоко", dictionary)); } BOOST_AUTO_TEST_SUITE_END() // Функция ReadDictionaryFromFile BOOST_AUTO_TEST_SUITE(ReadDictionaryFromFile_function) // Создает пустой словарь при чтении пустого файла BOOST_AUTO_TEST_CASE(makes_empty_dictionary_from_empty_file) { wifstream dictionaryFile("empty_dictionary.txt"); map<wstring, wstring> dictionary; ReadDictionaryFromFile(dictionaryFile, dictionary); BOOST_CHECK_EQUAL(dictionary.size(), 0); } // Читает 2 слова(кот, яблоко) с их переводами(cat, apple) из файла в словарь BOOST_AUTO_TEST_CASE(read_two_words_with_translates_from_file_to_dictionary) { wifstream dictionaryFile(L"dictionary_for_read_testing.txt"); map<wstring, wstring> dictionary; ReadDictionaryFromFile(dictionaryFile, dictionary); BOOST_CHECK_EQUAL(dictionary.size(), 2); BOOST_CHECK(IsWordExistsInDictionary(L"кот", L"cat", dictionary)); BOOST_CHECK(IsWordExistsInDictionary(L"яблоко", L"apple", dictionary)); } BOOST_AUTO_TEST_SUITE_END() // Функция AddWordToDictionary BOOST_AUTO_TEST_SUITE(AddWordToDictionary_function) // Добавляет слово с переводом в словарь BOOST_AUTO_TEST_CASE(adds_word_with_translation_to_dictionary) { map<wstring, wstring> dictionary; AddWordToDictionary(L"туман", L"fog", dictionary); BOOST_CHECK_EQUAL(dictionary.size(), 1); BOOST_CHECK(IsWordExistsInDictionary(L"туман", L"fog", dictionary)); } BOOST_AUTO_TEST_SUITE_END() // Функция SaveDictionaryToFile BOOST_AUTO_TEST_SUITE(SaveDictionaryToFile_function) // Сохраняет словарь в файл BOOST_AUTO_TEST_CASE(save_dictionary_to_file) { wofstream dictionaryFileOut(L"dictionary_for_write_testing.txt"); map<wstring, wstring> dictionary = { {L"яблоко", L"apple"}, {L"кот", L"cat"} }; SaveDictionaryToFile(dictionaryFileOut, dictionary); wifstream dictionaryFileIn("dictionary_for_write_testring.txt"); ReadDictionaryFromFile(dictionaryFileIn, dictionary); BOOST_CHECK_EQUAL(dictionary.size(), 2); BOOST_CHECK(IsWordExistsInDictionary(L"яблоко", L"apple", dictionary)); BOOST_CHECK(IsWordExistsInDictionary(L"кот", L"cat", dictionary)); } BOOST_AUTO_TEST_SUITE_END()
[ "relz0071@gmail.com" ]
relz0071@gmail.com
ca1b0ead0b3558c8f4ed9b1551942cf7256f4d96
742f7e938f7d464b9479dc8a9b8f7b03c1135311
/downloadmanager.cpp
2b67f06583668f915791e60501cf0badbc688bb2
[]
no_license
KennethCheng/qt_browser
7730739402465d1ff5c1e11d264a28d8bfa0a947
bff21ef1dad9c57480c93e62c46e0f642af684d9
refs/heads/master
2020-04-18T23:27:58.808261
2011-01-27T09:54:55
2011-01-27T09:54:55
null
0
0
null
null
null
null
UTF-8
C++
false
false
19,242
cpp
/**************************************************************************** ** ** Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies). ** Contact: Nokia Corporation (qt-info@nokia.com) ** ** This file is part of the demonstration applications of the Qt Toolkit. ** ** $QT_BEGIN_LICENSE:LGPL$ ** Commercial Usage ** Licensees holding valid Qt Commercial licenses may use this file in ** accordance with the Qt Commercial License Agreement provided with the ** Software or, alternatively, in accordance with the terms contained in ** a written agreement between you and Nokia. ** ** GNU Lesser General Public License Usage ** Alternatively, this file may be used under the terms of the GNU Lesser ** General Public License version 2.1 as published by the Free Software ** Foundation and appearing in the file LICENSE.LGPL included in the ** packaging of this file. Please review the following information to ** ensure the GNU Lesser General Public License version 2.1 requirements ** will be met: http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. ** ** In addition, as a special exception, Nokia gives you certain ** additional rights. These rights are described in the Nokia Qt LGPL ** Exception version 1.0, included in the file LGPL_EXCEPTION.txt in this ** package. ** ** GNU General Public License Usage ** Alternatively, this file may be used under the terms of the GNU ** General Public License version 3.0 as published by the Free Software ** Foundation and appearing in the file LICENSE.GPL included in the ** packaging of this file. Please review the following information to ** ensure the GNU General Public License version 3.0 requirements will be ** met: http://www.gnu.org/copyleft/gpl.html. ** ** If you are unsure which license is appropriate for your use, please ** contact the sales department at http://www.qtsoftware.com/contact. ** $QT_END_LICENSE$ ** ****************************************************************************/ #include "downloadmanager.h" #include "autosaver.h" #include "browserapplication.h" #include "networkaccessmanager.h" #include <math.h> #include <QtCore/QMetaEnum> #include <QtCore/QSettings> #include <QtGui/QDesktopServices> #include <QtGui/QFileDialog> #include <QtGui/QHeaderView> #include <QtGui/QFileIconProvider> #include <QtCore/QDebug> #include <QtWebKit/QWebSettings> /*! DownloadItem is a widget that is displayed in the download manager list. It moves the data from the QNetworkReply into the QFile as well as update the information/progressbar and report errors. */ DownloadItem::DownloadItem(QNetworkReply *reply, bool requestFileName, QWidget *parent) : QWidget(parent) , m_reply(reply) , m_requestFileName(requestFileName) , m_bytesReceived(0) { setupUi(this); QPalette p = downloadInfoLabel->palette(); p.setColor(QPalette::Text, Qt::darkGray); downloadInfoLabel->setPalette(p); progressBar->setMaximum(0); tryAgainButton->hide(); connect(stopButton, SIGNAL(clicked()), this, SLOT(stop())); connect(openButton, SIGNAL(clicked()), this, SLOT(open())); connect(tryAgainButton, SIGNAL(clicked()), this, SLOT(tryAgain())); init(); } void DownloadItem::init() { if (!m_reply) return; // attach to the m_reply m_url = m_reply->url(); m_reply->setParent(this); connect(m_reply, SIGNAL(readyRead()), this, SLOT(downloadReadyRead())); connect(m_reply, SIGNAL(error(QNetworkReply::NetworkError)), this, SLOT(error(QNetworkReply::NetworkError))); connect(m_reply, SIGNAL(downloadProgress(qint64, qint64)), this, SLOT(downloadProgress(qint64, qint64))); connect(m_reply, SIGNAL(metaDataChanged()), this, SLOT(metaDataChanged())); connect(m_reply, SIGNAL(finished()), this, SLOT(finished())); // reset info downloadInfoLabel->clear(); progressBar->setValue(0); getFileName(); // start timer for the download estimation m_downloadTime.start(); if (m_reply->error() != QNetworkReply::NoError) { error(m_reply->error()); finished(); } } void DownloadItem::getFileName() { QSettings settings; settings.beginGroup(QLatin1String("downloadmanager")); QString defaultLocation = QDesktopServices::storageLocation(QDesktopServices::DesktopLocation); QString downloadDirectory = settings.value(QLatin1String("downloadDirectory"), defaultLocation).toString(); if (!downloadDirectory.isEmpty()) downloadDirectory += QLatin1Char('/'); QString defaultFileName = saveFileName(downloadDirectory); QString fileName = defaultFileName; if (m_requestFileName) { fileName = QFileDialog::getSaveFileName(this, tr("Save File"), defaultFileName); if (fileName.isEmpty()) { m_reply->close(); fileNameLabel->setText(tr("Download canceled: %1").arg(QFileInfo(defaultFileName).fileName())); return; } } m_output.setFileName(fileName); fileNameLabel->setText(QFileInfo(m_output.fileName()).fileName()); if (m_requestFileName) downloadReadyRead(); } QString DownloadItem::saveFileName(const QString &directory) const { // Move this function into QNetworkReply to also get file name sent from the server QString path = m_url.path(); QFileInfo info(path); QString baseName = info.completeBaseName(); QString endName = info.suffix(); if (baseName.isEmpty()) { baseName = QLatin1String("unnamed_download"); qDebug() << "DownloadManager:: downloading unknown file:" << m_url; } QString name = directory + baseName + QLatin1Char('.') + endName; if (QFile::exists(name)) { // already exists, don't overwrite int i = 1; do { name = directory + baseName + QLatin1Char('-') + QString::number(i++) + QLatin1Char('.') + endName; } while (QFile::exists(name)); } return name; } void DownloadItem::stop() { setUpdatesEnabled(false); stopButton->setEnabled(false); stopButton->hide(); tryAgainButton->setEnabled(true); tryAgainButton->show(); setUpdatesEnabled(true); m_reply->abort(); } void DownloadItem::open() { QFileInfo info(m_output); QUrl url = QUrl::fromLocalFile(info.absolutePath()); QDesktopServices::openUrl(url); } void DownloadItem::tryAgain() { if (!tryAgainButton->isEnabled()) return; tryAgainButton->setEnabled(false); tryAgainButton->setVisible(false); stopButton->setEnabled(true); stopButton->setVisible(true); progressBar->setVisible(true); QNetworkReply *r = BrowserApplication::networkAccessManager()->get(QNetworkRequest(m_url)); if (m_reply) m_reply->deleteLater(); if (m_output.exists()) m_output.remove(); m_reply = r; init(); emit statusChanged(); } void DownloadItem::downloadReadyRead() { if (m_requestFileName && m_output.fileName().isEmpty()) return; if (!m_output.isOpen()) { // in case someone else has already put a file there if (!m_requestFileName) getFileName(); if (!m_output.open(QIODevice::WriteOnly)) { downloadInfoLabel->setText(tr("Error opening save file: %1") .arg(m_output.errorString())); stopButton->click(); emit statusChanged(); return; } emit statusChanged(); } if (-1 == m_output.write(m_reply->readAll())) { downloadInfoLabel->setText(tr("Error saving: %1") .arg(m_output.errorString())); stopButton->click(); } } void DownloadItem::error(QNetworkReply::NetworkError) { qDebug() << "DownloadItem::error" << m_reply->errorString() << m_url; downloadInfoLabel->setText(tr("Network Error: %1").arg(m_reply->errorString())); tryAgainButton->setEnabled(true); tryAgainButton->setVisible(true); } void DownloadItem::metaDataChanged() { qDebug() << "DownloadItem::metaDataChanged: not handled."; } void DownloadItem::downloadProgress(qint64 bytesReceived, qint64 bytesTotal) { m_bytesReceived = bytesReceived; if (bytesTotal == -1) { progressBar->setValue(0); progressBar->setMaximum(0); } else { progressBar->setValue(bytesReceived); progressBar->setMaximum(bytesTotal); } updateInfoLabel(); } void DownloadItem::updateInfoLabel() { if (m_reply->error() == QNetworkReply::NoError) return; qint64 bytesTotal = progressBar->maximum(); bool running = !downloadedSuccessfully(); // update info label double speed = m_bytesReceived * 1000.0 / m_downloadTime.elapsed(); double timeRemaining = ((double)(bytesTotal - m_bytesReceived)) / speed; QString timeRemainingString = tr("seconds"); if (timeRemaining > 60) { timeRemaining = timeRemaining / 60; timeRemainingString = tr("minutes"); } timeRemaining = floor(timeRemaining); // When downloading the eta should never be 0 if (timeRemaining == 0) timeRemaining = 1; QString info; if (running) { QString remaining; if (bytesTotal != 0) remaining = tr("- %4 %5 remaining") .arg(timeRemaining) .arg(timeRemainingString); info = QString(tr("%1 of %2 (%3/sec) %4")) .arg(dataString(m_bytesReceived)) .arg(bytesTotal == 0 ? tr("?") : dataString(bytesTotal)) .arg(dataString((int)speed)) .arg(remaining); } else { if (m_bytesReceived == bytesTotal) info = dataString(m_output.size()); else info = tr("%1 of %2 - Stopped") .arg(dataString(m_bytesReceived)) .arg(dataString(bytesTotal)); } downloadInfoLabel->setText(info); } QString DownloadItem::dataString(int size) const { QString unit; if (size < 1024) { unit = tr("bytes"); } else if (size < 1024*1024) { size /= 1024; unit = tr("kB"); } else { size /= 1024*1024; unit = tr("MB"); } return QString(QLatin1String("%1 %2")).arg(size).arg(unit); } bool DownloadItem::downloading() const { return (progressBar->isVisible()); } bool DownloadItem::downloadedSuccessfully() const { return (stopButton->isHidden() && tryAgainButton->isHidden()); } void DownloadItem::finished() { progressBar->hide(); stopButton->setEnabled(false); stopButton->hide(); m_output.close(); updateInfoLabel(); emit statusChanged(); } /*! DownloadManager is a Dialog that contains a list of DownloadItems It is a basic download manager. It only downloads the file, doesn't do BitTorrent, extract zipped files or anything fancy. */ DownloadManager::DownloadManager(QWidget *parent) : QDialog(parent) , m_autoSaver(new AutoSaver(this)) , m_manager(BrowserApplication::networkAccessManager()) , m_iconProvider(0) , m_removePolicy(Never) { setupUi(this); downloadsView->setShowGrid(false); downloadsView->verticalHeader()->hide(); downloadsView->horizontalHeader()->hide(); downloadsView->setAlternatingRowColors(true); downloadsView->horizontalHeader()->setStretchLastSection(true); m_model = new DownloadModel(this); downloadsView->setModel(m_model); connect(cleanupButton, SIGNAL(clicked()), this, SLOT(cleanup())); load(); } DownloadManager::~DownloadManager() { m_autoSaver->changeOccurred(); m_autoSaver->saveIfNeccessary(); if (m_iconProvider) delete m_iconProvider; } int DownloadManager::activeDownloads() const { int count = 0; for (int i = 0; i < m_downloads.count(); ++i) { if (m_downloads.at(i)->stopButton->isEnabled()) ++count; } return count; } void DownloadManager::download(const QNetworkRequest &request, bool requestFileName) { if (request.url().isEmpty()) return; handleUnsupportedContent(m_manager->get(request), requestFileName); } void DownloadManager::handleUnsupportedContent(QNetworkReply *reply, bool requestFileName) { if (!reply || reply->url().isEmpty()) return; QVariant header = reply->header(QNetworkRequest::ContentLengthHeader); bool ok; int size = header.toInt(&ok); if (ok && size == 0) return; qDebug() << "DownloadManager::handleUnsupportedContent" << reply->url() << "requestFileName" << requestFileName; DownloadItem *item = new DownloadItem(reply, requestFileName, this); addItem(item); } void DownloadManager::addItem(DownloadItem *item) { connect(item, SIGNAL(statusChanged()), this, SLOT(updateRow())); int row = m_downloads.count(); m_model->beginInsertRows(QModelIndex(), row, row); m_downloads.append(item); m_model->endInsertRows(); updateItemCount(); if (row == 0) show(); downloadsView->setIndexWidget(m_model->index(row, 0), item); QIcon icon = style()->standardIcon(QStyle::SP_FileIcon); item->fileIcon->setPixmap(icon.pixmap(48, 48)); downloadsView->setRowHeight(row, item->sizeHint().height()); } void DownloadManager::updateRow() { DownloadItem *item = qobject_cast<DownloadItem*>(sender()); int row = m_downloads.indexOf(item); if (-1 == row) return; if (!m_iconProvider) m_iconProvider = new QFileIconProvider(); QIcon icon = m_iconProvider->icon(item->m_output.fileName()); if (icon.isNull()) icon = style()->standardIcon(QStyle::SP_FileIcon); item->fileIcon->setPixmap(icon.pixmap(48, 48)); downloadsView->setRowHeight(row, item->minimumSizeHint().height()); bool remove = false; QWebSettings *globalSettings = QWebSettings::globalSettings(); if (!item->downloading() && globalSettings->testAttribute(QWebSettings::PrivateBrowsingEnabled)) remove = true; if (item->downloadedSuccessfully() && removePolicy() == DownloadManager::SuccessFullDownload) { remove = true; } if (remove) m_model->removeRow(row); cleanupButton->setEnabled(m_downloads.count() - activeDownloads() > 0); } DownloadManager::RemovePolicy DownloadManager::removePolicy() const { return m_removePolicy; } void DownloadManager::setRemovePolicy(RemovePolicy policy) { if (policy == m_removePolicy) return; m_removePolicy = policy; m_autoSaver->changeOccurred(); } void DownloadManager::save() const { QSettings settings; settings.beginGroup(QLatin1String("downloadmanager")); QMetaEnum removePolicyEnum = staticMetaObject.enumerator(staticMetaObject.indexOfEnumerator("RemovePolicy")); settings.setValue(QLatin1String("removeDownloadsPolicy"), QLatin1String(removePolicyEnum.valueToKey(m_removePolicy))); settings.setValue(QLatin1String("size"), size()); if (m_removePolicy == Exit) return; for (int i = 0; i < m_downloads.count(); ++i) { QString key = QString(QLatin1String("download_%1_")).arg(i); settings.setValue(key + QLatin1String("url"), m_downloads[i]->m_url); settings.setValue(key + QLatin1String("location"), QFileInfo(m_downloads[i]->m_output).filePath()); settings.setValue(key + QLatin1String("done"), m_downloads[i]->downloadedSuccessfully()); } int i = m_downloads.count(); QString key = QString(QLatin1String("download_%1_")).arg(i); while (settings.contains(key + QLatin1String("url"))) { settings.remove(key + QLatin1String("url")); settings.remove(key + QLatin1String("location")); settings.remove(key + QLatin1String("done")); key = QString(QLatin1String("download_%1_")).arg(++i); } } void DownloadManager::load() { QSettings settings; settings.beginGroup(QLatin1String("downloadmanager")); QSize size = settings.value(QLatin1String("size")).toSize(); if (size.isValid()) resize(size); QByteArray value = settings.value(QLatin1String("removeDownloadsPolicy"), QLatin1String("Never")).toByteArray(); QMetaEnum removePolicyEnum = staticMetaObject.enumerator(staticMetaObject.indexOfEnumerator("RemovePolicy")); m_removePolicy = removePolicyEnum.keyToValue(value) == -1 ? Never : static_cast<RemovePolicy>(removePolicyEnum.keyToValue(value)); int i = 0; QString key = QString(QLatin1String("download_%1_")).arg(i); while (settings.contains(key + QLatin1String("url"))) { QUrl url = settings.value(key + QLatin1String("url")).toUrl(); QString fileName = settings.value(key + QLatin1String("location")).toString(); bool done = settings.value(key + QLatin1String("done"), true).toBool(); if (!url.isEmpty() && !fileName.isEmpty()) { DownloadItem *item = new DownloadItem(0, this); item->m_output.setFileName(fileName); item->fileNameLabel->setText(QFileInfo(item->m_output.fileName()).fileName()); item->m_url = url; item->stopButton->setVisible(false); item->stopButton->setEnabled(false); item->tryAgainButton->setVisible(!done); item->tryAgainButton->setEnabled(!done); item->progressBar->setVisible(!done); addItem(item); } key = QString(QLatin1String("download_%1_")).arg(++i); } cleanupButton->setEnabled(m_downloads.count() - activeDownloads() > 0); } void DownloadManager::cleanup() { if (m_downloads.isEmpty()) return; m_model->removeRows(0, m_downloads.count()); updateItemCount(); if (m_downloads.isEmpty() && m_iconProvider) { delete m_iconProvider; m_iconProvider = 0; } m_autoSaver->changeOccurred(); } void DownloadManager::updateItemCount() { int count = m_downloads.count(); itemCount->setText(count == 1 ? tr("1 Download") : tr("%1 Downloads").arg(count)); } DownloadModel::DownloadModel(DownloadManager *downloadManager, QObject *parent) : QAbstractListModel(parent) , m_downloadManager(downloadManager) { } QVariant DownloadModel::data(const QModelIndex &index, int role) const { if (index.row() < 0 || index.row() >= rowCount(index.parent())) return QVariant(); if (role == Qt::ToolTipRole) if (!m_downloadManager->m_downloads.at(index.row())->downloadedSuccessfully()) return m_downloadManager->m_downloads.at(index.row())->downloadInfoLabel->text(); return QVariant(); } int DownloadModel::rowCount(const QModelIndex &parent) const { return (parent.isValid()) ? 0 : m_downloadManager->m_downloads.count(); } bool DownloadModel::removeRows(int row, int count, const QModelIndex &parent) { if (parent.isValid()) return false; int lastRow = row + count - 1; for (int i = lastRow; i >= row; --i) { if (m_downloadManager->m_downloads.at(i)->downloadedSuccessfully() || m_downloadManager->m_downloads.at(i)->tryAgainButton->isEnabled()) { beginRemoveRows(parent, i, i); m_downloadManager->m_downloads.takeAt(i)->deleteLater(); endRemoveRows(); } } m_downloadManager->m_autoSaver->changeOccurred(); return true; }
[ "root@ubuntu.(none)" ]
root@ubuntu.(none)
177c9bee3466ffc37abfda78b3085e33724d0919
336b38ce17fee2ce179edba0a7e1c80cdade021e
/src/input.h
949bc6fcd187ddc54040944bbdcf9b1a165b1f7c
[ "MIT" ]
permissive
milesdave/skiopen
0805120212807256bb490dd096c38e9b118cfba6
7550104c2f52aeb0e030a6df6b11219d60bba49e
refs/heads/master
2020-12-03T02:01:44.622495
2017-07-23T10:34:50
2017-07-23T10:34:50
95,895,603
2
0
null
null
null
null
UTF-8
C++
false
false
2,159
h
#ifndef INPUT_H_ #define INPUT_H_ #include <SDL.h> #include "structures/queue.h" #include "types.h" class Input { public: ~Input(); // Possible controller inputs. enum In { // Digital inputs. A = SDL_CONTROLLER_BUTTON_A, B = SDL_CONTROLLER_BUTTON_B, X = SDL_CONTROLLER_BUTTON_X, Y = SDL_CONTROLLER_BUTTON_Y, Select = SDL_CONTROLLER_BUTTON_BACK, Home = SDL_CONTROLLER_BUTTON_GUIDE, Start = SDL_CONTROLLER_BUTTON_START, L3 = SDL_CONTROLLER_BUTTON_LEFTSTICK, R3 = SDL_CONTROLLER_BUTTON_RIGHTSTICK, L1 = SDL_CONTROLLER_BUTTON_LEFTSHOULDER, R1 = SDL_CONTROLLER_BUTTON_RIGHTSHOULDER, Up = SDL_CONTROLLER_BUTTON_DPAD_UP, Down = SDL_CONTROLLER_BUTTON_DPAD_DOWN, Left = SDL_CONTROLLER_BUTTON_DPAD_LEFT, Right = SDL_CONTROLLER_BUTTON_DPAD_RIGHT, // Analogue inputs. LeftStickX = (Right + 1) + SDL_CONTROLLER_AXIS_LEFTX, LeftStickY = (Right + 1) + SDL_CONTROLLER_AXIS_LEFTY, RightStickX = (Right + 1) + SDL_CONTROLLER_AXIS_RIGHTX, RightStickY = (Right + 1) + SDL_CONTROLLER_AXIS_RIGHTY, L2 = (Right + 1) + SDL_CONTROLLER_AXIS_TRIGGERLEFT, R2 = (Right + 1) + SDL_CONTROLLER_AXIS_TRIGGERRIGHT }; // Eveything about a single input event. struct InputEvent { In input; Sint16 state; }; // Returns a pointer to this singleton instance. static Input* instance(); // Opens a controller if one is dectected. void initController(); // Closes a controller if one is open. void closeController(); // Returns the state of the specified input right now. Sint16 getInput(In input) const; // Returns a constant reference to the input event queue, allowing it // to be copied. inline const Queue<InputEvent>& events() const { return _events; } // Converst an SDL_Event and adds it to the Queue. Should only be used // by the Game class. void offerEvent(const SDL_Event& e); // Clears the event queue. Should only be used by the Game class. inline void clearEvents() { _events.clear(); } private: Input(); // The connected controller. SDL_GameController* _controller = nullptr; // The event queue. Queue<InputEvent> _events; // This singleton instance. static Input* _instance; }; #endif
[ "davis.g.miles@gmail.com" ]
davis.g.miles@gmail.com
7ebe35ea4612ffe0b806784598f3fb8b7643ff63
bcfc1d294607d448d59ad23d415338a16ab84f0c
/DataStructure/SeqQueue.cpp
2ae88fda50f90772ac7f191ff9e0f431d6ed88d3
[]
no_license
Yunnglin/DataStructure
4fb4f32cdafa11ae45cbecbed3828373b6857e6d
7df73538a0620016d67b35bfe3516bb78a045ec3
refs/heads/master
2020-03-28T08:58:29.390946
2018-11-06T12:03:47
2018-11-06T12:03:47
148,003,953
0
0
null
null
null
null
GB18030
C++
false
false
763
cpp
#include "pch.h" #include "SeqQueue.h" #ifndef _SeqQueue_Cpp_ #define _SeqQueue_Cpp_ template<class T> SeqQueue<T>::SeqQueue() { //顺序队的front和rear初始化为-1 this->front = -1; this->rear = -1; } template<class T> SeqQueue<T>::~SeqQueue() { } template<class T> void SeqQueue<T>::Destroy() { delete this; } template<class T> bool SeqQueue<T>::IsEmpty() { return (this->front == this->rear); } template<class T> bool SeqQueue<T>::enQueue(T e) { if (this->rear == SQMaxSize - 1) return false; this->rear++; this->data[this->rear] = e; return true; } template<class T> bool SeqQueue<T>::deQueue(T& e) { if (this->front == this->rear) return false; this->front++; e = this->data[this->front]; return true; } #endif // !_SeqQueue_Cpp_
[ "mao.looper@qq.com" ]
mao.looper@qq.com
8d4f4014a9de0b0d3691e57cc83ae233a727c5ee
b761757a02d38f4d0bf4f8879c4389041a530745
/Tensorflow-micro/CIFAR-Models/build/CMakeFiles/CMakeTmp/CompilerFlagC.c
d025068d92ca2e35321ecf8d7cd15efbf8a29ca5
[]
no_license
chrpro/TinyML-Evaluation
14c771839d02938734c73bd13e3e07f15c2b4bfb
4ca8b6582d38d84744e37cca93697ea388593278
refs/heads/main
2023-09-03T22:22:55.063375
2023-08-12T11:35:10
2023-08-12T11:35:10
350,752,223
6
3
null
null
null
null
UTF-8
C++
false
false
30
c
int main (void) { return 0; }
[ "chrpro@chalmers.se" ]
chrpro@chalmers.se
01d8fa011ed036e6ba4d7bca2a13a25e457336e7
31ac07ecd9225639bee0d08d00f037bd511e9552
/externals/OCCTLib/inc/TColStd_HSetOfInteger.hxx
167cb7a8103a14679ea6644f73d34226bbec15e0
[]
no_license
litao1009/SimpleRoom
4520e0034e4f90b81b922657b27f201842e68e8e
287de738c10b86ff8f61b15e3b8afdfedbcb2211
refs/heads/master
2021-01-20T19:56:39.507899
2016-07-29T08:01:57
2016-07-29T08:01:57
64,462,604
1
0
null
null
null
null
UTF-8
C++
false
false
2,943
hxx
// This file is generated by WOK (CPPExt). // Please do not edit this file; modify original file instead. // The copyright and license terms as defined for the original file apply to // this header file considered to be the "object code" form of the original source. #ifndef _TColStd_HSetOfInteger_HeaderFile #define _TColStd_HSetOfInteger_HeaderFile #ifndef _Standard_HeaderFile #include <Standard.hxx> #endif #ifndef _Standard_DefineHandle_HeaderFile #include <Standard_DefineHandle.hxx> #endif #ifndef _Handle_TColStd_HSetOfInteger_HeaderFile #include <Handle_TColStd_HSetOfInteger.hxx> #endif #ifndef _TColStd_SetOfInteger_HeaderFile #include <TColStd_SetOfInteger.hxx> #endif #ifndef _MMgt_TShared_HeaderFile #include <MMgt_TShared.hxx> #endif #ifndef _Standard_Integer_HeaderFile #include <Standard_Integer.hxx> #endif #ifndef _Standard_Boolean_HeaderFile #include <Standard_Boolean.hxx> #endif class TColStd_SetOfInteger; class TColStd_HSetOfInteger : public MMgt_TShared { public: Standard_EXPORT TColStd_HSetOfInteger(); Standard_Integer Extent() const; Standard_Boolean IsEmpty() const; void Clear() ; Standard_Boolean Add(const Standard_Integer& T) ; Standard_Boolean Remove(const Standard_Integer& T) ; Standard_EXPORT Handle_TColStd_HSetOfInteger Union(const Handle(TColStd_HSetOfInteger)& B) const; Standard_EXPORT Handle_TColStd_HSetOfInteger Intersection(const Handle(TColStd_HSetOfInteger)& B) const; Standard_EXPORT Handle_TColStd_HSetOfInteger Difference(const Handle(TColStd_HSetOfInteger)& B) const; Standard_Boolean Contains(const Standard_Integer& T) const; Standard_Boolean IsASubset(const Handle(TColStd_HSetOfInteger)& S) const; Standard_Boolean IsAProperSubset(const Handle(TColStd_HSetOfInteger)& S) const; Standard_EXPORT Handle_TColStd_HSetOfInteger ShallowCopy() const; const TColStd_SetOfInteger& Set() const; TColStd_SetOfInteger& ChangeSet() ; DEFINE_STANDARD_RTTI(TColStd_HSetOfInteger) protected: private: TColStd_SetOfInteger mySet; }; #define Item Standard_Integer #define Item_hxx <Standard_Integer.hxx> #define TheSet TColStd_SetOfInteger #define TheSet_hxx <TColStd_SetOfInteger.hxx> #define TCollection_HSet TColStd_HSetOfInteger #define TCollection_HSet_hxx <TColStd_HSetOfInteger.hxx> #define Handle_TCollection_HSet Handle_TColStd_HSetOfInteger #define TCollection_HSet_Type_() TColStd_HSetOfInteger_Type_() #include <TCollection_HSet.lxx> #undef Item #undef Item_hxx #undef TheSet #undef TheSet_hxx #undef TCollection_HSet #undef TCollection_HSet_hxx #undef Handle_TCollection_HSet #undef TCollection_HSet_Type_ // other Inline functions and methods (like "C++: function call" methods) inline Handle_TColStd_HSetOfInteger ShallowCopy(const Handle_TColStd_HSetOfInteger& me) { return me->ShallowCopy(); } #endif
[ "litao1009@gmail.com" ]
litao1009@gmail.com
08ef87f2a6e218df9b841d7d995fa37b6bea2420
be0282afa8dd436619c71d6118c9db455eaf1a29
/Intermediate/Build/Win64/Design3D/Inc/NavigationSystem/NavModifierVolume.gen.cpp
6c908e88404eefe38da33fbeccc05f8472ce306d
[]
no_license
Quant2017/Design3D
0f915580b222af40ab911021cceef5c26375d7f9
94a22386be4aa37aa0f546354cc62958820a4bf6
refs/heads/master
2022-04-23T10:44:12.398772
2020-04-22T01:02:39
2020-04-22T01:02:39
262,966,755
1
0
null
2020-05-11T07:12:37
2020-05-11T07:12:36
null
UTF-8
C++
false
false
8,800
cpp
// Copyright 1998-2019 Epic Games, Inc. All Rights Reserved. /*=========================================================================== Generated code exported from UnrealHeaderTool. DO NOT modify this manually! Edit the corresponding .h files instead! ===========================================================================*/ #include "UObject/GeneratedCppIncludes.h" #include "NavigationSystem/Public/NavModifierVolume.h" #ifdef _MSC_VER #pragma warning (push) #pragma warning (disable : 4883) #endif PRAGMA_DISABLE_DEPRECATION_WARNINGS void EmptyLinkFunctionForGeneratedCodeNavModifierVolume() {} // Cross Module References NAVIGATIONSYSTEM_API UClass* Z_Construct_UClass_ANavModifierVolume_NoRegister(); NAVIGATIONSYSTEM_API UClass* Z_Construct_UClass_ANavModifierVolume(); ENGINE_API UClass* Z_Construct_UClass_AVolume(); UPackage* Z_Construct_UPackage__Script_NavigationSystem(); NAVIGATIONSYSTEM_API UFunction* Z_Construct_UFunction_ANavModifierVolume_SetAreaClass(); COREUOBJECT_API UClass* Z_Construct_UClass_UClass(); NAVIGATIONSYSTEM_API UClass* Z_Construct_UClass_UNavArea_NoRegister(); ENGINE_API UClass* Z_Construct_UClass_UNavRelevantInterface_NoRegister(); // End Cross Module References void ANavModifierVolume::StaticRegisterNativesANavModifierVolume() { UClass* Class = ANavModifierVolume::StaticClass(); static const FNameNativePtrPair Funcs[] = { { "SetAreaClass", &ANavModifierVolume::execSetAreaClass }, }; FNativeFunctionRegistrar::RegisterFunctions(Class, Funcs, ARRAY_COUNT(Funcs)); } struct Z_Construct_UFunction_ANavModifierVolume_SetAreaClass_Statics { struct NavModifierVolume_eventSetAreaClass_Parms { TSubclassOf<UNavArea> NewAreaClass; }; static const UE4CodeGen_Private::FClassPropertyParams NewProp_NewAreaClass; static const UE4CodeGen_Private::FPropertyParamsBase* const PropPointers[]; #if WITH_METADATA static const UE4CodeGen_Private::FMetaDataPairParam Function_MetaDataParams[]; #endif static const UE4CodeGen_Private::FFunctionParams FuncParams; }; const UE4CodeGen_Private::FClassPropertyParams Z_Construct_UFunction_ANavModifierVolume_SetAreaClass_Statics::NewProp_NewAreaClass = { "NewAreaClass", nullptr, (EPropertyFlags)0x0014000000000080, UE4CodeGen_Private::EPropertyGenFlags::Class, RF_Public|RF_Transient|RF_MarkAsNative, 1, STRUCT_OFFSET(NavModifierVolume_eventSetAreaClass_Parms, NewAreaClass), Z_Construct_UClass_UNavArea_NoRegister, Z_Construct_UClass_UClass, METADATA_PARAMS(nullptr, 0) }; const UE4CodeGen_Private::FPropertyParamsBase* const Z_Construct_UFunction_ANavModifierVolume_SetAreaClass_Statics::PropPointers[] = { (const UE4CodeGen_Private::FPropertyParamsBase*)&Z_Construct_UFunction_ANavModifierVolume_SetAreaClass_Statics::NewProp_NewAreaClass, }; #if WITH_METADATA const UE4CodeGen_Private::FMetaDataPairParam Z_Construct_UFunction_ANavModifierVolume_SetAreaClass_Statics::Function_MetaDataParams[] = { { "Category", "AI|Navigation" }, { "CPP_Default_NewAreaClass", "None" }, { "ModuleRelativePath", "Public/NavModifierVolume.h" }, }; #endif const UE4CodeGen_Private::FFunctionParams Z_Construct_UFunction_ANavModifierVolume_SetAreaClass_Statics::FuncParams = { (UObject*(*)())Z_Construct_UClass_ANavModifierVolume, nullptr, "SetAreaClass", sizeof(NavModifierVolume_eventSetAreaClass_Parms), Z_Construct_UFunction_ANavModifierVolume_SetAreaClass_Statics::PropPointers, ARRAY_COUNT(Z_Construct_UFunction_ANavModifierVolume_SetAreaClass_Statics::PropPointers), RF_Public|RF_Transient|RF_MarkAsNative, (EFunctionFlags)0x04020401, 0, 0, METADATA_PARAMS(Z_Construct_UFunction_ANavModifierVolume_SetAreaClass_Statics::Function_MetaDataParams, ARRAY_COUNT(Z_Construct_UFunction_ANavModifierVolume_SetAreaClass_Statics::Function_MetaDataParams)) }; UFunction* Z_Construct_UFunction_ANavModifierVolume_SetAreaClass() { static UFunction* ReturnFunction = nullptr; if (!ReturnFunction) { UE4CodeGen_Private::ConstructUFunction(ReturnFunction, Z_Construct_UFunction_ANavModifierVolume_SetAreaClass_Statics::FuncParams); } return ReturnFunction; } UClass* Z_Construct_UClass_ANavModifierVolume_NoRegister() { return ANavModifierVolume::StaticClass(); } struct Z_Construct_UClass_ANavModifierVolume_Statics { static UObject* (*const DependentSingletons[])(); static const FClassFunctionLinkInfo FuncInfo[]; #if WITH_METADATA static const UE4CodeGen_Private::FMetaDataPairParam Class_MetaDataParams[]; #endif #if WITH_METADATA static const UE4CodeGen_Private::FMetaDataPairParam NewProp_AreaClass_MetaData[]; #endif static const UE4CodeGen_Private::FClassPropertyParams NewProp_AreaClass; static const UE4CodeGen_Private::FPropertyParamsBase* const PropPointers[]; static const UE4CodeGen_Private::FImplementedInterfaceParams InterfaceParams[]; static const FCppClassTypeInfoStatic StaticCppClassTypeInfo; static const UE4CodeGen_Private::FClassParams ClassParams; }; UObject* (*const Z_Construct_UClass_ANavModifierVolume_Statics::DependentSingletons[])() = { (UObject* (*)())Z_Construct_UClass_AVolume, (UObject* (*)())Z_Construct_UPackage__Script_NavigationSystem, }; const FClassFunctionLinkInfo Z_Construct_UClass_ANavModifierVolume_Statics::FuncInfo[] = { { &Z_Construct_UFunction_ANavModifierVolume_SetAreaClass, "SetAreaClass" }, // 4229470781 }; #if WITH_METADATA const UE4CodeGen_Private::FMetaDataPairParam Z_Construct_UClass_ANavModifierVolume_Statics::Class_MetaDataParams[] = { { "HideCategories", "Navigation Brush Physics Object Display Rendering Physics Input Blueprint" }, { "IncludePath", "NavModifierVolume.h" }, { "ModuleRelativePath", "Public/NavModifierVolume.h" }, { "ObjectInitializerConstructorDeclared", "" }, { "ShowCategories", "Input|MouseInput Input|TouchInput" }, { "ToolTip", "Allows applying selected AreaClass to navmesh, using Volume's shape" }, }; #endif #if WITH_METADATA const UE4CodeGen_Private::FMetaDataPairParam Z_Construct_UClass_ANavModifierVolume_Statics::NewProp_AreaClass_MetaData[] = { { "Category", "Default" }, { "ModuleRelativePath", "Public/NavModifierVolume.h" }, }; #endif const UE4CodeGen_Private::FClassPropertyParams Z_Construct_UClass_ANavModifierVolume_Statics::NewProp_AreaClass = { "AreaClass", nullptr, (EPropertyFlags)0x0024080000000015, UE4CodeGen_Private::EPropertyGenFlags::Class, RF_Public|RF_Transient|RF_MarkAsNative, 1, STRUCT_OFFSET(ANavModifierVolume, AreaClass), Z_Construct_UClass_UNavArea_NoRegister, Z_Construct_UClass_UClass, METADATA_PARAMS(Z_Construct_UClass_ANavModifierVolume_Statics::NewProp_AreaClass_MetaData, ARRAY_COUNT(Z_Construct_UClass_ANavModifierVolume_Statics::NewProp_AreaClass_MetaData)) }; const UE4CodeGen_Private::FPropertyParamsBase* const Z_Construct_UClass_ANavModifierVolume_Statics::PropPointers[] = { (const UE4CodeGen_Private::FPropertyParamsBase*)&Z_Construct_UClass_ANavModifierVolume_Statics::NewProp_AreaClass, }; const UE4CodeGen_Private::FImplementedInterfaceParams Z_Construct_UClass_ANavModifierVolume_Statics::InterfaceParams[] = { { Z_Construct_UClass_UNavRelevantInterface_NoRegister, (int32)VTABLE_OFFSET(ANavModifierVolume, INavRelevantInterface), false }, }; const FCppClassTypeInfoStatic Z_Construct_UClass_ANavModifierVolume_Statics::StaticCppClassTypeInfo = { TCppClassTypeTraits<ANavModifierVolume>::IsAbstract, }; const UE4CodeGen_Private::FClassParams Z_Construct_UClass_ANavModifierVolume_Statics::ClassParams = { &ANavModifierVolume::StaticClass, nullptr, &StaticCppClassTypeInfo, DependentSingletons, FuncInfo, Z_Construct_UClass_ANavModifierVolume_Statics::PropPointers, InterfaceParams, ARRAY_COUNT(DependentSingletons), ARRAY_COUNT(FuncInfo), ARRAY_COUNT(Z_Construct_UClass_ANavModifierVolume_Statics::PropPointers), ARRAY_COUNT(InterfaceParams), 0x009000A0u, METADATA_PARAMS(Z_Construct_UClass_ANavModifierVolume_Statics::Class_MetaDataParams, ARRAY_COUNT(Z_Construct_UClass_ANavModifierVolume_Statics::Class_MetaDataParams)) }; UClass* Z_Construct_UClass_ANavModifierVolume() { static UClass* OuterClass = nullptr; if (!OuterClass) { UE4CodeGen_Private::ConstructUClass(OuterClass, Z_Construct_UClass_ANavModifierVolume_Statics::ClassParams); } return OuterClass; } IMPLEMENT_CLASS(ANavModifierVolume, 230976370); template<> NAVIGATIONSYSTEM_API UClass* StaticClass<ANavModifierVolume>() { return ANavModifierVolume::StaticClass(); } static FCompiledInDefer Z_CompiledInDefer_UClass_ANavModifierVolume(Z_Construct_UClass_ANavModifierVolume, &ANavModifierVolume::StaticClass, TEXT("/Script/NavigationSystem"), TEXT("ANavModifierVolume"), false, nullptr, nullptr, nullptr); DEFINE_VTABLE_PTR_HELPER_CTOR(ANavModifierVolume); PRAGMA_ENABLE_DEPRECATION_WARNINGS #ifdef _MSC_VER #pragma warning (pop) #endif
[ "Snake_Jenny@126.com" ]
Snake_Jenny@126.com
f3ec87edfa4a626b1614360420481d59c7bf7081
2c0e6e0723895caee73f05445aac5f22d1e41f89
/mainwindow.h
afe0040322182a2a5aa8a6e2153b024beb16f6a9
[]
no_license
jerryjiahaha/reversi
4db0ab431ec5c66e517fcfac4d63ba716dd3017a
6dc04e16f3dbab1d9c147815474a84ce1f103b1c
refs/heads/master
2021-01-01T04:18:38.093528
2016-05-27T13:24:15
2016-05-27T13:24:15
59,720,106
0
0
null
null
null
null
UTF-8
C++
false
false
1,046
h
#ifndef MAINWINDOW_H #define MAINWINDOW_H #include <QMainWindow> #include <QPainter> #include <QWidget> #include <QObject> #include <QMessageBox> //#include <QThread> #include <QDesktopWidget> #include <map> #include "virtual_board.h" #include "boardview.h" #include "newgamedialog.h" #include "ai/SmartGecko.h" namespace Ui { class MainWindow; } class MainWindow : public QMainWindow { Q_OBJECT public: explicit MainWindow(QWidget *parent = 0); ~MainWindow(); signals: void nextPlayer(); void endOfGame(); private slots: void on_actionNew_triggered(); void startGame(int ret); void handleNextPos(int x, int y); void handleNextPlayer(); void handleEndOfGame(); //void updateInfo(); private: Ui::MainWindow *ui; BoardWidget *board_view; vBoard *board_model; newGameDialog *newgame; int imfirst; std::map<int, int> playerList; // Ai:1, human:0 std::map<int, QString> playerNames; SmartGecko *ai; //int whiteisAi; //int blackisAi; }; #endif // MAINWINDOW_H
[ "jerryjiahaha@gmail.com" ]
jerryjiahaha@gmail.com
f221cb1881e2f892a884b5019880ba4dd153784f
4a49b92106830b269ab1331061611bdb6dfd5a0a
/src/series.h
72974680f5e6df25ddce40003a00c8d6dbaa8e77
[]
no_license
heavenchou/CBReader
1e5a8a9f2e01b95da88f48cbe17b5a409b0cf097
590d73051ebd16cb9423c8b1bfd499f59beead47
refs/heads/master
2022-05-04T05:14:09.320858
2021-04-18T19:38:26
2021-04-18T19:38:26
83,400,590
2
1
null
null
null
null
BIG5
C++
false
false
2,474
h
// --------------------------------------------------------------------------- #ifndef SeriesH #define SeriesH #ifdef _Windows #include <Xml.Win.msxmldom.hpp> #else #include <Xml.omnixmldom.hpp> #endif #include <Xml.XMLDoc.hpp> #include <fmx.h> #include "catalog.h" #include "spine.h" #include "bookdata.h" #include "juanline.h" #include <utility> // for std::pair #include "../../Monster/src/monster.h" // --------------------------------------------------------------------------- class CSeries { private: // User declarations public: // User declarations String Dir; // 本書的目錄 String ID; // ID 代碼, CBETA 的指定為 CBEAT String Title; // 標題 String Creator; // 作者 String PublishDate; // 出版日期 String NavFile; // 導覽文件 String Nav2File; // 導覽文件 (CBETA 特有的, 未來再考慮如何處理多目錄) String Nav3File; // 導覽文件 (CBETA 特有的, 未來再考慮如何處理多目錄) String CatalogFile; // 目錄文件 String SpineFile; // 遍歷文件 String BookDataFile; // BookData 文件 String JSFile; // CBReader 專用的 js 檔 String Version; // 版本 CCatalog * Catalog; // 目錄 CSpine * Spine; // 遍歷文件 CJuanLine * JuanLine; // 各卷與頁欄行的關係物件, CBETA 專用 CBookData * BookData; // 每本書的資訊, 例如 T , 大正藏, 2 TmyMonster * SearchEngine_orig; // 原書全文檢索引擎 TmyMonster * SearchEngine_CB; // CB 版全文檢索引擎 void __fastcall LoadMetaData(String sMeta); // 載入後設文件 // 由經卷去找經文, Vol 可以是空的, 但有跨冊的經文就要指定 String __fastcall CBGetFileNameBySutraNumJuan(String sBookID, String sVol, String sSutraNum, String sJuan = "", String sPage = "", String sField = "", String sLine = ""); // 由冊頁欄行找經文 String __fastcall CBGetFileNameByVolPageFieldLine(String sBook, String sVol = "", String sPage = "", String sField = "", String sLine = ""); // 由頁欄行取得標準 0001a01 格式的字串 String __fastcall CBGetPageLine(String sPage, String sField, String sLine); // 載入全文檢索引擎 void __fastcall LoadSearchEngine(); // 釋放全文檢索引擎 void __fastcall FreeSearchEngine(); __fastcall CSeries(String sDir); // 傳入目錄, 進行初值化 __fastcall ~CSeries(); }; // --------------------------------------------------------------------------- #endif
[ "heaven.chou@gmail.com" ]
heaven.chou@gmail.com
04669c2dae169d1c298abbdfc8712aea782570c2
5252563bae16bc43fe455bd2d24416e8916d06d4
/controller/autobot/autobot.h
b22661b816b0675b6fa8d6fd69613b05e8702f59
[]
no_license
shantnu-agarwal/core
03e72fd1ff696d0b7f25fba5cfadce5c343c995b
e835b6d9a19dedaa9e79ca912a5968924d25518c
refs/heads/master
2020-04-01T10:27:11.597842
2018-07-17T05:46:23
2018-07-17T05:46:23
null
0
0
null
null
null
null
UTF-8
C++
false
false
440
h
#ifndef __AUTOBOT_H__ #define __AUTOBOT_H__ #include <iostream> #include <cmath> #include "../helper/helper.h" #define ACCURACY 1.5 class Autobot{ private: double latitude,longitude,difference,distance,bearing; int Right = 16,Left = 64,Leftdrift = 192,Rightdrift = 144,fwd = 128,stop = 0; int err = 5,dat = 0, isAuto = 0; public: double destlat,destlon; Autobot(); int update(double heading,Helper H); }; #endif
[ "rajanaga_ra@srmuniv.edu.in" ]
rajanaga_ra@srmuniv.edu.in
f0291994a9eda62a5a45cbc5988f311fccbfe645
6b40e9dccf2edc767c44df3acd9b626fcd586b4d
/NT/shell/ext/dsui/dsquery/frame.cpp
cf9d2c9699a264ecd018ea472581e47af1b3af7a
[]
no_license
jjzhang166/WinNT5_src_20201004
712894fcf94fb82c49e5cd09d719da00740e0436
b2db264153b80fbb91ef5fc9f57b387e223dbfc2
refs/heads/Win2K3
2023-08-12T01:31:59.670176
2021-10-14T15:14:37
2021-10-14T15:14:37
586,134,273
1
0
null
2023-01-07T03:47:45
2023-01-07T03:47:44
null
UTF-8
C++
false
false
142,455
cpp
#include "pch.h" #include "uxtheme.h" #pragma hdrstop /*----------------------------------------------------------------------------- / Private data and helper functions /----------------------------------------------------------------------------*/ // // ICommonQuery stuff // class CCommonQuery : public ICommonQuery, IObjectWithSite { private: LONG _cRef; IUnknown* _punkSite; public: CCommonQuery(); ~CCommonQuery(); // IUnknown STDMETHOD(QueryInterface)(REFIID riid, LPVOID* ppvObject); STDMETHOD_(ULONG, AddRef)(); STDMETHOD_(ULONG, Release)(); // ICommonQuery STDMETHOD(OpenQueryWindow)(THIS_ HWND hwndParent, LPOPENQUERYWINDOW pOpenQueryWnd, IDataObject** ppDataObject); // IObjectWithSite STDMETHODIMP SetSite(IUnknown* punk); STDMETHODIMP GetSite(REFIID riid, void **ppv); }; // // View layout constants used by our dialogs // #define VIEWER_DEFAULT_CY 200 #define COMBOEX_IMAGE_CX 16 #define COMBOEX_IMAGE_CY 16 typedef struct { HDSA hdsaPages; // DSA containing page entries DWORD dwFlags; // flags CLSID clsidForm; // CLSID identifier for this form LPTSTR pTitle; // title used for drop down / title bar HICON hIcon; // hIcon passed by caller INT iImage; // image list index of icon INT iForm; // visible index of form in control INT iPage; // currently selected page on form } QUERYFORM, * LPQUERYFORM; typedef struct { CLSID clsidForm; // CLSID to associate this form with LPCQPAGE pPage; // CQPAGE structures LPCQPAGEPROC pPageProc; // PageProc's used by thunking layer LPARAM lParam; // PAGEPROC lParam HWND hwndPage; // hWnd of page dialog // = NULL if none } QUERYFORMPAGE, * LPQUERYFORMPAGE; typedef struct { LPCQSCOPE pScope; INT iImage; } QUERYSCOPE, * LPQUERYSCOPE; class CQueryFrame : public IQueryFrame { friend INT QueryWnd_MessageProc(HWND hwnd, LPMSG pMsg); friend INT_PTR CALLBACK QueryWnd_DlgProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam); public: CQueryFrame(IUnknown* punkSite, LPOPENQUERYWINDOW pOpenQueryWindow, IDataObject** ppDataObject); ~CQueryFrame(); // IUnknown STDMETHOD(QueryInterface)(REFIID riid, LPVOID* ppvObject); STDMETHOD_(ULONG, AddRef)(); STDMETHOD_(ULONG, Release)(); // Internal helper functions STDMETHOD(DoModal)(HWND hwndParent); // IQueryFrame STDMETHOD(AddScope)(THIS_ LPCQSCOPE pScope, INT i, BOOL fSelect); STDMETHOD(GetWindow)(THIS_ HWND* phWnd); STDMETHOD(InsertMenus)(THIS_ HMENU hmenuShared, LPOLEMENUGROUPWIDTHS lpMenuWidth); STDMETHOD(RemoveMenus)(THIS_ HMENU hmenuShared); STDMETHOD(SetMenu)(THIS_ HMENU hmenuShared, HOLEMENU holereservedMenu); STDMETHOD(SetStatusText)(THIS_ LPCTSTR pszStatusText); STDMETHOD(StartQuery)(THIS_ BOOL fStarting); STDMETHOD(LoadQuery)(THIS_ IPersistQuery* pPersistQuery); STDMETHOD(SaveQuery)(THIS_ IPersistQuery* pPersistQuery); STDMETHOD(CallForm)(THIS_ LPCLSID pclsidForm, UINT uMsg, WPARAM wParam, LPARAM lParam); STDMETHOD(GetScope)(THIS_ LPCQSCOPE* ppScope); STDMETHOD(GetHandler)(THIS_ REFIID riid, void **ppv); protected: // Helper functions VOID CloseQueryFrame(HRESULT hres); INT FrameMessageBox(LPCTSTR pPrompt, UINT uType); // Message handlers HRESULT OnInitDialog(HWND hwnd); VOID DoEnableControls(VOID); LRESULT OnNotify(INT idCtrl, LPNMHDR pNotify); VOID OnSize(INT cx, INT cy); VOID OnGetMinMaxInfo(LPMINMAXINFO lpmmi); VOID OnCommand(WPARAM wParam, LPARAM lParam); VOID OnInitMenu(HMENU hMenu); VOID OnEnterMenuLoop(BOOL fEntering); VOID OnMenuSelect(HMENU hMenu, UINT uID); HRESULT OnFindNow(VOID); BOOL OnNewQuery(BOOL fAlwaysPrompt); HRESULT OnBrowse(VOID); HRESULT OnHelp(LPHELPINFO pHelpInfo); // Form/Scope helper fucntions HRESULT InsertScopeIntoList(LPCQSCOPE pScope, INT i, BOOL fAddToControl); HRESULT AddScopeToControl(LPQUERYSCOPE pQueryScope, INT i); HRESULT PopulateScopeControl(VOID); HRESULT GetSelectedScope(LPQUERYSCOPE* ppQueryScope); HRESULT AddFromIQueryForm(IQueryForm* pQueryForm, HKEY hkeyForm); HRESULT GatherForms(VOID); HRESULT GetForms(HKEY hKeyForms, LPTSTR pName); HRESULT PopulateFormControl(BOOL fIncludeHidden); HRESULT SelectForm(REFCLSID clsidForm); VOID SelectFormPage(LPQUERYFORM pQueryForm, INT iPage); HRESULT CallFormPages(LPQUERYFORM pQueryForm, UINT uMsg, WPARAM wParam, LPARAM lParam); LPQUERYFORM FindQueryForm(REFCLSID clsidForm); private: LONG _cRef; // reference count for the object IUnknown* _punkSite; // site object we need to pass through IQueryHandler* _pQueryHandler; // IQueryHandler object we need to interact with LPOPENQUERYWINDOW _pOpenQueryWnd; // copy of initial parameters provided by caller IDataObject** _ppDataObject; // receives the resulting data object from handler DWORD _dwHandlerViewFlags; // flags from the handler BOOL _fQueryRunning:1; // = 1 => query has been started, via IQueryFrame::StartQuery(TRUE) BOOL _fExitModalLoop:1; // = 1 => must leave modal loop BOOL _fScopesPopulated:1; // = 1 => scope control has been populated BOOL _fTrackingMenuBar:1; // = 1 => then we are tracking the menu bar, therefore send activates etc BOOL _fAddScopesNYI:1; // = 1 => did AddScopes return E_NOTIMPL BOOL _fScopesAddedAsync:1; // = 1 => scopes added async by the handler BOOL _fScopeImageListSet:1; // = 1 => scope image list has been set BOOL _fFormFirstEnable:1; // = 1 => enabling controls for first item, so ensure we set focus HRESULT _hResult; // result value stored by CloseQueryFrame HKEY _hkHandler; // registry key for the handler HWND _hwnd; // main window handle HWND _hwndResults; // result viewer HWND _hwndStatus; // status bar HWND _hwndFrame; // Query Pages tab control HWND _hwndLookForLabel; // "Find:" HWND _hwndLookFor; // Form combo HWND _hwndLookInLabel; // "In:" HWND _hwndLookIn; // Scope combo HWND _hwndBrowse; // "Browse" HWND _hwndFindNow; // "Find now" HWND _hwndStop; // "Stop" HWND _hwndNewQuery; // "New Query" HWND _hwndOK; // "OK" HWND _hwndCancel; // "Cancel" HWND _hwndFindAnimation; // Query issued animation HICON _hiconSmall; // large/small app icons HICON _hiconLarge; HMENU _hmenuFile; // handle of the frames menu bar HIMAGELIST _himlForms; // image list for query form objects SIZE _szMinTrack; // minimum track size of the window INT _dxFormAreaLeft; // offset to left edge of form area (from window left) INT _dxFormAreaRight; // offset to right edge of form area (from window right) INT _dxButtonsLeft; // offset to left edge of buttons (from window right) INT _dxAnimationLeft; // offset to left edge of aniimation (from window right) INT _dyResultsTop; // offset to top of results (from top of window) INT _dyOKTop; // offset to top of "OK" buttom (from results top) INT _dxGap; // gap between OK + Cancel / LookIn + Browse INT _dyGap; // gap between bottom of OK,Cancel and the frame. INT _cyStatus; // height of the status bar HDSA _hdsaForms; // forms DSA HDSA _hdsaPages; // pages DSA SIZE _szForm; // size of the (current form we are displaying) HDSA _hdsaScopes; // scopes DSA INT _iDefaultScope; // index of the defualt scope to select (into DSA) LPQUERYFORM _pCurrentForm; // == NULL if none / else -> form structure LPQUERYFORMPAGE _pCurrentFormPage; // == NULL if none / else -> page structure }; // // Helper functions // INT_PTR CALLBACK QueryWnd_DlgProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam); INT QueryWnd_MessageProc(HWND hwnd, LPMSG pMsg); HRESULT _CallScopeProc(LPQUERYSCOPE pQueryScope, UINT uMsg, LPVOID pVoid); INT _FreeScope(LPQUERYSCOPE pQueryScope); INT _FreeScopeCB(LPVOID pItem, LPVOID pData); HRESULT _CallPageProc(LPQUERYFORMPAGE pQueryFormPage, UINT uMsg, WPARAM wParam, LPARAM lParam); INT _FreeQueryFormCB(LPVOID pItem, LPVOID pData); INT _FreeQueryForm(LPQUERYFORM pQueryForm); INT _FreeQueryFormPageCB(LPVOID pItem, LPVOID pData); INT _FreeQueryFormPage(LPQUERYFORMPAGE pQueryFormPage); HRESULT _AddFormsProc(LPARAM lParam, LPCQFORM pForm); HRESULT _AddPagesProc(LPARAM lParam, REFCLSID clsidForm, LPCQPAGE pPage); // // Help stuff // #define HELP_FILE (NULL) static DWORD const aHelpIDs[] = { 0, 0 }; // // constant strings // TCHAR const c_szCLSID[] = TEXT("CLSID"); TCHAR const c_szForms[] = TEXT("Forms"); TCHAR const c_szFlags[] = TEXT("Flags"); TCHAR const c_szCommonQuery[] = TEXT("CommonQuery"); TCHAR const c_szHandlerIs[] = TEXT("Handler"); TCHAR const c_szFormIs[] = TEXT("Form"); TCHAR const c_szSearchPaneHidden[] = TEXT("SearchPaneHidden"); /*----------------------------------------------------------------------------- / CCommonQuery /----------------------------------------------------------------------------*/ CCommonQuery::CCommonQuery() : _punkSite(NULL), _cRef(1) { DllAddRef(); } CCommonQuery::~CCommonQuery() { DoRelease(_punkSite); DllRelease(); } // QI handling ULONG CCommonQuery::AddRef() { return InterlockedIncrement(&_cRef); } ULONG CCommonQuery::Release() { TraceAssert( 0 != _cRef ); ULONG cRef = InterlockedDecrement(&_cRef); if ( 0 == cRef ) { delete this; } return cRef; } HRESULT CCommonQuery::QueryInterface(REFIID riid, void **ppv) { static const QITAB qit[] = { QITABENT(CCommonQuery, ICommonQuery), // IID_ICommonQuery QITABENT(CCommonQuery, IObjectWithSite), // IID_IObjectWithSite {0, 0 }, }; return QISearch(this, qit, riid, ppv); } STDAPI CCommonQuery_CreateInstance(IUnknown* punkOuter, IUnknown** ppunk, LPCOBJECTINFO poi) { CCommonQuery *pcq = new CCommonQuery; if (!pcq) return E_OUTOFMEMORY; HRESULT hres = pcq->QueryInterface(IID_IUnknown, (void **)ppunk); pcq->Release(); return hres; } // ICommonQuery methods STDMETHODIMP CCommonQuery::OpenQueryWindow(THIS_ HWND hwndParent, LPOPENQUERYWINDOW pOpenQueryWnd, IDataObject** ppDataObject) { HRESULT hres; CQueryFrame* pQueryFrame = NULL; TraceEnter(TRACE_QUERY, "CCommonQuery::OpenQueryWindow"); if (!pOpenQueryWnd || (hwndParent && !IsWindow(hwndParent))) ExitGracefully(hres, E_INVALIDARG, "Bad parameters"); if (ppDataObject) *(ppDataObject) = NULL; pQueryFrame = new CQueryFrame(_punkSite, pOpenQueryWnd, ppDataObject); TraceAssert(pQueryFrame); if (!pQueryFrame) ExitGracefully(hres, E_OUTOFMEMORY, "Failed to construct the query window object"); hres = pQueryFrame->DoModal(hwndParent); // don't bother fail gracefully etc FailGracefully(hres, "Failed on calling DoModal"); exit_gracefully: DoRelease(pQueryFrame); TraceLeaveResult(hres); } // IObjectWithSite STDMETHODIMP CCommonQuery::SetSite(IUnknown* punk) { HRESULT hres = S_OK; TraceEnter(TRACE_QUERY, "CCommonQuery::SetSite"); DoRelease(_punkSite); if (punk) { TraceMsg("QIing for IUnknown from the site object"); hres = punk->QueryInterface(IID_IUnknown, (void **)&_punkSite); FailGracefully(hres, "Failed to get IUnknown from the site object"); } exit_gracefully: TraceLeaveResult(hres); } STDMETHODIMP CCommonQuery::GetSite(REFIID riid, void **ppv) { HRESULT hres; TraceEnter(TRACE_QUERY, "CCommonQuery::GetSite"); if (!_punkSite) ExitGracefully(hres, E_NOINTERFACE, "No site to QI from"); hres = _punkSite->QueryInterface(riid, ppv); FailGracefully(hres, "QI failed on the site unknown object"); exit_gracefully: TraceLeaveResult(hres); } // IQueryFrame stuff CQueryFrame::CQueryFrame(IUnknown *punkSite, LPOPENQUERYWINDOW pOpenQueryWindow, IDataObject** ppDataObject) : _cRef(1), _punkSite(punkSite), _pOpenQueryWnd(pOpenQueryWindow), _ppDataObject(ppDataObject), _hiconLarge(NULL), _hiconSmall(NULL) { if (_punkSite) _punkSite->AddRef(); DllAddRef(); } CQueryFrame::~CQueryFrame() { DoRelease(_punkSite); if (_hiconLarge) DestroyIcon(_hiconLarge); if (_hiconSmall) DestroyIcon(_hiconSmall); if (_hkHandler) RegCloseKey(_hkHandler); if (_hmenuFile) DestroyMenu(_hmenuFile); if (_himlForms) ImageList_Destroy(_himlForms); if (_hdsaForms) { Trace(TEXT("Destroying QUERYFORM DSA (%d)"), DSA_GetItemCount(_hdsaForms)); DSA_DestroyCallback(_hdsaForms, _FreeQueryFormCB, NULL); _hdsaForms = NULL; } if (_hdsaPages) { Trace(TEXT("Destroying QUERYFORMPAGE DSA (%d)"), DSA_GetItemCount(_hdsaPages)); DSA_DestroyCallback(_hdsaPages, _FreeQueryFormPageCB, NULL); _hdsaPages = NULL; } if (_hdsaScopes) { Trace(TEXT("Destroying QUERYSCOPE DSA (%d)"), DSA_GetItemCount(_hdsaScopes)); DSA_DestroyCallback(_hdsaScopes, _FreeScopeCB, NULL); _hdsaScopes = NULL; } _pCurrentForm = NULL; _pCurrentFormPage = NULL; // Now discard the handler and its window (if we have one), if // we don't do this they will never kill their objects if (_hwndResults) { DestroyWindow(_hwndResults); _hwndResults = NULL; } DllRelease(); } // QI handling ULONG CQueryFrame::AddRef() { return InterlockedIncrement(&_cRef); } ULONG CQueryFrame::Release() { TraceAssert( 0 != _cRef ); ULONG cRef = InterlockedDecrement(&_cRef); if ( 0 == cRef ) { delete this; } return cRef; } HRESULT CQueryFrame::QueryInterface(REFIID riid, void **ppv) { static const QITAB qit[] = { QITABENT(CQueryFrame, IQueryFrame), // IID_IQueryFrame {0, 0 }, }; return QISearch(this, qit, riid, ppv); } /*----------------------------------------------------------------------------- / IQueryFrame /----------------------------------------------------------------------------*/ STDMETHODIMP CQueryFrame::DoModal(HWND hwndParent) { HRESULT hres; HWND hwndFrame = NULL; HWND hwndFocus = NULL; HWND hwndTopOwner = hwndParent; MSG msg; INITCOMMONCONTROLSEX iccex; TraceEnter(TRACE_FRAME, "CQueryFrame::DoModal"); // initialize with the query handler we need //REVIEWED-2002-02-25-lucios. hres = CoCreateInstance(_pOpenQueryWnd->clsidHandler, NULL, CLSCTX_INPROC_SERVER, IID_IQueryHandler, (LPVOID*)&_pQueryHandler); FailGracefully(hres, "Failed to get IQueryHandler for the given CLSID"); hres = _pQueryHandler->Initialize(this, _pOpenQueryWnd->dwFlags, _pOpenQueryWnd->pHandlerParameters); FailGracefully(hres, "Failed to initialize the handler"); // mimic the behaviour of DialogBox by working out which control previously // had focus, which window to disable and then running a message // pump for our dialog. Having done this we can then restore the state // back to something sensible. _fExitModalLoop = FALSE; // can be changed from hear down iccex.dwSize = SIZEOF(iccex); iccex.dwICC = ICC_USEREX_CLASSES; InitCommonControlsEx(&iccex); if (_pOpenQueryWnd->dwFlags & OQWF_HIDESEARCHUI) { hwndFrame = CreateDialogParam(GLOBAL_HINSTANCE, MAKEINTRESOURCE(IDD_FILTER), hwndParent, QueryWnd_DlgProc, (LPARAM)this); } else { hwndFrame = CreateDialogParam(GLOBAL_HINSTANCE, MAKEINTRESOURCE(IDD_FIND), hwndParent, QueryWnd_DlgProc, (LPARAM)this); } if (!hwndFrame) ExitGracefully(hres, E_FAIL, "Failed to create the dialog"); hwndFocus = GetFocus(); if (hwndTopOwner) { // walk up the window stack looking for the window to be disabled, this must // be the top-most non-child window. If the resulting window is either // the desktop or is already disabled then don't bother. while (GetWindowLong(hwndTopOwner, GWL_STYLE) & WS_CHILD) hwndTopOwner = GetParent(hwndTopOwner); TraceAssert(hwndTopOwner); if ((hwndTopOwner == GetDesktopWindow()) || EnableWindow(hwndTopOwner, FALSE)) { TraceMsg("Parent is disabled or the desktop window, therefore setting to NULL"); hwndTopOwner = NULL; } } ShowWindow(hwndFrame, SW_SHOW); // show the query window while (!_fExitModalLoop && GetMessage(&msg, NULL, 0, 0) > 0) { if (!QueryWnd_MessageProc(hwndFrame, &msg) && !IsDialogMessage(hwndFrame, &msg)) { TranslateMessage(&msg); DispatchMessage(&msg); } } // Now tidy up, make the parent the active window, enable the top most // window if there is one and restore focus as required. if (hwndTopOwner) EnableWindow(hwndTopOwner, TRUE); if (hwndParent && (GetActiveWindow() == hwndFrame)) { TraceMsg("Passing activation to parent"); SetActiveWindow(hwndParent); } if (IsWindow(hwndFocus)) SetFocus(hwndFocus); DestroyWindow(hwndFrame); // discard the current frame window exit_gracefully: DoRelease(_pQueryHandler); TraceLeaveResult(_hResult); } /*---------------------------------------------------------------------------*/ STDMETHODIMP CQueryFrame::AddScope(THIS_ LPCQSCOPE pScope, INT i, BOOL fSelect) { HRESULT hres; TraceEnter(TRACE_FRAME, "CQueryFrame::AddScope"); if (!pScope) ExitGracefully(hres, E_INVALIDARG, "No scope to add to the list"); // Add the scope to the control and then ensure that we either have // its index stored (for default selection) or we select the // item. if (!_hdsaScopes || !DSA_GetItemCount(_hdsaScopes)) { TraceMsg("First scope being added, thefore selecting"); fSelect = TRUE; } hres = InsertScopeIntoList(pScope, i, _fScopesPopulated); FailGracefully(hres, "Failed to add scope to control"); if (fSelect) { if (!_fScopesPopulated) { Trace(TEXT("Storing default scope index %d"), ShortFromResult(hres)); _iDefaultScope = ShortFromResult(hres); } else { Trace(TEXT("Selecting scope index %d"), ShortFromResult(hres)); ComboBox_SetCurSel(_hwndLookIn, ShortFromResult(hres)); } } // hres = S_OK; exit_gracefully: TraceLeaveResult(hres); } /*---------------------------------------------------------------------------*/ STDMETHODIMP CQueryFrame::GetWindow(THIS_ HWND* phWnd) { TraceEnter(TRACE_FRAME, "CQueryFrame::GetWindow"); TraceAssert(phWnd); *phWnd = _hwnd; TraceLeaveResult(S_OK); } /*---------------------------------------------------------------------------*/ // Add a menu group to the given menu bar, updating the width index accordingly // so that other people can merge in accordingly VOID _DoInsertMenu(HMENU hMenu, INT iIndexTo, HMENU hMenuToInsert, INT iIndexFrom) { TCHAR szBuffer[MAX_PATH]; HMENU hPopupMenu = NULL; TraceEnter(TRACE_FRAME, "_DoInsertMenu"); hPopupMenu = CreatePopupMenu(); if (hPopupMenu) { Shell_MergeMenus(hPopupMenu, GetSubMenu(hMenuToInsert, iIndexFrom), 0x0, 0x0, 0x7fff, 0); //REVIEWED-2002-02-25-lucios. GetMenuString(hMenuToInsert, iIndexFrom, szBuffer, ARRAYSIZE(szBuffer), MF_BYPOSITION); InsertMenu(hMenu, iIndexTo, MF_BYPOSITION|MF_POPUP, (UINT_PTR)hPopupMenu, szBuffer); } TraceLeave(); } VOID _AddMenuGroup(HMENU hMenuShared, HMENU hMenuGroup, LONG iInsertAt, LPLONG pWidth) { HRESULT hres; TCHAR szBuffer[MAX_PATH]; HMENU hMenu; INT i; TraceEnter(TRACE_FRAME, "_AddMenuGroup"); TraceAssert(hMenuShared); TraceAssert(hMenuGroup); TraceAssert(pWidth); for (i = 0 ; i < GetMenuItemCount(hMenuGroup) ; i++) { _DoInsertMenu(hMenuShared, iInsertAt+i, hMenuGroup, i); *pWidth += 1; } TraceLeave(); } STDMETHODIMP CQueryFrame::InsertMenus(THIS_ HMENU hmenuShared, LPOLEMENUGROUPWIDTHS lpMenuWidth) { HRESULT hres; TraceEnter(TRACE_FRAME, "CQueryFrame::InsertMenus"); if (!hmenuShared || !lpMenuWidth) ExitGracefully(hres, E_INVALIDARG, "Unable to insert menus"); // if we don't have the menu bar already loaded then lets load it, // having done that we can then add our menu to the bar (we only // provide entries for the file menu). if (!_hmenuFile) { _hmenuFile = LoadMenu(GLOBAL_HINSTANCE, MAKEINTRESOURCE(IDR_FILEMENUGROUP)); if (!_hmenuFile) ExitGracefully(hres, E_FAIL, "Failed to load base menu defn"); } _AddMenuGroup(hmenuShared, _hmenuFile, 0, &lpMenuWidth->width[0]); hres = S_OK; // success exit_gracefully: TraceLeaveResult(hres); } /*---------------------------------------------------------------------------*/ STDMETHODIMP CQueryFrame::RemoveMenus(THIS_ HMENU hmenuShared) { TraceEnter(TRACE_FRAME, "CQueryFrame::RemoveMenus"); // We don't need to implement this as we copy or menus into the // menu that the handler supplies - fix DSQUERY if this ever // changes. TraceLeaveResult(S_OK); } /*---------------------------------------------------------------------------*/ STDMETHODIMP CQueryFrame::SetMenu(THIS_ HMENU hmenuShared, HOLEMENU holereservedMenu) { TraceEnter(TRACE_FRAME, "CQueryFrame::SetMenu"); if (!(_pOpenQueryWnd->dwFlags & OQWF_HIDEMENUS)) { HMENU hmenuOld = ::GetMenu(_hwnd); if (!hmenuShared) hmenuShared = _hmenuFile; ::SetMenu(_hwnd, hmenuShared); DoEnableControls(); // ensure the menu state is valid ::DrawMenuBar(_hwnd); if (hmenuOld && (hmenuOld != _hmenuFile) && (hmenuOld != hmenuShared)) { TraceMsg("Destroying old menu"); DestroyMenu(hmenuOld); } } TraceLeaveResult(S_OK); } /*---------------------------------------------------------------------------*/ STDMETHODIMP CQueryFrame::SetStatusText(THIS_ LPCTSTR pszStatusText) { TraceEnter(TRACE_FRAME, "CQueryFrame::SetStatusText"); Trace(TEXT("Setting status text to: %s"), pszStatusText); if (_hwndStatus) SendMessage(_hwndStatus, SB_SETTEXT, 0, (LPARAM)pszStatusText); TraceLeaveResult(S_OK); } /*---------------------------------------------------------------------------*/ STDMETHODIMP CQueryFrame::StartQuery(THIS_ BOOL fStarting) { TraceEnter(TRACE_FRAME, "CQueryFrame::StartQuery"); if (fStarting) { Animate_Play(_hwndFindAnimation, 0, -1, -1); } else { Animate_Stop(_hwndFindAnimation); Animate_Seek(_hwndFindAnimation, 0); // go to start } if (_pQueryHandler) _pQueryHandler->ActivateView(CQRVA_STARTQUERY, (WPARAM)fStarting, 0); // now set the controls into a sensble state _fQueryRunning = fStarting; DoEnableControls(); TraceLeaveResult(S_OK); } /*---------------------------------------------------------------------------*/ STDMETHODIMP CQueryFrame::LoadQuery(THIS_ IPersistQuery* pPersistQuery) { HRESULT hres; TCHAR szGUID[GUIDSTR_MAX+1]; LPQUERYFORM pQueryForm = NULL; GUID guid; TraceEnter(TRACE_FRAME, "CQueryFrame::LoadQuery"); _pQueryHandler->StopQuery(); // ensure that the handler stops its processing // Attempt to read the handler GUID from the query stream, first try reading it as // as string then parsing it into something that we can use, if that fails then // try again, but this time read it as a structure. // // having aquired the GUID for the handler make sure that we have the correct handler // selected. if (FAILED(pPersistQuery->ReadString(c_szCommonQuery, c_szHandlerIs, szGUID, ARRAYSIZE(szGUID))) || !GetGUIDFromString(szGUID, &guid)) { TraceMsg("Trying new style handler GUID as struct"); hres = pPersistQuery->ReadStruct(c_szCommonQuery, c_szHandlerIs, &guid, SIZEOF(guid)); FailGracefully(hres, "Failed to read handler GUID as struct"); } if (guid != _pOpenQueryWnd->clsidHandler) ExitGracefully(hres, E_FAIL, "Persisted handler GUID and specified handler GUID don't match"); hres = _pQueryHandler->LoadQuery(pPersistQuery); FailGracefully(hres, "Handler failed to load its query data"); // Get the form ID, then look up the form to see if we have one that matches, // if not then we cannot load any thing else. If we do haved that form then // ensure that we clear it and then load away. if (FAILED(pPersistQuery->ReadString(c_szCommonQuery, c_szFormIs, szGUID, ARRAYSIZE(szGUID))) || !GetGUIDFromString(szGUID, &guid)) { TraceMsg("Trying new style form GUID as struct"); hres = pPersistQuery->ReadStruct(c_szCommonQuery, c_szFormIs, &guid, SIZEOF(guid)); FailGracefully(hres, "Failed to read handler GUID as struct"); } hres = SelectForm(guid); FailGracefully(hres, "Failed to select the query form"); if (hres == S_FALSE) ExitGracefully(hres, E_FAIL, "Failed to select the query form to read the query info"); hres = CallFormPages(_pCurrentForm, CQPM_CLEARFORM, 0, 0); FailGracefully(hres, "Failed to clear form before loading"); // Load the persisted query from the stream, coping correctly with the // UNICODE / ANSI issue. We will be passed an IPersistQuery object which // we must then thunk accordingly if we are UNICODE for the pages we // are going to talk to. hres = CallFormPages(_pCurrentForm, CQPM_PERSIST, TRUE, (LPARAM)pPersistQuery); FailGracefully(hres, "Failed to load page data (UNICODE)"); hres = S_OK; // success exit_gracefully: if (SUCCEEDED(hres)) { TraceMsg("Query loaded successfully, select form query"); SelectForm(guid); } TraceLeaveResult(hres); } /*---------------------------------------------------------------------------*/ STDMETHODIMP CQueryFrame::SaveQuery(THIS_ IPersistQuery* pPersistQuery) { HRESULT hres; LPQUERYSCOPE pQueryScope; TCHAR szBuffer[MAX_PATH]; TraceEnter(TRACE_FRAME, "CQueryFrame::SaveQuery"); if (!pPersistQuery) ExitGracefully(hres, E_INVALIDARG, "No pPersistQuery object to write into"); pPersistQuery->Clear(); // flush the contents hres = pPersistQuery->WriteStruct(c_szCommonQuery, c_szHandlerIs, &_pOpenQueryWnd->clsidHandler, SIZEOF(_pOpenQueryWnd->clsidHandler)); FailGracefully(hres, "Failed to write handler GUID"); hres = pPersistQuery->WriteStruct(c_szCommonQuery, c_szFormIs, &_pCurrentForm->clsidForm, SIZEOF(_pCurrentForm->clsidForm)); FailGracefully(hres, "Failed to write form GUID"); // Allow the handler to persist itself into the the stream, this includes // giving it the current scope to store. hres = GetSelectedScope(&pQueryScope); FailGracefully(hres, "Failed to get the scope from the LookIn control"); hres = _pQueryHandler->SaveQuery(pPersistQuery, pQueryScope->pScope); FailGracefully(hres, "Failed when calling handler to persist itself"); // Save the query into the stream, coping correctly with the // UNICODE / ANSI issue. We will be passed an IPersistQuery object which // we must then thunk accordingly if we are UNICODE for the pages we // are going to talk to. hres = CallFormPages(_pCurrentForm, CQPM_PERSIST, FALSE, (LPARAM)pPersistQuery); FailGracefully(hres, "Failed to load page data (UNICODE)"); hres = S_OK; exit_gracefully: TraceLeaveResult(hres); } /*---------------------------------------------------------------------------*/ STDMETHODIMP CQueryFrame::CallForm(THIS_ LPCLSID pclsidForm, UINT uMsg, WPARAM wParam, LPARAM lParam) { HRESULT hres; LPQUERYFORM pQueryForm = _pCurrentForm; TraceEnter(TRACE_FRAME, "CQueryFrame::CallForm"); if (pclsidForm) { pQueryForm = FindQueryForm(*pclsidForm); TraceAssert(pQueryForm); } if (!pQueryForm) ExitGracefully(hres, E_FAIL, "Failed to find query form for given CLSID"); hres = CallFormPages(pQueryForm, uMsg, wParam, lParam); FailGracefully(hres, "Failed when calling CallFormPages"); // hres = S_OK; exit_gracefully: TraceLeaveResult(hres); } /*---------------------------------------------------------------------------*/ STDMETHODIMP CQueryFrame::GetScope(THIS_ LPCQSCOPE* ppScope) { HRESULT hres; LPQUERYSCOPE pQueryScope; TraceEnter(TRACE_FRAME, "CQueryFrame::GetScope"); if (!ppScope) ExitGracefully(hres, E_INVALIDARG, "ppScope == NULL, thats bad"); hres = GetSelectedScope(&pQueryScope); FailGracefully(hres, "Failed to get the current scope"); *ppScope = (LPCQSCOPE)CoTaskMemAlloc(pQueryScope->pScope->cbStruct); TraceAssert(*ppScope); if (!*ppScope) ExitGracefully(hres, E_OUTOFMEMORY, "Failed to allocate the scope block"); //REVIEWED-2002-02-25-lucios. memcpy(*ppScope, pQueryScope->pScope, pQueryScope->pScope->cbStruct); hres = S_OK; exit_gracefully: TraceLeaveResult(hres); } /*---------------------------------------------------------------------------*/ STDMETHODIMP CQueryFrame::GetHandler(THIS_ REFIID riid, void **ppv) { HRESULT hres; TraceEnter(TRACE_FRAME, "CQueryFrame::GetHandler"); if (!_pQueryHandler) ExitGracefully(hres, E_UNEXPECTED, "_pQueryHandler is NULL"); hres = _pQueryHandler->QueryInterface(riid, ppv); exit_gracefully: TraceLeaveResult(hres); } /*----------------------------------------------------------------------------- / Dialog box handler functions (core guts) /----------------------------------------------------------------------------*/ #define REAL_WINDOW(hwnd) \ (hwnd && \ IsWindowVisible(hwnd) && \ IsWindowEnabled(hwnd) && \ (GetWindowLong(hwnd, GWL_STYLE) & WS_TABSTOP)) HWND _NextTabStop(HWND hwndSearch, BOOL fShift) { HWND hwnd; Trace(TEXT("hwndSearch %08x, fShift %d"), hwndSearch, fShift); // do we have a window to search into? while (hwndSearch) { // if we have a window then lets check to see if it has any children? hwnd = GetWindow(hwndSearch, GW_CHILD); Trace(TEXT("Child of %08x is %08x"), hwndSearch, hwnd); if (hwnd) { // it has a child therefore lets to go its first/last // and continue the search there for a window that // matches the criteria we are looking for. hwnd = GetWindow(hwnd, fShift ? GW_HWNDLAST:GW_HWNDFIRST); if (!REAL_WINDOW(hwnd)) { Trace(TEXT("Trying to recurse into %08x"), hwnd); hwnd = _NextTabStop(hwnd, fShift); } Trace(TEXT("Tabstop child of %08x is %08x"), hwndSearch, hwnd); } // after all that is hwnd a valid window? if so then pass // that back out to the caller. if (REAL_WINDOW(hwnd)) { Trace(TEXT("Child tab stop was %08x"), hwnd); return hwnd; } // do we have a sibling? if so then lets return that otherwise // lets just continue to search until we either run out of windows // or hit something interesting hwndSearch = GetWindow(hwndSearch, fShift ? GW_HWNDPREV:GW_HWNDNEXT); if (REAL_WINDOW(hwndSearch)) { Trace(TEXT("Next tab stop was %08x"), hwndSearch); return hwndSearch; } } return hwndSearch; } INT QueryWnd_MessageProc(HWND hwnd, LPMSG pMsg) { LRESULT lResult = 0; CQueryFrame* pQueryFrame = NULL; NMHDR nmhdr; pQueryFrame = (CQueryFrame*)GetWindowLongPtr(hwnd, DWLP_USER); if (!pQueryFrame) return 0; if ((pMsg->message == WM_KEYDOWN) && (pMsg->wParam == VK_TAB)) { BOOL fCtrl = GetAsyncKeyState(VK_CONTROL) < 0; BOOL fShift = GetAsyncKeyState(VK_SHIFT) < 0; // ensure that the focus rectangles are shown #if (_WIN32_WINNT >= 0x0500) SendMessage(hwnd, WM_CHANGEUISTATE, MAKEWPARAM(UIS_CLEAR, UISF_HIDEFOCUS), 0); #endif if (fCtrl) { // if this is a key press within the parent then lets ensure that we // allow the tab control to change the page correctly. otherwise lets // just hack around the problem of the result view not handling tabs // properly. INT iCur = TabCtrl_GetCurSel(pQueryFrame->_hwndFrame); INT nPages = TabCtrl_GetItemCount(pQueryFrame->_hwndFrame); if (fShift) iCur += (nPages-1); else iCur++; pQueryFrame->SelectFormPage(pQueryFrame->_pCurrentForm, iCur % nPages); return 1; // we processed it } else { // is the window that has the focus a child of the result view, if // so then we must attempt to pass focus to its 1st child and hope // that is can do the rest. HWND hwndNext, hwndFocus = GetFocus(); Trace(TEXT("Current focus window %08x"), hwndFocus); while (hwndFocus && GetWindowLong(hwndFocus, GWL_STYLE) & WS_CHILD) { hwndNext = _NextTabStop(hwndFocus, fShift); Trace(TEXT("_NextTabStop yeilds %08x from %08x"), hwndNext, hwndFocus); if (hwndNext) { Trace(TEXT("SetFocus on child %08x"), hwndNext); SendMessage(GetParent(hwndNext),WM_NEXTDLGCTL,(WPARAM)hwndNext,TRUE); SetFocus(hwndNext); return 1; } while (TRUE) { // look up the parent list trying to find a window that we can // tab back into. We must watch that when we walk out of the // child list we loop correctly at the top of the list. hwndNext = GetParent(hwndFocus); Trace(TEXT("Parent hwnd %08x"), hwndNext); if (GetWindowLong(hwndNext, GWL_STYLE) & WS_CHILD) { // the parent window is a child, therefore we can check // to see if has any siblings. Trace(TEXT("hwndNext is a child, therefore hwndNext of it is %08x"), GetWindow(hwndNext, fShift ? GW_HWNDPREV:GW_HWNDNEXT)); if (GetWindow(hwndNext, fShift ? GW_HWNDPREV:GW_HWNDNEXT)) { hwndFocus = GetWindow(hwndNext, fShift ? GW_HWNDPREV:GW_HWNDNEXT); Trace(TEXT("Silbing window found %08x"), hwndFocus); break; } else { TraceMsg("There was no sibling, therefore continuing parent loop"); hwndFocus = hwndNext; } } else { // we have hit the parent window of it all (the overlapped one) // therefore we must attempt to go to its first child. Walk forward // in the stack looking for a window that matches the // "REAL_WINDOW" conditions. hwndFocus = GetWindow(hwndFocus, fShift ? GW_HWNDLAST:GW_HWNDFIRST); Trace(TEXT("First child is %08x"), hwndFocus); break; // continue the sibling search etc } } if (REAL_WINDOW(hwndFocus)) { SendMessage(GetParent(hwndFocus),WM_NEXTDLGCTL,(WPARAM)hwndFocus,TRUE); SetFocus(hwndFocus); return 1; } } } } return 0; } // // Main DLGPROC // INT_PTR CALLBACK QueryWnd_DlgProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) { CQueryFrame* pQueryFrame; if (uMsg == WM_INITDIALOG) { HRESULT hres; pQueryFrame = (CQueryFrame*)lParam; SetWindowLongPtr(hwnd, DWLP_USER, (LRESULT)pQueryFrame); hres = pQueryFrame->OnInitDialog(hwnd); Trace(TEXT("OnInitDialog returns %08x"), hres); if (FAILED(hres)) { TraceMsg("Failed to initialize the dialog, Destroying the window"); pQueryFrame->CloseQueryFrame(hres); DestroyWindow(hwnd); } } else { pQueryFrame = (CQueryFrame*)GetWindowLongPtr(hwnd, DWLP_USER); if (!pQueryFrame) goto exit_gracefully; switch (uMsg) { case WM_ERASEBKGND: { HDC hdc = (HDC)wParam; RECT rc; // if we have a DC then lets fill it, and if we have a // query form then lets paint the divider between the menu bar and // this area. if (hdc) { GetClientRect(hwnd, &rc); FillRect(hdc, &rc, (HBRUSH)(COLOR_3DFACE+1)); if (!(pQueryFrame->_pOpenQueryWnd->dwFlags & OQWF_HIDEMENUS)) DrawEdge(hdc, &rc, EDGE_ETCHED, BF_TOP); SetWindowLongPtr(hwnd, DWLP_MSGRESULT, 1L); } return 1; } case WM_NOTIFY: return pQueryFrame->OnNotify((int)wParam, (LPNMHDR)lParam); case WM_SIZE: pQueryFrame->OnSize(LOWORD(lParam), HIWORD(lParam)); return(1); case WM_GETMINMAXINFO: pQueryFrame->OnGetMinMaxInfo((LPMINMAXINFO)lParam); return(1); case WM_COMMAND: pQueryFrame->OnCommand(wParam, lParam); return(1); case WM_ACTIVATE: pQueryFrame->_pQueryHandler->ActivateView(wParam ? CQRVA_ACTIVATE : CQRVA_DEACTIVATE, 0, 0); // NTRAID#NTBUG9-411693-2001/10/24-lucios // We return 0 so that we don't call DefWndProc and therefore the // focus is not set to the first child control return(0); case WM_INITMENU: pQueryFrame->OnInitMenu((HMENU)wParam); return(1); case WM_SETCURSOR: { // do we have any scopes? if not then let us display the wait // cursor for the user. if we have a query running then lets // display the app start cursor. if (!pQueryFrame->_fAddScopesNYI && !ComboBox_GetCount(pQueryFrame->_hwndLookIn)) { if (LOWORD(lParam) == HTCLIENT) { SetCursor(LoadCursor(NULL, MAKEINTRESOURCE(IDC_WAIT))); SetWindowLongPtr(hwnd, DWLP_MSGRESULT, 1L); return 1; } } break; } case WM_INITMENUPOPUP: { // only send sub-menu activates if the menu bar is being tracked, this is // handled within OnInitMenu, if we are not tracking the menu then we // assume that the client has already primed the menu and that they are // using some kind of popup menu. if (pQueryFrame->_fTrackingMenuBar) pQueryFrame->_pQueryHandler->ActivateView(CQRVA_INITMENUBARPOPUP, wParam, lParam); return(1); } case WM_ENTERMENULOOP: pQueryFrame->OnEnterMenuLoop(TRUE); return(1); case WM_EXITMENULOOP: pQueryFrame->OnEnterMenuLoop(FALSE); return(1); case WM_MENUSELECT: { UINT uID = LOWORD(wParam); UINT uFlags = HIWORD(wParam); HMENU hMenu = (HMENU)lParam; // the command opens a popup menu the the uID is actually // the index into the menu, so lets ensure that we pick // up the correct ID by calling GetMenuItemInfo, note that // GetMenuItemID returns -1 in this case which is totally // useless. if (uFlags & MF_POPUP) { MENUITEMINFO mii; ZeroMemory(&mii, SIZEOF(mii)); mii.cbSize = SIZEOF(mii); mii.fMask = MIIM_ID; if (GetMenuItemInfo(hMenu, uID, TRUE, &mii)) uID = mii.wID; } pQueryFrame->OnMenuSelect(hMenu, uID); return(1); } case WM_SYSCOMMAND: if (wParam == SC_CLOSE) { pQueryFrame->CloseQueryFrame(S_FALSE); return(1); } break; case WM_CONTEXTMENU: { // there are a couple of controls we don't care about for the // frame, so lets ignore those when passing the CQRVA_CONTEXTMENU // through to the handler. POINT pt = { GET_X_LPARAM(lParam), GET_Y_LPARAM(lParam) }; ScreenToClient((HWND)wParam, &pt); switch (GetDlgCtrlID(ChildWindowFromPoint((HWND)wParam, pt))) { case IDC_FORMAREA: case IDC_FINDANIMATION: case IDC_STATUS: return TRUE; // handled default: pQueryFrame->_pQueryHandler->ActivateView(CQRVA_CONTEXTMENU, wParam, lParam); return TRUE; } return FALSE; } case WM_HELP: { LPHELPINFO phi = (LPHELPINFO)lParam; // filter out those controls we are not interested in (they make no sense) // to bother the user with switch (GetDlgCtrlID((HWND)phi->hItemHandle)) { case IDC_FORMAREA: case IDC_FINDANIMATION: case IDC_STATUS: return TRUE; default: pQueryFrame->OnHelp(phi); return TRUE; } return FALSE; } case CQFWM_ADDSCOPE: { LPCQSCOPE pScope = (LPCQSCOPE)wParam; BOOL fSelect = LOWORD(lParam); INT iIndex = HIWORD(lParam); if (SUCCEEDED(pQueryFrame->AddScope(pScope, iIndex, fSelect))) SetWindowLongPtr(hwnd, DWLP_MSGRESULT, 1L); return 1; } case CQFWM_GETFRAME: { IQueryFrame** ppQueryFrame = (IQueryFrame**)lParam; if (ppQueryFrame) { pQueryFrame->AddRef(); *ppQueryFrame = pQueryFrame; SetWindowLongPtr(hwnd, DWLP_MSGRESULT, 1L); } return 1; } case CQFWM_ALLSCOPESADDED: { // there is an async scope collector, it has added all the scopes // so we must now attempt to issue the query if the we are in the // holding pattern waiting for the scopes to be collected. pQueryFrame->_fScopesAddedAsync = FALSE; // all scopes have been added if (pQueryFrame->_pOpenQueryWnd->dwFlags & OQWF_ISSUEONOPEN) PostMessage(pQueryFrame->_hwnd, CQFWM_STARTQUERY, 0, 0); return 1; } case CQFWM_STARTQUERY: pQueryFrame->OnFindNow(); return 1; case CQFWM_SETDEFAULTFOCUS: { HWND hwndNextTab = _NextTabStop(pQueryFrame->_pCurrentFormPage->hwndPage, FALSE); SendMessage(pQueryFrame->_pCurrentFormPage->hwndPage, WM_NEXTDLGCTL, (WPARAM)hwndNextTab, 1); break; } default: break; } } exit_gracefully: return(0); } /*----------------------------------------------------------------------------- / CQueryFrame::CloseQueryFrame / ---------------------------- / Close the query window passing back the data object if required, and ensuring / that our result code indicates what is going on. / / In: / hResult = result code to pass to the caller / / Out: / - /----------------------------------------------------------------------------*/ VOID CQueryFrame::CloseQueryFrame(HRESULT hres) { TraceEnter(TRACE_FRAME, "CQueryFrame::CloseQueryFrame"); Trace(TEXT("hResult %08x"), hres); // If we succeeded then attempt to collect the IDataObject and pass it // back to the caller. if (hres == S_OK) { if (_ppDataObject) { hres = _pQueryHandler->GetViewObject(CQRVS_SELECTION, IID_IDataObject, (LPVOID*)_ppDataObject); FailGracefully(hres, "Failed when collecting the data object"); } if ((_pOpenQueryWnd->dwFlags & OQWF_SAVEQUERYONOK) && _pOpenQueryWnd->pPersistQuery) { hres = SaveQuery(_pOpenQueryWnd->pPersistQuery); FailGracefully(hres, "Failed when persisting query to IPersistQuery blob"); } hres = S_OK; // success } exit_gracefully: _hResult = hres; _fExitModalLoop = TRUE; // bomb out of the modal loop TraceLeave(); } /*----------------------------------------------------------------------------- / CQueryFrame::FrameMessageBox / ---------------------------- / Our message box for putting up prompts that relate to the current / query. We handle getting the view information and displaying / the prompt, returning the result from MessageBox. / / In: / pPrompt = text displayed as a prompt / uType = message box type / / Out: / INT /----------------------------------------------------------------------------*/ INT CQueryFrame::FrameMessageBox(LPCTSTR pPrompt, UINT uType) { TCHAR szTitle[MAX_PATH]; CQVIEWINFO vi; TraceEnter(TRACE_FRAME, "CQueryFrame::FrameMessageBox"); ZeroMemory(&vi, SIZEOF(vi)); //vi. dwFlags = 0; // display attributes if (SUCCEEDED(_pQueryHandler->GetViewInfo(&vi)) && vi.hInstance && vi.idTitle) LoadString(vi.hInstance, vi.idTitle, szTitle, ARRAYSIZE(szTitle)); else GetWindowText(_hwnd, szTitle, ARRAYSIZE(szTitle)); TraceLeaveValue(MessageBox(_hwnd, pPrompt, szTitle, uType)); } /*----------------------------------------------------------------------------- / CQueryFrame::OnInitDlg / ---------------------- / Handle a WM_INITDAILOG message, this is sent as the first thing the / dialog receives, therefore we must handle our initialization that / was not handled in the constructor. / / In: / hwnd = handle of dialog we are initializing / / Out: / HRESULT /----------------------------------------------------------------------------*/ HRESULT CQueryFrame::OnInitDialog(HWND hwnd) { HRESULT hres; HICON hIcon = NULL; TCHAR szGUID[GUIDSTR_MAX+1]; TCHAR szBuffer[MAX_PATH]; CQVIEWINFO vi; INT dyControls = 0; RECT rect, rect2; SIZE size; TraceEnter(TRACE_FRAMEDLG, "CQueryFrame::OnInitDialog"); // get the HKEY for the handler we are using hres = GetKeyForCLSID(_pOpenQueryWnd->clsidHandler, NULL, &_hkHandler); FailGracefully(hres, "Failed to open handlers HKEY"); // pick up the control handles and store them, saves picking them up later _hwnd = hwnd; _hwndFrame = GetDlgItem(hwnd, IDC_FORMAREA); _hwndLookForLabel = GetDlgItem(hwnd, CQID_LOOKFORLABEL); _hwndLookFor = GetDlgItem(hwnd, CQID_LOOKFOR); _hwndLookInLabel = GetDlgItem(hwnd, CQID_LOOKINLABEL); _hwndLookIn = GetDlgItem(hwnd, CQID_LOOKIN); _hwndBrowse = GetDlgItem(hwnd, CQID_BROWSE); _hwndFindNow = GetDlgItem(hwnd, CQID_FINDNOW); _hwndStop = GetDlgItem(hwnd, CQID_STOP); _hwndNewQuery = GetDlgItem(hwnd, CQID_CLEARALL); _hwndFindAnimation = GetDlgItem(hwnd, IDC_FINDANIMATION); _hwndOK = GetDlgItem(hwnd, IDOK); _hwndCancel = GetDlgItem(hwnd, IDCANCEL); // when enable is called this will be the first _fFormFirstEnable = TRUE; // call the IQueryHandler interface and get its display attributes, // then reflect these into the dialog we are about to display to the // outside world. vi.dwFlags = 0; vi.hInstance = NULL; vi.idLargeIcon = 0; vi.idSmallIcon = 0; vi.idTitle = 0; vi.idAnimation = 0; hres = _pQueryHandler->GetViewInfo(&vi); FailGracefully(hres, "Failed when getting the view info from the handler"); _dwHandlerViewFlags = vi.dwFlags; if (vi.hInstance) { HICON hiTemp = NULL; if (vi.idLargeIcon) { _hiconLarge = (HICON)LoadImage(vi.hInstance, MAKEINTRESOURCE(vi.idLargeIcon), IMAGE_ICON, 0, 0, LR_DEFAULTCOLOR|LR_DEFAULTSIZE); if (_hiconLarge) SendMessage(hwnd, WM_SETICON, ICON_BIG, (LPARAM)_hiconLarge); } if (vi.idSmallIcon) { _hiconSmall = (HICON)LoadImage(vi.hInstance, MAKEINTRESOURCE(vi.idLargeIcon), IMAGE_ICON, GetSystemMetrics(SM_CXSMICON), GetSystemMetrics(SM_CYSMICON), LR_DEFAULTCOLOR); if (_hiconSmall) SendMessage(hwnd, WM_SETICON, ICON_SMALL, (LPARAM)_hiconSmall); } if (vi.idTitle) { LoadString(vi.hInstance, vi.idTitle, szBuffer, ARRAYSIZE(szBuffer)); SetWindowText(hwnd, szBuffer); } } if (vi.hInstance && vi.idAnimation) { SetWindowLongPtr(_hwndFindAnimation, GWLP_HINSTANCE, (LRESULT)vi.hInstance); Animate_Open(_hwndFindAnimation, MAKEINTRESOURCE(vi.idAnimation)); } else { Animate_Open(_hwndFindAnimation, MAKEINTRESOURCE(IDR_FINDANIMATION)); } // now adjust the positions and hide the controls we are not interested in if (_pOpenQueryWnd->dwFlags & OQWF_REMOVEFORMS) { // NTRAID#NTBUG9-619016-2002/05/21-lucios EnableWindow(_hwndLookForLabel,FALSE); ShowWindow(_hwndLookForLabel, SW_HIDE); ShowWindow(_hwndLookFor, SW_HIDE); } if (_pOpenQueryWnd->dwFlags & OQWF_REMOVESCOPES) { // NTRAID#NTBUG9-619016-2002/05/21-lucios EnableWindow(_hwndLookInLabel,FALSE); ShowWindow(_hwndLookInLabel, SW_HIDE); ShowWindow(_hwndLookIn, SW_HIDE); ShowWindow(_hwndBrowse, SW_HIDE); } // hiding both the scopes and the forms control causes us to // move all the controls up by so many units. if ((_pOpenQueryWnd->dwFlags & (OQWF_REMOVEFORMS|OQWF_REMOVESCOPES)) == (OQWF_REMOVEFORMS|OQWF_REMOVESCOPES)) { GetRealWindowInfo(_hwndLookForLabel, &rect, NULL); GetRealWindowInfo(_hwndFrame, &rect2, NULL); dyControls += rect2.top - rect.top; Trace(TEXT("Moving all controls up by %d units"), dyControls); OffsetWindow(_hwndFrame, 0, -dyControls); OffsetWindow(_hwndFindNow, 0, -dyControls); OffsetWindow(_hwndStop, 0, -dyControls); OffsetWindow(_hwndNewQuery, 0, -dyControls); OffsetWindow(_hwndFindAnimation, 0, -dyControls); OffsetWindow(_hwndOK, 0, -dyControls); if (_hwndCancel) OffsetWindow(_hwndCancel, 0, -dyControls); } // hiding OK/Cancel so lets adjust the size here to include the // OK/Cancel buttons disappearing, note that we update dyControls // to include this delta if (!(_pOpenQueryWnd->dwFlags & OQWF_OKCANCEL)) { ShowWindow(_hwndOK, SW_HIDE); if (_hwndCancel) ShowWindow(_hwndCancel, SW_HIDE); // if this is the filter dialog then lets ensure that // we trim the OK/Cancel buttons from the size by adjusting the // dyControls further. GetRealWindowInfo(_hwndOK, &rect, NULL); GetRealWindowInfo(_hwndFrame, &rect2, NULL); dyControls += rect.bottom - rect2.bottom; } // having performed that extra bit of initialization lets cache the // positions of the various controls, to make sizing more fun... GetClientRect(hwnd, &rect2); rect2.bottom -= dyControls; _dyResultsTop = rect2.bottom; GetRealWindowInfo(hwnd, NULL, &size); GetRealWindowInfo(_hwndFrame, &rect, &_szForm); Trace(TEXT("dyControls %d"), dyControls); size.cy -= dyControls; _dxFormAreaLeft = rect.left; _dxFormAreaRight = rect2.right - rect.right; _szMinTrack.cx = size.cx - _szForm.cx; _szMinTrack.cy = size.cy - _szForm.cy; if (!(_pOpenQueryWnd->dwFlags & OQWF_HIDEMENUS)) { TraceMsg("Adjusting _szMinTrack.cy to account for menu bar"); _szMinTrack.cy += GetSystemMetrics(SM_CYMENU); } GetRealWindowInfo(_hwndBrowse, &rect, NULL); _dxButtonsLeft = rect2.right - rect.left; GetRealWindowInfo(_hwndLookIn, &rect, NULL); _dxGap = (rect2.right - rect.right) - _dxButtonsLeft; GetRealWindowInfo(_hwndFindAnimation, &rect, NULL); _dxAnimationLeft = rect2.right - rect.left; GetRealWindowInfo(_hwndOK, &rect, NULL); _dyOKTop = rect2.bottom - rect.top; _dyGap = size.cy - rect.bottom; // Now collect the forms and pages, then walk them building the size // information that we need. hres = GatherForms(); FailGracefully(hres, "Failed to init form list"); _szMinTrack.cx += _szForm.cx; _szMinTrack.cy += _szForm.cy; // Populate the scope control by querying the handler for them, // if there are none then we display a suitable message box and // let the user know that something went wrong. hres = PopulateScopeControl(); FailGracefully(hres, "Failed to init scope list"); _fScopesPopulated = TRUE; // scope control now populated // perform final fix up of the window, ensure that we size it so that // the entire form and buttons are visible. Then set ourselves into the // no query state and reset the animation. SetWindowPos(hwnd, NULL, 0, 0, _szMinTrack.cx, _szMinTrack.cy, SWP_NOMOVE|SWP_NOZORDER); if (_pOpenQueryWnd->dwFlags & OQWF_HIDEMENUS) ::SetMenu(hwnd, NULL); hres = PopulateFormControl(_pOpenQueryWnd->dwFlags & OQWF_SHOWOPTIONAL); FailGracefully(hres, "Failed to populate form control"); // Now load the query which inturn selects the form that we should be using, // if there is no query to load then either use the default form or // the first in the list. if ((_pOpenQueryWnd->dwFlags & OQWF_LOADQUERY) && _pOpenQueryWnd->pPersistQuery) { // NTRAID#NTBUG9-627056-2002/06/11-artm // If unable to load query, still show the window but w/out values filled in. HRESULT hResLoad = LoadQuery(_pOpenQueryWnd->pPersistQuery); if (FAILED(hResLoad)) { Trace(TEXT("Failed when trying to load query from supplied IPersistQuery with error %x"), hResLoad); } } else { if (_pOpenQueryWnd->dwFlags & OQWF_DEFAULTFORM) { SelectForm(_pOpenQueryWnd->clsidDefaultForm); if (!_pCurrentForm) ExitGracefully(hres, E_FAIL, "Failed to select the query form"); } else { INT iForm = (int)ComboBox_GetItemData(_hwndLookFor, 0); LPQUERYFORM pQueryForm = (LPQUERYFORM)DSA_GetItemPtr(_hdsaForms, iForm); TraceAssert(pQueryForm); SelectForm(pQueryForm->clsidForm); } } StartQuery(FALSE); // issue on open, therefore lets get the query going, if there is async // scope collection then the query will be issued by the bg thread. if (_pOpenQueryWnd->dwFlags & OQWF_ISSUEONOPEN) PostMessage(_hwnd, CQFWM_STARTQUERY, 0, 0); SetForegroundWindow(hwnd); hres = S_OK; // success exit_gracefully: TraceLeaveResult(hres); } /*----------------------------------------------------------------------------- / CQueryFrame::EnableControls / --------------------------- / Set the controls into their enabled/disabled state based on the / state of the dialog. / / In: / - / / Out: / HRESULT /----------------------------------------------------------------------------*/ VOID CQueryFrame::DoEnableControls(VOID) { BOOL fScopes = (_fAddScopesNYI || ComboBox_GetCount(_hwndLookIn)); BOOL fEnable = fScopes; UINT uEnable = fScopes ? MF_ENABLED:MF_GRAYED; HMENU hMenu = GetMenu(_hwnd); INT i; TraceEnter(TRACE_FRAMEDLG, "CQueryFrame::DoEnableControls"); EnableWindow(_hwndFindNow, !_fQueryRunning && fEnable); EnableWindow(_hwndStop, _fQueryRunning && fEnable); EnableWindow(_hwndNewQuery, fEnable); EnableWindow(_hwndLookFor, !_fQueryRunning && fEnable); EnableWindow(_hwndLookIn, !_fQueryRunning && fEnable); EnableWindow(_hwndBrowse, !_fQueryRunning && fEnable); if (_pCurrentForm) { CallFormPages(_pCurrentForm, CQPM_ENABLE, (BOOL)(!_fQueryRunning && fEnable), 0); if (_fFormFirstEnable) { PostMessage(_hwnd, CQFWM_SETDEFAULTFOCUS, 0, 0); _fFormFirstEnable = FALSE; } } if (_hwndOK) EnableWindow(_hwndOK, !_fQueryRunning && fEnable); if (_hwndCancel) EnableWindow(_hwndCancel, !_fQueryRunning && fEnable); for (i = 0 ; i < GetMenuItemCount(hMenu) ; i++) EnableMenuItem(hMenu, i, MF_BYPOSITION|uEnable); DrawMenuBar(_hwnd); TraceLeave(); } /*----------------------------------------------------------------------------- / CQueryFrame::OnNotify / --------------------- / Notify event received, decode it and handle accordingly / / In: / idCtrl = ID of control issuing notify / pNotify -> LPNMHDR structure / / Out: / LRESULT /----------------------------------------------------------------------------*/ LRESULT CQueryFrame::OnNotify(INT idCtrl, LPNMHDR pNotify) { LRESULT lr = 0; TraceEnter(TRACE_FRAMEDLG, "CQueryFrame::OnNotify"); // TCN_SELCHANGE used to indicate that the currently active // tab has been changed if (pNotify->code == TCN_SELCHANGE) { INT iPage = TabCtrl_GetCurSel(_hwndFrame); TraceAssert(iPage >= 0); if (iPage >= 0) { SelectFormPage(_pCurrentForm, iPage); lr = 0; } } TraceLeaveResult((HRESULT)lr); } /*----------------------------------------------------------------------------- / CQueryFrame::OnSize / ------------------- / The window is being sized and we received a WM_SIZE, therefore move / the content of the window about. / / In: / cx = new width / cy = new height / / Out: / - /----------------------------------------------------------------------------*/ VOID CQueryFrame::OnSize(INT cx, INT cy) { HDWP hdwp; RECT rect, rect2; SIZE sz, sz2; INT x, cxForm, cyForm; INT dyResultsTop = 0; INT frameBottom = 0; TraceEnter(TRACE_FRAMEDLG, "CQueryFrame::OnSize"); // do as much as we can within a DefWindowPos to aVOID too // much flicker. hdwp = BeginDeferWindowPos(16); if (hdwp) { { // adjust the look for controls, if there is no scope then // stretch the look for control over the entire client area // of the window. if (!(_pOpenQueryWnd->dwFlags & OQWF_REMOVEFORMS)) { if (_pOpenQueryWnd->dwFlags & OQWF_REMOVESCOPES) { GetRealWindowInfo(_hwndLookFor, &rect, &sz); if (hdwp) { hdwp = DeferWindowPos(hdwp, _hwndLookFor, NULL, 0, 0, (cx - _dxFormAreaRight) - rect.left, sz.cy, SWP_NOZORDER|SWP_NOMOVE); } } } // adjust the "look in" controls, if there is a form control // then stretch across the remaining space, otherwise move the // label and stretch the scope over the remaining space. if (!(_pOpenQueryWnd->dwFlags & OQWF_REMOVESCOPES)) { INT xScopeRight; GetRealWindowInfo(_hwndLookIn, &rect, &sz); xScopeRight = cx - _dxFormAreaRight - _dxGap; if (_pOpenQueryWnd->dwFlags & OQWF_HIDESEARCHUI) { // // when hiding the search UI, then adjust the button position to account for the // right edge of the dialog not having buttons. // xScopeRight -= (_dxButtonsLeft - _dxFormAreaRight) + _dxGap; } if (_pOpenQueryWnd->dwFlags & OQWF_REMOVEFORMS) { GetRealWindowInfo(_hwndLookInLabel, &rect2, &sz2); if (hdwp) { hdwp = DeferWindowPos(hdwp, _hwndLookInLabel, NULL, _dxFormAreaLeft, rect2.top, 0, 0, SWP_NOSIZE|SWP_NOZORDER); } if(hdwp) { hdwp = DeferWindowPos(hdwp, _hwndLookIn, NULL, _dxFormAreaLeft+sz2.cx, rect.top, xScopeRight - (_dxFormAreaLeft + sz2.cx), sz.cy, SWP_NOZORDER); } } else { if(hdwp) { hdwp = DeferWindowPos(hdwp, _hwndLookIn, NULL, 0, 0, xScopeRight - rect.left, sz.cy, SWP_NOZORDER|SWP_NOMOVE); } } // browse control is displayed always if we are showing the // scopes. GetRealWindowInfo(_hwndBrowse, &rect, NULL); if(hdwp) { hdwp = DeferWindowPos(hdwp, _hwndBrowse, NULL, xScopeRight+_dxGap, rect.top, 0, 0, SWP_NOZORDER|SWP_NOSIZE); } } // all the buttons have a fixed offset from the right edege // of the dialog, so just handle that as we can. if (!(_pOpenQueryWnd->dwFlags & OQWF_HIDESEARCHUI)) { GetRealWindowInfo(_hwndFindNow, &rect, NULL); if(hdwp) { hdwp = DeferWindowPos(hdwp, _hwndFindNow, NULL, (cx - _dxButtonsLeft), rect.top, 0, 0, SWP_NOZORDER|SWP_NOSIZE); } GetRealWindowInfo(_hwndStop, &rect, &sz); if(hdwp) { hdwp = DeferWindowPos(hdwp, _hwndStop, NULL, (cx - _dxButtonsLeft), rect.top, 0, 0, SWP_NOZORDER|SWP_NOSIZE); } GetRealWindowInfo(_hwndNewQuery, &rect, NULL); if(hdwp) { hdwp = DeferWindowPos(hdwp, _hwndNewQuery, NULL, (cx - _dxButtonsLeft), rect.top, 0, 0, SWP_NOZORDER|SWP_NOSIZE); } GetRealWindowInfo(_hwndFindAnimation, &rect2, &sz2); if(hdwp) { hdwp = DeferWindowPos(hdwp, _hwndFindAnimation, NULL, (cx - _dxAnimationLeft), rect2.top, 0, 0, SWP_NOZORDER|SWP_NOSIZE); } } // position the form "frame" control GetRealWindowInfo(_hwndFrame, &rect, &sz); cxForm = (cx - _dxFormAreaRight) - rect.left; if(hdwp) { hdwp = DeferWindowPos(hdwp, _hwndFrame, NULL, 0, 0, cxForm, _szForm.cy, SWP_NOZORDER|SWP_NOMOVE); } dyResultsTop = _dyResultsTop; // NOTICE-NTRAID#NTBUG9-577850-2002/05/21-artm // Layout did not give enough vertical room to the result label. // In FE localized builds it was clipped when the window was // repainted. _dyResultsTop does not take into account space // needed between frame bottom and the top of the result label. // Store the bottom of the frame for later calculation. frameBottom = rect.bottom; // when we have a cancel button then ensure that it is to the right // of the OK button. if (_hwndCancel) { GetRealWindowInfo(_hwndCancel, &rect, &sz); if(hdwp) { hdwp = DeferWindowPos(hdwp, _hwndCancel, NULL, (cx - _dxButtonsLeft), dyResultsTop - _dyOKTop, 0, 0, SWP_NOZORDER|SWP_NOSIZE); } GetRealWindowInfo(_hwndOK, &rect, &sz); if(hdwp) { hdwp = DeferWindowPos(hdwp, _hwndOK, NULL, (cx - _dxButtonsLeft - _dxGap - sz.cx), dyResultsTop - _dyOKTop, 0, 0, SWP_NOZORDER|SWP_NOSIZE); } } else { GetRealWindowInfo(_hwndOK, &rect, &sz); if(hdwp) { hdwp = DeferWindowPos(hdwp, _hwndOK, NULL, (cx - _dxButtonsLeft), dyResultsTop - _dyOKTop, 0, 0, SWP_NOZORDER|SWP_NOSIZE); } } } // move the results and status bar as required if (_hwndResults) { if(hdwp) { hdwp = DeferWindowPos(hdwp, _hwndStatus, NULL, 0, cy - _cyStatus, cx, _cyStatus, SWP_SHOWWINDOW|SWP_NOZORDER); } // NTRAID#NTBUG9-406927-2001/10/24-lucios HWND resultsLabel=GetDlgItem(_hwnd,CQID_RESULTSLABEL); if(resultsLabel) { // NOTICE-NTRAID#NTBUG9-577850-2002/05/15-artm Label showing on FE builds. // Make sure that the label is enabled now that we want to show it. EnableWindow(resultsLabel, TRUE); RECT rec; GetClientRect(resultsLabel,&rec); INT height=rect.bottom-rect.top; // Include blank space above label proportional to height of label. dyResultsTop = frameBottom + (height / 4); if(hdwp) { hdwp = DeferWindowPos(hdwp, resultsLabel, NULL, 0, dyResultsTop, cx, height, SWP_SHOWWINDOW|SWP_NOZORDER); } dyResultsTop+=height; } if(hdwp) { hdwp = DeferWindowPos(hdwp, _hwndResults, NULL, 0, dyResultsTop, cx, max(0, cy - (dyResultsTop + _cyStatus)), SWP_SHOWWINDOW|SWP_NOZORDER); } } // NTRAID#NTBUG9-670595-2002/08/08-artm // Need to call EndDeferWindowPos() whether or not results and status bar moved. if(hdwp) { EndDeferWindowPos(hdwp); } // here is the strange bit, by this point we have moved & sized all the // controls on the dialog except the current page, as this is a child window // and not a control which in turn has controls doing this would break // the DefWindowPos path, therefore having updated everybody, lets update // the page. if (_pCurrentFormPage && _pCurrentFormPage->hwndPage) { GetRealWindowInfo(_hwndFrame, &rect, NULL); TabCtrl_AdjustRect(_hwndFrame, FALSE, &rect); cxForm = rect.right - rect.left; cyForm = rect.bottom - rect.top; SetWindowPos(_pCurrentFormPage->hwndPage, NULL, rect.left, rect.top, cxForm, cyForm, SWP_NOZORDER); } } TraceLeave(); } /*----------------------------------------------------------------------------- / CQueryFrame::OnGetMinMaxInfo / ---------------------------- / The window is being sized and we received a WM_SIZE, therefore move / the content of the window about. / / In: / lpmmin -> MINMAXINFO structure / / Out: / - /----------------------------------------------------------------------------*/ VOID CQueryFrame::OnGetMinMaxInfo(LPMINMAXINFO lpmmi) { RECT rect = {0, 0, 0, 0}; TraceEnter(TRACE_FRAMEDLG, "CQueryFrame::OnGetMinMaxInfo"); #if 0 if (!_fHideSearchPane) #endif { lpmmi->ptMinTrackSize.x = _szMinTrack.cx; lpmmi->ptMinTrackSize.y = _szMinTrack.cy; if (!_hwndResults) { lpmmi->ptMaxSize.y = lpmmi->ptMinTrackSize.y; lpmmi->ptMaxTrackSize.y = lpmmi->ptMinTrackSize.y; } } #if 0 else { AdjustWindowRect(&rect, GetWindowLong(_hwnd, GWL_STYLE), (NULL != GetMenu(_hwnd))); lpmmi->ptMinTrackSize.y = rect.bottom - rect.top; } #endif if (_hwndResults && _hwndStatus) lpmmi->ptMinTrackSize.y += _cyStatus; TraceLeave(); } /*----------------------------------------------------------------------------- / CQueryFrame::OnCommand / ---------------------- / We have recieved a WM_COMMAND so process it accordingly. / / In: / wParam, lParam = parameters from the message / / Out: / - /----------------------------------------------------------------------------*/ VOID CQueryFrame::OnCommand(WPARAM wParam, LPARAM lParam) { HRESULT hres; UINT uID = LOWORD(wParam); UINT uNotify = HIWORD(wParam); HWND hwndControl = (HWND)lParam; INT i; TraceEnter(TRACE_FRAMEDLG, "CQueryFrame::OnCommand"); Trace(TEXT("uID %08x, uNotify %d, hwndControl %08x"), uID, uNotify, hwndControl); switch (uID) { case IDOK: TraceMsg("IDOK received"); CloseQueryFrame(S_OK); break; case IDCANCEL: TraceMsg("IDCANCEL received"); CloseQueryFrame(S_FALSE); break; case CQID_LOOKFOR: { if (uNotify == CBN_SELCHANGE) { INT iSel = ComboBox_GetCurSel(_hwndLookFor); INT iForm = (int)ComboBox_GetItemData(_hwndLookFor, iSel); LPQUERYFORM pQueryForm = (LPQUERYFORM)DSA_GetItemPtr(_hdsaForms, iForm); TraceAssert(pQueryForm); if (S_FALSE == SelectForm(pQueryForm->clsidForm)) { TraceMsg("SelectForm return S_FALSE, so the user doesn't want the new form"); PostMessage(_hwndLookFor, CB_SETCURSEL, (WPARAM)_pCurrentForm->iForm, 0); } } break; } case CQID_BROWSE: OnBrowse(); break; case CQID_FINDNOW: OnFindNow(); break; case CQID_STOP: { LONG style; _pQueryHandler->StopQuery(); // For some reason, the standard method of getting the old // def button used in SetDefButton() below isn't working, // so we have to forcibly remove the BS_DEFPUSHBUTTON style // from the CQID_STOP button. style = GetWindowLong(_hwndStop, GWL_STYLE) & ~BS_DEFPUSHBUTTON; SendMessage(_hwndStop, BM_SETSTYLE, MAKEWPARAM(style, 0), MAKELPARAM(TRUE, 0)); SetDefButton(_hwnd, CQID_FINDNOW); SendMessage(GetParent(_hwndFindNow),WM_NEXTDLGCTL,(WPARAM)_hwndFindNow,TRUE); SetFocus(_hwndFindNow); break; } case CQID_CLEARALL: OnNewQuery(TRUE); // discard the current query break; case CQID_FILE_CLOSE: TraceMsg("CQID_FILE_CLOSE received"); CloseQueryFrame(S_FALSE); break; default: _pQueryHandler->InvokeCommand(_hwnd, uID); break; } TraceLeave(); } /*----------------------------------------------------------------------------- / CQueryFrame::OnInitMenu / ----------------------- / Handle telling the handler that the menu is being initialised, however / this should only happen if the menu being activated is the / menu bar, otherwise we assume that the caller is tracking a popup / menu and has performed the required initalization. / / In: / wParam, lParam = parameters from the WM_INITMENU / / Out: / - /----------------------------------------------------------------------------*/ VOID CQueryFrame::OnInitMenu(HMENU hMenu) { TraceEnter(TRACE_FRAMEDLG, "CQueryFrame::OnInitMenu"); _fTrackingMenuBar = (GetMenu(_hwnd) == hMenu); if (_fTrackingMenuBar) { TraceMsg("Tracking the menu bar, sending activate"); _pQueryHandler->ActivateView(CQRVA_INITMENUBAR, (WPARAM)hMenu, 0L); // NTRAID#NTBUG9-630248-2002/06/12-artm // Only enable View menu if the results list box is displayed. EnableMenuItem( hMenu, CQID_VIEW_SEARCHPANE, MF_BYCOMMAND| ((_hwndResults != NULL) ? MF_ENABLED:MF_GRAYED) ); } TraceLeave(); } /*----------------------------------------------------------------------------- / CQueryFrame::OnEnterMenuLoop / ---------------------------- / When the user displays a menu we must reflect this into the status bar / so that we can give the user help text relating to the commands they / select. / / In: / fEntering = entering the menu loop, or leaving. / / Out: / - /----------------------------------------------------------------------------*/ VOID CQueryFrame::OnEnterMenuLoop(BOOL fEntering) { TraceEnter(TRACE_FRAMEDLG, "CQueryFrame::OnEnterMenuLoop"); if (_hwndStatus) { if (fEntering) { SendMessage(_hwndStatus, SB_SIMPLE, (WPARAM)TRUE, 0L); SendMessage(_hwndStatus, SB_SETTEXT, (WPARAM)SBT_NOBORDERS|255, 0L); } else { SendMessage(_hwndStatus, SB_SIMPLE, (WPARAM)FALSE, 0L); } } TraceLeave(); } /*----------------------------------------------------------------------------- / CQueryFrame::OnMenuSelect / ------------------------- / Get the status text for this menu item and display it to the user, / if this doesn't map to any particular command then NULL out / the string. At this point we also trap our commands. / / In: / hMenu = menu the user is on / uID = command ID for that item / / Out: / - /----------------------------------------------------------------------------*/ VOID CQueryFrame::OnMenuSelect(HMENU hMenu, UINT uID) { TCHAR szBuffer[MAX_PATH] = { TEXT('\0') }; TraceEnter(TRACE_FRAMEDLG, "CQueryFrame::OnMenuSelect"); Trace(TEXT("hMenu %08x, uID %08x"), hMenu, uID); if (_hwndStatus) { switch (uID) { case CQID_FILE_CLOSE: case CQID_VIEW_SEARCHPANE: LoadString(GLOBAL_HINSTANCE, uID, szBuffer, ARRAYSIZE(szBuffer)); break; default: _pQueryHandler->GetCommandString(uID, 0x0, szBuffer, ARRAYSIZE(szBuffer)); break; } Trace(TEXT("Setting status bar to: %s"), szBuffer); SendMessage(_hwndStatus, SB_SETTEXT, (WPARAM)SBT_NOBORDERS|255, (LPARAM)szBuffer); } TraceLeave(); } /*----------------------------------------------------------------------------- / CQueryFrame::OnFindNow / ---------------------- // Issue the query, resulting in a view window being created and then issuing // the parameter block to the query client. / / In: / Out: / HRESULT /----------------------------------------------------------------------------*/ HRESULT CQueryFrame::OnFindNow(VOID) { HRESULT hres; CQPARAMS qp = { 0 }; LPQUERYSCOPE pQueryScope = NULL; TCHAR szBuffer[MAX_PATH]; BOOL fFixSize = TRUE; RECT rc; DECLAREWAITCURSOR; BOOL fSetCursor = FALSE; TraceEnter(TRACE_FRAMEDLG, "CQueryFrame::OnFindNow"); TraceAssert(_pCurrentForm != NULL); if (_fQueryRunning) ExitGracefully(hres, E_FAIL, "Quyery is already running"); SetWaitCursor(); fSetCursor = TRUE; // If we have not created the viewer before now lets do so, also at the // same time we attempt to fix the window size to ensure that enough // of the view is visible. if (!_hwndResults) { if (!_hwndStatus) { _hwndStatus = CreateStatusWindow(WS_CHILD, NULL, _hwnd, IDC_STATUS); GetClientRect(_hwndStatus, &rc); _cyStatus = rc.bottom - rc.top; } // Now construct the result viewer for us to use hres = _pQueryHandler->CreateResultView(_hwnd, &_hwndResults); FailGracefully(hres, "Failed when creating the view object"); GetWindowRect(_hwnd, &rc); SetWindowPos(_hwnd, NULL, 0, 0, rc.right - rc.left, _szMinTrack.cy + VIEWER_DEFAULT_CY, SWP_NOZORDER|SWP_NOMOVE); } // are we still collecting the scopes async? If so then lets wait until // they have all arrived before we set the UI running. if (_hdsaScopes && DSA_GetItemCount(_hdsaScopes)) { // Collect the parameters ready for starting the query, if this fails then // there is no point us continuing. ZeroMemory(&qp, SIZEOF(qp)); qp.cbStruct = SIZEOF(qp); //qp.dwFlags = 0x0; qp.clsidForm = _pCurrentForm->clsidForm; // new NT5 beta 2 hres = GetSelectedScope(&pQueryScope); FailGracefully(hres, "Failed to get the scope from the LookIn control"); if (pQueryScope) { Trace(TEXT("pQueryScope %08x"), pQueryScope); qp.pQueryScope = pQueryScope->pScope; } hres = CallFormPages(_pCurrentForm, CQPM_GETPARAMETERS, 0, (LPARAM)&qp.pQueryParameters); FailGracefully(hres, "Failed when collecting parameters from form"); if (!qp.pQueryParameters) { LoadString(GLOBAL_HINSTANCE, IDS_ERR_NOPARAMS, szBuffer, ARRAYSIZE(szBuffer)); FrameMessageBox(szBuffer, MB_ICONERROR|MB_OK); ExitGracefully(hres, E_FAIL, "Failed to issue the query, no parameters"); } // We either already had a view, or have just created one. Either way // we must now prepare the query for sending. Trace(TEXT("qp.cbStruct %08x"), qp.cbStruct); Trace(TEXT("qp.dwFlags %08x"), qp.dwFlags); Trace(TEXT("qp.pQueryScope %08x"), qp.pQueryScope); Trace(TEXT("qp.pQueryParameters %08x"), qp.pQueryParameters); TraceGUID("qp.clsidForm: ", qp.clsidForm); hres = _pQueryHandler->IssueQuery(&qp); FailGracefully(hres, "Failed in IssueQuery"); } else { // set the status text to reflect that we are initializng, otherwise it is // left empty and looks like we have crashed. if (LoadString(GLOBAL_HINSTANCE, IDS_INITIALIZING, szBuffer, ARRAYSIZE(szBuffer))) { SetStatusText(szBuffer); } } hres = S_OK; // success exit_gracefully: if (qp.pQueryParameters) CoTaskMemFree(qp.pQueryParameters); if (fSetCursor) ResetWaitCursor(); TraceLeaveResult(hres); } /*----------------------------------------------------------------------------- / CQueryFrame::OnNewQuery / ----------------------- / Discard the current query, prompting the user as requierd. / / In: / fAlwaysPrompt = TRUE if we force prompting of the user / / Out: / BOOL /----------------------------------------------------------------------------*/ BOOL CQueryFrame::OnNewQuery(BOOL fAlwaysPrompt) { BOOL fQueryCleared = TRUE; TCHAR szBuffer[MAX_PATH]; RECT rc; TraceEnter(TRACE_FRAMEDLG, "CQueryFrame::OnNewQuery"); if (_hwndResults || fAlwaysPrompt) { LoadString(GLOBAL_HINSTANCE, IDS_CLEARCURRENT, szBuffer, ARRAYSIZE(szBuffer)); if (IDOK != FrameMessageBox(szBuffer, MB_ICONINFORMATION|MB_OKCANCEL)) ExitGracefully(fQueryCleared, FALSE, "Used cancled new query"); if (_pQueryHandler) _pQueryHandler->StopQuery(); CallFormPages(_pCurrentForm, CQPM_CLEARFORM, 0, 0); if (_hwndResults) { DestroyWindow(_hwndResults); // no result view now _hwndResults = NULL; // NOTICE-NTRAID#NTBUG9-577850-2002/05/15-artm Label showing in FE builds. // Hide the label so there is no chance of seeing it when result view not // visible. HWND resultsLabel = GetDlgItem(_hwnd, CQID_RESULTSLABEL); if (resultsLabel) { EnableWindow(resultsLabel, FALSE); ShowWindow(resultsLabel, SW_HIDE); } DestroyWindow(_hwndStatus); // no status bar _hwndStatus = NULL; GetWindowRect(_hwnd, &rc); // shrink the window SetWindowPos(_hwnd, NULL, 0, 0, rc.right - rc.left, _szMinTrack.cy, SWP_NOZORDER|SWP_NOMOVE); } } exit_gracefully: TraceLeaveValue(fQueryCleared); } /*----------------------------------------------------------------------------- / CQueryFrame::OnBrowse / --------------------- / Browse for a new scope, adding it to the list if not already present, / or selecting the previous scope. / / In: / Out: / HRESULT /----------------------------------------------------------------------------*/ HRESULT CQueryFrame::OnBrowse(VOID) { HRESULT hres; LPQUERYSCOPE pQueryScope = NULL; LPCQSCOPE pScope = NULL; TraceEnter(TRACE_FRAMEDLG, "CQueryFrame::OnBrowse"); // Call the handler and get a scope allocation back, then add it to the list // of scopes to be displayed. hres = GetSelectedScope(&pQueryScope); FailGracefully(hres, "Failed to get the scope from the LookIn control"); Trace(TEXT("Calling BrowseForScope _hwnd %08x, pQueryScope %08x (%08x)"), _hwnd, pQueryScope, pQueryScope->pScope); hres = _pQueryHandler->BrowseForScope(_hwnd, pQueryScope ? pQueryScope->pScope:NULL, &pScope); FailGracefully(hres, "Failed when calling BrowseForScope"); if ((hres != S_FALSE) && pScope) { hres = InsertScopeIntoList(pScope, DA_LAST, TRUE); FailGracefully(hres, "Failed when adding the scope to the control"); ComboBox_SetCurSel(_hwndLookIn, ShortFromResult(hres)); } hres = S_OK; exit_gracefully: if (pScope) CoTaskMemFree(pScope); TraceLeaveResult(hres); } /*----------------------------------------------------------------------------- / CQueryFrame::OnHelp / ------------------- / Invoke the context sensitive help for the window, catch the / handler specific and page specific stuff and pass those help / requests down to the relevant objects. / / In: / pHelpInfo -> help info structure / / Out: / HRESULT /----------------------------------------------------------------------------*/ HRESULT CQueryFrame::OnHelp(LPHELPINFO pHelpInfo) { HRESULT hres; RECT rc; HWND hwnd = (HWND)pHelpInfo->hItemHandle; TraceEnter(TRACE_FRAME, "CQueryFrame::OnHelp"); // We are invoking help, theroefore we need ot check to see where element // of the window we are being invoked for. If it is the // result view then route the message to that, if its the form then // likewise. // // If we don't hit any of the extension controls then lets pass the // help onto WinHelp and get it to display the topics we have. if (pHelpInfo->iContextType != HELPINFO_WINDOW) ExitGracefully(hres, E_FAIL, "WM_HELP handler only copes with WINDOW objects"); if (_pCurrentFormPage->hwndPage && IsChild(_pCurrentFormPage->hwndPage, hwnd)) { // it was on the query form page, therefore let it go there, that way // they can provide topics specific to them TraceMsg("Invoking help on the form pane"); hres = _CallPageProc(_pCurrentFormPage, CQPM_HELP, 0, (LPARAM)pHelpInfo); FailGracefully(hres, "Failed when calling page proc to get help"); } else { // pass the help information through to the handler as an activation, // this should really just be a new method, but this works. TraceMsg("Invoking help on the results pane"); TraceAssert(_pQueryHandler); hres = _pQueryHandler->ActivateView(CQRVA_HELP, 0, (LPARAM)pHelpInfo); FailGracefully(hres, "Handler WndProc returned FALSE"); } hres = S_OK; exit_gracefully: TraceLeaveResult(hres); } /*----------------------------------------------------------------------------- / Scope helper functions /----------------------------------------------------------------------------*/ /*----------------------------------------------------------------------------- / _CallScopeProc / -------------- / Releae the given scope object, freeing the object that is referenced / and passing a CQSM_RELEASE message to it. / / In: / pQueryScope -> scope object to be called / uMsg, pVoid -> parameters for the scope / / Out: / HRESULT /----------------------------------------------------------------------------*/ HRESULT _CallScopeProc(LPQUERYSCOPE pQueryScope, UINT uMsg, LPVOID pVoid) { HRESULT hres; TraceEnter(TRACE_SCOPES, "_CallScopeProc"); Trace(TEXT("pQueryScope %08x, uMsg %d, pVoid %08x"), pQueryScope, uMsg, pVoid); Trace(TEXT("(cbStruct %d, pScopeProc %08x, lParam %08x)"), pQueryScope->pScope->cbStruct, pQueryScope->pScope->pScopeProc, pQueryScope->pScope->lParam); if (!pQueryScope) ExitGracefully(hres, S_OK, "pQueryScope == NULL"); hres = (pQueryScope->pScope->pScopeProc)(pQueryScope->pScope, uMsg, pVoid); FailGracefully(hres, "Failed calling ScopeProc"); exit_gracefully: TraceLeaveResult(hres); } /*----------------------------------------------------------------------------- / _FreeScope / ---------- / Releae the given scope object, freeing the object that is referenced / and passing a CQSM_RELEASE message to it. / / In: / pQueryScope -> scope object to be released / / Out: / INT == 1 always /----------------------------------------------------------------------------*/ INT _FreeScopeCB(LPVOID pItem, LPVOID pData) { return _FreeScope((LPQUERYSCOPE)pItem); } INT _FreeScope(LPQUERYSCOPE pQueryScope) { TraceEnter(TRACE_SCOPES, "_FreeScope"); Trace(TEXT("pQueryScope %08x, pQueryScope->pScope %08x"), pQueryScope, pQueryScope->pScope); if (pQueryScope) { _CallScopeProc(pQueryScope, CQSM_RELEASE, NULL); if (pQueryScope->pScope) { LocalFree((HLOCAL)pQueryScope->pScope); pQueryScope->pScope = NULL; } } TraceLeaveValue(TRUE); } /*----------------------------------------------------------------------------- / CQueryFrame::InsertScopeIntoList / -------------------------------- / Adds the given scope to the scope picker. / / In: / pQueryScope -> zcope object to be added to the view / i = index to insert the scope at / fAddToControl = add the scope the picker control / ppQueryScope -> recieves the new query scope object / = NULL / / Out: / HRESULT /----------------------------------------------------------------------------*/ HRESULT CQueryFrame::InsertScopeIntoList(LPCQSCOPE pScope, INT i, BOOL fAddToControl) { HRESULT hres; QUERYSCOPE qs; INT iScope; TraceEnter(TRACE_SCOPES, "CQueryFrame::InsertScopeIntoList"); Trace(TEXT("pScope %08x, i %d, fAddToControl %d"), pScope, i, fAddToControl); if (!pScope) ExitGracefully(hres, E_INVALIDARG, "pScope == NULL, not allowed"); // if we don't have any scopes then allocate the DSA if (!_hdsaScopes) { _hdsaScopes = DSA_Create(SIZEOF(QUERYSCOPE), 4); TraceAssert(_hdsaScopes); if (!_hdsaScopes) ExitGracefully(hres, E_OUTOFMEMORY, "Failed to allocate the scope DPA"); } // Walk the list of scopes checking to see if this one is already in // there, if not then we can add it. for (iScope = 0 ; iScope < DSA_GetItemCount(_hdsaScopes) ; iScope++) { LPQUERYSCOPE pQueryScope = (LPQUERYSCOPE)DSA_GetItemPtr(_hdsaScopes, iScope); TraceAssert(pQueryScope); if (S_OK == _CallScopeProc(pQueryScope, CQSM_SCOPEEQUAL, pScope)) { hres = ResultFromShort(iScope); goto exit_gracefully; } } // Take a copy of the scope blob passed by the caller. We copy the entire // structure who's size is defined by cbStruct into a LocalAlloc block, // once we have this we can then build the QUERYSCOPE structure that references // it. Trace(TEXT("pScope->cbStruct == %d"), pScope->cbStruct); qs.pScope = (LPCQSCOPE)LocalAlloc(LPTR, pScope->cbStruct); if (!qs.pScope) ExitGracefully(hres, E_OUTOFMEMORY, "Failed to allocate query scope"); Trace(TEXT("Copying structure qs.pScope %08x, pScope %08x"), qs.pScope, pScope); //REVIEWED-2002-02-25-lucios. CopyMemory(qs.pScope, pScope, pScope->cbStruct); //qs.pScope = NULL; qs.iImage = -1; // no image // We have a QUERYSCOPE, so initialize it, if that works then append it to the // DSA before either setting the return value or appending it to the control. _CallScopeProc(&qs, CQSM_INITIALIZE, NULL); iScope = DSA_InsertItem(_hdsaScopes, i, &qs); Trace(TEXT("iScope = %d"), iScope); if (iScope == -1) { _FreeScope(&qs); ExitGracefully(hres, E_OUTOFMEMORY, "Failed to add scope to DSA"); } if (fAddToControl) { LPQUERYSCOPE pQueryScope = (LPQUERYSCOPE)DSA_GetItemPtr(_hdsaScopes, iScope); TraceAssert(pQueryScope); Trace(TEXT("Calling AddScopeToControl with %08x (%d)"), pQueryScope, iScope); hres = AddScopeToControl(pQueryScope, iScope); } else { hres = ResultFromShort(iScope); } exit_gracefully: TraceLeaveResult(hres); } /*----------------------------------------------------------------------------- / CQueryFrame::AddScopeToControl / ------------------------------ / Adds the given scope to the scope picker. / / In: / pQueryScope -> zcope object to be added to the view / i = index into view where to insert the scope / / Out: / HRESULT (== index of item added) /----------------------------------------------------------------------------*/ HRESULT CQueryFrame::AddScopeToControl(LPQUERYSCOPE pQueryScope, INT i) { HRESULT hres; CQSCOPEDISPLAYINFO cqsdi; COMBOBOXEXITEM cbi; TCHAR szBuffer[MAX_PATH]; TCHAR szIconLocation[MAX_PATH] = { 0 }; INT item; TraceEnter(TRACE_SCOPES, "CQueryFrame::AddScopeToControl"); if (!pQueryScope) ExitGracefully(hres, E_INVALIDARG, "No scope specified"); // Call the scope to get the display information about this // scope before we attempt to add it. cqsdi.cbStruct = SIZEOF(cqsdi); cqsdi.dwFlags = 0; cqsdi.pDisplayName = szBuffer; cqsdi.cchDisplayName = ARRAYSIZE(szBuffer); cqsdi.pIconLocation = szIconLocation; cqsdi.cchIconLocation = ARRAYSIZE(szIconLocation); cqsdi.iIconResID = 0; cqsdi.iIndent = 0; hres = _CallScopeProc(pQueryScope, CQSM_GETDISPLAYINFO, &cqsdi); FailGracefully(hres, "Failed to get display info for the scope"); // Now add the item to the control, if they gave as an image then // add that to the image list (and tweak the INSERTITEM structure // accordingly). cbi.mask = CBEIF_TEXT|CBEIF_INDENT; cbi.iItem = i; cbi.pszText = cqsdi.pDisplayName; cbi.iIndent = cqsdi.iIndent; Trace(TEXT("Indent is %d"), cqsdi.iIndent); if (szIconLocation[0] && cqsdi.iIconResID) { INT iImage; if (!_fScopeImageListSet) { HIMAGELIST himlSmall; Shell_GetImageLists(NULL, &himlSmall); SendMessage(_hwndLookIn, CBEM_SETIMAGELIST, 0, (LPARAM)himlSmall); _fScopeImageListSet = TRUE; } cbi.mask |= CBEIF_IMAGE|CBEIF_SELECTEDIMAGE; cbi.iImage = Shell_GetCachedImageIndex(szIconLocation, cqsdi.iIconResID, 0x0);; cbi.iSelectedImage = cbi.iImage; Trace(TEXT("Image index set to: %d"), cbi.iImage); } item = (INT)SendMessage(_hwndLookIn, CBEM_INSERTITEM, 0, (LPARAM)&cbi); if (item == -1) ExitGracefully(hres, E_FAIL, "Failed when inserting the scope to the list"); DoEnableControls(); // reflect button changes into UI hres = ResultFromShort(item); exit_gracefully: TraceLeaveResult(hres); } /*----------------------------------------------------------------------------- / CQueryFrame::PopulateScopeControl / --------------------------------- / Collect the scopes that we want to display in the scope control and / then populate it. If the handler doesn't return any scopes then / we remove the control and assume that know what to do when they / don't receive a scope pointer. / / In: / - / / Out: / HRESULT /----------------------------------------------------------------------------*/ HRESULT CQueryFrame::PopulateScopeControl(VOID) { HRESULT hres; LPQUERYSCOPE pQueryScope; INT i; TraceEnter(TRACE_SCOPES, "CQueryFrame::PopulateScopeControl"); // Collect the scopes that we should be showing in the view, if we don't // get any back then we disable the scope control, if we do get some then // populate the scope control with them. hres = _pQueryHandler->AddScopes(); _fAddScopesNYI = (hres == E_NOTIMPL); if (hres != E_NOTIMPL) FailGracefully(hres, "Failed when calling handler to add scopes"); if (_hdsaScopes) { // We have some scopes, so now we create the image list that we can use // for icons with scopes. Then walk through the DPA getting the scope // to give us some display information about itself that we can // add to the combo box. ComboBox_SetExtendedUI(_hwndLookIn, TRUE); for (i = 0 ; i < DSA_GetItemCount(_hdsaScopes); i++) { pQueryScope = (LPQUERYSCOPE)DSA_GetItemPtr(_hdsaScopes, i); TraceAssert(pQueryScope); AddScopeToControl(pQueryScope, i); } } else { // we don't have any scopes after calling AddScopes, this is either // because the ::AddScopes method is not implemented, or the // scopes are being added async. If IssueQuery returned a success // we assume they are coming in async and flag as such in our // state. if (!_fAddScopesNYI) { TraceMsg("Handler adding scopes async, so marking so"); _fScopesAddedAsync = TRUE; } } hres = S_OK; // success exit_gracefully: Trace(TEXT("Default scope is index %d"), _iDefaultScope); ComboBox_SetCurSel(_hwndLookIn, _iDefaultScope); TraceLeaveResult(hres); } /*----------------------------------------------------------------------------- / CQueryFrame::GetSelectedScope / ----------------------------- / Get the selected from the the scope ComboBox, this is a reference into the / scope DSA. / / In: / ppQueryScope = receives a pointer to the new scope / / Out: / HRESULT /----------------------------------------------------------------------------*/ HRESULT CQueryFrame::GetSelectedScope(LPQUERYSCOPE* ppQueryScope) { HRESULT hres; COMBOBOXEXITEM cbi; INT iScope; TraceEnter(TRACE_SCOPES, "CQueryFrame::GetSelectedScope"); *ppQueryScope = NULL; if (_hdsaScopes) { // Get the index for the current scope, if it doesn't give a real // index to a item in our view then barf! Otherwise look up the // associated scope. iScope = ComboBox_GetCurSel(_hwndLookIn); Trace(TEXT("iScope %d"), iScope); if (iScope == -1) ExitGracefully(hres, E_FAIL, "User entered scopes not supported yet"); *ppQueryScope = (LPQUERYSCOPE)DSA_GetItemPtr(_hdsaScopes, iScope); TraceAssert(*ppQueryScope); } hres = *ppQueryScope ? S_OK : E_FAIL; exit_gracefully: Trace(TEXT("Returning LPQUERYSCOPE %08x"), *ppQueryScope); TraceLeaveResult(hres); } /*----------------------------------------------------------------------------- / Form handling functions /----------------------------------------------------------------------------*/ /*----------------------------------------------------------------------------- / _FreeQueryForm / --------------- / Destroy the QUERYFORM allocation being used to describe the form in / our DPA. We ensure that we issue a CQPM_RELEASE before doing anything / / In: / pQueryForm -> query form to be destroyed / / Out: / INT == 1 always /----------------------------------------------------------------------------*/ INT _FreeQueryFormCB(LPVOID pItem, LPVOID pData) { return _FreeQueryForm((LPQUERYFORM)pItem); } INT _FreeQueryForm(LPQUERYFORM pQueryForm) { TraceEnter(TRACE_FORMS, "_FreeQueryForm"); if (pQueryForm) { if (pQueryForm->hdsaPages) { DSA_DestroyCallback(pQueryForm->hdsaPages, _FreeQueryFormPageCB, NULL); pQueryForm->hdsaPages = NULL; } Str_SetPtr(&pQueryForm->pTitle, NULL); if (pQueryForm->hIcon) { DestroyIcon(pQueryForm->hIcon); } } TraceLeaveValue(TRUE); } /*----------------------------------------------------------------------------- / _FreeQueryFormPage / ------------------ / Given a pointer to a query form page structure release the members that // are of interest, including calling the PAGEPROC to releasee the underlying / object. / / In: / pQueryFormPage -> page to be removed / / Out: / INT == 1 always /----------------------------------------------------------------------------*/ INT _FreeQueryFormPageCB(LPVOID pItem, LPVOID pData) { return _FreeQueryFormPage((LPQUERYFORMPAGE)pItem); } INT _FreeQueryFormPage(LPQUERYFORMPAGE pQueryFormPage) { TraceEnter(TRACE_FORMS, "_FreeQueryFormPage"); if (pQueryFormPage) { _CallPageProc(pQueryFormPage, CQPM_RELEASE, 0, 0); // NB: ignore return code if (pQueryFormPage->hwndPage) { EnableThemeDialogTexture(pQueryFormPage->hwndPage, ETDT_DISABLE); DestroyWindow(pQueryFormPage->hwndPage); pQueryFormPage->hwndPage = NULL; } if (pQueryFormPage->pPage) { LocalFree(pQueryFormPage->pPage); pQueryFormPage->pPage = NULL; } } TraceLeaveValue(TRUE); } /*----------------------------------------------------------------------------- / _CallPageProc / ------------- / Call the given page object thunking the arguments as required if the / page object is non-UNICODE (only if building UNICODE). / / In: / pQueryFormPage -> page object to be called / uMsg, wParam, lParam = parameters for message / / Out: / HRESULT /----------------------------------------------------------------------------*/ HRESULT _CallPageProc(LPQUERYFORMPAGE pQueryFormPage, UINT uMsg, WPARAM wParam, LPARAM lParam) { HRESULT hres; TraceEnter(TRACE_FORMS, "_CallPageProc"); Trace(TEXT("pQueryFormPage %08x, pPage %08x, uMsg %d, wParam %08x, lParam %08x"), pQueryFormPage, pQueryFormPage->pPage, uMsg, wParam, lParam); if (!pQueryFormPage) ExitGracefully(hres, S_OK, "pQueryFormPage == NULL"); hres = (pQueryFormPage->pPage->pPageProc)(pQueryFormPage->pPage, pQueryFormPage->hwndPage, uMsg, wParam, lParam); FailGracefully(hres, "Failed calling PageProc"); // hres = S_OK; exit_gracefully: TraceLeaveResult(hres); } /*----------------------------------------------------------------------------- / Functions for adding query forms/pages /----------------------------------------------------------------------------*/ // CB to add forms to the form DSA. HRESULT _AddFormsProc(LPARAM lParam, LPCQFORM pForm) { HRESULT hres; QUERYFORM qf = {0}; HDSA hdsaForms = (HDSA)lParam; TraceEnter(TRACE_FORMS, "_AddFormsProc"); if (!pForm || !hdsaForms) ExitGracefully(hres, E_INVALIDARG, "Failed to add page pForm == NULL"); // Allocate and thunk as required qf.hdsaPages = NULL; // DSA of pages qf.dwFlags = pForm->dwFlags; // flags qf.clsidForm = pForm->clsid; // CLSID identifier for this form qf.pTitle = NULL; // title used for drop down / title bar qf.hIcon = pForm->hIcon; // hIcon passed by caller qf.iImage = -1; // image list index of icon qf.iForm = 0; // visible index of form in control qf.iPage = 0; // currently selected page on form if (!Str_SetPtr(&qf.pTitle, pForm->pszTitle)) ExitGracefully(hres, E_OUTOFMEMORY, "Failed to copy form title string"); // Allocate the DSA if one doesn't exist yet, then add in the form // structure as required. if (-1 == DSA_AppendItem(hdsaForms, &qf)) ExitGracefully(hres, E_FAIL, "Failed to add form to the form DSA"); hres = S_OK; // success exit_gracefully: if (FAILED(hres)) _FreeQueryForm(&qf); TraceLeaveResult(hres); } // CB to add pages to the page DSA. HRESULT _AddPagesProc(LPARAM lParam, REFCLSID clsidForm, LPCQPAGE pPage) { HRESULT hres; QUERYFORMPAGE qfp = {0}; HDSA hdsaPages = (HDSA)lParam; TraceEnter(TRACE_FORMS, "_AddPagesProc"); if (!pPage || !hdsaPages) ExitGracefully(hres, E_INVALIDARG, "Failed to add page pPage == NULL"); // copy the pPage structure for us to pass to the PAGEPROC later, nb: we // use the cbStruct field to indicate the size of blob we must copy. Trace(TEXT("pPage->cbStruct == %d"), pPage->cbStruct); qfp.pPage = (LPCQPAGE)LocalAlloc(LPTR, pPage->cbStruct); if (!qfp.pPage) ExitGracefully(hres, E_OUTOFMEMORY, "Failed to allocate copy of page structure"); Trace(TEXT("Copying structure qfp.pPage %08x, pPage %08x"), qfp.pPage, pPage); //REVIEWED-2002-02-25-lucios. CopyMemory(qfp.pPage, pPage, pPage->cbStruct); // copy the page structure //qfp.pPage = NULL; qfp.clsidForm = clsidForm; qfp.pPageProc = pPage->pPageProc; qfp.lParam = pPage->lParam; qfp.hwndPage = NULL; _CallPageProc(&qfp, CQPM_INITIALIZE, 0, 0); if (-1 == DSA_AppendItem(hdsaPages, &qfp)) ExitGracefully(hres, E_FAIL, "Failed to add the form to the DSA"); hres = S_OK; // succcess exit_gracefully: if (FAILED(hres)) _FreeQueryFormPage(&qfp); TraceLeaveResult(hres); } // Add forms/pages from a UNICODE IQueryForm iface HRESULT CQueryFrame::AddFromIQueryForm(IQueryForm* pQueryForm, HKEY hKeyForm) { HRESULT hres; TraceEnter(TRACE_FORMS, "CQueryFrame::AddFromIQueryForm"); if (!pQueryForm) ExitGracefully(hres, E_FAIL, "pQueryForm == NULL, failing"); hres = pQueryForm->Initialize(hKeyForm); FailGracefully(hres, "Failed in IQueryFormW::Initialize"); // Call the form object to add its form and then its pages hres = pQueryForm->AddForms(_AddFormsProc, (LPARAM)_hdsaForms); if (SUCCEEDED(hres) || (hres == E_NOTIMPL)) { hres = pQueryForm->AddPages(_AddPagesProc, (LPARAM)_hdsaPages); FailGracefully(hres, "Failed in IQueryForm::AddPages"); } else { FailGracefully(hres, "Failed when calling IQueryForm::AddForms"); } hres = S_OK; // success exit_gracefully: TraceLeaveResult(hres); } #ifdef UNICODE #define ADD_FROM_IQUERYFORM AddFromIQueryFormW #else #define ADD_FROM_IQUERYFORM AddFromIQueryFormA #endif /*----------------------------------------------------------------------------- / CQueryFrame::GatherForms / ------------------------ / Enumerate all the query forms for the given query handler and build / the DPA containing the list of them. Once we have done this we / can then populate the control at some more convientent moment. / / When gathering we first hit the "handler", then the "Forms" sub-key / trying to load all the InProc servers that provide forms. We build / list of hidden, never shown etc. / / In: / - / Out: / HRESULT /----------------------------------------------------------------------------*/ HRESULT _AddPageToForm(LPQUERYFORM pQueryForm, LPQUERYFORMPAGE pQueryFormPage, BOOL fClone) { HRESULT hres; QUERYFORMPAGE qfp; TraceEnter(TRACE_FORMS, "_AddPageToForm"); TraceAssert(pQueryForm); TraceAssert(pQueryFormPage); // ensure that we have a page DSA for this form object if (!pQueryForm->hdsaPages) { TraceMsg("Creating a new page DSA for form"); pQueryForm->hdsaPages = DSA_Create(SIZEOF(QUERYFORMPAGE), 4); if (!pQueryForm->hdsaPages) ExitGracefully(hres, E_OUTOFMEMORY, "*** No page DSA on form object ***"); } if (!fClone) { // Moving this page structure to the one associated with the query form, // therefore just ensure that the form has a DSA for pages and just // insert an item at the header (yes, we add the pages in reverse). Trace(TEXT("Adding page %08x to form %s"), pQueryFormPage, pQueryForm->pTitle); if (-1 == DSA_InsertItem(pQueryForm->hdsaPages, 0, pQueryFormPage)) ExitGracefully(hres, E_FAIL, "Failed to copy page to form page DSA"); } else { LPCQPAGE pPage = pQueryFormPage->pPage; // Copying the page structure (it must be global), therefore clone // the QUERYFORMPAGE strucutre and the CQPAGE into a new allocation // and insert that into the page DSA. Trace(TEXT("Cloning page %08x to form %s"), pQueryFormPage, pQueryForm->pTitle); CopyMemory(&qfp, pQueryFormPage, SIZEOF(QUERYFORMPAGE)); qfp.pPage = (LPCQPAGE)LocalAlloc(LPTR, pPage->cbStruct); if (!qfp.pPage) ExitGracefully(hres, E_OUTOFMEMORY, "Failed to allocate copy of page structure"); Trace(TEXT("Copying structure qfp.pPage %08x, pPage %08x"), qfp.pPage, pPage); //REVIEWED-2002-02-25-lucios. CopyMemory(qfp.pPage, pPage, pPage->cbStruct); // copy the page structure _CallPageProc(&qfp, CQPM_INITIALIZE, 0, 0); if (-1 == DSA_AppendItem(pQueryForm->hdsaPages, &qfp)) { _FreeQueryFormPage(&qfp); ExitGracefully(hres, E_FAIL, "Failed to copy page to form DSA"); } } hres = S_OK; // success exit_gracefully: TraceLeaveResult(hres); } HRESULT CQueryFrame::GatherForms(VOID) { HRESULT hres; IQueryForm* pQueryFormA = NULL; HKEY hKeyForms = NULL; TCHAR szBuffer[MAX_PATH]; INT i, iPage, iForm; RECT rect; TC_ITEM tci; TraceEnter(TRACE_FORMS, "CQueryFrame::GatherForms"); // Construct DSA's so we can store the forms and pages as required. _hdsaForms = DSA_Create(SIZEOF(QUERYFORM), 4); _hdsaPages = DSA_Create(SIZEOF(QUERYFORMPAGE), 4); if (!_hdsaForms || !_hdsaPages) ExitGracefully(hres, E_OUTOFMEMORY, "Failed to create DSA's for storing pages/forms"); // First check the IQueryHandler to see if it supports IQueryForm, if it does // then call it to add its objects. Note that we don't bother with ANSI/UNICODE // at this point as the handler is assumed to be built the same the // the query framework. if (SUCCEEDED(_pQueryHandler->QueryInterface(IID_IQueryForm, (LPVOID*)&pQueryFormA))) { hres = AddFromIQueryForm(pQueryFormA, NULL); FailGracefully(hres, "Failed when calling AddFromIQueryForm on handlers IQueryForm iface)"); } // now attempt to build the list of forms and pages from the registered form // extensions. These are declared under the handlers CLSID in the registry, // under the sub-key "Forms". if (ERROR_SUCCESS != RegOpenKeyEx(_hkHandler, c_szForms, NULL, KEY_READ, &hKeyForms)) { TraceMsg("No 'Forms' sub-key found, therefore skipping"); } else { // Enumerate all the keys in the "Forms" key, these are assumed to be a list of // the form handlers. for (i = 0 ; TRUE ; i++) { DWORD cchStruct = ARRAYSIZE(szBuffer); if (ERROR_SUCCESS != RegEnumKeyEx(hKeyForms, i, szBuffer, &cchStruct, NULL, NULL, NULL, NULL)) { TraceMsg("RegEnumKeyEx return's false, therefore stopping eunmeration"); break; } GetForms(hKeyForms, szBuffer); } } // Now tally the form/page information together and remove duplicates and attach the pages // to forms, take special note of the global pages. As all forms will now be in the // DSA we can check for a zero count and we don't have to worry about the order // in which the the forms and pages were added. if (!DSA_GetItemCount(_hdsaForms) || !DSA_GetItemCount(_hdsaPages)) ExitGracefully(hres, E_FAIL, "Either the forms or pages DSA is empty"); for (iPage = DSA_GetItemCount(_hdsaPages) ; --iPage >= 0 ;) { LPQUERYFORMPAGE pQueryFormPage = (LPQUERYFORMPAGE)DSA_GetItemPtr(_hdsaPages, iPage); TraceAssert(pQueryFormPage); Trace(TEXT("iPage %d (of %d)"), iPage, DSA_GetItemCount(_hdsaPages)); if (!(pQueryFormPage->pPage->dwFlags & CQPF_ISGLOBAL)) { LPQUERYFORM pQueryFormB = FindQueryForm(pQueryFormPage->clsidForm); TraceAssert(pQueryFormB); TraceGUID("Adding page to form:", pQueryFormPage->clsidForm); if (pQueryFormB) { hres = _AddPageToForm(pQueryFormB, pQueryFormPage, FALSE); FailGracefully(hres, "Failed when adding page to form"); if (!DSA_DeleteItem(_hdsaPages, iPage)) TraceMsg("**** Failed to remove page from global DSA ****"); } } } for (iPage = DSA_GetItemCount(_hdsaPages) ; --iPage >= 0 ;) { LPQUERYFORMPAGE pQueryFormPage = (LPQUERYFORMPAGE)DSA_GetItemPtr(_hdsaPages, iPage); TraceAssert(pQueryFormPage); if ((pQueryFormPage->pPage->dwFlags & CQPF_ISGLOBAL)) { Trace(TEXT("Adding global page to %d forms"), DSA_GetItemCount(_hdsaForms)); for (iForm = 0 ; iForm < DSA_GetItemCount(_hdsaForms); iForm++) { LPQUERYFORM pQueryFormC = (LPQUERYFORM)DSA_GetItemPtr(_hdsaForms, iForm); TraceAssert(pQueryFormC); if (!(pQueryFormC->dwFlags & CQFF_NOGLOBALPAGES)) { hres = _AddPageToForm(pQueryFormC, pQueryFormPage, TRUE); FailGracefully(hres, "Failed when adding global page to form"); } } _FreeQueryFormPage(pQueryFormPage); if (!DSA_DeleteItem(_hdsaPages, iPage)) TraceMsg("**** Failed to remove page from global DSA ****"); } } // Walk the list of forms, rmeoving the ones which have no pages assocaited with // them, we don't need these around confusing the world around us. Note that // we walk backwards through the list removing. // // Also remove the optional forms we don't want to ehw orld to see for (iForm = DSA_GetItemCount(_hdsaForms) ; --iForm >= 0 ;) { LPQUERYFORM pQueryFormD = (LPQUERYFORM)DSA_GetItemPtr(_hdsaForms, iForm); TraceAssert(pQueryFormD); Trace(TEXT("pQueryForm %08x (%s), pQueryFormD->hdsaPages %08x (%d)"), pQueryFormD, pQueryFormD->pTitle, pQueryFormD->hdsaPages, pQueryFormD->hdsaPages ? DSA_GetItemCount(pQueryFormD->hdsaPages):0); if (!pQueryFormD->hdsaPages || !DSA_GetItemCount(pQueryFormD->hdsaPages) || ((pQueryFormD->dwFlags & CQFF_ISOPTIONAL) && !(_pOpenQueryWnd->dwFlags & OQWF_SHOWOPTIONAL))) { TraceGUID("Removing form: ", pQueryFormD->clsidForm); _FreeQueryForm(pQueryFormD); DSA_DeleteItem(_hdsaForms, iForm); } } if (!DSA_GetItemCount(_hdsaForms)) ExitGracefully(hres, E_FAIL, "!!!!! No forms registered after page/form fix ups !!!!!"); // The pages have been attached to the forms so we can now attempt to create the // form/page objects. _szForm.cx = 0; _szForm.cy = 0; tci.mask = TCIF_TEXT; tci.pszText = TEXT(""); tci.cchTextMax = 0; TabCtrl_InsertItem(_hwndFrame, 0, &tci); // tabctrl needs at least one item so we can compute sizes for (iForm = 0 ; iForm < DSA_GetItemCount(_hdsaForms); iForm++) { LPQUERYFORM pQueryFormE = (LPQUERYFORM)DSA_GetItemPtr(_hdsaForms, iForm); TraceAssert(pQueryFormE); // Create each of the modeless page dialoges that we show to allow the user // to edit the search criteria. We also grab the size and modify the // form informaiton we have so that the default size of the dialog can be // correctly computed. for (iPage = 0 ; iPage < DSA_GetItemCount(pQueryFormE->hdsaPages); iPage++) { LPQUERYFORMPAGE pQueryFormPage = (LPQUERYFORMPAGE)DSA_GetItemPtr(pQueryFormE->hdsaPages, iPage); TraceAssert(pQueryFormPage); pQueryFormPage->hwndPage = CreateDialogParam(pQueryFormPage->pPage->hInstance, MAKEINTRESOURCE(pQueryFormPage->pPage->idPageTemplate), _hwnd, pQueryFormPage->pPage->pDlgProc, (LPARAM)pQueryFormPage->pPage); if (!pQueryFormPage->hwndPage) ExitGracefully(hres, E_FAIL, "Failed to create query form page"); EnableThemeDialogTexture(pQueryFormPage->hwndPage, ETDT_ENABLETAB); GetRealWindowInfo(pQueryFormPage->hwndPage, &rect, NULL); TabCtrl_AdjustRect(_hwndFrame, TRUE, &rect); _szForm.cx = max(rect.right-rect.left, _szForm.cx); _szForm.cy = max(rect.bottom-rect.top, _szForm.cy); // flush the form parameters _CallPageProc(pQueryFormPage, CQPM_CLEARFORM, 0, 0); // Call the page with CQPM_SETDEFAULTPARAMETERS with the // OPENQUERYWINDOW structure. wParam is TRUE/FALSE indiciating if // the form is the default one, and therefore if the pFormParam is // valid. _CallPageProc(pQueryFormPage, CQPM_SETDEFAULTPARAMETERS, (WPARAM)((_pOpenQueryWnd->dwFlags & OQWF_DEFAULTFORM) && IsEqualCLSID(_pOpenQueryWnd->clsidDefaultForm, pQueryFormPage->clsidForm)), (LPARAM)_pOpenQueryWnd); } // If the form has an hIcon then lets ensure that we add that to the form image // list, any failure here is non-fatal, in that we will just skip that forms // icon in the list (rather than barfing) if (pQueryFormE->hIcon) { if (!_himlForms) _himlForms = ImageList_Create(COMBOEX_IMAGE_CX, COMBOEX_IMAGE_CY, 0, 4, 1); if (_himlForms) { pQueryFormE->iImage = ImageList_AddIcon(_himlForms, pQueryFormE->hIcon); TraceAssert(pQueryFormE->iImage >= 0); } DestroyIcon(pQueryFormE->hIcon); pQueryFormE->hIcon = NULL; } } hres = S_OK; // success exit_gracefully: DoRelease(pQueryFormA); if (hKeyForms) RegCloseKey(hKeyForms); TraceLeaveResult(hres); } /*----------------------------------------------------------------------------- / CQueryFrame::GetForms / --------------------- / Given a HKEY to the forms list and the value name for the form we want / to add, query for the form information add add the form objects / to the master list. / / In: / hKeyForms = HKEY for the {CLSID provider}\Forms key / pName -> key value to query for / / Out: / VOID /----------------------------------------------------------------------------*/ HRESULT CQueryFrame::GetForms(HKEY hKeyForms, LPTSTR pName) { HRESULT hres; HKEY hKeyForm = NULL; TCHAR szQueryFormCLSID[GUIDSTR_MAX+1]; DWORD dwFlags; DWORD dwSize; IUnknown* pUnknown = NULL; IQueryForm* pQueryForm = NULL; CLSID clsidForm; BOOL fIncludeForms = FALSE; TraceEnter(TRACE_FORMS, "CQueryFrame::_GetForms"); Trace(TEXT("pName %s"), pName); if (ERROR_SUCCESS != RegOpenKeyEx(hKeyForms, pName, NULL, KEY_READ, &hKeyForm)) ExitGracefully(hres, E_UNEXPECTED, "Failed to open the form key"); // Read the flags and try to determine if we should invoke this form object. dwSize = SIZEOF(dwFlags); if (ERROR_SUCCESS != RegQueryValueEx(hKeyForm, c_szFlags, NULL, NULL, (LPBYTE)&dwFlags, &dwSize)) { TraceMsg("No flags, defaulting to something sensible"); dwFlags = QUERYFORM_CHANGESFORMLIST; } Trace(TEXT("Forms flag is %08x"), dwFlags); // should be invoke this form object? // // - if dwFlags has QUERYFORM_CHANGESFORMSLIST, or // - if dwFlags has QUERYFORM_CHANGESOPTFORMLIST and we are showing optional forms, or // - neither set and the form object supports the requested form if (!(dwFlags & QUERYFORM_CHANGESFORMLIST)) { if ((dwFlags & QUERYFORM_CHANGESOPTFORMLIST) && (_pOpenQueryWnd->dwFlags & OQWF_SHOWOPTIONAL)) { TraceMsg("Form is optional, are we are showing optional forms"); fIncludeForms = TRUE; } else { // OK, so it either didn't update the form list, or wasn't marked as optional, // so lets check to see if it supports the form the user has requested, if not // then don't bother loading this guy. if (_pOpenQueryWnd->dwFlags & OQWF_DEFAULTFORM) { TCHAR szBuffer[GUIDSTR_MAX+32]; HKEY hkFormsSupported; TraceMsg("Checking for supported form"); if (ERROR_SUCCESS == RegOpenKeyEx(hKeyForm, TEXT("Forms Supported"), NULL, KEY_READ, &hkFormsSupported)) { TraceMsg("Form has a 'Supported Forms' sub-key"); GetStringFromGUID(_pOpenQueryWnd->clsidDefaultForm, szQueryFormCLSID, ARRAYSIZE(szQueryFormCLSID)); Trace(TEXT("Checking for: %s"), szQueryFormCLSID); if (ERROR_SUCCESS == RegQueryValueEx(hkFormsSupported, szQueryFormCLSID, NULL, NULL, NULL, NULL)) { TraceMsg("Query form is in supported list"); fIncludeForms = TRUE; } RegCloseKey(hkFormsSupported); } else { TraceMsg("No forms supported sub-key, so loading form object anyway"); fIncludeForms = TRUE; } } } } else { TraceMsg("Form updates form list"); fIncludeForms = TRUE; } // if fIncludeForms is TRUE, then the checks above succeeded and we are including forms // from this object (identified by pName), so we must now get the CLSID of the object // we are invoking and use its IQueryForm interface to add the forms that we want. if (fIncludeForms) { // get the form object CLSID, having parse it, then CoCreate it adding the forms. dwSize = SIZEOF(szQueryFormCLSID); if (ERROR_SUCCESS != RegQueryValueEx(hKeyForm, c_szCLSID, NULL, NULL, (LPBYTE)szQueryFormCLSID, &dwSize)) ExitGracefully(hres, E_UNEXPECTED, "Failed to read the CLSID of the form"); Trace(TEXT("szQueryFormCLSID: %s"), szQueryFormCLSID); if (!GetGUIDFromString(szQueryFormCLSID, &clsidForm)) ExitGracefully(hres, E_UNEXPECTED, "Fialed to parse the string as a GUID"); // we now have the CLISD of the form object, so we must attempt to CoCreate it, we try for // the current build type (eg UNICODE) and then fall back to ANSI if thats not supported, // so we can support ANSI query form objects on a UNICODE platform. hres = CoCreateInstance(clsidForm, NULL, CLSCTX_INPROC_SERVER, IID_IUnknown, (void**)&pUnknown); FailGracefully(hres, "Failed to CoCreate the form object"); if (SUCCEEDED(pUnknown->QueryInterface(IID_IQueryForm, (LPVOID*)&pQueryForm))) { hres = AddFromIQueryForm(pQueryForm, hKeyForm); FailGracefully(hres, "Failed when adding forms from specified IQueryForm iface"); } else { ExitGracefully(hres, E_UNEXPECTED, "Form object doesn't support IQueryForm(A/W)"); } } hres = S_OK; exit_gracefully: if (hKeyForm) RegCloseKey(hKeyForm); DoRelease(pUnknown); DoRelease(pQueryForm); TraceLeaveResult(hres); } /*----------------------------------------------------------------------------- / CQueryFrame::PopulateFormControl / --------------------------------- / Enumerate all the query forms for the given query handler and build / the DPA containing the list of them. Once we have done this we / can then populate the control at some more convientent moment. / / When gathering we first hit the "handler", then the "Forms" sub-key / trying to load all the InProc servers that provide forms. We build / list of hidden, never shown etc. / / In: / fIncludeHidden = list forms marked as hidden in control / / Out: / VOID /----------------------------------------------------------------------------*/ HRESULT CQueryFrame::PopulateFormControl(BOOL fIncludeHidden) { HRESULT hres; COMBOBOXEXITEM cbi; INT i, iForm; TraceEnter(TRACE_FORMS, "CQueryFrame::PopulateFormControl"); Trace(TEXT("fIncludeHidden: %d"), fIncludeHidden); // list which forms within the control if (!_hdsaForms) ExitGracefully(hres, E_FAIL, "No forms to list"); ComboBox_ResetContent(_hwndLookFor); // remove all items from that control for (i = 0, iForm = 0 ; iForm < DSA_GetItemCount(_hdsaForms); iForm++) { LPQUERYFORM pQueryForm = (LPQUERYFORM)DSA_GetItemPtr(_hdsaForms, iForm); TraceAssert(pQueryForm); // filter out those forms that are not of interest to this instance of the // dialog. if (((pQueryForm->dwFlags & CQFF_ISOPTIONAL) && !fIncludeHidden) || (pQueryForm->dwFlags & CQFF_ISNEVERLISTED)) { Trace(TEXT("Hiding form: %s"), pQueryForm->pTitle); continue; } // now add the form to the control, including the image if there is an image // specified. cbi.mask = CBEIF_TEXT|CBEIF_LPARAM; cbi.iItem = i++; cbi.pszText = pQueryForm->pTitle; cbi.cchTextMax = lstrlen(pQueryForm->pTitle); cbi.lParam = iForm; if (pQueryForm->iImage >= 0) { Trace(TEXT("Form has an image %d"), pQueryForm->iImage); cbi.mask |= CBEIF_IMAGE|CBEIF_SELECTEDIMAGE; cbi.iImage = pQueryForm->iImage; cbi.iSelectedImage = pQueryForm->iImage; } pQueryForm->iForm = (int)SendMessage(_hwndLookFor, CBEM_INSERTITEM, 0, (LPARAM)&cbi); if (pQueryForm->iForm < 0) { Trace(TEXT("Form name: %s"), pQueryForm->pTitle); ExitGracefully(hres, E_FAIL, "Failed to add the entry to the combo box"); } } hres = S_OK; exit_gracefully: TraceLeaveValue(hres); } /*----------------------------------------------------------------------------- / CQueryFrame::SelectForm / ----------------------- / Changes the current form to the one specified as an into the DPA. / / In: / iForm = form to be selected / / Out: / - /----------------------------------------------------------------------------*/ HRESULT CQueryFrame::SelectForm(REFCLSID clsidForm) { HRESULT hres; LPQUERYFORM pQueryForm, pOldQueryForm; LPQUERYFORMPAGE pQueryFormPage; LPCQPAGE pPage; INT nCmdShow = SW_SHOW; TCHAR szBuffer[64], szTitle[MAX_PATH];; TC_ITEM tci; INT i; TraceEnter(TRACE_FORMS, "CQueryFrame::SelectForm"); pQueryForm = FindQueryForm(clsidForm); TraceAssert(pQueryForm); if (!pQueryForm) ExitGracefully(hres, S_FALSE, "Failed to find the requested form"); // Change the currently displayed form and change the displayed // tabs to correctly indicate this if ((pQueryForm != _pCurrentForm)) { if (!OnNewQuery(FALSE)) // prompt the user ExitGracefully(hres, S_FALSE, "Failed to select the new form"); TabCtrl_DeleteAllItems(_hwndFrame); for (i = 0 ; i < DSA_GetItemCount(pQueryForm->hdsaPages) ; i++) { pQueryFormPage = (LPQUERYFORMPAGE)DSA_GetItemPtr(pQueryForm->hdsaPages, i); pPage = pQueryFormPage->pPage; tci.mask = TCIF_TEXT; tci.pszText = pQueryForm->pTitle; tci.cchTextMax = MAX_PATH; if (pPage->idPageName && LoadString(pPage->hInstance, pPage->idPageName, szBuffer, ARRAYSIZE(szBuffer))) { Trace(TEXT("Loaded page title string %s"), szBuffer); tci.pszText = szBuffer; } TabCtrl_InsertItem(_hwndFrame, i, &tci); } ComboBox_SetCurSel(_hwndLookFor, pQueryForm->iForm); _pCurrentForm = pQueryForm; SelectFormPage(pQueryForm, pQueryForm->iPage); // Change the dialog title to reflect the new form if (LoadString(GLOBAL_HINSTANCE, IDS_FRAMETITLE, szBuffer, ARRAYSIZE(szBuffer))) { // NTRAID#NTBUG9-554458-2002/02/20-lucios. Pending fix. wsprintf(szTitle, szBuffer, pQueryForm->pTitle); SetWindowText(_hwnd, szTitle); } // Tell the handler that we have changed the form, they can then use this // new form name to modify their UI. _pQueryHandler->ActivateView(CQRVA_FORMCHANGED, (WPARAM)lstrlen(pQueryForm->pTitle), (LPARAM)pQueryForm->pTitle); } hres = S_OK; exit_gracefully: TraceLeaveResult(hres); } /*----------------------------------------------------------------------------- / CQueryFrame::SelectFormPage / --------------------------- / Change the currently active page of a query form to the one specified / by the index. / / In: / pQueryForm = query form to be changed / iForm = form to be selected / / Out: / - /----------------------------------------------------------------------------*/ VOID CQueryFrame::SelectFormPage(LPQUERYFORM pQueryForm, INT iPage) { LPQUERYFORMPAGE pQueryFormPage; RECT rect; TraceEnter(TRACE_FORMS, "CQueryFrame::SelectFormPage"); pQueryFormPage = (LPQUERYFORMPAGE)DSA_GetItemPtr(pQueryForm->hdsaPages, iPage); // Have we changed the query form page? If so then display the now dialog // hiding the previous one. We call the TabCtrl to find out where we should // be placing this new control. if (pQueryFormPage != _pCurrentFormPage) { // Reflect the change into the tab control TabCtrl_SetCurSel(_hwndFrame, iPage); pQueryForm->iPage = iPage; // Fix the size and visability of the new form if (_pCurrentFormPage) ShowWindow(_pCurrentFormPage->hwndPage, SW_HIDE); GetRealWindowInfo(_hwndFrame, &rect, NULL); TabCtrl_AdjustRect(_hwndFrame, FALSE, &rect); SetWindowPos(pQueryFormPage->hwndPage, HWND_TOP, rect.left, rect.top, rect.right - rect.left, rect.bottom - rect.top, SWP_SHOWWINDOW); _pCurrentFormPage = pQueryFormPage; } TraceLeave(); } /*----------------------------------------------------------------------------- / CQueryFrame::CallFormPages / -------------------------- / Given a query form traverse the array of pages calling each of them / with the given message information. If any of the pages return / an error code (other than E_NOTIMPL) we bail. / / In: / pQueryForm = query form to call / uMsg, wParam, lParam = parameters for the page / / Out: / HRESULT /----------------------------------------------------------------------------*/ HRESULT CQueryFrame::CallFormPages(LPQUERYFORM pQueryForm, UINT uMsg, WPARAM wParam, LPARAM lParam) { HRESULT hres = S_OK; INT iPage; TraceEnter(TRACE_FORMS, "CQueryFrame::CallFormPages"); if (!pQueryForm || !pQueryForm->hdsaPages) ExitGracefully(hres, E_FAIL, "No pQueryForm || pQueryForm->hdsaPages == NULL"); Trace(TEXT("pQueryForm %08x"), pQueryForm); Trace(TEXT("uMsg %08x, wParam %08x, lParam %08x"), uMsg, wParam, lParam); Trace(TEXT("%d pages to call"), DSA_GetItemCount(pQueryForm->hdsaPages)); // Call each page in turn if it matches the filter we have been given for calling // down. If a page returns S_FALSE or a FAILURE then we exit the loop. If the // failure however is E_NOTIMPL then we ignore. for (iPage = 0 ; iPage < DSA_GetItemCount(pQueryForm->hdsaPages); iPage++) { LPQUERYFORMPAGE pQueryFormPage = (LPQUERYFORMPAGE)DSA_GetItemPtr(pQueryForm->hdsaPages, iPage); TraceAssert(pQueryFormPage); hres = _CallPageProc(pQueryFormPage, uMsg, wParam, lParam); if (FAILED(hres) && (hres != E_NOTIMPL)) { TraceMsg("PageProc returned a FAILURE"); break; } else if (hres == S_FALSE) { TraceMsg("PageProc returned S_FALSE, exiting loop"); break; } } exit_gracefully: TraceLeaveResult(hres); } /*----------------------------------------------------------------------------- / CQueryFrame::FindQueryForm / -------------------------- / Given the CLSID for the form return a pointer to its LPQUERYFORM structure, / or NULL if not found. / / In: / clsidForm = ID of the form / / Out: / LPQUERYFORM /----------------------------------------------------------------------------*/ LPQUERYFORM CQueryFrame::FindQueryForm(REFCLSID clsidForm) { LPQUERYFORM pQueryForm = NULL; INT i; TraceEnter(TRACE_FORMS, "CQueryFrame::FindQueryForm"); TraceGUID("Form ID", clsidForm); for (i = 0 ; _hdsaForms && (i < DSA_GetItemCount(_hdsaForms)) ; i++) { pQueryForm = (LPQUERYFORM)DSA_GetItemPtr(_hdsaForms, i); TraceAssert(pQueryForm); if (IsEqualCLSID(clsidForm, pQueryForm->clsidForm)) { Trace(TEXT("Form is index %d (%08x)"), i, pQueryForm); break; } } if (!_hdsaForms || (i >= DSA_GetItemCount(_hdsaForms))) pQueryForm = NULL; TraceLeaveValue(pQueryForm); }
[ "seta7D5@protonmail.com" ]
seta7D5@protonmail.com
4a80f607a33a8d32bacb667f0deacf0c63f9f805
98e45aa1ea2adbc961fe5ee0cf87ad71640c3193
/67 Add Binary.cp
5227f3d03513cae3b78621bc28e485e8cce70d67
[]
no_license
Amin747/My-Codes
991b680241d3de6d946c410e734dc9fd50e2a465
76fb69b6dc78f6ff8be4d0f5a34de05fd6e25525
refs/heads/master
2020-12-23T13:36:34.762890
2020-05-14T23:53:29
2020-05-14T23:53:29
237,169,337
0
0
null
null
null
null
UTF-8
C++
false
false
2,178
cp
#include <iostream> #include <string> #include <vector> #include <cmath> using namespace std; //Given a non-empty array of digits representing a non-negative integer, plus one to the integer. // //The digits are stored such that the most significant digit is at the head of the list, and each element in the array contain a single digit. // //You may assume the integer does not contain any leading zero, except the number 0 itself. // //Example 1: // //Input: [1,2,3] //Output: [1,2,4] //Explanation: The array represents the integer 123. //Example 2: // //Input: [4,3,2,1] //Output: [4,3,2,2] //Explanation: The array represents the integer 4321. string addBinary(string a, string b){ int alen = a.length()-1; int blen = b.length()-1; int anslen =max(alen, blen); string answer(anslen+1,' '); int carry = 0; if (alen > blen){ while (blen!=alen){ b = '0' + b; blen++; } } if (blen > alen){ while (alen!=blen){ a = '0' + a; alen ++; } } while (alen >=0 || blen>=0){ if (a[alen]-'0'+b[blen]-'0'+carry==2){ answer[anslen] = '0'; carry = 1; alen--; blen--; anslen--; continue; } if (a[alen]-'0'+b[blen]-'0'+carry==3){ answer[anslen] = '1'; carry = 1; alen--; blen--; anslen--; continue; } if (a[alen]-'0'+b[blen]-'0'+carry==1){ answer[anslen] = '1'; carry = 0; alen--; blen--; anslen--; continue; } if (a[alen]-'0'+b[blen]-'0'+carry==0){ answer[anslen] = '0'; carry = 0; alen--; blen--; anslen--; continue; } } if (alen==-1 && blen==-1 && carry==1){ answer = '1'+answer; } return answer; } int main(){ string one = "1010"; string two = "1011"; string answer = addBinary(one, two); for (int i=0; i<answer.length(); i++){ cout << answer[i] << " "; } }
[ "57550077+Amin747@users.noreply.github.com" ]
57550077+Amin747@users.noreply.github.com
e7d2f771cfe2d34c1fda44b807f79f0c8cfd7946
5437dc6424b182adc0b655739ff7cd94f169feaf
/test/task.h
b4dc094bd66dc0b3cdff8e2dd212c4140a869b88
[]
no_license
ziyuan520/test
23fccbeeed4dee537765e064a71a48918fa010b6
fec6fe66a0bb31b8d773daa93cc2fb75e144b631
refs/heads/master
2021-01-01T06:13:21.193428
2017-07-16T13:09:37
2017-07-16T13:09:37
97,383,485
0
0
null
null
null
null
UTF-8
C++
false
false
705
h
#ifndef TASK_H #define TASK_H #include <QWidget> #include <QString> #include "data.h" //a namespace Ui { class task; } class task : public QWidget { Q_OBJECT public: explicit task(QWidget *parent = 0); void setTitle(char*); void setTime(QDate time,QDate end); void setIndex(int i); void setTitle(QString); void setData(timedata Data); ~task(); private: Ui::task *ui; int index; timedata data; signals: void done(int state,int index); void editDone(int); private slots: void on_checkBox_stateChanged(int arg1); void on_more_clicked(); void sentEditData(timedata editedData); }; #endif // TASK_H
[ "lean@LeandeMacBook-Pro.local" ]
lean@LeandeMacBook-Pro.local
67a675b90bbd11e26da53dd0e76d48a64f1d9da8
20c9c11b8400c6605d869c84e69c41c5faa3f260
/blmarket/2014/Codejam/R1A/D.cc
06adc918dfa298f4a2812406728abac80e8589b0
[]
no_license
blmarket/icpc
312ea2c667ec08d16864c1faa6fe75d3864dedbe
febfc2b758b7a4a4d6e5a6f05d24e3a964a3213a
refs/heads/master
2021-07-23T20:20:19.780664
2021-05-15T13:39:04
2021-05-15T13:39:04
4,029,598
3
1
null
null
null
null
UTF-8
C++
false
false
1,716
cc
#include <iostream> #include <vector> using namespace std; double prob[2][1024][1024]; int main(void) { for(int i=0;i<1000;i++) { prob[0][i][i] = 1.0; } for(int i=0;i<1000;i++) { int cur = (i%2); int nex = (1-cur); memset(prob[nex], 0, sizeof(prob[0])); for(int j=0;j<1000;j++) prob[nex][i][j] = prob[cur][i][j]; for(int j=0;j<1000;j++) if(j != i) { for(int k=0;k<1000;k++) { prob[nex][j][k] += prob[cur][j][k] * 0.999 + prob[cur][i][k] * 0.001; prob[nex][i][k] += prob[cur][j][k] * 0.001 - prob[cur][i][k] * 0.001; } } // for(int j=0;j<1000;j++) for(int k=0;k<1000;k++) prob[nex][j][k] = prob[cur][j][k] * 0.999; // for(int j=0;j<1000;j++) { // for(int a=0;a<1000;a++) for(int b=0;b<1000;b++) { // int na = a; // if(a == i || a == j) { // na = (i+j-a); // } // prob[nex][na][b] += 0.001 * prob[cur][a][b]; // } // } } for(int i=0;i<1000;i++) { for(int j=0;j<1000;j++) { cout << prob[0][i][j] << " "; } cout << endl; } return 0; int T; scanf("%d", &T); int bc = 0; for(int i=0;i<T;i++) { int n; scanf("%d", &n); double pp = 1; for(int j=0;j<n;j++) { int tmp; scanf("%d", &tmp); pp *= prob[0][j][tmp] * 1000; } printf("Case #%d: ", i+1); if(pp > 5.0) { printf("BAD\n"); bc++; } else { printf("GOOD\n"); } } cerr << bc << endl; }
[ "blmarket@gmail.com" ]
blmarket@gmail.com
e5181bd3fef1845ca15a81d031820b647c14f918
e05a2da817a8524e10b1c0c02490825f06dbc83e
/week-07/day-02/01.cpp
49804261ed8268b485c24dcb2f8e03afacecd072
[]
no_license
green-fox-academy/Gabor11
ed54b7a167defa95934b784d92eb5a95a63576cf
9a75874ae0fecea918f38c2858a46a5a71b4f5b7
refs/heads/master
2021-09-06T04:17:40.460148
2018-02-02T09:04:38
2018-02-02T09:04:38
null
0
0
null
null
null
null
UTF-8
C++
false
false
536
cpp
#include <iostream> using namespace std; // create a function that adds two integers. // Create an other function of the same name that takes 3 integers and returns the result of adding these 3 integers. // Write code that uses both after one an other and prints out the results in a new line each. // For input use 1 and 2, then 1, 2 and 3. int sum(int a, int b) { return a + b; } int sum(int a, int b, int c) { return a + b + c; } int main() { cout << sum(1, 2) << endl; cout << sum(1, 2, 3) << endl; return 0; }
[ "matejkagabor@gmail.com" ]
matejkagabor@gmail.com
675591a86efbf8394e529e2b2407f5b2f4334ed9
8ce4ed0f23fc861e024ed66a4cd3328d032df00f
/TanksTutorial/Source/TanksTutorial/Public/TankTracks.h
282311e83f6680359e9f70ce40cc2395673895cf
[]
no_license
PlasmaSnake/TanksTutorial
d22aea5f5820c30b6cc5001a71bebc557932bf58
54dd0136bb7edb1418dfcbcb7a830b9ff3389db9
refs/heads/master
2021-09-16T12:32:11.095614
2018-06-20T16:30:09
2018-06-20T16:30:09
114,600,950
1
0
null
null
null
null
UTF-8
C++
false
false
886
h
// Fill out your copyright notice in the Description page of Project Settings. #pragma once #include "CoreMinimal.h" #include "Components/StaticMeshComponent.h" #include "TankTracks.generated.h" /** * */ UCLASS(meta = (BluePrintSpawnableComponent)) class TANKSTUTORIAL_API UTankTracks : public UStaticMeshComponent { GENERATED_BODY() public: UFUNCTION(BlueprintCallable, Category = "Input") void SetThrottle(float Throttle); //Max Track Force in Newtons UPROPERTY(EditDefaultsOnly) float TrackMaxDrivingForce = 400000; // Assume 40 Ton Tank + 1g ton accel private: UTankTracks(); virtual void BeginPlay() override; void ApplySidewaysForce(); UFUNCTION() void OnHit(UPrimitiveComponent* HitComponent, AActor* OtherActor, UPrimitiveComponent* OtherComponent, FVector NormalImpulse, const FHitResult& Hit); void DriveTracks(); float CurrentThrottle = 0; };
[ "michaelsy34@gmail.com" ]
michaelsy34@gmail.com
6a97959d170efccf1f83d4d7a61bf39c12e87aa4
e00fbab8a4edfc4cec3fbeb461bb33275be91c63
/XMLnew/XmlDocument/XmlDocument.h
af96a089db553a3d75b16c2b3842ebbd8ffd5b31
[]
no_license
Sushanthkengunte/Project-2
3dd368ee01fccc2e53dc243be6ef9901d470b5e0
36452da251cf2fabf95ce3dbc6151d3a697ce812
refs/heads/master
2021-01-23T01:51:39.348253
2017-05-31T02:32:16
2017-05-31T02:32:16
92,895,593
0
0
null
null
null
null
UTF-8
C++
false
false
6,334
h
#ifndef XMLDOCUMENT_H #define XMLDOCUMENT_H /////////////////////////////////////////////////////////////////// // XmlDocument.h - a container of XmlElement nodes // // Ver 2.2 // // Application: Help for CSE687 Pr#2, Spring 2015 // // Platform: Dell XPS 2720, Win 8.1 Pro, Visual Studio 2013 // // Author: Jim Fawcett, CST 4-187, 443-3948 // // jfawcett@twcny.rr.com // /////////////////////////////////////////////////////////////////// /* * Package Operations: * ------------------- * This package is intended to help students in CSE687 - Object Oriented Design * get started with Project #2 - XML Document Model. It uses C++11 constructs, * most noteably std::shared_ptr. The XML Document Model is essentially * a program-friendly wrapper around an Abstract Syntax Tree (AST) used to * contain the results of parsing XML markup. * * Abstract Syntax Trees, defined in this package, are unordered trees with * two types of nodes: * Terminal nodes - nodes with no children * Non-Terminal nodes - nodes which may have a finite number of children * They are often used to contain the results of parsing some language. * * The elements defined in the companion package, XmlElement, will be used in * the AST defined in this package. They are: * AbstractXmlElement - base for all the XML Element types * DocElement - XML element with children designed to hold prologue, Xml root, and epilogue * TaggedElement - XML element with tag, attributes, child elements * TextElement - XML element with only text, no markup * CommentElement - XML element with comment markup and text * ProcInstrElement - XML element with markup and attributes but no children * XmlDeclarElement - XML declaration element with attributes but no children * * Required Files: * --------------- * - XmlDocument.h, XmlDocument.cpp, * XmlElement.h, XmlElement.cpp * * Build Process: * -------------- * devenv AST.sln /debug rebuild * * Maintenance History: * -------------------- * ver 2.2 : 01 Jun 2015 * - added building document from XML file using XmlParser in constructor * - added test to teststub * ver 2.1 : 07 Mar 2015 * - added an XmlDocument method DFS(...) to implement Depth First Search. * This isn't really needed, but was added to illustrate the answer to * a Midterm question. * ver 2.0 : 04 Mar 2015 * This version can programmatically create, edit, and save an XML document. * It is not yet able to parse an XML string or file. * - deleted copy constructor and assignment operator * - defined move constructor and move assignment * - defined search methods element, elements, descendents, select, find * - defined access methods docElement() and xmlRoot() * - defined toString() * ver 1.2 : 21 Feb 2015 * - modified these comments * ver 1.1 : 14 Feb 2015 * - minor changes to comments, method arguments * Ver 1.0 : 11 Feb 2015 * - first release * * ToDo: * ----- * This is the beginning of an XmlDocument class for Project #2. * It lays out a suggested design, which you are not compelled to follow. * If it helps then use it. If not you don't have to. * * Note that I've simply roughed in a design that is similar to that * used in the .Net Framework XDocument class. */ #include <memory> #include <string> #include "../XmlElement/XmlElement.h" namespace XmlProcessing { /////////////////////////////////////////////////////////////////////////// // XmlDocument class class XmlDocument { public: using sPtr = std::shared_ptr < AbstractXmlElement > ; enum sourceType { file, str }; // construction and assignment XmlDocument(sPtr pRoot = nullptr) : pDocElement_(pRoot) {} XmlDocument(const std::string& src, sourceType srcType=str); XmlDocument(const XmlDocument& doc) = delete; XmlDocument(XmlDocument&& doc); XmlDocument& operator=(const XmlDocument& doc) = delete; XmlDocument& operator=(XmlDocument&& doc); // access to docElement and XML root std::shared_ptr<AbstractXmlElement>& docElement() { return pDocElement_; } std::shared_ptr<AbstractXmlElement> xmlRoot(); bool xmlRoot(sPtr pRoot); // queries return XmlDocument references so they can be chained, e.g., doc.element("foobar").descendents(); XmlDocument& element(const std::string& tag); // found_[0] contains first element (DFS order) with tag XmlDocument& elements(const std::string& tag); // found_ contains all children of first element with tag XmlDocument& descendents(const std::string& tag = ""); // found_ contains descendents of prior found_[0] std::vector<sPtr> select(); // returns found_. Uses std::move(found_) to clear found_ bool find(const std::string& tag, sPtr pElem, bool findall = true); size_t size(); std::string toString(); template<typename CallObj> void DFS(sPtr pElem, CallObj& co); private: sPtr pDocElement_; // AST that holds procInstr, comments, XML root, and more comments std::vector<sPtr> found_; // query results }; //----< search subtree of XmlDocument >------------------------------------ template<typename CallObj> void XmlDocument::DFS(sPtr pElem, CallObj& co) { co(*pElem); for (auto pChild : pElem->children()) DFS(pChild, co); } /////////////////////////////////////////////////////////////////////////// // Global Functions for Depth First Search // // These functions take a callable object to define processing on each // element encountered on search traversal. They may be functions, // functors, or lambdas - see XmlDocument.cpp for examples. //----< search subtree of XmlDocument >------------------------------------ template<typename CallObj> void DFS(XmlDocument::sPtr pElem, CallObj& co) { using sPtr = XmlDocument::sPtr; co(*pElem); for (auto pChild : pElem->children()) DFS(pChild, co); } //----< search entire XmlDocument >---------------------------------------- template<typename CallObj> void DFS(XmlDocument& doc, CallObj& co) { using sPtr = XmlDocument::sPtr; sPtr pDocElem = doc.docElement(); DFS(pDocElem, co); } } #endif
[ "sushanthkengunte@gmail.com" ]
sushanthkengunte@gmail.com
6b255903573b568c6a2d48f1703d977e15c2e7ce
5ca725fa93f69be671866e7b57f8be1df3eecf3a
/code/editor/qt/qgleswidget.h
0da78e7383cec6351b66ad1135ca79fb674d44f3
[ "MIT" ]
permissive
PureDu/potato
9544577fcdb756f9c7516d4e776eb1c0b2305e5a
aa574be8262f98099b9b657e03f175bb98df78f2
refs/heads/master
2021-05-29T17:10:51.566955
2015-01-10T01:15:36
2015-01-10T01:15:36
null
0
0
null
null
null
null
UTF-8
C++
false
false
1,965
h
#pragma once #include "input.h" #include <QtOpenGL/QGLWidget> #include <QtCore/QBasicTimer> #if defined(CXX_GNU) #include <EGL/egl.h> #elif defined(CXX_MSVC) #include <Windows.h> #endif namespace c4g { namespace core { class IRender; } namespace scene { class ISceneImpl; } namespace qt { class QGLESFormat : public QGLFormat { public: static QGLESFormat instance; private: QGLESFormat(); virtual ~QGLESFormat(); public: }; class QGLESWidget; class QGLESContext : public QGLContext { public: explicit QGLESContext(QGLESWidget* widget); virtual ~QGLESContext(); public: virtual bool create(const QGLContext* shareContext = 0); protected: virtual bool chooseContext(const QGLContext* shareContext = 0); public: virtual void makeCurrent(); virtual void doneCurrent(); virtual void swapBuffers() const; private: QGLESWidget* m_pWidget; #if defined(CXX_GNU) EGLConfig m_pGLConfig; EGLDisplay m_pGLDisplay; EGLContext m_pGLContext; EGLSurface m_pGLSurface; #elif defined(CXX_MSVC) HGLRC m_pRC; HDC m_pDC; #endif }; class QGLESWidget : public QGLWidget { Q_OBJECT public: QGLESWidget(QWidget* pParent = NULL); virtual ~QGLESWidget(); public: void Initialize(core::MString2Module& rmModule); public Q_SLOTS: void ToLoadScene(QString sScenePath); Q_SIGNALS: void DidLoadScene(c4g::scene::ISceneImpl*const pScene); protected: void mousePressEvent(QMouseEvent *e); void mouseReleaseEvent(QMouseEvent *e); void timerEvent(QTimerEvent *e); protected: void initializeGL(); void resizeGL(int w, int h); void paintGL(); private: c4g::core::IRender* m_pRender; c4g::scene::ISceneImpl* m_pScene; QBasicTimer timer; float m_fWidth; float m_fHeight; display::CInput m_oInput; #if defined(CXX_GNU) timeval time; #elif defined(CXX_MSVC) SYSTEMTIME time; #endif double second; double second_temp; double second_delta; double second_sleep; double second_per_frame_min; }; } }
[ "alex@alexchi.me" ]
alex@alexchi.me
5dfc8bad2bc9ae87c1dec8d27b296f25800c7978
81c959f7894efc60a2747bf5136429d914b92f96
/ui/views/mus/views_mus_test_suite.cc
cf479177218cebe7e13b9d49b05600e5982d7ee6
[ "BSD-3-Clause" ]
permissive
emilio/chromium
89f175c679c63e9e2b11e23c0764b02851235cfe
ab3d36b33fb3412d562033d68c716ddae6e4c3bd
refs/heads/master
2023-03-10T04:49:52.623535
2017-03-10T02:57:25
2017-03-10T02:57:25
84,578,466
2
0
null
2017-03-10T16:21:05
2017-03-10T16:21:05
null
UTF-8
C++
false
false
9,826
cc
// Copyright 2016 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 "ui/views/mus/views_mus_test_suite.h" #include <memory> #include <string> #include "base/command_line.h" #include "base/files/file_path.h" #include "base/memory/ptr_util.h" #include "base/run_loop.h" #include "base/synchronization/waitable_event.h" #include "base/threading/simple_thread.h" #include "base/threading/thread.h" #include "mojo/edk/embedder/embedder.h" #include "mojo/edk/embedder/scoped_ipc_support.h" #include "services/catalog/catalog.h" #include "services/service_manager/background/background_service_manager.h" #include "services/service_manager/public/cpp/connector.h" #include "services/service_manager/public/cpp/service.h" #include "services/service_manager/public/cpp/service_context.h" #include "services/ui/common/switches.h" #include "testing/gtest/include/gtest/gtest.h" #include "ui/aura/mus/window_tree_host_mus.h" #include "ui/aura/test/env_test_helper.h" #include "ui/aura/test/mus/input_method_mus_test_api.h" #include "ui/aura/window.h" #include "ui/gl/gl_switches.h" #include "ui/views/mus/desktop_window_tree_host_mus.h" #include "ui/views/mus/mus_client.h" #include "ui/views/mus/test_utils.h" #include "ui/views/test/platform_test_helper.h" #include "ui/views/test/views_test_helper_aura.h" #include "ui/views/views_delegate.h" #include "ui/views/widget/desktop_aura/desktop_native_widget_aura.h" namespace views { namespace { const base::FilePath::CharType kCatalogFilename[] = FILE_PATH_LITERAL("views_mus_tests_catalog.json"); void EnsureCommandLineSwitch(const std::string& name) { base::CommandLine* cmd_line = base::CommandLine::ForCurrentProcess(); if (!cmd_line->HasSwitch(name)) cmd_line->AppendSwitch(name); } class DefaultService : public service_manager::Service { public: DefaultService() {} ~DefaultService() override {} // service_manager::Service: bool OnConnect(const service_manager::ServiceInfo& remote_info, service_manager::InterfaceRegistry* registry) override { return false; } private: DISALLOW_COPY_AND_ASSIGN(DefaultService); }; class PlatformTestHelperMus : public PlatformTestHelper { public: PlatformTestHelperMus(service_manager::Connector* connector, const service_manager::Identity& identity) { aura::test::EnvTestHelper().SetWindowTreeClient(nullptr); // It is necessary to recreate the MusClient for each test, // since a new MessageLoop is created for each test. mus_client_ = test::MusClientTestApi::Create(connector, identity); ViewsDelegate::GetInstance()->set_native_widget_factory(base::Bind( &PlatformTestHelperMus::CreateNativeWidget, base::Unretained(this))); } ~PlatformTestHelperMus() override { aura::test::EnvTestHelper().SetWindowTreeClient(nullptr); } // PlatformTestHelper: void OnTestHelperCreated(ViewsTestHelper* helper) override { static_cast<ViewsTestHelperAura*>(helper)->EnableMusWithWindowTreeClient( mus_client_->window_tree_client()); } void SimulateNativeDestroy(Widget* widget) override { aura::WindowTreeHostMus* window_tree_host = static_cast<aura::WindowTreeHostMus*>( widget->GetNativeView()->GetHost()); static_cast<aura::WindowTreeClientDelegate*>(mus_client_.get()) ->OnEmbedRootDestroyed(window_tree_host); } private: NativeWidget* CreateNativeWidget(const Widget::InitParams& init_params, internal::NativeWidgetDelegate* delegate) { NativeWidget* native_widget = mus_client_->CreateNativeWidget(init_params, delegate); if (!native_widget) return nullptr; // Disable sending KeyEvents to IME as tests aren't set up to wait for an // ack (and tests run concurrently). aura::WindowTreeHostMus* window_tree_host_mus = static_cast<aura::WindowTreeHostMus*>( static_cast<DesktopNativeWidgetAura*>(native_widget)->host()); aura::InputMethodMusTestApi::Disable(window_tree_host_mus->input_method()); return native_widget; } std::unique_ptr<MusClient> mus_client_; DISALLOW_COPY_AND_ASSIGN(PlatformTestHelperMus); }; std::unique_ptr<PlatformTestHelper> CreatePlatformTestHelper( const service_manager::Identity& identity, const base::Callback<service_manager::Connector*(void)>& callback) { return base::MakeUnique<PlatformTestHelperMus>(callback.Run(), identity); } } // namespace class ServiceManagerConnection { public: ServiceManagerConnection() : thread_("Persistent service_manager connections"), ipc_thread_("IPC thread") { catalog::Catalog::LoadDefaultCatalogManifest( base::FilePath(kCatalogFilename)); mojo::edk::Init(); ipc_thread_.StartWithOptions( base::Thread::Options(base::MessageLoop::TYPE_IO, 0)); ipc_support_ = base::MakeUnique<mojo::edk::ScopedIPCSupport>( ipc_thread_.task_runner(), mojo::edk::ScopedIPCSupport::ShutdownPolicy::CLEAN); base::WaitableEvent wait(base::WaitableEvent::ResetPolicy::AUTOMATIC, base::WaitableEvent::InitialState::NOT_SIGNALED); base::Thread::Options options; thread_.StartWithOptions(options); thread_.task_runner()->PostTask( FROM_HERE, base::Bind(&ServiceManagerConnection::SetUpConnections, base::Unretained(this), &wait)); wait.Wait(); // WindowManagerConnection cannot be created from here yet, although the // connector and identity are available at this point. This is because // WindowManagerConnection needs a ViewsDelegate and a MessageLoop to have // been installed first. So delay the creation until the necessary // dependencies have been met. PlatformTestHelper::set_factory( base::Bind(&CreatePlatformTestHelper, service_manager_identity_, base::Bind(&ServiceManagerConnection::GetConnector, base::Unretained(this)))); } ~ServiceManagerConnection() { base::WaitableEvent wait(base::WaitableEvent::ResetPolicy::AUTOMATIC, base::WaitableEvent::InitialState::NOT_SIGNALED); thread_.task_runner()->PostTask( FROM_HERE, base::Bind(&ServiceManagerConnection::TearDownConnections, base::Unretained(this), &wait)); wait.Wait(); } private: service_manager::Connector* GetConnector() { service_manager_connector_.reset(); base::WaitableEvent wait(base::WaitableEvent::ResetPolicy::AUTOMATIC, base::WaitableEvent::InitialState::NOT_SIGNALED); thread_.task_runner()->PostTask( FROM_HERE, base::Bind(&ServiceManagerConnection::CloneConnector, base::Unretained(this), &wait)); wait.Wait(); DCHECK(service_manager_connector_); return service_manager_connector_.get(); } void CloneConnector(base::WaitableEvent* wait) { service_manager_connector_ = context_->connector()->Clone(); wait->Signal(); } void SetUpConnections(base::WaitableEvent* wait) { background_service_manager_ = base::MakeUnique<service_manager::BackgroundServiceManager>( nullptr, nullptr); service_manager::mojom::ServicePtr service; context_ = base::MakeUnique<service_manager::ServiceContext>( base::MakeUnique<DefaultService>(), service_manager::mojom::ServiceRequest(&service)); background_service_manager_->RegisterService( service_manager::Identity( GetTestName(), service_manager::mojom::kRootUserID), std::move(service), nullptr); // ui/views/mus requires a WindowManager running, so launch test_wm. service_manager::Connector* connector = context_->connector(); connector->Connect("test_wm"); service_manager_connector_ = connector->Clone(); service_manager_identity_ = context_->identity(); wait->Signal(); } void TearDownConnections(base::WaitableEvent* wait) { context_.reset(); wait->Signal(); } // Returns the name of the test executable, e.g. // "views_mus_unittests". std::string GetTestName() { base::FilePath executable = base::CommandLine::ForCurrentProcess() ->GetProgram() .BaseName() .RemoveExtension(); return std::string("") + executable.MaybeAsASCII(); } base::Thread thread_; base::Thread ipc_thread_; std::unique_ptr<mojo::edk::ScopedIPCSupport> ipc_support_; std::unique_ptr<service_manager::BackgroundServiceManager> background_service_manager_; std::unique_ptr<service_manager::ServiceContext> context_; std::unique_ptr<service_manager::Connector> service_manager_connector_; service_manager::Identity service_manager_identity_; DISALLOW_COPY_AND_ASSIGN(ServiceManagerConnection); }; ViewsMusTestSuite::ViewsMusTestSuite(int argc, char** argv) : ViewsTestSuite(argc, argv) {} ViewsMusTestSuite::~ViewsMusTestSuite() {} void ViewsMusTestSuite::Initialize() { PlatformTestHelper::SetIsMus(); // Let other services know that we're running in tests. Do this with a // command line flag to avoid making blocking calls to other processes for // setup for tests (e.g. to unlock the screen in the window manager). EnsureCommandLineSwitch(ui::switches::kUseTestConfig); EnsureCommandLineSwitch(switches::kOverrideUseSoftwareGLForTests); ViewsTestSuite::Initialize(); service_manager_connections_ = base::MakeUnique<ServiceManagerConnection>(); } void ViewsMusTestSuite::Shutdown() { service_manager_connections_.reset(); ViewsTestSuite::Shutdown(); } } // namespace views
[ "commit-bot@chromium.org" ]
commit-bot@chromium.org
83bb4efdcb27e64d45083aa20b1353fbf0f3525e
603cb2bd2a1098ad60bf3b7f3ee1e81d7a7ffb58
/src/Config.h
bf17cc08ba29fe80893c6508e8d313b4d339184e
[]
no_license
ajorians/nHitori
d564cd215dacd7428a53ef5747f568870286fe6f
1de81e0bb32a3f2551ce156723e09d29dfaa96a2
refs/heads/master
2016-09-06T12:07:47.495363
2016-01-26T21:23:33
2016-01-26T21:23:33
22,314,044
0
0
null
null
null
null
UTF-8
C++
false
false
524
h
#ifndef CONFIG_H #define CONFIG_H extern "C" { #include <os.h> #include "ArchiveLib/ArchiveLib.h" } class Config { public: Config(); ~Config(); bool GetSolutionHelper() const; void SetSolutionHelper(bool bEnable); bool GetSelectorMovementAnimate() const; void SetSelectorMovementAnimate(bool bEnable); bool BeatLevel(int nLevelNumber) const; void SetBeatLevel(int nLevelNumber); protected: ArchiveLib m_Archive; bool m_bSolutionHelper; bool m_bSelectorMovementAnimate; }; #endif
[ "aj@orians.org" ]
aj@orians.org
93db2c0e94d5a63b27df6d04bb552e070309469d
21ede326b6cfcf5347ca6772d392d3acca80cfa0
/ash/wm/panels/panel_layout_manager.cc
f849908f7d434ed8ddfaa6950ccf0f68181bcb88
[ "BSD-3-Clause" ]
permissive
csagan5/kiwi
6eaab0ab4db60468358291956506ad6f889401f8
eb2015c28925be91b4a3130b3c2bee2f5edc91de
refs/heads/master
2020-04-04T17:06:54.003121
2018-10-24T08:20:01
2018-10-24T08:20:01
156,107,399
2
0
null
null
null
null
UTF-8
C++
false
false
35,291
cc
// Copyright (c) 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 "ash/wm/panels/panel_layout_manager.h" #include <algorithm> #include <map> #include <utility> #include "ash/public/cpp/shell_window_ids.h" #include "ash/public/cpp/window_properties.h" #include "ash/root_window_controller.h" #include "ash/shelf/shelf.h" #include "ash/shell.h" #include "ash/wm/overview/window_selector_controller.h" #include "ash/wm/window_animation_types.h" #include "ash/wm/window_parenting_utils.h" #include "ash/wm/window_properties.h" #include "ash/wm/window_state.h" #include "ash/wm/window_util.h" #include "base/auto_reset.h" #include "third_party/skia/include/core/SkColor.h" #include "third_party/skia/include/core/SkPath.h" #include "ui/aura/client/window_parenting_client.h" #include "ui/aura/window_delegate.h" #include "ui/compositor/scoped_layer_animation_settings.h" #include "ui/gfx/canvas.h" #include "ui/gfx/geometry/rect.h" #include "ui/gfx/geometry/vector2d.h" #include "ui/views/background.h" #include "ui/views/widget/widget.h" #include "ui/wm/core/coordinate_conversion.h" #include "ui/wm/core/window_util.h" #include "ui/wm/public/activation_client.h" using aura::Window; namespace ash { namespace { const int kPanelIdealSpacing = 4; const float kMaxHeightFactor = .80f; const float kMaxWidthFactor = .50f; // Duration for panel animations. const int kPanelSlideDurationMilliseconds = 50; const int kCalloutFadeDurationMilliseconds = 50; // Offset used when sliding panel in/out of the shelf. Used for minimizing, // restoring and the initial showing of a panel. const int kPanelSlideInOffset = 20; // Callout arrow dimensions. const int kArrowWidth = 18; const int kArrowHeight = 9; class CalloutWidgetBackground : public views::Background { public: CalloutWidgetBackground() : alignment_(SHELF_ALIGNMENT_BOTTOM) {} void Paint(gfx::Canvas* canvas, views::View* view) const override { SkPath path; switch (alignment_) { case SHELF_ALIGNMENT_BOTTOM: case SHELF_ALIGNMENT_BOTTOM_LOCKED: path.moveTo(SkIntToScalar(0), SkIntToScalar(0)); path.lineTo(SkIntToScalar(kArrowWidth / 2), SkIntToScalar(kArrowHeight)); path.lineTo(SkIntToScalar(kArrowWidth), SkIntToScalar(0)); break; case SHELF_ALIGNMENT_LEFT: path.moveTo(SkIntToScalar(kArrowHeight), SkIntToScalar(kArrowWidth)); path.lineTo(SkIntToScalar(0), SkIntToScalar(kArrowWidth / 2)); path.lineTo(SkIntToScalar(kArrowHeight), SkIntToScalar(0)); break; case SHELF_ALIGNMENT_RIGHT: path.moveTo(SkIntToScalar(0), SkIntToScalar(0)); path.lineTo(SkIntToScalar(kArrowHeight), SkIntToScalar(kArrowWidth / 2)); path.lineTo(SkIntToScalar(0), SkIntToScalar(kArrowWidth)); break; } // Hard code the arrow color for now. cc::PaintFlags flags; flags.setStyle(cc::PaintFlags::kFill_Style); flags.setColor(SkColorSetARGB(0xff, 0xe5, 0xe5, 0xe5)); canvas->DrawPath(path, flags); } ShelfAlignment alignment() { return alignment_; } void set_alignment(ShelfAlignment alignment) { alignment_ = alignment; } private: ShelfAlignment alignment_; DISALLOW_COPY_AND_ASSIGN(CalloutWidgetBackground); }; struct VisiblePanelPositionInfo { VisiblePanelPositionInfo() : min_major(0), max_major(0), major_pos(0), major_length(0), window(nullptr), slide_in(false) {} int min_major; int max_major; int major_pos; int major_length; Window* window; bool slide_in; }; bool CompareWindowMajor(const VisiblePanelPositionInfo& win1, const VisiblePanelPositionInfo& win2) { return win1.major_pos < win2.major_pos; } void FanOutPanels(std::vector<VisiblePanelPositionInfo>::iterator first, std::vector<VisiblePanelPositionInfo>::iterator last) { int num_panels = last - first; if (num_panels == 1) { (*first).major_pos = std::max( (*first).min_major, std::min((*first).max_major, (*first).major_pos)); } if (num_panels <= 1) return; if (num_panels == 2) { // If there are two adjacent overlapping windows, separate them by the // minimum major_length necessary. std::vector<VisiblePanelPositionInfo>::iterator second = first + 1; int separation = (*first).major_length / 2 + (*second).major_length / 2 + kPanelIdealSpacing; int overlap = (*first).major_pos + separation - (*second).major_pos; (*first).major_pos = std::max((*first).min_major, (*first).major_pos - overlap / 2); (*second).major_pos = std::min((*second).max_major, (*first).major_pos + separation); // Recalculate the first panel position in case the second one was // constrained on the right. (*first).major_pos = std::max((*first).min_major, (*second).major_pos - separation); return; } // If there are more than two overlapping windows, fan them out from minimum // position to maximum position equally spaced. int delta = ((*(last - 1)).max_major - (*first).min_major) / (num_panels - 1); int major_pos = (*first).min_major; for (std::vector<VisiblePanelPositionInfo>::iterator iter = first; iter != last; ++iter) { (*iter).major_pos = std::max((*iter).min_major, std::min((*iter).max_major, major_pos)); major_pos += delta; } } bool BoundsAdjacent(const gfx::Rect& bounds1, const gfx::Rect& bounds2) { return bounds1.x() == bounds2.right() || bounds1.y() == bounds2.bottom() || bounds1.right() == bounds2.x() || bounds1.bottom() == bounds2.y(); } gfx::Vector2d GetSlideInAnimationOffset(ShelfAlignment alignment) { gfx::Vector2d offset; if (alignment == SHELF_ALIGNMENT_LEFT) offset.set_x(-kPanelSlideInOffset); else if (alignment == SHELF_ALIGNMENT_RIGHT) offset.set_x(kPanelSlideInOffset); else offset.set_y(kPanelSlideInOffset); return offset; } } // namespace class PanelCalloutWidget : public views::Widget { public: explicit PanelCalloutWidget(Window* container) : background_(nullptr) { InitWidget(container); } // Updates the bounds based on the shelf alignment. void UpdateBounds(Shelf* shelf) { Window* window = this->GetNativeWindow(); gfx::Rect callout_bounds = window->bounds(); if (shelf->IsHorizontalAlignment()) { callout_bounds.set_width(kArrowWidth); callout_bounds.set_height(kArrowHeight); } else { callout_bounds.set_width(kArrowHeight); callout_bounds.set_height(kArrowWidth); } Window* parent = window->parent(); // It's important this go through Window and not Widget. Going through // Widget means it may move do a different screen, we don't want that. window->SetBounds(callout_bounds); // Setting the bounds should not trigger changing the parent. DCHECK_EQ(parent, window->parent()); if (background_->alignment() != shelf->alignment()) { background_->set_alignment(shelf->alignment()); SchedulePaintInRect(gfx::Rect(callout_bounds.size())); } } private: void InitWidget(Window* parent) { views::Widget::InitParams params; params.type = views::Widget::InitParams::TYPE_POPUP; params.opacity = views::Widget::InitParams::TRANSLUCENT_WINDOW; params.keep_on_top = true; params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET; ::wm::ConvertRectToScreen(parent, &params.bounds); params.bounds.set_width(kArrowWidth); params.bounds.set_height(kArrowHeight); params.accept_events = false; params.parent = parent; set_focus_on_creation(false); Init(params); Window* widget_window = this->GetNativeWindow(); DCHECK_EQ(widget_window->GetRootWindow(), parent->GetRootWindow()); views::View* content_view = new views::View; background_ = new CalloutWidgetBackground; content_view->SetBackground( std::unique_ptr<views::Background>(background_)); SetContentsView(content_view); widget_window->layer()->SetOpacity(0); } // Weak pointer owned by this widget's content view. CalloutWidgetBackground* background_; DISALLOW_COPY_AND_ASSIGN(PanelCalloutWidget); }; views::Widget* PanelLayoutManager::PanelInfo::CalloutWidget() { return callout_widget; } //////////////////////////////////////////////////////////////////////////////// // PanelLayoutManager public implementation: PanelLayoutManager::PanelLayoutManager(Window* panel_container) : panel_container_(panel_container), root_window_controller_(RootWindowController::ForWindow(panel_container)), in_add_window_(false), in_layout_(false), show_callout_widgets_(true), dragged_panel_(nullptr), shelf_(nullptr), last_active_panel_(nullptr), weak_factory_(this) { DCHECK(panel_container); Shell::Get()->activation_client()->AddObserver(this); Shell::Get()->window_tree_host_manager()->AddObserver(this); Shell::Get()->AddShellObserver(this); } PanelLayoutManager::~PanelLayoutManager() { Shutdown(); } // static PanelLayoutManager* PanelLayoutManager::Get(Window* window) { if (!window) return nullptr; return static_cast<PanelLayoutManager*>( window->GetRootWindow() ->GetChildById(kShellWindowId_PanelContainer) ->layout_manager()); } void PanelLayoutManager::Shutdown() { if (shelf_) { shelf_->RemoveObserver(this); shelf_ = nullptr; } for (PanelList::iterator iter = panel_windows_.begin(); iter != panel_windows_.end(); ++iter) { delete iter->callout_widget; } panel_windows_.clear(); Shell::Get()->activation_client()->RemoveObserver(this); Shell::Get()->window_tree_host_manager()->RemoveObserver(this); Shell::Get()->RemoveShellObserver(this); } void PanelLayoutManager::StartDragging(Window* panel) { DCHECK(!dragged_panel_); dragged_panel_ = panel; Relayout(); } void PanelLayoutManager::FinishDragging() { dragged_panel_ = nullptr; Relayout(); } void PanelLayoutManager::SetShelf(Shelf* shelf) { DCHECK(!shelf_); shelf_ = shelf; shelf_->AddObserver(this); WillChangeVisibilityState(shelf_->GetVisibilityState()); } void PanelLayoutManager::ToggleMinimize(Window* panel) { DCHECK(panel->parent() == panel_container_); wm::WindowState* window_state = wm::GetWindowState(panel); if (window_state->IsMinimized()) window_state->Restore(); else window_state->Minimize(); } void PanelLayoutManager::SetShowCalloutWidgets(bool show) { if (show_callout_widgets_ == show) return; show_callout_widgets_ = show; UpdateCallouts(); } views::Widget* PanelLayoutManager::GetCalloutWidgetForPanel(Window* panel) { DCHECK(panel->parent() == panel_container_); PanelList::iterator found = std::find(panel_windows_.begin(), panel_windows_.end(), panel); DCHECK(found != panel_windows_.end()); return found->callout_widget; } //////////////////////////////////////////////////////////////////////////////// // PanelLayoutManager, aura::LayoutManager implementation: void PanelLayoutManager::OnWindowResized() { Relayout(); } void PanelLayoutManager::OnWindowAddedToLayout(Window* child) { if (child->type() == aura::client::WINDOW_TYPE_POPUP) return; if (in_add_window_) return; base::AutoReset<bool> auto_reset_in_add_window(&in_add_window_, true); if (!child->GetProperty(kPanelAttachedKey)) { // This should only happen when a window is added to panel container as a // result of bounds change from within the application during a drag. // If so we have already stopped the drag and should reparent the panel // back to appropriate container and ignore it. // TODO(varkha): Updating bounds during a drag can cause problems and a more // general solution is needed. See http://crbug.com/251813 . Window* old_parent = child->parent(); aura::client::ParentWindowWithContext( child, child, child->GetRootWindow()->GetBoundsInScreen()); wm::ReparentTransientChildrenOfChild(child, old_parent, child->parent()); DCHECK(child->parent()->id() != kShellWindowId_PanelContainer); return; } PanelInfo panel_info; panel_info.window = child; panel_info.callout_widget = new PanelCalloutWidget(panel_container_); panel_info.slide_in = child != dragged_panel_; panel_windows_.push_back(panel_info); child->AddObserver(this); wm::GetWindowState(child)->AddObserver(this); Relayout(); } void PanelLayoutManager::OnWillRemoveWindowFromLayout(Window* child) {} void PanelLayoutManager::OnWindowRemovedFromLayout(Window* child) { if (child->type() == aura::client::WINDOW_TYPE_POPUP) return; PanelList::iterator found = std::find(panel_windows_.begin(), panel_windows_.end(), child); if (found != panel_windows_.end()) { delete found->callout_widget; panel_windows_.erase(found); } if (restore_windows_on_shelf_visible_) restore_windows_on_shelf_visible_->Remove(child); child->RemoveObserver(this); wm::GetWindowState(child)->RemoveObserver(this); if (dragged_panel_ == child) dragged_panel_ = nullptr; if (last_active_panel_ == child) last_active_panel_ = nullptr; Relayout(); } void PanelLayoutManager::OnChildWindowVisibilityChanged(Window* child, bool visible) { if (visible) wm::GetWindowState(child)->Restore(); Relayout(); } void PanelLayoutManager::SetChildBounds(Window* child, const gfx::Rect& requested_bounds) { gfx::Rect bounds(requested_bounds); const gfx::Rect& max_bounds = panel_container_->GetRootWindow()->bounds(); const int max_width = max_bounds.width() * kMaxWidthFactor; const int max_height = max_bounds.height() * kMaxHeightFactor; if (bounds.width() > max_width) bounds.set_width(max_width); if (bounds.height() > max_height) bounds.set_height(max_height); // Reposition dragged panel in the panel order. if (dragged_panel_ == child) { PanelList::iterator dragged_panel_iter = std::find(panel_windows_.begin(), panel_windows_.end(), dragged_panel_); DCHECK(dragged_panel_iter != panel_windows_.end()); PanelList::iterator new_position; for (new_position = panel_windows_.begin(); new_position != panel_windows_.end(); ++new_position) { const gfx::Rect& bounds = (*new_position).window->bounds(); if (bounds.x() + bounds.width() / 2 <= requested_bounds.x()) break; } if (new_position != dragged_panel_iter) { PanelInfo dragged_panel_info = *dragged_panel_iter; panel_windows_.erase(dragged_panel_iter); panel_windows_.insert(new_position, dragged_panel_info); } } // Respect the minimum size of the window. if (child->delegate()) { const gfx::Size min_size = child->delegate()->GetMinimumSize(); bounds.set_width(std::max(min_size.width(), bounds.width())); bounds.set_height(std::max(min_size.height(), bounds.height())); } SetChildBoundsDirect(child, bounds); wm::SnapWindowToPixelBoundary(child); Relayout(); } //////////////////////////////////////////////////////////////////////////////// // PanelLayoutManager, ShellObserver implementation: void PanelLayoutManager::OnOverviewModeEnded() { Relayout(); } void PanelLayoutManager::OnShelfAlignmentChanged(aura::Window* root_window) { if (root_window_controller_->GetRootWindow() == root_window) Relayout(); } ///////////////////////////////////////////////////////////////////////////// // PanelLayoutManager, WindowObserver implementation: void PanelLayoutManager::OnWindowPropertyChanged(Window* window, const void* key, intptr_t old) { // Trigger a relayout to position the panels whenever the panel icon is set // or changes. if (key == kShelfIDKey) Relayout(); } ///////////////////////////////////////////////////////////////////////////// // PanelLayoutManager, WindowStateObserver implementation: void PanelLayoutManager::OnPostWindowStateTypeChange( wm::WindowState* window_state, mojom::WindowStateType old_type) { // If the shelf is currently hidden then windows will not actually be shown // but the set to restore when the shelf becomes visible is updated. if (restore_windows_on_shelf_visible_) { if (window_state->IsMinimized()) { MinimizePanel(window_state->window()); restore_windows_on_shelf_visible_->Remove(window_state->window()); } else { restore_windows_on_shelf_visible_->Add(window_state->window()); } return; } if (window_state->IsMinimized()) MinimizePanel(window_state->window()); else RestorePanel(window_state->window()); } //////////////////////////////////////////////////////////////////////////////// // PanelLayoutManager, wm::ActivationChangeObserver implementation: void PanelLayoutManager::OnWindowActivated(ActivationReason reason, Window* gained_active, Window* lost_active) { // Ignore if the panel that is not managed by this was activated. if (gained_active && gained_active->type() == aura::client::WINDOW_TYPE_PANEL && gained_active->parent() == panel_container_) { UpdateStacking(gained_active); UpdateCallouts(); } } //////////////////////////////////////////////////////////////////////////////// // PanelLayoutManager, WindowTreeHostManager::Observer implementation: void PanelLayoutManager::OnDisplayConfigurationChanged() { Relayout(); } //////////////////////////////////////////////////////////////////////////////// // PanelLayoutManager, ShelfLayoutManagerObserver implementation: void PanelLayoutManager::WillChangeVisibilityState( ShelfVisibilityState new_state) { // On entering / leaving full screen mode the shelf visibility state is // changed to / from SHELF_HIDDEN. In this state, panel windows should hide // to allow the full-screen application to use the full screen. bool shelf_hidden = new_state == ash::SHELF_HIDDEN; if (!shelf_hidden) { if (restore_windows_on_shelf_visible_) { std::unique_ptr<aura::WindowTracker> restore_windows( std::move(restore_windows_on_shelf_visible_)); for (Window* window : restore_windows->windows()) RestorePanel(window); } return; } if (restore_windows_on_shelf_visible_) return; std::unique_ptr<aura::WindowTracker> minimized_windows( new aura::WindowTracker); for (PanelList::iterator iter = panel_windows_.begin(); iter != panel_windows_.end();) { Window* window = iter->window; // Minimizing a panel window may remove it from the panel_windows_ list. // Advance the iterator before minimizing it: http://crbug.com/393047. ++iter; if (window != dragged_panel_ && window->IsVisible()) { minimized_windows->Add(window); wm::GetWindowState(window)->Minimize(); } } restore_windows_on_shelf_visible_ = std::move(minimized_windows); } void PanelLayoutManager::OnShelfIconPositionsChanged() { // TODO: As this is called for every animation step now. Relayout needs to be // updated to use current icon position instead of use the ideal bounds so // that the panels slide with their icons instead of jumping. Relayout(); } //////////////////////////////////////////////////////////////////////////////// // PanelLayoutManager private implementation: void PanelLayoutManager::MinimizePanel(Window* panel) { // Clusterfuzz can trigger panel accelerators before the shelf is created. // TODO(jamescook): Revert this after http://crbug.com/648964 is fixed. if (!shelf_) return; ::wm::SetWindowVisibilityAnimationType( panel, wm::WINDOW_VISIBILITY_ANIMATION_TYPE_MINIMIZE); ui::Layer* layer = panel->layer(); ui::ScopedLayerAnimationSettings panel_slide_settings(layer->GetAnimator()); panel_slide_settings.SetPreemptionStrategy( ui::LayerAnimator::IMMEDIATELY_ANIMATE_TO_NEW_TARGET); panel_slide_settings.SetTransitionDuration( base::TimeDelta::FromMilliseconds(kPanelSlideDurationMilliseconds)); gfx::Rect bounds(panel->bounds()); bounds.Offset(GetSlideInAnimationOffset(shelf_->alignment())); SetChildBoundsDirect(panel, bounds); panel->Hide(); layer->SetOpacity(0); if (::wm::IsActiveWindow(panel)) ::wm::DeactivateWindow(panel); Relayout(); } void PanelLayoutManager::RestorePanel(Window* panel) { PanelList::iterator found = std::find(panel_windows_.begin(), panel_windows_.end(), panel); DCHECK(found != panel_windows_.end()); found->slide_in = true; Relayout(); } void PanelLayoutManager::Relayout() { if (!shelf_ || !shelf_->GetWindow()) return; // Suppress layouts during overview mode because changing window bounds // interfered with overview mode animations. However, layouts need to be done // when the WindowSelectorController is restoring minimized windows so that // they actually become visible. WindowSelectorController* window_selector_controller = Shell::Get()->window_selector_controller(); if (in_layout_ || (window_selector_controller->IsSelecting() && !window_selector_controller->IsRestoringMinimizedWindows())) { return; } base::AutoReset<bool> auto_reset_in_layout(&in_layout_, true); const bool horizontal = shelf_->IsHorizontalAlignment(); gfx::Rect shelf_bounds = shelf_->GetWindow()->GetBoundsInScreen(); ::wm::ConvertRectFromScreen(panel_container_, &shelf_bounds); int panel_start_bounds = kPanelIdealSpacing; int panel_end_bounds = horizontal ? panel_container_->bounds().width() - kPanelIdealSpacing : panel_container_->bounds().height() - kPanelIdealSpacing; Window* active_panel = nullptr; std::vector<VisiblePanelPositionInfo> visible_panels; for (PanelList::iterator iter = panel_windows_.begin(); iter != panel_windows_.end(); ++iter) { Window* panel = iter->window; iter->callout_widget->UpdateBounds(shelf_); // Consider the dragged panel as part of the layout as long as it is // touching the shelf. if ((!panel->IsVisible() && !iter->slide_in) || (panel == dragged_panel_ && !BoundsAdjacent(panel->bounds(), shelf_bounds))) { continue; } // If the shelf is currently hidden (full-screen mode), minimize panel until // full-screen mode is exited. When a panel is dragged from another display // the shelf state does not update before the panel is added so we exclude // the dragged panel. if (panel != dragged_panel_ && restore_windows_on_shelf_visible_) { wm::GetWindowState(panel)->Minimize(); restore_windows_on_shelf_visible_->Add(panel); continue; } gfx::Rect icon_bounds = shelf_->GetScreenBoundsOfItemIconForWindow(panel); // If both the icon width and height are 0 then there is no icon in the // shelf. If the shelf is hidden, one of the height or width will be // 0 but the position in the shelf and major dimension is still reported // correctly and the panel can be aligned above where the hidden icon is. if (icon_bounds.width() == 0 && icon_bounds.height() == 0) continue; if (panel->HasFocus() || panel->Contains(wm::GetFocusedWindow())) { DCHECK(!active_panel); active_panel = panel; } ::wm::ConvertRectFromScreen(panel_container_, &icon_bounds); gfx::Point icon_origin = icon_bounds.origin(); VisiblePanelPositionInfo position_info; int icon_start = horizontal ? icon_origin.x() : icon_origin.y(); int icon_end = icon_start + (horizontal ? icon_bounds.width() : icon_bounds.height()); position_info.major_length = horizontal ? panel->bounds().width() : panel->bounds().height(); position_info.min_major = std::max(panel_start_bounds + position_info.major_length / 2, icon_end - position_info.major_length / 2); position_info.max_major = std::min(icon_start + position_info.major_length / 2, panel_end_bounds - position_info.major_length / 2); position_info.major_pos = (icon_start + icon_end) / 2; position_info.window = panel; position_info.slide_in = iter->slide_in; iter->slide_in = false; visible_panels.push_back(position_info); } // Sort panels by their X positions and fan out groups of overlapping panels. // The fan out method may result in new overlapping panels however given that // the panels start at least a full panel width apart this overlap will // never completely obscure a panel. // TODO(flackr): Rearrange panels if new overlaps are introduced. std::sort(visible_panels.begin(), visible_panels.end(), CompareWindowMajor); size_t first_overlapping_panel = 0; for (size_t i = 1; i < visible_panels.size(); ++i) { if (visible_panels[i - 1].major_pos + visible_panels[i - 1].major_length / 2 < visible_panels[i].major_pos - visible_panels[i].major_length / 2) { FanOutPanels(visible_panels.begin() + first_overlapping_panel, visible_panels.begin() + i); first_overlapping_panel = i; } } FanOutPanels(visible_panels.begin() + first_overlapping_panel, visible_panels.end()); for (size_t i = 0; i < visible_panels.size(); ++i) { if (visible_panels[i].window == dragged_panel_) continue; bool slide_in = visible_panels[i].slide_in; gfx::Rect bounds = visible_panels[i].window->GetTargetBounds(); if (shelf_->alignment() == SHELF_ALIGNMENT_LEFT) bounds.set_x(shelf_bounds.right()); else if (shelf_->alignment() == SHELF_ALIGNMENT_RIGHT) bounds.set_x(shelf_bounds.x() - bounds.width()); else bounds.set_y(shelf_bounds.y() - bounds.height()); bool on_shelf = visible_panels[i].window->GetTargetBounds() == bounds; if (horizontal) { bounds.set_x(visible_panels[i].major_pos - visible_panels[i].major_length / 2); } else { bounds.set_y(visible_panels[i].major_pos - visible_panels[i].major_length / 2); } ui::Layer* layer = visible_panels[i].window->layer(); if (slide_in) { // New windows shift up from the shelf into position and fade in. layer->SetOpacity(0); gfx::Rect initial_bounds(bounds); initial_bounds.Offset(GetSlideInAnimationOffset(shelf_->alignment())); SetChildBoundsDirect(visible_panels[i].window, initial_bounds); // Set on shelf so that the panel animates into its target position. on_shelf = true; } if (on_shelf) { ui::ScopedLayerAnimationSettings panel_slide_settings( layer->GetAnimator()); panel_slide_settings.SetPreemptionStrategy( ui::LayerAnimator::IMMEDIATELY_ANIMATE_TO_NEW_TARGET); panel_slide_settings.SetTransitionDuration( base::TimeDelta::FromMilliseconds(kPanelSlideDurationMilliseconds)); SetChildBoundsDirect(visible_panels[i].window, bounds); if (slide_in) { layer->SetOpacity(1); visible_panels[i].window->Show(); } } else { // If the shelf moved don't animate, move immediately to the new // target location. SetChildBoundsDirect(visible_panels[i].window, bounds); } } UpdateStacking(active_panel); UpdateCallouts(); } void PanelLayoutManager::UpdateStacking(Window* active_panel) { // Clusterfuzz can trigger panel accelerators before the shelf is created. // TODO(jamescook): Revert this after http://crbug.com/648964 is fixed. if (!shelf_) return; if (!active_panel) { if (!last_active_panel_) return; active_panel = last_active_panel_; } // We want to to stack the panels like a deck of cards: // ,--,--,--,-------.--.--. // | | | | | | | // | | | | | | | // // We use the middle of each panel to figure out how to stack the panels. This // allows us to update the stacking when a panel is being dragged around by // the titlebar--even though it doesn't update the shelf icon positions, we // still want the visual effect. std::map<int, Window*> window_ordering; const bool horizontal = shelf_->IsHorizontalAlignment(); for (PanelList::const_iterator it = panel_windows_.begin(); it != panel_windows_.end(); ++it) { const gfx::Rect& bounds = it->window->bounds(); window_ordering.insert( std::make_pair(horizontal ? bounds.x() + bounds.width() / 2 : bounds.y() + bounds.height() / 2, it->window)); } Window* previous_panel = nullptr; for (std::map<int, Window*>::const_iterator it = window_ordering.begin(); it != window_ordering.end() && it->second != active_panel; ++it) { if (previous_panel) panel_container_->StackChildAbove(it->second, previous_panel); previous_panel = it->second; } previous_panel = nullptr; for (std::map<int, Window*>::const_reverse_iterator it = window_ordering.rbegin(); it != window_ordering.rend() && it->second != active_panel; ++it) { if (previous_panel) panel_container_->StackChildAbove(it->second, previous_panel); previous_panel = it->second; } panel_container_->StackChildAtTop(active_panel); if (dragged_panel_ && dragged_panel_->parent() == panel_container_) panel_container_->StackChildAtTop(dragged_panel_); last_active_panel_ = active_panel; } void PanelLayoutManager::UpdateCallouts() { // Clusterfuzz can trigger panel accelerators before the shelf is created. // TODO(jamescook): Revert this after http://crbug.com/648964 is fixed. if (!shelf_) return; const bool horizontal = shelf_->IsHorizontalAlignment(); for (PanelList::iterator iter = panel_windows_.begin(); iter != panel_windows_.end(); ++iter) { Window* panel = iter->window; views::Widget* callout_widget = iter->callout_widget; Window* callout_widget_window = callout_widget->GetNativeWindow(); gfx::Rect current_bounds = panel->GetBoundsInScreen(); gfx::Rect bounds = panel->GetTargetBounds(); ::wm::ConvertRectToScreen(panel->parent(), &bounds); gfx::Rect icon_bounds = shelf_->GetScreenBoundsOfItemIconForWindow(panel); if (icon_bounds.IsEmpty() || !panel->layer()->GetTargetVisibility() || panel == dragged_panel_ || !show_callout_widgets_) { callout_widget->Hide(); callout_widget_window->layer()->SetOpacity(0); continue; } gfx::Rect callout_bounds = callout_widget->GetWindowBoundsInScreen(); gfx::Vector2d slide_vector = bounds.origin() - current_bounds.origin(); int slide_distance = horizontal ? slide_vector.x() : slide_vector.y(); int distance_until_over_panel = 0; if (horizontal) { callout_bounds.set_x(icon_bounds.x() + (icon_bounds.width() - callout_bounds.width()) / 2); distance_until_over_panel = std::max(current_bounds.x() - callout_bounds.x(), callout_bounds.right() - current_bounds.right()); } else { callout_bounds.set_y(icon_bounds.y() + (icon_bounds.height() - callout_bounds.height()) / 2); distance_until_over_panel = std::max(current_bounds.y() - callout_bounds.y(), callout_bounds.bottom() - current_bounds.bottom()); } if (shelf_->alignment() == SHELF_ALIGNMENT_LEFT) callout_bounds.set_x(bounds.x() - callout_bounds.width()); else if (shelf_->alignment() == SHELF_ALIGNMENT_RIGHT) callout_bounds.set_x(bounds.right()); else callout_bounds.set_y(bounds.bottom()); ::wm::ConvertRectFromScreen(callout_widget_window->parent(), &callout_bounds); SetChildBoundsDirect(callout_widget_window, callout_bounds); DCHECK_EQ(panel_container_, callout_widget_window->parent()); DCHECK_EQ(panel_container_, panel->parent()); panel_container_->StackChildAbove(callout_widget_window, panel); ui::Layer* layer = callout_widget_window->layer(); // If the panel is not over the callout position or has just become visible // then fade in the callout. if ((distance_until_over_panel > 0 || layer->GetTargetOpacity() < 1)) { if (distance_until_over_panel > 0 && slide_distance >= distance_until_over_panel) { // If the panel is not yet over the callout, then delay fading in // the callout until after the panel should be over it. int delay = kPanelSlideDurationMilliseconds * distance_until_over_panel / slide_distance; layer->SetOpacity(0); layer->GetAnimator()->StopAnimating(); layer->GetAnimator()->SchedulePauseForProperties( base::TimeDelta::FromMilliseconds(delay), ui::LayerAnimationElement::OPACITY); } ui::ScopedLayerAnimationSettings callout_settings(layer->GetAnimator()); callout_settings.SetPreemptionStrategy( ui::LayerAnimator::REPLACE_QUEUED_ANIMATIONS); callout_settings.SetTransitionDuration( base::TimeDelta::FromMilliseconds(kCalloutFadeDurationMilliseconds)); layer->SetOpacity(1); } // Show after changing the opacity animation. This way we don't have a // state where the widget is visible but the opacity is 0. callout_widget->Show(); } } //////////////////////////////////////////////////////////////////////////////// // keyboard::KeyboardControllerObserver implementation: void PanelLayoutManager::OnKeyboardWorkspaceOccludedBoundsChanged( const gfx::Rect& keyboard_bounds) { const gfx::Rect& parent_bounds = panel_container_->bounds(); int available_space = parent_bounds.height() - keyboard_bounds.height(); for (PanelList::iterator iter = panel_windows_.begin(); iter != panel_windows_.end(); ++iter) { Window* panel = iter->window; wm::WindowState* panel_state = wm::GetWindowState(panel); if (keyboard_bounds.height() > 0) { // Save existing bounds, so that we can restore them when the keyboard // hides. panel_state->SaveCurrentBoundsForRestore(); gfx::Rect panel_bounds = panel->GetTargetBounds(); ::wm::ConvertRectToScreen(panel->parent(), &panel_bounds); int delta = panel_bounds.height() - available_space; // Ensure panels are not pushed above the parent boundaries, shrink any // panels that violate this constraint. if (delta > 0) { SetChildBoundsDirect( panel, gfx::Rect(panel_bounds.x(), panel_bounds.y() + delta, panel_bounds.width(), panel_bounds.height() - delta)); } } else if (panel_state->HasRestoreBounds()) { // Keyboard hidden, restore original bounds if they exist. SetChildBoundsDirect(panel, panel_state->GetRestoreBoundsInScreen()); } } // This bounds change will have caused a change to the Shelf which does not // propagate automatically to this class, so manually recalculate bounds. OnWindowResized(); } } // namespace ash
[ "team@geometry.ee" ]
team@geometry.ee
8f167fe7e7999a7b096e15e039138b574362ff4c
17e06748f1ee759b619ceb2339ca34ac6a560f9e
/Src/DemoEngine/SoundServer.cpp
9494090e40b3c61af4529fc7d5726bbd779530f9
[]
no_license
Fincodr/SDL_Course
b5040cd94436f3fcfdb74f4c92ce0752a17c7fd7
e9aa60d3c1213186da8ff3042d90b275ab06a97c
refs/heads/master
2021-01-25T07:19:27.297184
2012-08-30T03:06:57
2012-08-30T03:06:57
5,597,035
2
0
null
null
null
null
UTF-8
C++
false
false
1,368
cpp
/* * _/_/_/_/ _/ _/ * _/ _/_/_/ _/_/_/ _/_/ _/_/_/ _/ _/_/ * _/_/_/ _/ _/ _/ _/ _/ _/ _/ _/ _/_/ * _/ _/ _/ _/ _/ _/ _/ _/ _/ _/ * _/ _/ _/ _/ _/_/_/ _/_/ _/_/_/ _/ * * Copyright (c) 2012 Mika Luoma-aho <fincodr@mxl.fi> * * This source code and software is provided 'as-is', without any express or implied warranty. * In no event will the authors be held liable for any damages arising from the use of this source code or software. * * Permission is granted to anyone to use this software (and the source code when its released from the author) * as a learning point to create games, including commercial applications. * * You are however subject to the following restrictions: * * 1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. * If you use this software's source code in a product, * an acknowledgment in the product documentation would be appreciated but is not required. * 2. Altered versions must be plainly marked as such, and must not be misrepresented as being the original software. * 3. This notice may not be removed or altered from any distribution. * */ #include "SoundServer.hpp" namespace DemoEngine { }
[ "mika.luoma-aho@mxl.fi" ]
mika.luoma-aho@mxl.fi
2f763ca1aa29b91cdf67e0c907fcf6af1f8d9da2
d3e50a16ce55c6a322533d5f5e1b68f99d961d19
/cpp/oo/3.4-Observer/Observer.h
40d9f0aa91240a22676e160e95a95ad2512657bf
[]
no_license
monkeyde17/et-notes
0f2e88fd18c50a770fef7c807f64caaddf329d7e
8e9cfa016efa9f08a234e91c523aa498574e3fe5
refs/heads/master
2021-01-20T03:39:20.955149
2015-03-16T12:45:59
2015-03-16T12:45:59
20,673,513
1
1
null
null
null
null
UTF-8
C++
false
false
750
h
#ifndef _OBSERVER_H_ #define _OBSERVER_H_ #include "Subject.h" #include <string> using namespace std; typedef string State; class Observer { public: virtual ~Observer(); virtual void Update(Subject *sub) = 0; virtual void PrintInfo() = 0; protected: Observer(); State _st; }; class ConcreteObserverA : public Observer { public: virtual Subject* GetSubject(); ConcreteObserverA(Subject *sub); virtual ~ConcreteObserverA(); void Update(Subject *sub); void PrintInfo(); private: Subject *_sub; }; class ConcreteObserverB : public Observer { public: virtual Subject* GetSubject(); ConcreteObserverB(Subject *sub); virtual ~ConcreteObserverB(); void Update(Subject *sub); void PrintInfo(); private: Subject *_sub; }; #endif
[ "monkey_tv@126.com" ]
monkey_tv@126.com
b029d0540c5309446c2c38688cd6ac5710a0f1c9
e68c1f9134b44ddea144f7efa7523076f3f12d3a
/FinalCode/Monk_Male_DW_SS_DebilitatingBlows_03_2.cpp
c26c1a13ac6e49fb6a87d5471ebf647ccae90297
[]
no_license
iso5930/Direct-3D-Team-Portfolio
4ac710ede0c9176702595cba5579af42887611cf
84e64eb4e91c7e5b4aed77212cd08cfee038fcd3
refs/heads/master
2021-08-23T08:15:00.128591
2017-12-04T06:14:39
2017-12-04T06:14:39
112,998,717
0
0
null
null
null
null
UTF-8
C++
false
false
707
cpp
#include "StdAfx.h" #include "Monk_Male_DW_SS_DebilitatingBlows_03_2.h" CMonk_Male_DW_SS_DebilitatingBlows_03_2::CMonk_Male_DW_SS_DebilitatingBlows_03_2(void) { m_eStateType = STATE_TYPE_MONK_MALE_DW_SS_DEBILITATINGBLOWS_03_2; } CMonk_Male_DW_SS_DebilitatingBlows_03_2::~CMonk_Male_DW_SS_DebilitatingBlows_03_2(void) { } void CMonk_Male_DW_SS_DebilitatingBlows_03_2::Initialize() { CPlayerState::Initialize(); // SetAnimation m_pOwner->SetAnimation(67); // Clear m_pPathFindCom->Clear(); } CPlayerState* CMonk_Male_DW_SS_DebilitatingBlows_03_2::Action() { if(m_pAnimController->m_dFrameTime - 0.25 <= m_pAnimController->GetTrackPos()) { return new CMonk_Male_DW_SS_Idle; } return NULL; }
[ "iso5930@naver.com" ]
iso5930@naver.com
08634f581f8e5feb67182492a84b86f94f9f6566
7de52062ec797ce2f2e206672fbce6be4ff8341f
/2022.cpp
2c82db24a7c327fddea8a14a3c9803fd953a8c66
[]
no_license
joselynzhao/ALGORITHM_PROCTICE
2278bca3d194e88ef60522d438de18659e69ad03
a026c5e4046585d71d4068f694e24eded44eccef
refs/heads/master
2020-04-16T07:26:55.082322
2019-05-02T02:39:40
2019-05-02T02:39:40
165,387,245
2
0
null
null
null
null
UTF-8
C++
false
false
330
cpp
#include <iostream> using namespace std; int main(){ int m,n; while(scanf("%d%d",&m,&n)!=EOF){ int max=0,temp,x=1,y=1; for(int i=0;i<m;i++){ for(int j=0;j<n;j++){ scanf("%d",&temp); if((temp*temp)>(max*max)){ max=temp; x=i+1; y=j+1; } } } cout<<x<<" "<<y<<" "<<max<<endl; } return 0; }
[ "1326549593@qq.com" ]
1326549593@qq.com
9505a5d810920755bd43e31eb61eb7918ecd7b51
c3f715589f5d83e3ba92baaa309414eb253ca962
/C++/round-5/0801-0900/0861-0880/0876.h
f454f30ea46b4c66f774c87d53130b4f3457f551
[]
no_license
kophy/Leetcode
4b22272de78c213c4ad42c488df6cffa3b8ba785
7763dc71fd2f34b28d5e006a1824ca7157cec224
refs/heads/master
2021-06-11T05:06:41.144210
2021-03-09T08:25:15
2021-03-09T08:25:15
62,117,739
13
1
null
null
null
null
UTF-8
C++
false
false
407
h
/** * Definition for singly-linked list. * struct ListNode { * int val; * ListNode *next; * ListNode(int x) : val(x), next(NULL) {} * }; */ class Solution { public: ListNode *middleNode(ListNode *head) { ListNode *slow = head, *fast = head; while (fast != nullptr && fast->next != nullptr) { slow = slow->next; fast = fast->next->next; } return slow; } };
[ "kophy@protonmail.com" ]
kophy@protonmail.com
83e66ebfae7c487c782346107b51b62be9220887
23bc99fcf78c2c3f216e1ed3e7435579168094b1
/棋牌/PlatForm/Client/MainFrame/RoomSetWnd.cpp
eaee978f2661eedaf79150691604ff64b4d168cd
[]
no_license
15831944/liuwanbing
0b080a7d074dba30f81c6c2fbac136fd724d6793
4c527deb62446b0d24b1c5e6b65bc95ce949d942
refs/heads/master
2021-06-01T13:21:52.320236
2016-07-26T13:18:26
2016-07-26T13:18:26
null
0
0
null
null
null
null
GB18030
C++
false
false
15,720
cpp
#include "StdAfx.h" #include "RoomSetWnd.h" using namespace BzDui; bool CRoomSetWnd::m_bPlayBkMusic = true; CRoomSetWnd::CRoomSetWnd(void) { //是否允许设置桌面密码 m_bAllowSetDesk = true; m_szPass[0]=0; m_bCutPercent=10; m_bPass=FALSE; m_bSameIP=false; m_bSameIPNumber=0; m_bLimitCut=FALSE; m_bLimitPoint=0x00; m_bInvaliMode=INVALI_ALL; m_dwLowPoint=-100000L; m_dwHighPoint=100000L; m_dwLowMoney=-100000L; m_dwHighMoney=100000L; m_bSaveTalk=TRUE; m_bShowUser=TRUE; m_bShowMessage=TRUE; } CRoomSetWnd::~CRoomSetWnd(void) { } LPCTSTR CRoomSetWnd::GetWindowClassName() const { return _T("UIFrame"); }; UINT CRoomSetWnd::GetClassStyle() const { return UI_CLASSSTYLE_DIALOG; }; void CRoomSetWnd::OnFinalMessage(HWND hWnd) { m_pm.RemovePreMessageFilter(this); //delete this; }; LRESULT CRoomSetWnd::OnCreate(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled) { LONG styleValue = ::GetWindowLong(*this, GWL_STYLE); styleValue &= ~WS_CAPTION; ::SetWindowLong(*this, GWL_STYLE, styleValue | WS_CLIPSIBLINGS | WS_CLIPCHILDREN); m_pm.Init(m_hWnd); m_pm.AddPreMessageFilter(this); CDialogBuilder builder; CControlUI* pRoot = builder.Create(_T("room_mid\\RoomSet\\RoomSet.xml"), (UINT)0, NULL, &m_pm); ASSERT(pRoot && "Failed to parse XML"); m_pm.AttachDialog(pRoot); m_pm.AddNotifier(this); ::SetWindowPos(m_hWnd,CWnd::wndTopMost, 0, 0, 0, 0, SWP_NOSIZE|SWP_NOMOVE); Init(); return 0; } LRESULT CRoomSetWnd::OnDestroy(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled) { bHandled = FALSE; return 0; } LRESULT CRoomSetWnd::OnNcActivate(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled) { if( ::IsIconic(*this) ) bHandled = FALSE; return (wParam == 0) ? TRUE : FALSE; } LRESULT CRoomSetWnd::OnNcCalcSize(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled) { return 0; } LRESULT CRoomSetWnd::OnNcPaint(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled) { return 0; } LRESULT CRoomSetWnd::OnNcHitTest(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled) { POINT pt; pt.x = GET_X_LPARAM(lParam); pt.y = GET_Y_LPARAM(lParam); ::ScreenToClient(*this, &pt); RECT rcClient; ::GetClientRect(*this, &rcClient); RECT rcCaption = m_pm.GetCaptionRect(); if( pt.x >= rcClient.left + rcCaption.left && pt.x < rcClient.right - rcCaption.right \ && pt.y >= rcCaption.top && pt.y < rcCaption.bottom ) { CControlUI* pControl = static_cast<CControlUI*>(m_pm.FindControl(pt)); if( pControl && _tcscmp(pControl->GetClass(), _T("ButtonUI")) != 0 ) return HTCAPTION; } return HTCLIENT; } LRESULT CRoomSetWnd::OnSize(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled) { return 0; } LRESULT CRoomSetWnd::HandleMessage(UINT uMsg, WPARAM wParam, LPARAM lParam) { LRESULT lRes = 0; BOOL bHandled = TRUE; switch(uMsg) { case WM_CREATE: { lRes = OnCreate(uMsg, wParam, lParam, bHandled); } break; case WM_DESTROY: { lRes = OnDestroy(uMsg, wParam, lParam, bHandled); } break; case WM_NCACTIVATE: { lRes = OnNcActivate(uMsg, wParam, lParam, bHandled); } break; case WM_NCCALCSIZE: { lRes = OnNcCalcSize(uMsg, wParam, lParam, bHandled); } break; case WM_NCPAINT: { lRes = OnNcPaint(uMsg, wParam, lParam, bHandled); } break; case WM_NCHITTEST: { lRes = OnNcHitTest(uMsg, wParam, lParam, bHandled); } break; case WM_SIZE: { lRes = OnSize(uMsg, wParam, lParam, bHandled); } break; default: bHandled = FALSE; } if(bHandled) { return lRes; } if(m_pm.MessageHandler(uMsg,wParam,lParam,lRes)) { return lRes; } return CWindowWnd::HandleMessage(uMsg, wParam, lParam); } LRESULT CRoomSetWnd::MessageHandler(UINT uMsg, WPARAM wParam, LPARAM lParam, bool& bHandled) { if( uMsg == WM_KEYDOWN ) { if( wParam == VK_RETURN ) { OnOK(); return true; } else if( wParam == VK_ESCAPE ) { m_nRetFlag = 0; Close(); return true; } } return false; } void CRoomSetWnd::OnOK() { m_bLimitPoint = 0x00; COptionUI* pOptCtrl = NULL; CComboUI* pCobCtrl = NULL; CEditUI* pEdtCrl = NULL; TCHAR sz[32]; pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_1")); m_bSameIP = pOptCtrl->IsSelected(); pCobCtrl = static_cast<CComboUI*>(m_pm.FindControl("Cob_1")); LPCTSTR lpSel = pCobCtrl->GetText().GetData(); pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_2")); if (pOptCtrl->IsSelected()) { ::sscanf_s(lpSel,"%d",&m_bSameIPNumber); } else { m_bSameIPNumber = 0; } pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_3")); m_bLimitCut = pOptCtrl->IsSelected(); pCobCtrl = static_cast<CComboUI*>(m_pm.FindControl("Cob_2")); ::sscanf_s(pCobCtrl->GetText().GetData(),"%d",&m_bCutPercent); pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_4")); if (pOptCtrl->IsSelected()) { m_bLimitPoint |= 0x40; } pEdtCrl = static_cast<CEditUI*>(m_pm.FindControl("Edt_2")); ::sscanf_s(pEdtCrl->GetText().GetData(),"%d",&m_dwLowPoint); pEdtCrl = static_cast<CEditUI*>(m_pm.FindControl("Edt_3")); ::sscanf_s(pEdtCrl->GetText().GetData(),"%d",&m_dwHighPoint); pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_8")); if (pOptCtrl->IsSelected()) { m_bLimitPoint |= 0x80; } pEdtCrl = static_cast<CEditUI*>(m_pm.FindControl("Edt_5")); ::sscanf_s(pEdtCrl->GetText().GetData(),"%d",&m_dwLowMoney); pEdtCrl = static_cast<CEditUI*>(m_pm.FindControl("Edt_6")); ::sscanf_s(pEdtCrl->GetText().GetData(),"%d",&m_dwHighMoney); pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_5")); m_bShowUser = pOptCtrl->IsSelected(); pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_6")); m_bPass = pOptCtrl->IsSelected(); pEdtCrl = static_cast<CEditUI*>(m_pm.FindControl("Edt_4")); strcpy(m_szPass,pEdtCrl->GetText()); pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_7")); m_bPlayBkMusic = pOptCtrl->IsSelected(); m_nRetFlag = 1; Close(); } void CRoomSetWnd::Init() { LoadNormalCtrlSkin(); COptionUI* pOptCtrl = NULL; CComboUI* pCobCtrl = NULL; CEditUI* pEdtCtrl = NULL; TCHAR sz[128]; pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_1")); pOptCtrl->Selected(m_bSameIP); if (!m_bAllowSetDesk) { pOptCtrl->SetEnabled(false); pOptCtrl->SetVisible(false); } pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_2")); if (!m_bAllowSetDesk) { pOptCtrl->SetEnabled(false); pOptCtrl->SetVisible(false); } pCobCtrl = static_cast<CComboUI*>(m_pm.FindControl("Cob_1")); LPCTSTR szItems1[2] = {_T("3"),_T("4")}; LoadComboItems(pCobCtrl,szItems1,2); if (m_bSameIPNumber > 0) { ::sprintf_s(sz,sizeof(sz),"%d",m_bSameIPNumber); SelectComboItem(pCobCtrl,sz); pOptCtrl->Selected(true); pCobCtrl->SetEnabled(true); } else { SelectComboItem(pCobCtrl,szItems1[0]); pOptCtrl->Selected(false); pCobCtrl->SetEnabled(false); } pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_3")); pOptCtrl->Selected(m_bLimitCut); if (!m_bAllowSetDesk) { pOptCtrl->SetEnabled(false); pOptCtrl->SetVisible(false); } pCobCtrl = static_cast<CComboUI*>(m_pm.FindControl("Cob_2")); LPCTSTR szItems2[9] = {_T("10"),_T("20"),_T("30"),_T("40"),_T("50"),_T("60"),_T("70"),_T("80"),_T("90")}; LoadComboItems(pCobCtrl,szItems2,9); ::sprintf_s(sz,sizeof(sz),"%d",m_bCutPercent); SelectComboItem(pCobCtrl,sz); pCobCtrl->SetEnabled(m_bLimitCut); pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_4")); pOptCtrl->Selected(m_bLimitPoint & 0x40); if (!m_bAllowSetDesk) { pOptCtrl->SetEnabled(false); pOptCtrl->SetVisible(false); } pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_8")); pOptCtrl->Selected(m_bLimitPoint & 0x80); if (!m_bAllowSetDesk) { pOptCtrl->SetEnabled(false); pOptCtrl->SetVisible(false); } pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_5")); pOptCtrl->Selected(m_bShowUser); pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_6")); pOptCtrl->Selected(m_bPass); if (!m_bAllowSetDesk) { pOptCtrl->SetEnabled(false); pOptCtrl->SetVisible(false); } pEdtCtrl = static_cast<CEditUI*>(m_pm.FindControl("Edt_2")); ::sprintf_s(sz,sizeof(sz),"%d",m_dwLowPoint); pEdtCtrl->SetText(sz); pEdtCtrl->SetEnabled(m_bLimitPoint & 0x40); pEdtCtrl = static_cast<CEditUI*>(m_pm.FindControl("Edt_3")); ::sprintf_s(sz,sizeof(sz),"%d",m_dwHighPoint); pEdtCtrl->SetText(sz); pEdtCtrl->SetEnabled(m_bLimitPoint & 0x40); pEdtCtrl = static_cast<CEditUI*>(m_pm.FindControl("Edt_5")); ::sprintf_s(sz,sizeof(sz),"%d",m_dwLowMoney); pEdtCtrl->SetText(sz); pEdtCtrl->SetEnabled(m_bLimitPoint & 0x80); pEdtCtrl = static_cast<CEditUI*>(m_pm.FindControl("Edt_6")); ::sprintf_s(sz,sizeof(sz),"%d",m_dwHighMoney); pEdtCtrl->SetText(sz); pEdtCtrl->SetEnabled(m_bLimitPoint & 0x80); pEdtCtrl = static_cast<CEditUI*>(m_pm.FindControl("Edt_4")); pEdtCtrl->SetText(m_szPass); pEdtCtrl->SetEnabled(m_bPass); if (!m_bAllowSetDesk) { pEdtCtrl->SetEnabled(false); } pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_7")); pOptCtrl->Selected(m_bPlayBkMusic); //限制IP /*if(Glb().m_release) { m_bSameIP=true; ((CButton *)GetDlgItem(IDC_SAME_IP))->SetCheck(BST_CHECKED); ((CButton *)GetDlgItem(IDC_SAME_IP))->EnableWindow(0); }*/ //设置邀请方式 // if (m_bInvaliMode==INVALI_ALL) ((CButton *)GetDlgItem(IDC_INVALI_ALL))->SetCheck(BST_CHECKED); // else if (m_bInvaliMode==INVALI_ONLY_FRIEND) ((CButton *)GetDlgItem(IDC_FRIEND_INVALI))->SetCheck(BST_CHECKED); // else ((CButton *)GetDlgItem(IDC_NO_INVALI))->SetCheck(BST_CHECKED); // // //设置输入 // if (m_bSaveTalk) ((CButton *)GetDlgItem(IDC_SAVE_TALK))->SetCheck(BST_CHECKED); // if (m_bShowUser) ((CButton *)GetDlgItem(IDC_SHOW_USER))->SetCheck(BST_CHECKED); // int r,g,b; } //加载Combol的列表项 void CRoomSetWnd::LoadComboItems(CComboUI* pCtrl,LPCTSTR items[],int nums,int nSelect/* = 0*/) { if (!pCtrl || nums <= 0) { return; } for (int i = 0; i < nums; ++i) { CListLabelElementUI* p = new CListLabelElementUI(); p->SetText(items[i]); pCtrl->Add(p); } return; } //根据文本设置选择列表项 bool CRoomSetWnd::SelectComboItem(BzDui::CComboUI* pCtrl,LPCTSTR szText) { if (!pCtrl) { return false; } int itNums = pCtrl->GetCount(); if (itNums <= 0) { return false; } for (int i = 0; i < itNums; ++i) { if (strcmp(szText,pCtrl->GetItemAt(i)->GetText().GetData()) == 0) { pCtrl->SelectItem(i); return true; } } return false; } void CRoomSetWnd::Notify(TNotifyUI& msg) { if( msg.sType == _T("click")) { if( msg.pSender->GetName() == _T("Bnt_Close")) { m_nRetFlag = 0; Close(); } if( msg.pSender->GetName() == _T("Btn_OK")) { OnOK(); } if( msg.pSender->GetName() == _T("Btn_Cancel")) { m_nRetFlag = 0; Close(); } } else if(msg.sType == _T("selectchanged")) { if (msg.pSender->GetName() == _T("Opt_2")) { COptionUI* pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_2")); CComboUI* pCobCtrl = NULL; pCobCtrl = static_cast<CComboUI*>(m_pm.FindControl("Cob_1")); pCobCtrl->SetEnabled(pOptCtrl->IsSelected()); } else if (msg.pSender->GetName() == _T("Opt_3")) { COptionUI* pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_3")); CComboUI* pCobCtrl = NULL; pCobCtrl = static_cast<CComboUI*>(m_pm.FindControl("Cob_2")); pCobCtrl->SetEnabled(pOptCtrl->IsSelected()); } else if (msg.pSender->GetName() == _T("Opt_4")) { COptionUI* pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_4")); CEditUI* pEdtCtrl = NULL; pEdtCtrl = static_cast<CEditUI*>(m_pm.FindControl("Edt_2")); pEdtCtrl->SetEnabled(pOptCtrl->IsSelected()); pEdtCtrl = static_cast<CEditUI*>(m_pm.FindControl("Edt_3")); pEdtCtrl->SetEnabled(pOptCtrl->IsSelected()); } else if (msg.pSender->GetName() == _T("Opt_6")) { COptionUI* pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_6")); CEditUI* pEdtCtrl = NULL; pEdtCtrl = static_cast<CEditUI*>(m_pm.FindControl("Edt_4")); pEdtCtrl->SetEnabled(pOptCtrl->IsSelected()); } else if (msg.pSender->GetName() == _T("Opt_8")) { COptionUI* pOptCtrl = static_cast<COptionUI*>(m_pm.FindControl("Opt_8")); CEditUI* pEdtCtrl = NULL; pEdtCtrl = static_cast<CEditUI*>(m_pm.FindControl("Edt_5")); pEdtCtrl->SetEnabled(pOptCtrl->IsSelected()); pEdtCtrl = static_cast<CEditUI*>(m_pm.FindControl("Edt_6")); pEdtCtrl->SetEnabled(pOptCtrl->IsSelected()); } } } //加载常规控件皮肤 void CRoomSetWnd::LoadNormalCtrlSkin() { int idx = 0; CStdPtrArray* pCtrls = NULL; //加载所有文本编辑框的皮肤 pCtrls = m_pm.FindSubControlsByClass(m_pm.GetRoot(),_TEXT("EditUI")); CEditUI* pEditUI = NULL; do { pEditUI = static_cast<CEditUI*>(pCtrls->GetAt(idx++)); if (pEditUI) { if (pEditUI->GetName() == _T("Edt_ID")) { continue; } pEditUI->SetNormalImage("file='dialog\\edit.png' dest='0,0,500,22' source='0,0,500,22' corner='3,4,2,2'"); pEditUI->SetHotImage("file='dialog\\edit.png' dest='0,0,500,22' source='0,22,500,44' corner='3,4,2,2'"); pEditUI->SetFocusedImage("file='dialog\\edit.png' dest='0,0,500,22' source='0,44,500,66' corner='3,4,2,2'"); pEditUI->SetDisabledImage("file='dialog\\edit.png' dest='0,0,500,22' source='0,66,500,88' corner='3,4,2,2'"); } } while (pEditUI); //加载所有下拉列表框的皮肤 idx = 0; pCtrls = m_pm.FindSubControlsByClass(m_pm.GetRoot(),_TEXT("ComboUI")); CComboUI* pComboUI = NULL; do { pComboUI = static_cast<CComboUI*>(pCtrls->GetAt(idx++)); if (pComboUI) { pComboUI->SetNormalImage("file='dialog\\combo.png' dest='0,0,500,22' source='0,0,500,22' corner='5,0,22,0'"); pComboUI->SetHotImage("file='dialog\\combo.png' dest='0,0,500,22' source='0,22,500,44' corner='5,0,22,0'"); pComboUI->SetPushedImage("file='dialog\\combo.png' dest='0,0,500,22' source='0,44,500,66' corner='5,0,22,0'"); pComboUI->SetDisabledImage("file='dialog\\combo.png' dest='0,0,500,22' source='0,66,500,88' corner='5,0,22,0'"); RECT rc = {6,0,0,0}; pComboUI->SetItemTextPadding(rc); // CScrollBarUI* pVScroll = pComboUI->GetVerticalScrollBar(); // if (pVScroll) // { // pVScroll->SetBkNormalImage("file='dialog\\vscrollbar_back.png' dest='0,0,14,100' source='0,0,14,100' corner='0,0,0,0'"); // pVScroll->SetButton1NormalImage("file='dialog\\vscrollbar_up.png' dest='0,0,16,16' source='0,0,16,16' corner='0,0,0,0'"); // } } } while (pComboUI); //加载所有多选框的皮肤 idx = 0; pCtrls = m_pm.FindSubControlsByClass(m_pm.GetRoot(),_TEXT("OptionUI")); COptionUI* pOptionUI = NULL; do { pOptionUI = static_cast<COptionUI*>(pCtrls->GetAt(idx++)); if (pOptionUI) { pOptionUI->SetNormalImage("file='dialog\\check.png' dest='0,0,15,15' source='0,0,15,15' corner='0,0,0,0'"); pOptionUI->SetHotImage("file='dialog\\check.png' dest='0,0,15,15' source='15,0,30,15' corner='0,0,0,0'"); pOptionUI->SetSelectedImage("file='dialog\\check.png' dest='0,0,15,15' source='30,0,45,15' corner='0,0,0,0'"); } } while (pOptionUI); }
[ "970006421@qq.com" ]
970006421@qq.com
5cc333e002330336e8ffb63bc75c81fd27c5027c
ce989e9fb6a42fc1dd5c19d46bdad46e175797df
/src/gslstat/tbb_cilk/tbb.cpp
734b76638c5fa3c68335a4510ee57f41850ccfb6
[]
no_license
RanWangTilburg/BayesianOrdinal
4b17f4b6e1f40db9c3149a92119ad769f5017a13
a1b8df3660ed07a12a77292d43d174ef326aa536
refs/heads/master
2020-12-03T06:36:06.573063
2017-06-28T19:47:42
2017-06-28T19:47:42
95,705,714
0
0
null
null
null
null
UTF-8
C++
false
false
2,084
cpp
#include <gtest/gtest.h> #include <tbb/tbb.h> #include <cilk/cilk.h> #include <cstdio> #include <tbb/flow_graph.h> #pragma warning(disable: 588) static const int N = 10000; using namespace tbb::flow; class TBBTest : public ::testing::Test { }; struct square { int operator()(int v) { return v * v; } }; struct cube { int operator()(int v) { return v * v * v; } }; class sum { int &my_sum; public: sum(int &s) : my_sum(s) {} int operator()(tuple<int, int> v) { my_sum += get<0>(v) + get<1>(v); return my_sum; } }; class SumFoo { float *my_a; public: float my_sum; void operator()(const tbb::blocked_range<size_t> &r) { float *a = my_a; float sum = my_sum; size_t end = r.end(); for (size_t i = r.begin(); i != end; ++i) sum += a[i]; my_sum = sum; } SumFoo(SumFoo &x, tbb::split) : my_a(x.my_a), my_sum(0) {} void join(const SumFoo &y) { my_sum += y.my_sum; } SumFoo(float a[]) : my_a(a), my_sum(0) {} }; __attribute__((vector(uniform(input)))) int add_one(int input) { return input + 1; } void parallel_add_one(int *a) { tbb::parallel_for(0, N, [=](int index) { a[index] = add_one(a[index]); }); } TEST_F(TBBTest, TBBTestForSimpleLoop) { int a[N]; a[:]=0; parallel_add_one(a); for (int i = 0; i < N; i++) { EXPECT_EQ(a[i], 1); } } TEST_F(TBBTest, TEST_FLOW_GRAPH) { int result = 0; graph g; broadcast_node<int> input(g); function_node<int, int> squarer(g, unlimited, square()); function_node<int, int> cuber(g, unlimited, cube()); join_node<tuple<int, int>, queueing> join(g); function_node<tuple<int, int>, int> summer(g, serial, sum(result)); make_edge(input, squarer); make_edge(input, cuber); make_edge(squarer, get<0>(join.input_ports())); make_edge(cuber, get<1>(join.input_ports())); make_edge(join, summer); for (int i = 1; i <= 10; ++i) input.try_put(i); g.wait_for_all(); ASSERT_EQ(result, 3410); }
[ "EssayEliteDutch@gmail.com" ]
EssayEliteDutch@gmail.com
99e723cf7ca17804ec91d42cf6b889cee29ed78f
b3710dfdd0eeb3e28d3a4c666af5df6558a03553
/cgodeps/godot_engine/core/math/math_funcs.cpp
1585c96b3887bc3b905bf87ea83b1aadb02155f4
[ "MIT", "CC-BY-3.0", "CC-BY-4.0", "LicenseRef-scancode-free-unknown", "OFL-1.1", "BSD-3-Clause", "Bitstream-Vera", "FTL", "MPL-2.0", "Zlib", "LicenseRef-scancode-nvidia-2002", "BSL-1.0", "Apache-2.0", "LicenseRef-scancode-public-domain", "BSD-2-Clause" ]
permissive
gabstv/godot-go
5befd7539ef35a9e459046644dd4b246a0db1ad9
e0e7f07e1e44716e18330f063c9b3fd3c2468d31
refs/heads/master
2021-05-21T23:48:25.434825
2020-08-27T16:52:18
2020-08-27T16:52:18
252,864,512
10
3
MIT
2020-08-27T16:52:20
2020-04-03T23:26:52
C++
UTF-8
C++
false
false
5,028
cpp
/*************************************************************************/ /* math_funcs.cpp */ /*************************************************************************/ /* This file is part of: */ /* GODOT ENGINE */ /* https://godotengine.org */ /*************************************************************************/ /* Copyright (c) 2007-2020 Juan Linietsky, Ariel Manzur. */ /* Copyright (c) 2014-2020 Godot Engine contributors (cf. AUTHORS.md). */ /* */ /* Permission is hereby granted, free of charge, to any person obtaining */ /* a copy of this software and associated documentation files (the */ /* "Software"), to deal in the Software without restriction, including */ /* without limitation the rights to use, copy, modify, merge, publish, */ /* distribute, sublicense, and/or sell copies of the Software, and to */ /* permit persons to whom the Software is furnished to do so, subject to */ /* the following conditions: */ /* */ /* The above copyright notice and this permission notice shall be */ /* included in all copies or substantial portions of the Software. */ /* */ /* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, */ /* EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF */ /* MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.*/ /* IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY */ /* CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, */ /* TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE */ /* SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ /*************************************************************************/ #include "math_funcs.h" #include "core/error_macros.h" RandomPCG Math::default_rand(RandomPCG::DEFAULT_SEED, RandomPCG::DEFAULT_INC); #define PHI 0x9e3779b9 uint32_t Math::rand_from_seed(uint64_t *seed) { RandomPCG rng = RandomPCG(*seed, RandomPCG::DEFAULT_INC); uint32_t r = rng.rand(); *seed = rng.get_seed(); return r; } void Math::seed(uint64_t x) { default_rand.seed(x); } void Math::randomize() { default_rand.randomize(); } uint32_t Math::rand() { return default_rand.rand(); } int Math::step_decimals(double p_step) { static const int maxn = 10; static const double sd[maxn] = { 0.9999, // somehow compensate for floating point error 0.09999, 0.009999, 0.0009999, 0.00009999, 0.000009999, 0.0000009999, 0.00000009999, 0.000000009999, 0.0000000009999 }; double abs = Math::abs(p_step); double decs = abs - (int)abs; // Strip away integer part for (int i = 0; i < maxn; i++) { if (decs >= sd[i]) { return i; } } return 0; } // Only meant for editor usage in float ranges, where a step of 0 // means that decimal digits should not be limited in String::num. int Math::range_step_decimals(double p_step) { if (p_step < 0.0000000000001) { return 16; // Max value hardcoded in String::num } return step_decimals(p_step); } double Math::dectime(double p_value, double p_amount, double p_step) { double sgn = p_value < 0 ? -1.0 : 1.0; double val = Math::abs(p_value); val -= p_amount * p_step; if (val < 0.0) { val = 0.0; } return val * sgn; } double Math::ease(double p_x, double p_c) { if (p_x < 0) { p_x = 0; } else if (p_x > 1.0) { p_x = 1.0; } if (p_c > 0) { if (p_c < 1.0) { return 1.0 - Math::pow(1.0 - p_x, 1.0 / p_c); } else { return Math::pow(p_x, p_c); } } else if (p_c < 0) { //inout ease if (p_x < 0.5) { return Math::pow(p_x * 2.0, -p_c) * 0.5; } else { return (1.0 - Math::pow(1.0 - (p_x - 0.5) * 2.0, -p_c)) * 0.5 + 0.5; } } else { return 0; // no ease (raw) } } double Math::stepify(double p_value, double p_step) { if (p_step != 0) { p_value = Math::floor(p_value / p_step + 0.5) * p_step; } return p_value; } uint32_t Math::larger_prime(uint32_t p_val) { static const uint32_t primes[] = { 5, 13, 23, 47, 97, 193, 389, 769, 1543, 3079, 6151, 12289, 24593, 49157, 98317, 196613, 393241, 786433, 1572869, 3145739, 6291469, 12582917, 25165843, 50331653, 100663319, 201326611, 402653189, 805306457, 1610612741, 0, }; int idx = 0; while (true) { ERR_FAIL_COND_V(primes[idx] == 0, 0); if (primes[idx] > p_val) { return primes[idx]; } idx++; } } double Math::random(double from, double to) { return default_rand.random(from, to); } float Math::random(float from, float to) { return default_rand.random(from, to); }
[ "gabs@gabs.tv" ]
gabs@gabs.tv
aa1291df5dd50623e8c06d5de110bac882c5d94f
449c7e09d28e60eec7a9ff86702f5ad591230fb5
/include/Globals.h
f9c77b2cf0f9c612651e6033c1014b7daa0f4b20
[ "MIT" ]
permissive
PyrokinesisStudio/modioSDK
2819bba56d184e24954b354b759f564c4bda6631
951de6d90806794b5f86f82a1bbfda3e0ba0b65f
refs/heads/master
2020-03-31T00:34:03.247271
2018-09-17T17:16:07
2018-09-17T17:16:07
151,745,494
1
0
MIT
2018-10-05T15:58:40
2018-10-05T15:58:40
null
UTF-8
C++
false
false
916
h
#ifndef MODIO_GLOBALS_H #define MODIO_GLOBALS_H #include <iostream> #include "Utility.h" namespace modio { extern std::string API_KEY; extern std::string ACCESS_TOKEN; extern u32 GAME_ID; extern std::string ROOT_PATH; extern u32 DEBUG_LEVEL; extern std::string MODIO_URL; extern std::string MODIO_VERSION_PATH; extern u32 MAX_CALL_CACHE; extern u32 MAX_CACHE_TIME; extern u32 LAST_MOD_EVENT_POLL; extern u32 LAST_USER_EVENT_POLL; extern u32 EVENT_POLL_INTERVAL; extern u32 AUTOMATIC_UPDATES; extern u32 BACKGROUND_DOWNLOADS; extern u32 RETRY_AFTER; extern void (*callback)(ModioResponse response, ModioEvent* events_array, u32 events_array_size); extern void (*download_callback)(u32 response_code, u32 mod_id); extern void (*upload_callback)(u32 response_code, u32 mod_id); std::vector<std::string> getHeaders(); std::vector<std::string> getUrlEncodedHeaders(); } #endif
[ "ahmed.hn.43@gmail.com" ]
ahmed.hn.43@gmail.com
2f03a308ecd33e9865b2a1f42c52a52ebe146fbb
7d23a85363397f527f3e36242e9af43a3fc81b47
/openmp_bitminer/openmp_bitminer/main.cpp
3317e501ba7eee3bab335fdedff81ca6e9806ba7
[ "MIT" ]
permissive
fbasatemur/openmp_blockchain
3642651dc18c431fee74c405f5373430297bb67b
4d3032c86b21c6307fd26672392f84cc588df580
refs/heads/main
2023-06-18T07:04:14.046026
2021-07-13T23:17:52
2021-07-13T23:17:52
365,493,075
3
1
null
null
null
null
UTF-8
C++
false
false
3,807
cpp
#include <stdlib.h> #include <iostream> #include "Sha.h" #include "BlockChain.h" #include <omp.h> #include <iomanip> using namespace std; int main() { string inputText = "Bize her yer Trabzon! Bolumun en yakisikli hocasi Ibrahim Hoca'dir"; // ascii text string initializeHash = "0000000000000000000000000000000000000000000000000000000000000000"; size_t threadNums; cout << "THREAD NUMS: "; cin >> threadNums; size_t nonce = 0; bool flag = false; size_t acceptNonce; // acceptNonce will be approved by other threads size_t acceptCounter; // accepted threads numbers WORD* sha256K = InitializeK(); BlockChain blockChain; blockChain.AddBack(inputText, initializeHash); cout << "\n# BLOCK: " << blockChain.current->blockNum << "\t tid: " << omp_get_thread_num() << endl; cout << "Hash initialized: " << blockChain.current->initializeHash << "\t nonce: " << nonce << "\t \t tid: " << omp_get_thread_num() << endl; size_t entryCounter; omp_lock_t lock; omp_init_lock(&lock); double start = omp_get_wtime(), end; double globalTime = start; int sec, h, m; #pragma omp parallel num_threads(threadNums) { string privateText, privateHash; size_t privateNonce; #pragma omp critical { privateNonce = nonce; nonce++; } #pragma omp barrier while (true) { privateText = blockChain.GetText(privateNonce); // text generate for SHA256 privateHash = Sha256(privateText, sha256K); // hash calculated if (blockChain.Control(privateHash)) { #pragma omp single nowait { acceptCounter = 0; entryCounter = 0; acceptNonce = privateNonce; flag = true; while (acceptCounter < threadNums / 2) {} // must accepted N/2 threads while (entryCounter < threadNums - 1) {} // wait threadNums-1 threads // privateNonce accepted for other threads, print block informations end = omp_get_wtime(); cout << "Hash found: " << privateHash << "\t \t nonce: " << acceptNonce << "\t \t tid: " << omp_get_thread_num() << endl << "Text: " << privateText << endl << "Block Run-time(s): " << std::setprecision(3) << fixed << (end - start); start = omp_get_wtime(); sec = int(end - globalTime); h = int(sec / 3600); m = int((sec - (3600 * h)) / 60); cout << "\t Total Run-time: " << h << ":" << m << ":" << (sec - (3600 * h) - (m * 60)) << endl; blockChain.AddBack(privateText, privateHash); // add next block nonce = 0; privateNonce = nonce; nonce++; cout << endl << endl << "# BLOCK: " << blockChain.blockCounter << "\t tid: " << omp_get_thread_num() << endl; cout << "Hash initialized: " << blockChain.current->initializeHash << "\t nonce: " << privateNonce << "\t \t tid: " << omp_get_thread_num() << endl; flag = false; } } else { // nonce couldnt found, nonce increment omp_set_lock(&lock); privateNonce = nonce; nonce++; omp_unset_lock(&lock); } if (flag) { privateText = blockChain.GetText(acceptNonce); privateHash = Sha256(privateText, sha256K); #pragma omp critical { if (acceptCounter < threadNums / 2) // must accepted N/2 threads => accepted total: N/2 + 1(main thread) threads { if (blockChain.Control(privateHash)) { cout << "Hash accepted: " << privateHash << "\t \t nonce: " << acceptNonce << "\t \t tid: " << omp_get_thread_num() << endl; ++acceptCounter; } else cout << "Error tid: " << omp_get_thread_num() << endl; } ++entryCounter; } while (flag) {} omp_set_lock(&lock); privateNonce = nonce; nonce++; omp_unset_lock(&lock); } } } omp_destroy_lock(&lock); return 0; }
[ "fatihbasatemur@gmail.com" ]
fatihbasatemur@gmail.com
d3af8fc00e3a028544c0f7eb072adbbe2d467d78
ef3c869fcf4aa1c89715660726bdfdabc828d36e
/dwooglib/OImageProcess.cpp
a26ce392ce11dc4ee1d88d73106fedbfac039a29
[ "BSD-2-Clause" ]
permissive
T-Nosaka/DWOOSizer
0dc6bfd7ab46be28f6e109f66dfd476107b4068b
10b92d9db8e1f68ee20a98018e91919ea736732e
refs/heads/main
2023-05-08T03:57:03.328454
2021-06-06T06:18:33
2021-06-06T06:18:33
374,280,322
0
0
null
null
null
null
SHIFT_JIS
C++
false
false
9,421
cpp
/*++ 画像処理基底 --*/ #include <windows.h> #include "OImageProcess.h" OImageProcess::OImageProcess() { Init(); } OImageProcess::~OImageProcess() { ListDelete(); } OImageProcess::OImageProcess( const OImageProcess& target ) { Init(); *this = target; } void OImageProcess::Init() { m_TopX = 0; m_TopY = 0; m_ulHorzRes = 0; m_ulVertRes = 0; } void OImageProcess::ListDelete() { //画像プレーン削除 for( auto it = m_planelist.begin(); it!=m_planelist.end(); it++ ) { if ( *it != NULL ) { delete *it ; *it = NULL; } } m_planelist.clear(); } void OImageProcess::ListCopy( PLANELIST& destList ) { //画像プレーン複製 for( auto it = destList.begin(); it!=destList.end(); it++ ) { if ( *it != NULL ) { OPlaneLeaf* pInstance = (*it)->Instance(); *pInstance = *(*it); m_planelist.push_back( pInstance ); } } } OPlaneLeaf* OImageProcess::GetPlane( std::string name ) { OPlaneLeaf* rtnObj = NULL; //画像プレーン取得 for( auto it = m_planelist.begin(); it!=m_planelist.end(); it++ ) { if ( *it != NULL ) { if ( (*it)->LeafName() == name ) return *it ; } } return NULL; } void OImageProcess::RemovePlane( std::string name, bool bDestroy ) { //画像プレーン削除 do { auto bFind = false; for (auto it = m_planelist.begin(); it != m_planelist.end() && m_planelist.size() > 0; it++) { if (*it != NULL) { if ((*it)->LeafName() == name) { if(bDestroy == true ) delete *it; m_planelist.erase(it); bFind = true; break; } } } if (bFind == false) break; } while (true); } void OImageProcess::operator=( const OImageProcess& target ) { m_TopX = target.m_TopX; m_TopY = target.m_TopY; m_ulHorzRes = target.m_ulHorzRes; m_ulVertRes = target.m_ulVertRes; //自身のプレーンを破棄 ListDelete(); //プレーンコピー ListCopy( ((OImageProcess&)target).m_planelist ); } OImageProcess* OImageProcess::operator +( const OImageProcess& target ) { if ( m_planelist.size() ) { //単純に追加の場合、高速な処理を行う if ( GetWidth() == ((OImageProcess&)target).GetWidth() && m_TopY + GetHeight() == target.m_TopY ) { return Append( target ); } } else { return Append( target ); } OImageProcess& RetObj = *Instance(); RetObj.m_TopX = ( m_TopX < ((OImageProcess&)target).GetTopX() ) ? m_TopX:((OImageProcess&)target).GetTopX(); RetObj.m_TopY = ( m_TopY < ((OImageProcess&)target).GetTopY() ) ? m_TopY:((OImageProcess&)target).GetTopY(); //合体後の領域計算 DWORD dwWidth = ( ( m_TopX+GetWidth() > ((OImageProcess&)target).GetTopX()+((OImageProcess&)target).GetWidth() ) ? m_TopX+GetWidth() : ((OImageProcess&)target).GetTopX()+((OImageProcess&)target).GetWidth() ) - RetObj.m_TopX ; DWORD dwHeight = ( ( m_TopY+GetHeight() > ((OImageProcess&)target).GetTopY()+((OImageProcess&)target).GetHeight() ) ? m_TopY+GetHeight() : ((OImageProcess&)target).GetTopY()+((OImageProcess&)target).GetHeight() ) - RetObj.m_TopY ; RetObj.m_ulHorzRes = m_ulHorzRes; RetObj.m_ulVertRes = m_ulVertRes; //全てのプレーンを処理 for( auto it=m_planelist.begin(); it!=m_planelist.end(); it++ ) { //新領域のプレーンを作成 OPlaneLeaf* pPlane = (*it)->Instance( dwWidth, dwHeight ); //まず、自身の画像をコピーする。 DWORD dwLine ; for( dwLine=0; dwLine< (*it)->Height(); dwLine++ ) { pPlane->CopyDot( pPlane->GetPoint( m_TopX - RetObj.m_TopX, m_TopY - RetObj.m_TopY + dwLine ), (*it)->GetPointObj( 0, dwLine ), (*it)->Width() ); } //次に相手の画像をコピーする。 OPlaneLeaf* pDestPlane = ((OImageProcess&)target).GetPlane( (*it)->LeafName() ); if ( pDestPlane != NULL ) { for( dwLine=0; dwLine< pDestPlane->Height(); dwLine++ ) { pPlane->CopyDot( pPlane->GetPoint( target.m_TopX - RetObj.m_TopX, target.m_TopY - RetObj.m_TopY + dwLine ), pDestPlane->GetPointObj( 0, dwLine ), pDestPlane->Width() ); } } //完成したプレーンを追加 RetObj.m_planelist.push_back( pPlane ); } return &RetObj; } OImageProcess* OImageProcess::GetLine( DWORD startLine , DWORD endLine ) { if ( endLine < startLine ) { DWORD tmp = endLine; endLine = startLine; startLine = tmp; } DWORD dwHeight = GetHeight(); if ( startLine >= dwHeight ) { startLine = dwHeight; } if ( endLine >= dwHeight ) { endLine = dwHeight; } OImageProcess* pRetObj = Instance(); pRetObj->m_TopX = m_TopX; pRetObj->m_TopY = m_TopY + startLine; pRetObj->m_ulHorzRes = m_ulHorzRes; pRetObj->m_ulVertRes = m_ulVertRes; DWORD dwPlaneWidth = GetWidth(); DWORD dwPlaneHeight = endLine - startLine ; //全てのプレーンを処理 for( auto it=m_planelist.begin(); it!=m_planelist.end(); it++ ) { //新領域のプレーンを作成 OPlaneLeaf* pPlane = (*it)->Instance( dwPlaneWidth, dwPlaneHeight ); //領域の画像をコピーする。 pPlane->CopyDot( pPlane->GetPoint( 0, 0 ), (*it)->GetPointObj( 0, startLine ), pPlane->Width() * pPlane->Height() ); //完成したプレーンを追加 pRetObj->m_planelist.push_back( pPlane ); } return pRetObj; } OImageProcess* OImageProcess::GetPerpendicularArea( DWORD startPos , DWORD endPos ) { if ( endPos < startPos ) { DWORD tmp = endPos; endPos = startPos; startPos = tmp; } DWORD dwWidth = GetWidth(); if ( startPos >= dwWidth ) { startPos = dwWidth; } if ( endPos >= dwWidth ) { endPos = dwWidth; } OImageProcess* pRetObj = Instance(); pRetObj->m_TopX = m_TopX + startPos; pRetObj->m_TopY = m_TopY ; pRetObj->m_ulHorzRes = m_ulHorzRes; pRetObj->m_ulVertRes = m_ulVertRes; DWORD dwPlaneWidth = endPos - startPos; DWORD dwPlaneHeight = GetHeight() ; //全てのプレーンを処理 for( auto it=m_planelist.begin(); it!=m_planelist.end(); it++ ) { //新領域のプレーンを作成 OPlaneLeaf* pPlane = (*it)->Instance( dwPlaneWidth, dwPlaneHeight ); DWORD row ; for( row=0; row<(*it)->Height(); row++ ) { pPlane->CopyDot( pPlane->GetPoint( 0, row ), (*it)->GetPointObj( startPos, row ), dwPlaneWidth ); } //完成したプレーンを追加 pRetObj->m_planelist.push_back( pPlane ); } return pRetObj; } DWORD OImageProcess::GetWidth() { DWORD dwWidth = 0; //所有するプレーンの最大幅 for( auto it = m_planelist.begin(); it!=m_planelist.end(); it++ ) if ( *it != NULL ) dwWidth = ( (*it)->Width() > dwWidth ) ? (*it)->Width():dwWidth ; return dwWidth; } DWORD OImageProcess::GetHeight() { DWORD dwHeight = 0; //所有するプレーンの最大幅 for( auto it = m_planelist.begin(); it!=m_planelist.end(); it++ ) if ( *it != NULL ) dwHeight = ( (*it)->Height() > dwHeight ) ? (*it)->Height():dwHeight ; return dwHeight; } OImageProcess* OImageProcess::Append( const OImageProcess& target ) { OImageProcess* pRetObj = Instance(); DWORD dwWidth; DWORD dwHeight; if ( GetWidth() > 0 && GetHeight() > 0 ) { pRetObj->m_TopX = m_TopX; pRetObj->m_TopY = m_TopY; dwWidth = GetWidth(); } else { pRetObj->m_TopX = target.m_TopX; pRetObj->m_TopY = target.m_TopY; dwWidth = ((OImageProcess&)target).GetWidth(); } dwHeight = GetHeight() + ((OImageProcess&)target).GetHeight(); pRetObj->m_ulHorzRes = ((OImageProcess&)target).m_ulHorzRes; pRetObj->m_ulVertRes = ((OImageProcess&)target).m_ulVertRes; //全てのプレーンを処理 for( auto it=m_planelist.begin(); it!=m_planelist.end(); it++ ) { //新領域のプレーンを作成 OPlaneLeaf* pPlane = (*it)->Instance( dwWidth, dwHeight ); //まず、自身の画像をコピーする。 pPlane->CopyDot( pPlane->GetPoint( 0, 0 ), (*it)->GetPointObj( 0, 0 ), (*it)->Width() * (*it)->Height() ); //次に相手の画像をコピーする。 OPlaneLeaf* pDestPlane = ((OImageProcess&)target).GetPlane( (*it)->LeafName() ); if ( pDestPlane != NULL ) { pPlane->CopyDot( pPlane->GetPoint( 0, (*it)->Height() ), pDestPlane->GetPointObj( 0, 0 ), pDestPlane->Width() * pDestPlane->Height() ); } //完成したプレーンを追加 pRetObj->m_planelist.push_back( pPlane ); } return pRetObj; } //同じ水平画素のデータを作成 OImageProcess* OImageProcess::MakeAreaBoxH( DWORD dwSize ) { OImageProcess* pRetObj = Instance(); pRetObj->m_TopX = m_TopX ; pRetObj->m_TopY = m_TopY ; pRetObj->m_ulHorzRes = m_ulHorzRes ; pRetObj->m_ulVertRes = m_ulVertRes ; //全てのプレーンを処理 for( auto it=m_planelist.begin(); it!=m_planelist.end(); it++ ) { //新領域のプレーンを作成 OPlaneLeaf* pPlane = (*it)->Instance( GetWidth(), dwSize ); //完成したプレーンを追加 pRetObj->m_planelist.push_back( pPlane ); } return pRetObj; } //同じ垂直画素のデータを作成 OImageProcess* OImageProcess::MakeAreaBoxV( DWORD dwSize ) { OImageProcess* pRetObj = Instance(); pRetObj->m_TopX = m_TopX ; pRetObj->m_TopY = m_TopY ; pRetObj->m_ulHorzRes = m_ulHorzRes ; pRetObj->m_ulVertRes = m_ulVertRes ; //全てのプレーンを処理 for( auto it=m_planelist.begin(); it!=m_planelist.end(); it++ ) { //新領域のプレーンを作成 OPlaneLeaf* pPlane = (*it)->Instance( dwSize, GetHeight() ); //完成したプレーンを追加 pRetObj->m_planelist.push_back( pPlane ); } return pRetObj; }
[ "dangerouswoo@gmail.com" ]
dangerouswoo@gmail.com
3fea8e6bad03d17a482e9d2db5bf7f25846f5c67
e38f9db8141282bca7b460892921556dabfbc19c
/qt/tutorial/008/abc.cpp
debfaec6fbfc8f5ead7b0f57b901d39397dd9999
[]
no_license
ddddfang/my-exercise
29866672788f7ea695e482eb8c052ee4a9953bed
0a47d14547d50b6f1c4def78ebe82f2a0a3d3b74
refs/heads/master
2021-06-18T05:42:45.636838
2021-03-14T09:45:29
2021-03-14T09:45:29
187,171,975
0
0
null
null
null
null
UTF-8
C++
false
false
660
cpp
//#include <QApplication> //#include <QWidget> //#include <QIcon> //#include <QFrame> //#include <QGridLayout> //#include <QPushButton> #include "myWidget.h" int main(int argc, char *argv[]) { QApplication app(argc, argv); //qt5 的非console程序,都必须要创建 QApplication 对象 MyWidget window; //使用自己定制的 QWidget,所以这样定制的 QWidget 可以被放到单独的模块里 window.resize(500, 300); window.move(300, 300); window.setWindowTitle("simple sample"); window.setWindowIcon(QIcon("icon.png")); //app启动后左侧dock栏会显示这个图标 window.show(); return app.exec(); }
[ "fridayfang@zhaoxin.com" ]
fridayfang@zhaoxin.com
bef448a3fc650a04427ba3c6a3e6a47e3654fe0b
34be098d37471c5aa09b70d8de275747c239647c
/src/tx11.cpp
1fc09b2c7d5315530cc95d0fa7a202192d300de9
[]
no_license
akinomyoga/contra
e55678c0ce5acccc7f30468c3a8666d6e6c0de06
42367a7e8ccc0ace9b5fa2fbd42f8471c93826df
refs/heads/master
2023-04-07T04:23:33.547253
2023-03-16T03:19:49
2023-03-16T03:22:26
68,645,437
5
1
null
2020-10-06T03:40:10
2016-09-19T20:50:31
C++
UTF-8
C++
false
false
45,610
cpp
#define CONTRA_TX11_SUPPORT_HIGHDPI #include <cstdio> #include <cstdlib> #include <cstring> #include <unistd.h> #include <X11/Xlib.h> #include <X11/XKBlib.h> #include <X11/Xutil.h> #include <X11/Xatom.h> #include <X11/Xft/Xft.h> #include "ansi/render.hpp" #include "manager.hpp" #include "pty.hpp" #include "context.hpp" #include <memory> namespace contra::tx11 { namespace { const char* get_x11_event_name(XEvent const& event) { switch (event.type) { case ButtonPress: return "ButtonPress"; case ButtonRelease: return "ButtonRelease"; case CirculateNotify: return "CirculateNotify"; case CirculateRequest: return "CirculateRequest"; case ClientMessage: return "ClientMessage"; case ColormapNotify: return "ColormapNotify"; case ConfigureNotify: return "ConfigureNotify"; case ConfigureRequest: return "ConfigureRequest"; case CreateNotify: return "CreateNotify"; case DestroyNotify: return "DestroyNotify"; case EnterNotify: return "EnterNotify"; case Expose: return "Expose"; case FocusIn: return "FocusIn"; case FocusOut: return "FocusOut"; case GraphicsExpose: return "GraphicsExpose"; case GravityNotify: return "GravityNotify"; case KeyPress: return "KeyPress"; case KeyRelease: return "KeyRelease"; case KeymapNotify: return "KeymapNotify"; case LeaveNotify: return "LeaveNotify"; case MapNotify: return "MapNotify"; case MapRequest: return "MapRequest"; case MappingNotify: return "MappingNotify"; case MotionNotify: return "MotionNotify"; case NoExpose: return "NoExpose"; case PropertyNotify: return "PropertyNotify"; case ReparentNotify: return "ReparentNotify"; case ResizeRequest: return "ResizeRequest"; case SelectionClear: return "SelectionClear"; case SelectionNotify: return "SelectionNotify"; case SelectionRequest: return "SelectionRequest"; case UnmapNotify: return "UnmapNotify"; case VisibilityNotify: return "VisibilityNotify"; default: static char name[16]; std::sprintf(name, "unknown%d", event.type); return name; } } struct x11_color_manager_t { Display* m_display; Colormap m_cmap; std::size_t npixel = 0; ansi::color_t color256[256]; unsigned long color256_to_pixel[256]; void initialize_colors() { std::size_t index = 0; XColor xcolor {}; auto _alloc = [this, &index, &xcolor] (byte r, byte g, byte b) { xcolor.red = r | r << 8; xcolor.green = g | g << 8; xcolor.blue = b | b << 8; XAllocColor(m_display, m_cmap, &xcolor); color256[index] = contra::ansi::rgb( (xcolor.red + 128) / 257, (xcolor.green + 128) / 257, (xcolor.blue + 128) / 257); color256_to_pixel[index] = xcolor.pixel; index++; }; auto _intensity = [] (int i) -> byte { return i == 0 ? 0 : i * 40 + 55; }; // 8colors for (int i = 0; i < 8; i++) _alloc(i & 1 ? 0x80 : 0, i & 2 ? 0x80 : 0, i & 4 ? 0x80 : 0); // highlight 8 colors for (int i = 0; i < 8; i++) _alloc(i & 1 ? 0xFF : 0, i & 2 ? 0xFF : 0, i & 4 ? 0xFF : 0); // 6x6x6 colors for (int r = 0; r < 6; r++) { auto const R = _intensity(r); for (int g = 0; g < 6; g++) { auto const G = _intensity(g); for (int b = 0; b < 6; b++) { auto const B = _intensity(b); _alloc(R, G, B); } } } // 24 grayscale for (int k = 0; k < 24; k++) { byte const K = k * 10 + 8; _alloc(K, K, K); } mwg_assert(index == 256); } public: x11_color_manager_t(Display* display) { this->m_display = display; int const screen = DefaultScreen(display); this->m_cmap = DefaultColormap(display, screen); this->initialize_colors(); } ~x11_color_manager_t() { XFreeColors(m_display, m_cmap, &color256_to_pixel[0], std::size(color256_to_pixel), 0); } private: template<typename T> static std::pair<T, T> get_minmax3(T a, T b, T c) { if (a > b) std::swap(a, b); if (b <= c) return {a, c}; return {std::min(a, c), b}; } public: int index(ansi::color_t color) { byte r = contra::ansi::rgba2r(color); byte g = contra::ansi::rgba2g(color); byte b = contra::ansi::rgba2b(color); auto [mn, mx] = get_minmax3(r, g, b); if (mx - mn < 20) { byte k = (r + g + b) / 3; k = (k + 2) / 10; return k == 0 ? 16 : k == 25 ? 231 : 231 + k; } else { r = (r - 24) / 40; g = (g - 24) / 40; b = (b - 24) / 40; return 16 + r * 36 + g * 6 + b; } } unsigned long pixel(ansi::color_t color) { return color256_to_pixel[index(color)]; } }; class xft_font_factory { public: typedef XftFont* font_type; private: using font_t = ansi::font_t; Display* m_display = NULL; int m_screen = 0; std::string m_fontnames[16]; int m_font_padding; public: xft_font_factory(contra::app::context& actx) { // 既定ではどのフォントが入っているのか分からないので monospace にする m_fontnames[0] = "monospace"; m_fontnames[1] = "monospace"; m_fontnames[2] = "monospace"; m_fontnames[3] = "monospace"; m_fontnames[4] = "monospace"; m_fontnames[5] = "monospace"; m_fontnames[6] = "monospace"; m_fontnames[7] = "monospace"; m_fontnames[8] = "monospace"; m_fontnames[9] = "monospace"; m_fontnames[10] = "monospace"; actx.read("tx11_font_default", m_fontnames[0] ); actx.read("tx11_font_ansi1" , m_fontnames[1] ); actx.read("tx11_font_ansi2" , m_fontnames[2] ); actx.read("tx11_font_ansi3" , m_fontnames[3] ); actx.read("tx11_font_ansi4" , m_fontnames[4] ); actx.read("tx11_font_ansi5" , m_fontnames[5] ); actx.read("tx11_font_ansi6" , m_fontnames[6] ); actx.read("tx11_font_ansi7" , m_fontnames[7] ); actx.read("tx11_font_ansi8" , m_fontnames[8] ); actx.read("tx11_font_ansi9" , m_fontnames[9] ); actx.read("tx11_font_frak" , m_fontnames[10]); actx.read("tx11_font_padding", m_font_padding = 0); } bool setup_display(Display* display) { if (m_display == display) return false; m_display = display; m_screen = DefaultScreen(display); return true; } public: font_type create_font(font_t font, ansi::font_metric_t const& metric) const { using namespace contra::ansi; const char* fontname = m_fontnames[0].c_str(); if (font_t const face = (font & font_face_mask) >> font_face_shft) if (const char* const name = m_fontnames[face].c_str()) fontname = name; int slant = FC_SLANT_ROMAN; int weight = FC_WEIGHT_NORMAL; double height = metric.height(); double width = metric.width(); FcMatrix matrix; if (font & font_flag_italic) slant = FC_SLANT_OBLIQUE; switch (font & font_weight_mask) { case font_weight_bold: weight = FC_WEIGHT_BOLD; break; case font_weight_faint: weight = FC_WEIGHT_THIN; break; case font_weight_heavy: weight = FC_WEIGHT_HEAVY; break; } if (font & font_flag_small) { height = metric.small_height(); width = metric.small_width(); } if (font & font_decdhl) height *= 2; if (font & font_decdwl) width *= 2; // Note: ぴったりだと隣の文字とくっついてしまう様だ (使っているフォントの問題?) if (!(font & font_flag_small) && m_font_padding) { int const padding = std::min(m_font_padding, (int) std::ceil(width / 4)); height -= padding; width -= padding; } double const xscale = std::floor(std::max(width, 1.0)) / (height * 0.5); if (font_t const rotation = (font & font_rotation_mask) >> font_rotation_shft) { double const radian = 0.25 * M_PI * rotation; double const c = std::cos(radian), s = std::sin(radian); matrix.xx = c * xscale; matrix.xy = -s; matrix.yx = s * xscale; matrix.yy = c; } else { matrix.xx = xscale; matrix.yy = 1.0; matrix.xy = 0.0; matrix.yx = 0.0; } return XftFontOpen( m_display, m_screen, XFT_FAMILY, XftTypeString, fontname, XFT_PIXEL_SIZE, XftTypeDouble, height, XFT_SLANT, XftTypeInteger, slant, XFT_WEIGHT, XftTypeInteger, weight, XFT_MATRIX, XftTypeMatrix, &matrix, NULL); } void delete_font(font_type font) const { ::XftFontClose(m_display, font); } }; struct xft_character_buffer { using coord_t = ansi::coord_t; std::vector<byte> characters; std::vector<coord_t> position; std::vector<std::size_t> next; public: bool empty() const { return position.empty(); } void add_char(std::uint32_t code, coord_t x, bool is_extension) { contra::encoding::put_u8(code, characters); if (is_extension && position.size()) { next.back() = characters.size(); } else { next.push_back(characters.size()); position.push_back(x); } } void clear() { characters.clear(); position.clear(); next.clear(); } void reserve(std::size_t capacity) { characters.reserve(capacity * 3); position.reserve(capacity); } }; class xft_text_drawer_t { using font_t = ansi::font_t; using coord_t = ansi::coord_t; using color_t = ansi::color_t; Display* m_display = NULL; Colormap m_cmap = 0; Visual* m_visual = NULL; x11_color_manager_t* m_color_manager = NULL; ansi::font_manager_t<xft_font_factory> font_manager; Drawable m_drawable = 0; XftDraw* m_draw = NULL; Region m_clip_region = NULL; public: void clip_rectangle(coord_t x1, coord_t y1, coord_t x2, coord_t y2) { if (m_clip_region) XDestroyRegion(m_clip_region); m_clip_region = XCreateRegion(); XRectangle rect; rect.x = x1; rect.y = y1; rect.width = x2 - x1; rect.height = y2 - y1; XUnionRectWithRegion(&rect, m_clip_region, m_clip_region); XftDrawSetClip(m_draw, m_clip_region); } void clip_clear() { XftDrawSetClip(m_draw, 0); } private: void release() { if (m_draw) { XftDrawDestroy(m_draw); m_draw = NULL; } if (m_clip_region) { XDestroyRegion(m_clip_region); m_clip_region = NULL; } } public: xft_text_drawer_t(contra::app::context& actx): font_manager(actx) {} ~xft_text_drawer_t() { release(); } void initialize(Display* display, x11_color_manager_t* color_manager) { m_display = display; int const screen = DefaultScreen(display); m_cmap = DefaultColormap(m_display, screen); m_visual = DefaultVisual(m_display, screen); m_color_manager = color_manager; if (font_manager.factory().setup_display(display)) font_manager.clear(); } void set_size(coord_t width, coord_t height) { font_manager.set_size(width, height); } private: void update_target(Drawable drawable) { if (drawable == m_drawable) return; release(); this->m_drawable = drawable; this->m_draw = ::XftDrawCreate(m_display, drawable, m_visual, m_cmap); } private: void render(coord_t x, coord_t y, xft_character_buffer const& buff, XftFont* xftFont, color_t color) { XftColor xftcolor; xftcolor.pixel = m_color_manager ? m_color_manager->pixel(color) : contra::ansi::rgba2bgr(color); xftcolor.color.red = 257 * contra::ansi::rgba2r(color); xftcolor.color.green = 257 * contra::ansi::rgba2g(color); xftcolor.color.blue = 257 * contra::ansi::rgba2b(color); xftcolor.color.alpha = 0xFFFF; std::size_t index = 0; for (std::size_t i = 0, iN = buff.position.size(); i < iN; i++) { ::XftDrawStringUtf8( m_draw, &xftcolor, xftFont, x + buff.position[i], y, (FcChar8*) &buff.characters[index], buff.next[i] - index); index = buff.next[i]; } } public: void draw_characters(Drawable drawable, coord_t x1, coord_t y1, xft_character_buffer const& buff, font_t font, color_t color) { this->update_target(drawable); coord_t const h = font_manager.get_font_height(font); XftFont* const xftFont = font_manager.get_font(font); double const xftHeight = std::max({xftFont->ascent + xftFont->descent, xftFont->height, 1}); render(x1, y1 + h - h * xftFont->descent / xftHeight, buff, xftFont, color); } void draw_rotated_characters( Drawable drawable, coord_t x0, coord_t y0, coord_t dx, coord_t dy, coord_t w, xft_character_buffer const& buff, font_t font, color_t color ) { this->update_target(drawable); coord_t const h = font_manager.get_font_height(font); font_t const sco = (font & ansi::font_rotation_mask) >> ansi::font_rotation_shft; XftFont* const xftFont0 = font_manager.get_font(font & ~ansi::font_rotation_mask); double const xftHeight = std::max({xftFont0->ascent + xftFont0->descent, xftFont0->height, 1}); double const yshift = h * xftFont0->descent / xftHeight + (sco & 1 ? 1.0 : 0.0); double const angle = -(M_PI / 4.0) * sco; double const xc1 = 0.5 * w - dx; double const yc1 = -0.5 * h + yshift; double const xc2 = xc1 * std::cos(angle) - yc1 * std::sin(angle); double const yc2 = xc1 * std::sin(angle) + yc1 * std::cos(angle); int const rot_dx = (int) std::round(xc2 - xc1); int const rot_dy = (int) std::round(yc2 - yc1 + yshift); x0 += -rot_dx; y0 += -rot_dy; render(x0 + dx, y0 + dy + h, buff, font_manager.get_font(font), color); } }; class tx11_graphics_t; class tx11_graphics_buffer { using coord_t = ansi::coord_t; private: Display* m_display = NULL; int m_screen = 0; std::unique_ptr<x11_color_manager_t> m_color_manager; xft_text_drawer_t m_text_drawer; public: Display* display() const { return m_display; } x11_color_manager_t* color_manager() { return m_color_manager.get(); } xft_text_drawer_t& text_drawer() { return m_text_drawer; } void initialize(Display* display) { this->m_display = display; this->m_screen = DefaultScreen(display); Visual* const visual = DefaultVisual(m_display, m_screen); if (visual->c_class != TrueColor) m_color_manager = std::make_unique<x11_color_manager_t>(m_display); this->m_text_drawer.initialize(display, color_manager()); } private: coord_t m_width = -1, m_height = -1; public: coord_t width() { return m_width; } coord_t height() { return m_height; } void update_window_size(coord_t width, coord_t height, bool* out_resized = NULL) { bool const is_resized = width != m_width || height != m_height; if (is_resized) { release(); m_width = width; m_height = height; } if (out_resized) *out_resized = is_resized; } private: Window m_window = 0; GC m_gc = NULL; public: void setup(Window hWnd, GC hdc) { this->m_window = hWnd; this->m_gc = hdc; } private: struct layer_t { GC gc = NULL; Pixmap pixmap = 0; }; std::vector<layer_t> m_layers; void release() { for (layer_t& layer : m_layers) release_layer(layer); m_layers.clear(); } void release_layer(layer_t& layer) { if (layer.gc) { XFreeGC(m_display, layer.gc); layer.gc = NULL; } if (layer.pixmap) { XFreePixmap(m_display, layer.pixmap); layer.pixmap = 0; } } void initialize_layer(layer_t& layer) { release_layer(layer); layer.pixmap = XCreatePixmap(m_display, m_window, m_width, m_height, DefaultDepth(m_display, m_screen)); // create GC XGCValues gcparams; gcparams.graphics_exposures = false; layer.gc = XCreateGC(m_display, layer.pixmap, GCGraphicsExposures, &gcparams); } public: typedef layer_t context_t; context_t layer(std::size_t index) { if (index < m_layers.size() && m_layers[index].gc) return m_layers[index]; if (index >= m_layers.size()) m_layers.resize(index + 1); layer_t& layer = m_layers[index]; initialize_layer(layer); return layer; } public: tx11_graphics_buffer(contra::app::context& actx, ansi::window_state_t& wstat): m_text_drawer(actx) { m_text_drawer.set_size(wstat.m_xunit, wstat.m_yunit); } ~tx11_graphics_buffer() { release(); } void reset_size(ansi::window_state_t const& wstat) { m_text_drawer.set_size(wstat.m_xunit, wstat.m_yunit); } public: void bitblt( context_t ctx1, coord_t x1, coord_t y1, coord_t w, coord_t h, context_t ctx2, coord_t x2, coord_t y2 ) { ::XCopyArea(m_display, ctx2.pixmap, ctx1.pixmap, ctx1.gc, x2, y2, w, h, x1, y1); } void render(coord_t x1, coord_t y1, coord_t w, coord_t h, context_t ctx2, coord_t x2, coord_t y2) { ::XCopyArea(m_display, ctx2.pixmap, m_window, m_gc, x2, y2, w, h, x1, y1); } typedef tx11_graphics_t graphics_t; }; class tx11_graphics_t { using coord_t = ansi::coord_t; using color_t = ansi::color_t; using font_t = ansi::font_t; Display* m_display = NULL; x11_color_manager_t* color_manager = nullptr; xft_text_drawer_t& text_drawer; Drawable m_drawable = 0; GC m_gc = NULL; GC m_gc_delete = NULL; void release() { if (m_stipple) { XFreePixmap(m_display, m_stipple); m_stipple = 0; } if (m_gc_delete) { XFreeGC(m_display, m_gc_delete); m_gc_delete = NULL; } } public: typedef xft_character_buffer character_buffer; public: tx11_graphics_t(tx11_graphics_buffer& gbuffer, Drawable drawable): m_display(gbuffer.display()), color_manager(gbuffer.color_manager()), text_drawer(gbuffer.text_drawer()) { XGCValues gcparams; gcparams.graphics_exposures = false; this->m_drawable = drawable; this->m_gc_delete = XCreateGC(m_display, drawable, GCGraphicsExposures, &gcparams); this->m_gc = m_gc_delete; } tx11_graphics_t(tx11_graphics_buffer& gbuffer, tx11_graphics_buffer::context_t const& context): m_display(gbuffer.display()), color_manager(gbuffer.color_manager()), text_drawer(gbuffer.text_drawer()) { this->m_drawable = context.pixmap; this->m_gc = context.gc; } ~tx11_graphics_t() { this->release(); } GC gc() const { return m_gc; } private: unsigned long color2pixel(color_t color) const { return color_manager ? color_manager->pixel(color) : contra::ansi::rgba2bgr(color); } void set_foreground(color_t color) { XSetForeground(m_display, m_gc, color2pixel(color)); } public: void clip_rectangle(coord_t x1, coord_t y1, coord_t x2, coord_t y2) { XRectangle rect; rect.x = 0; rect.y = 0; rect.width = x2 - x1; rect.height = y2 - y1; XSetClipRectangles(m_display, m_gc, x1, y1, &rect, 1, YXBanded); text_drawer.clip_rectangle(x1, y1, x2, y2); } void clip_clear() { XSetClipMask(m_display, m_gc, None); text_drawer.clip_clear(); } private: std::vector<XPoint> xpoints; Pixmap m_stipple = 0; Pixmap get_stipple() { if (!m_stipple) { m_stipple = XCreatePixmap(m_display, m_drawable, 2, 2, 1); GC gc2 = XCreateGC(m_display, m_stipple, 0, 0); XSetForeground(m_display, gc2, 0); XFillRectangle(m_display, m_stipple, gc2, 0, 0, 2, 2); XSetForeground(m_display, gc2, 1); XDrawPoint(m_display, m_stipple, gc2, 0, 0); XDrawPoint(m_display, m_stipple, gc2, 1, 1); XFreeGC(m_display, gc2); } return m_stipple; } public: void fill_rectangle(coord_t x1, coord_t y1, coord_t x2, coord_t y2, color_t color) { set_foreground(color); ::XFillRectangle(m_display, m_drawable, m_gc, x1, y1, x2 - x1, y2 - y1); } void invert_rectangle(coord_t x1, coord_t y1, coord_t x2, coord_t y2) { XGCValues params; params.function = GXcopyInverted; XChangeGC(m_display, m_gc, GCFunction, &params); XCopyArea(m_display, m_drawable, m_drawable, m_gc, x1, y1, x2 - x1, y2 - y1, x1, y1); params.function = GXcopy; // default XChangeGC(m_display, m_gc, GCFunction, &params); } void checked_rectangle(coord_t x1, coord_t y1, coord_t x2, coord_t y2, color_t color) { XGCValues params; params.foreground = color2pixel(color); params.fill_style = FillStippled; params.stipple = get_stipple(); XChangeGC(m_display, m_gc, GCForeground | GCStipple | GCFillStyle, &params); XFillRectangle(m_display, m_drawable, m_gc, x1, y1, x2 - x1, y2 - y1); params.fill_style = FillSolid; // default XChangeGC(m_display, m_gc, GCFillStyle, &params); } void draw_ellipse(coord_t x1, coord_t y1, coord_t x2, coord_t y2, color_t color, int line_width) { XGCValues params; params.foreground = color2pixel(color); params.line_width = line_width; XChangeGC(m_display, m_gc, GCForeground | GCLineWidth, &params); XDrawArc(m_display, m_drawable, m_gc, x1, y1, x2 - x1, y2 - y1, 0 * 64, 360 * 64); } void fill_ellipse(coord_t x1, coord_t y1, coord_t x2, coord_t y2, color_t color) { set_foreground(color); XFillArc(m_display, m_drawable, m_gc, x1, y1, x2 - x1, y2 - y1, 0 * 64, 360 * 64); } void fill_polygon(coord_t const (*points)[2], std::size_t count, color_t color) { set_foreground(color); xpoints.resize(count); for (std::size_t i = 0; i < count; i++) { xpoints[i].x = points[i][0]; xpoints[i].y = points[i][1]; } XFillPolygon(m_display, m_drawable, m_gc, &xpoints[0], count, Nonconvex, CoordModeOrigin); } void draw_line(coord_t x1, coord_t y1, coord_t x2, coord_t y2, color_t color, int line_width) { XGCValues params; params.foreground = color2pixel(color); params.line_width = line_width; params.cap_style = CapRound; XChangeGC(m_display, m_gc, GCForeground | GCLineWidth | GCCapStyle, &params); XDrawLine(m_display, m_drawable, m_gc, x1, y1, x2, y2); } public: void draw_characters(coord_t x1, coord_t y1, character_buffer const& buff, font_t font, color_t color) { // set_foreground(color); // contra_unused(font); // coord_t x = x1, y = y1 + wstat.m_yunit - 1; // for (std::size_t i = 0, iN = buff.characters.size(); i < iN; i++) { // ::XDrawString(m_display, m_drawable, m_gc, x, y, &buff.characters[i], 1); // x += buff.progress[i]; // } text_drawer.draw_characters(m_drawable, x1, y1, buff, font, color); } void draw_rotated_characters( coord_t x0, coord_t y0, coord_t dx, coord_t dy, coord_t width, character_buffer const& buff, font_t font, color_t color ) { text_drawer.draw_rotated_characters(m_drawable, x0, y0, dx, dy, width, buff, font, color); } void draw_text(coord_t x1, coord_t y1, character_buffer const& buff, font_t font, color_t color) { draw_characters(x1, y1, buff, font, color); } }; struct tx11_settings: public ansi::window_settings_base { typedef ansi::window_settings_base base; const char* m_env_term = "xterm-256color"; const char* m_env_shell = "/bin/bash"; bool tx11_disableMouseReportOnScrLock = false; void configure(contra::app::context& actx) { base::configure(actx); actx.read("tx11_disable_mouse_report_on_scrlock", tx11_disableMouseReportOnScrLock = true); } }; class tx11_window_t: term::terminal_events { contra::app::context& actx; ansi::window_state_t wstat; ansi::status_tracer_t m_tracer; term::terminal_manager manager; ansi::window_renderer_t<tx11_graphics_t> renderer { wstat }; ::Display* display = NULL; ::Window main = 0; ::Atom WM_DELETE_WINDOW; tx11_settings settings; tx11_graphics_buffer gbuffer { actx, wstat }; public: tx11_window_t(contra::app::context& actx): actx(actx) { // size and dimension wstat.configure_metric(actx); manager.reset_size(wstat.m_col, wstat.m_row, wstat.m_xunit, wstat.m_yunit); gbuffer.reset_size(wstat); // other settings settings.configure(actx); kbflags_initialize(); } ~tx11_window_t() {} private: bool is_session_ready() { return display && manager.is_active(); } #ifdef CONTRA_TX11_SUPPORT_HIGHDPI double get_dpi(Display* display) { const char* dpi_resource = ::XGetDefault(display, "Xft", "dpi"); if (!dpi_resource) return 0.0; char* endptr; double const result = std::strtod(dpi_resource, &endptr); if (endptr && *endptr) return 0.0; return result; } #endif public: Display* display_handle() { return this->display; } Window window_handle() const { return this->main; } bool create_window() { // Setup X11 this->display = ::XOpenDisplay(NULL); if (this->display == NULL) { std::fprintf(stderr, "contra: Failed to open DISPLAY=%s\n", std::getenv("DISPLAY")); return false; } #ifdef CONTRA_TX11_SUPPORT_HIGHDPI if (double const dpi = get_dpi(display)) { double const dpiscale = std::max(1.0, dpi / 96.0); wstat.configure_metric(actx, dpiscale); gbuffer.reset_size(wstat); manager.initialize_zoom(wstat.m_xunit, wstat.m_yunit); manager.reset_size(wstat.m_col, wstat.m_row, wstat.m_xunit, wstat.m_yunit); } #endif int const screen = DefaultScreen(display); Window const root = RootWindow(display, screen); unsigned long const black = BlackPixel(display, screen); unsigned long const white = WhitePixel(display, screen); // Main Window this->m_window_width = wstat.calculate_client_width(); this->m_window_height = wstat.calculate_client_height(); this->main = XCreateSimpleWindow(display, root, 100, 100, m_window_width, m_window_height, 1, black, white); { // Properties XTextProperty win_name; win_name.value = (unsigned char*) "Contra/X11"; win_name.encoding = XA_STRING; win_name.format = 8; win_name.nitems = std::strlen((char const*) win_name.value); ::XSetWMName(display, this->main, &win_name); // Events long event_mask = ExposureMask | StructureNotifyMask; // ウィンドウ関連 event_mask |= FocusChangeMask; // FocusIn, FocusOut event_mask |= KeyPressMask | KeyReleaseMask; // キーボード関連 event_mask |= ButtonPressMask | ButtonReleaseMask | PointerMotionMask; // マウス関連 XSelectInput(display, this->main, event_mask); } // #D0162 何だかよく分からないが終了する時はこうするらしい。 this->WM_DELETE_WINDOW = XInternAtom(display, "WM_DELETE_WINDOW", False); XSetWMProtocols(display, this->main, &this->WM_DELETE_WINDOW, 1); this->gbuffer.initialize(this->display); XAutoRepeatOn(display); XkbSetDetectableAutoRepeat(display, True, NULL); // #D0238 this->manager.set_events(static_cast<term::terminal_events&>(*this)); return true; } private: ansi::coord_t m_window_width = 100; ansi::coord_t m_window_height = 100; public: void process_window_resize() { if (!is_session_ready()) return; XWindowAttributes attrs; XGetWindowAttributes(this->display, this->main, &attrs); this->m_window_width = attrs.width; this->m_window_height = attrs.height; ansi::curpos_t const new_col = std::max(1, (attrs.width - 2 * wstat.m_xframe) / wstat.m_xunit); ansi::curpos_t const new_row = std::max(1, (attrs.height - 2 * wstat.m_yframe) / wstat.m_yunit); if (new_col != wstat.m_col || new_row != wstat.m_row) { wstat.m_col = new_col; wstat.m_row = new_row; manager.reset_size(new_col, new_row); } } void adjust_window_size() { ansi::coord_t const width = wstat.calculate_client_width(); ansi::coord_t const height = wstat.calculate_client_height(); ::XResizeWindow(display, main, width, height); } private: // Implement terminal_events::request_change_size virtual bool request_change_size(ansi::curpos_t col, ansi::curpos_t row, ansi::coord_t xunit, ansi::coord_t yunit) override { auto& wm = wstat; if (xunit >= 0) xunit = limit::term_xunit.clamp(xunit); if (yunit >= 0) yunit = limit::term_yunit.clamp(yunit); if (col < 0 && row < 0) { // 文字サイズだけを変更→自動的に列・行を変えてウィンドウサイズを変えなくて済む様にする。 if (wm.m_xunit != xunit || wm.m_yunit != yunit) { wm.m_xunit = xunit; wm.m_yunit = yunit; gbuffer.reset_size(wm); process_window_resize(); return true; } } bool changed = false; if (xunit >= 0 && wm.m_xunit != xunit) { wm.m_xunit = xunit; changed = true; } if (yunit >= 0 && wm.m_yunit != yunit) { wm.m_yunit = yunit; changed = true; } if (col >= 0) { col = limit::term_col.clamp(col); if (col != wm.m_col) { wm.m_col = col; changed = true; } } if (row >= 0) { row = limit::term_row.clamp(row); if (row != wm.m_row) { wm.m_row = row; changed = true; } } if (changed) { this->gbuffer.reset_size(wm); this->adjust_window_size(); //this->manager.reset_size(wm.m_col, wm.m_row, wm.m_xunit, wm.m_yunit); } return true; } private: friend class ansi::window_renderer_t<tx11_graphics_t>; void unset_cursor_timer() {} void reset_cursor_timer() {} private: void render_window() { tx11_graphics_t g(gbuffer, this->main); if (!is_session_ready()) { const char* message = "Hello, world!"; XDrawString(display, this->main, g.gc(), 3, 15, message, std::strlen(message)); } else { bool resized = true; gbuffer.setup(this->main, g.gc()); gbuffer.update_window_size(this->m_window_width, this->m_window_height, &resized); renderer.render_view(*this, gbuffer, manager.app().view(), resized); } XFlush(display); } private: void process_input(std::uint32_t key) { //contra::print_key(key, stderr); manager.input_key(key); } private: byte m_kbflags[256]; enum kbflag_flags { kbflag_pressed = 1, kbflag_locked = 2, }; enum extended_key_flags { toggle_capslock = 0x100, toggle_numlock = 0x200, toggle_scrolllock = 0x400, }; void kbflags_initialize() { std::fill(std::begin(m_kbflags), std::end(m_kbflags), 0); } void kbflags_update_modifiers() { char table[32]; ::XQueryKeymap(display, table); auto const _update_kbflags = [this, &table] (KeySym sym) { KeyCode const keycode = XKeysymToKeycode(display, sym); if (keycode == 0) return; int const bit = 1 << (keycode & 7); if (table[keycode >> 3] & bit) m_kbflags[keycode] |= kbflag_pressed; else m_kbflags[keycode] &= ~kbflag_pressed; }; _update_kbflags(XK_Shift_L ); _update_kbflags(XK_Shift_R ); _update_kbflags(XK_Control_L); _update_kbflags(XK_Control_R); _update_kbflags(XK_Alt_L ); _update_kbflags(XK_Alt_R ); _update_kbflags(XK_Meta_L ); _update_kbflags(XK_Meta_R ); _update_kbflags(XK_Super_L ); _update_kbflags(XK_Super_R ); _update_kbflags(XK_Hyper_L ); _update_kbflags(XK_Hyper_R ); _update_kbflags(XK_Menu ); unsigned indicators = 0; if (XkbGetIndicatorState(display, XkbUseCoreKbd, &indicators) == Success) { auto const _update_locked = [this] (KeySym sym, bool state) { KeyCode const keycode = XKeysymToKeycode(display, sym); if (keycode == 0) return; if (state) m_kbflags[keycode] |= kbflag_locked; else m_kbflags[keycode] &= ~kbflag_locked; }; _update_locked(XK_Caps_Lock , indicators & 1); _update_locked(XK_Num_Lock , indicators & 2); _update_locked(XK_Scroll_Lock, indicators & 4); // 効かない様だ @ Cygwin,Linux } } bool kbflags_process_lockkey(KeySym sym) { switch (sym) { case XK_Caps_Lock : case XK_Num_Lock : case XK_Scroll_Lock: kbflags_update_modifiers(); return true; default: // Japanese & Korean keyboards if (0xFF20 <= sym && sym <= 0xFF3F) { kbflags_update_modifiers(); return true; } return false; } } key_t kbflags_get_modifiers() { key_t ret = 0; auto const _read_kbflags = [&ret, this] (KeySym sym, kbflag_flags flag, key_t mod) { KeyCode const keycode = XKeysymToKeycode(display, sym); if (keycode == 0) return; if (m_kbflags[keycode] & flag) ret |= mod; }; _read_kbflags(XK_Shift_L , kbflag_pressed, settings.term_mod_lshift); _read_kbflags(XK_Shift_R , kbflag_pressed, settings.term_mod_rshift); _read_kbflags(XK_Control_L , kbflag_pressed, settings.term_mod_lcontrol); _read_kbflags(XK_Control_R , kbflag_pressed, settings.term_mod_rcontrol); _read_kbflags(XK_Alt_L , kbflag_pressed, settings.term_mod_lalter); _read_kbflags(XK_Alt_R , kbflag_pressed, settings.term_mod_ralter); _read_kbflags(XK_Meta_L , kbflag_pressed, settings.term_mod_lmeta); _read_kbflags(XK_Meta_R , kbflag_pressed, settings.term_mod_rmeta); _read_kbflags(XK_Super_L , kbflag_pressed, settings.term_mod_lsuper); _read_kbflags(XK_Super_R , kbflag_pressed, settings.term_mod_rsuper); _read_kbflags(XK_Hyper_L , kbflag_pressed, settings.term_mod_lhyper); _read_kbflags(XK_Hyper_R , kbflag_pressed, settings.term_mod_rhyper); _read_kbflags(XK_Menu , kbflag_pressed, settings.term_mod_menu); _read_kbflags(XK_Caps_Lock , kbflag_locked , toggle_capslock); _read_kbflags(XK_Num_Lock , kbflag_locked , toggle_numlock); _read_kbflags(XK_Scroll_Lock, kbflag_locked , toggle_scrolllock); return ret; } private: void process_keyup(KeyCode keycode) { m_kbflags[(byte) keycode] &= ~kbflag_pressed; KeySym const sym = XkbKeycodeToKeysym(display, keycode, 0, 0); kbflags_process_lockkey(sym); } bool process_key(KeyCode keycode) { key_t modifiers = kbflags_get_modifiers(); // Note #D0238: autorepeat 検出 if (m_kbflags[(byte) keycode] & kbflag_pressed) modifiers |= modifier_autorepeat; else m_kbflags[(byte) keycode] |= kbflag_pressed; key_t code = XkbKeycodeToKeysym(display, keycode, 0, 0); if (ascii_sp <= code && code <= ascii_tilde) { // 前提: G1 の文字は XK は ASCII/Unicode に一致している。 mwg_assert(XK_space == ascii_sp && XK_asciitilde == ascii_tilde); // 観察した感じ XkbdKeycodeToKeysym に 0 を渡していれば此処には来ない? if (ascii_A <= code && code <= ascii_Z) code += ascii_a - ascii_A; if (ascii_a <= code && code <= ascii_z) { bool const modified = modifiers & ~(modifier_shift | modifier_autorepeat) & _modifier_mask; if (!modified) { bool const capslock = modifiers & toggle_capslock; bool const shifted = modifiers & modifier_shift; if (capslock != shifted) code += ascii_A - ascii_a; modifiers &= ~modifier_shift; } } else { if (modifiers & modifier_shift) { key_t code2 = XkbKeycodeToKeysym(display, keycode, 0, 1) & _character_mask; if (code2 != code) { modifiers &= ~modifier_shift; code = code2; } } } process_input(code | (modifiers & _modifier_mask)); return true; } else if (XK_F1 <= code && code < XK_F24) { // X11 では実は35まで実はあったりする。 process_input((code - XK_F1 + key_f1) | (modifiers & _modifier_mask)); return true; } else { key_t numlock = 0; switch (code) { case XK_BackSpace: code = ascii_bs; goto function_key; case XK_Tab : code = ascii_ht; goto function_key; case XK_Return : code = ascii_cr; goto function_key; case XK_Escape : code = ascii_esc; goto function_key; case XK_Delete : code = key_delete; goto function_key; case XK_Insert : code = key_insert; goto function_key; case XK_Prior : code = key_prior; goto function_key; case XK_Next : code = key_next; goto function_key; case XK_End : code = key_end; goto function_key; case XK_Home : code = key_home; goto function_key; case XK_Left : code = key_left; goto function_key; case XK_Up : code = key_up; goto function_key; case XK_Right : code = key_right; goto function_key; case XK_Down : code = key_down; goto function_key; function_key: process_input(code | (modifiers & _modifier_mask)); return true; case XK_KP_Insert : code = key_insert; numlock = ascii_0; goto keypad; case XK_KP_End : code = key_end; numlock = ascii_1; goto keypad; case XK_KP_Down : code = key_down; numlock = ascii_2; goto keypad; case XK_KP_Next : code = key_next; numlock = ascii_3; goto keypad; case XK_KP_Left : code = key_left; numlock = ascii_4; goto keypad; case XK_KP_Begin : code = key_begin; numlock = ascii_5; goto keypad; case XK_KP_Right : code = key_right; numlock = ascii_6; goto keypad; case XK_KP_Home : code = key_home; numlock = ascii_7; goto keypad; case XK_KP_Up : code = key_up; numlock = ascii_8; goto keypad; case XK_KP_Prior : code = key_prior; numlock = ascii_9; goto keypad; case XK_KP_Delete : code = key_delete; numlock = key_kpdec; goto keypad; keypad: if ((modifiers & toggle_numlock) != (modifiers & modifier_shift)) code = numlock; modifiers &= ~modifier_shift; goto function_key; case XK_KP_Divide : code = key_kpdiv; goto function_key; case XK_KP_Multiply: code = key_kpmul; goto function_key; case XK_KP_Subtract: code = key_kpsub; goto function_key; case XK_KP_Add : code = key_kpadd; goto function_key; case XK_KP_Enter : code = key_kpent; goto function_key; default: if (!kbflags_process_lockkey(code)) { // std::printf("ksym=%04x:XK_%s mods=%08x\n", code, XKeysymToString((KeySym) code), modifiers); // std::fflush(stdout); } break; } } return false; } bool process_mouse(key_t mouse_event, int x, int y) { key_t const modifiers = kbflags_get_modifiers(); key_t key = mouse_event | (modifiers & _modifier_mask); if (settings.tx11_disableMouseReportOnScrLock && (modifiers & toggle_scrolllock)) key |= modifier_application; ansi::coord_t const px = x - wstat.m_xframe; ansi::coord_t const py = y - wstat.m_yframe; ansi::curpos_t const x1 = px / wstat.m_xunit; ansi::curpos_t const y1 = py / wstat.m_yunit; manager.input_mouse(key, px, py, x1, y1); if (manager.m_dirty) render_window(); return true; } void process_event(XEvent const& event) { switch (event.type) { case Expose: if (event.xexpose.count == 0) render_window(); break; case ClientMessage: // #D0162 if ((Atom) event.xclient.data.l[0] == WM_DELETE_WINDOW) XDestroyWindow(display, this->main); break; case DestroyNotify: // #D0162 ::XSetCloseDownMode(display, DestroyAll); ::XCloseDisplay(display); this->display = NULL; break; case ConfigureNotify: this->process_window_resize(); break; case MapNotify: case UnmapNotify: case ReparentNotify: // 無視 break; case KeyPress: process_key(event.xkey.keycode); break; case KeyRelease: process_keyup(event.xkey.keycode); break; case FocusIn: kbflags_update_modifiers(); process_input(key_focus); break; case FocusOut: process_input(key_blur); break; case ButtonPress: // mousedown, wheel { key_t key; unsigned const button = event.xbutton.button; // 1: left, 2: middle, 3: right, 4: wheel up, 5: wheel down switch (button) { case 1: key = key_mouse1_down; break; case 2: key = key_mouse2_down; break; case 3: key = key_mouse3_down; break; case 4: key = key_wheel_up; break; case 5: key = key_wheel_down; break; default: return; } process_mouse(key, event.xbutton.x, event.xbutton.y); } break; case ButtonRelease: // mouseup { key_t key; unsigned const button = event.xbutton.button; switch (button) { case 1: key = key_mouse1_up; break; case 2: key = key_mouse2_up; break; case 3: key = key_mouse3_up; break; default: return; } process_mouse(key, event.xbutton.x, event.xbutton.y); } break; case MotionNotify: // mousemove { constexpr unsigned mouse_buttons = Button1Mask | Button2Mask | Button3Mask; key_t key = key_mouse_move; unsigned const kstate = event.xbutton.state; if (kstate & mouse_buttons) { if (kstate & Button1Mask) key = key_mouse1_drag; else if (kstate & Button2Mask) key = key_mouse3_drag; else if (kstate & Button3Mask) key = key_mouse2_drag; } process_mouse(key, event.xbutton.x, event.xbutton.y); } break; default: std::fprintf(stderr, "Event %s (%d)\n", get_x11_event_name(event), event.type); break; } } private: // この部分は twin.cpp からのコピー。後で整理する必要がある。 static void exec_error_handler(int errno1, std::uintptr_t) { char const* msg = std::strerror(errno1); std::ostringstream buff; buff << "exec: " << msg << " (errno=" << errno1 << ")"; //::MessageBoxA(NULL, buff.str().c_str(), "Contra/X11 - exec failed", MB_OK); } bool add_terminal_session() { term::terminal_session_parameters params; params.col = wstat.m_col; params.row = wstat.m_row; params.xunit = wstat.m_xunit; params.yunit = wstat.m_yunit; params.exec_error_handler = &exec_error_handler; //params.dbg_sequence_logfile = "tx11-allseq.txt"; actx.read("session_term", params.env["TERM"] = "xterm-256color"); actx.read("session_shell", params.shell = "/bin/bash"); std::unique_ptr<term::terminal_application> sess = contra::term::create_terminal_session(params); if (!sess) return false; contra::ansi::tstate_t& s = sess->state(); s.m_default_fg_space = contra::ansi::color_space_rgb; s.m_default_bg_space = contra::ansi::color_space_rgb; s.m_default_fg_color = contra::ansi::rgb(0x00, 0x00, 0x00); s.m_default_bg_color = contra::ansi::rgb(0xFF, 0xFF, 0xFF); // s.m_default_fg_color = contra::ansi::rgb(0xD0, 0xD0, 0xD0);//@color // s.m_default_bg_color = contra::ansi::rgb(0x00, 0x00, 0x00); manager.add_app(std::move(sess)); return true; } virtual bool create_new_session() override { return add_terminal_session(); } public: bool do_loop() { // CheckIfEvent 用のダミーフィルター Bool (*event_filter_proc)(Display*, XEvent*, XPointer) = [] (auto...) -> Bool { return True; }; this->kbflags_update_modifiers(); if (!this->add_terminal_session()) return false; XEvent event; while (this->display) { bool processed = manager.do_events(); if (manager.m_dirty) { render_window(); manager.m_dirty = false; } while (::XCheckIfEvent(display, &event, event_filter_proc, NULL)) { processed = true; process_event(event); if (!display) goto exit; } if (!manager.is_alive()) break; if (!processed) contra::term::msleep(10); } exit: manager.terminate(); return true; } }; } bool run(contra::app::context& actx) { contra::tx11::tx11_window_t win(actx); if (!win.create_window()) return 1; ::XMapWindow(win.display_handle(), win.window_handle()); ::XFlush(win.display_handle()); return win.do_loop(); } }
[ "myoga.murase@gmail.com" ]
myoga.murase@gmail.com
1f70f5b6ecb06ab09ed306a0a99353574897d8f0
d0c44dd3da2ef8c0ff835982a437946cbf4d2940
/cmake-build-debug/programs_tiling/function14689/function14689_schedule_14/function14689_schedule_14_wrapper.cpp
19a9f17f2b23116a4317b772697ede7ee91a3081
[]
no_license
IsraMekki/tiramisu_code_generator
8b3f1d63cff62ba9f5242c019058d5a3119184a3
5a259d8e244af452e5301126683fa4320c2047a3
refs/heads/master
2020-04-29T17:27:57.987172
2019-04-23T16:50:32
2019-04-23T16:50:32
176,297,755
1
2
null
null
null
null
UTF-8
C++
false
false
933
cpp
#include "Halide.h" #include "function14689_schedule_14_wrapper.h" #include "tiramisu/utils.h" #include <cstdlib> #include <iostream> #include <time.h> #include <fstream> #include <chrono> #define MAX_RAND 200 int main(int, char **){ Halide::Buffer<int32_t> buf00(128, 64, 64); Halide::Buffer<int32_t> buf0(64, 128, 64, 64); init_buffer(buf0, (int32_t)0); auto t1 = std::chrono::high_resolution_clock::now(); function14689_schedule_14(buf00.raw_buffer(), buf0.raw_buffer()); auto t2 = std::chrono::high_resolution_clock::now(); std::chrono::duration<double> diff = t2 - t1; std::ofstream exec_times_file; exec_times_file.open("../data/programs/function14689/function14689_schedule_14/exec_times.txt", std::ios_base::app); if (exec_times_file.is_open()){ exec_times_file << diff.count() * 1000000 << "us" <<std::endl; exec_times_file.close(); } return 0; }
[ "ei_mekki@esi.dz" ]
ei_mekki@esi.dz
4ae6e855642eef27c507ec0041fcde04c7de0a04
fc846546fc2da267589a09b82a97d6989986db72
/INEM.cpp
8654820602cf65c799d29fbea614e93f14a933a7
[]
no_license
lborges123/Aeda_Proj1
5ebdfdfda1ddba1620b90c108f1ae4b9e631c9a9
7f74e0ef393719229c7a86740575d2b7372d850a
refs/heads/master
2020-03-10T13:57:00.106099
2017-11-24T01:05:48
2017-11-24T01:05:48
null
0
0
null
null
null
null
UTF-8
C++
false
false
930
cpp
#pragma once #include "PostosDeSocorro.h" <<<<<<< HEAD Inem::Inem(int numSocorristas, int numVeiculos, string local, int x, int y, int numAmbulancias, int numCarros, int numMotos) : PostoDeSocorro(numSocorristas, numVeiculos, local, x, y) { ======= INEM::INEM(){ } INEM::INEM(int numSocorristas, int numVeiculos, string local, double x, double y, int numAmbulancias, int numCarros, int numMotos) : PostoDeSocorro(numSocorristas, numVeiculos, local, x, y) { >>>>>>> 439719ca816171d244ce83c6accb3c13c745512d setNumVeiculos(numCarros + numMotos + numAmbulancias); this->numMoto = numMotos; this->numCarro = numCarros; this->numAmbulancias = numAmbulancias; } double INEM::getProximidade(double x, double y) { double distancia; double x1 = coord.first; double y1 = coord.second; distancia = sqrt(((double)x - (double)x1)*((double)x - (double)x1) + ((double)y - (double)y1)*((double)y - (double)y1)); return distancia; }
[ "luis.borges123@hotmail.com" ]
luis.borges123@hotmail.com
4a01e742398c3f9f580a5fd9c4330a7a916ccc08
94987728d8a35fa16c8d42b699d17dc1a60b8fd4
/ouzel/core/android/WindowAndroid.h
98a116ab9ebd12ebf883607b148ba8356a06cc1f
[ "BSD-3-Clause", "BSD-2-Clause" ]
permissive
wengxxaa/ouzel
6db39de8e537e68d314a89f0373d5dd4443db58d
82cfc918216d0810cb354d40c02770616d3623b7
refs/heads/master
2021-01-12T04:10:38.629037
2016-12-28T10:32:14
2016-12-28T10:32:14
null
0
0
null
null
null
null
UTF-8
C++
false
false
399
h
// Copyright (C) 2016 Elviss Strazdins // This file is part of the Ouzel engine. #pragma once #include "core/Window.h" namespace ouzel { class WindowAndroid: public Window { friend Engine; public: void handleResize(const Size2& newSize); protected: WindowAndroid(const Size2& aSize, bool aResizable, bool aFullscreen, const std::string& aTitle); }; }
[ "elviss@elviss.lv" ]
elviss@elviss.lv
38537541f6568bf42c63dc6ebc1a23eb6d4e10a7
7cc8624e51638a595811a0ad04731d2e9d3ce78e
/068_circle/point.cpp
97a1575193a98c0e80d37ec64af3a6a83e503f78
[]
no_license
isildur7/ECE-551
d89ed74c2eaeeb03a6f7c37bb68e6f2a7467d608
08a69f6936d69cb66a5c46871528d56c870e8108
refs/heads/master
2020-04-13T03:56:25.738551
2018-12-24T03:55:38
2018-12-24T03:55:38
162,946,376
3
0
null
null
null
null
UTF-8
C++
false
false
22
cpp
../067_point/point.cpp
[ "aac55@duke.edu" ]
aac55@duke.edu
2e27af67bfb344792306c39005cbadef93198549
cfd82be1fcb1bb873b1d1053579564a224813f93
/mytest/CStringTest/PlaneFitting/Plane.h
0fa7e81e21935452a4b32f90a65eff3fede37414
[]
no_license
tangqinxin/qtdemo
2d6ad1715c078290c488af852e32418f6e083719
91952a48e2d6bea5e5c6f7df2bfbba9868e3512b
refs/heads/master
2020-12-11T06:57:42.990667
2020-09-16T11:16:45
2020-09-16T11:16:45
233,793,193
0
0
null
null
null
null
GB18030
C++
false
false
1,587
h
#ifndef PLANE_H #define PLANE_H #include <opencv2\imgproc.hpp> #include <opencv2\calib3d.hpp> #include <opencv2\highgui.hpp> #include<iostream> #include <vector> #include<math.h> #include"myfun.h" #include<fstream> using namespace cv; class LaserPlane { private: typedef struct { //Z=a0*X+a1*Y+a2; double a0; double a1; double a2; }PlaneCoeffs; typedef struct { double kx; double ky; double kz; Point3f PassPt; }Line; Line BaseLine; PlaneCoeffs PCoeffs; public: LaserPlane(); ~LaserPlane(); void PlaneFitting(vector<Point3f> &PointsCameraCoordinate);//利用三维点云集合进行拟合平面 void CleanCoeffs();//清空激光平面的系数 void ComputeImgPtOnPlane(Mat& M,vector<Point2f>& ImgPtSet,vector<Point3f>& PtsInCamera);//输入相机内参,像素坐标点集,输出他们在相机坐标系下的三维坐标 void SetBaseLine(Mat& M, vector<Point2f>& BaseLineImgPtSet);//设定一条基准线作为参考坐标 void SetBaseLineWith3DPts(vector<Point3f>& PtsInCamera);//利用空间中的三维点云坐标设置基线 float PointToBaseLine(Point3f& Pt);//计算单点Pt到基线的距离 void ComputePtDistToBaseLine(vector<Point3f>& PtSet, vector<float>& DistIn3D);//计算空间中的点集到直线的距离 void DisplayCoeffs();//打印平面参数 void DisplayBaseLine();//打印baseline的信息 float NormPoint3f(Point3f& vec);//计算向量的距离 void SetBaseLineParams(float _kx, float _ky, float _kz, Point3f& pt);//人为设定基线参数 void SavePlaneParams();//保存激光平面参数 }; #endif // ! PLANE_H
[ "48038133+tangqinxin@users.noreply.github.com" ]
48038133+tangqinxin@users.noreply.github.com
954cc5f1d3a7addedd782b911853e4eaf34b0f06
f13e48ec88b43167a30927859aa59bc5161e1fa4
/G1/aula1/main.cpp
77526a8b22005c9d0e89952defc6f91acf6b6a4f
[]
no_license
alexandrewanick/MAT1303
8214bba70a7648b03edfe56d01d15b63c881b89f
b4b4e802db1d53986d8f63fa59db3899ea986a89
refs/heads/master
2020-03-09T13:55:59.692841
2018-07-07T15:24:25
2018-07-07T15:24:25
128,822,930
0
0
null
null
null
null
UTF-8
C++
false
false
586
cpp
#include <iostream> using namespace std; // std determina comandos cout e endl como standard int main(void) { int a, f; a = 2; if (a > 3) { f = 2 + a; cout << a << endl; } else { f = 4; a = 3; } for (int i = 1; i < 5; i++) { int v = 8; // variável i e variável v só existem no for cout << v << endl; } cout << " a = " << a << endl; cout << " Mensagem teste " << endl; // seria a mesma coisa do que com std::cout e std::endl se não houvesse o comando "using namespace std;" } // cout = saída de dados // << = redireciona para // endl = pula uma linha
[ "alexandre@wvieira.com" ]
alexandre@wvieira.com
64f839e7e53aa23859ebe376d62d83319935257b
497efc69490194306a7260592a645e977a4bcd60
/2012/assignment_1/code/src/basis/App.cpp
1a1d382839c2f581433f912acf62a3b351ca4e78
[]
no_license
Zerphed/computer-graphics-course
def0e15aabdec3d95938ea580d05daec9f572113
6d6a10a5a5de5b814fb43c5ff0cf5f4904ef6fd0
refs/heads/master
2021-03-12T21:19:44.899407
2014-01-16T21:37:36
2014-01-16T21:37:36
null
0
0
null
null
null
null
UTF-8
C++
false
false
14,223
cpp
#define _USE_MATH_DEFINES #include "App.hpp" #include "base/Main.hpp" #include "gpu/GLContext.hpp" #include "io/File.hpp" #include "io/StateDump.hpp" #include "base/Random.hpp" #include "gui/Image.hpp" #include "extra.h" #include "surf.h" #include "parse.h" #include <stdio.h> #include <conio.h> #include <vector> #include <fstream> #include <sstream> #include <iostream> #include <GL/GLU.h> using namespace FW; using namespace std; //------------------------------------------------------------------------ App::App(void) : m_action (Action_None), m_commonCtrl (CommonControls::Feature_Default & ~CommonControls::Feature_RepaintOnF5), m_cullMode (CullMode_None), m_mousePressed (false), m_curveMode (CurveMode_Draw), m_surfaceMode (SurfaceMode_Draw), m_pointMode (PointMode_True), m_lineLen (0.1f) { m_commonCtrl.showFPS(true); m_commonCtrl.addButton((S32*)&m_action, Action_LoadSWP, FW_KEY_L, "Load SWP... (L)"); m_commonCtrl.addButton((S32*)&m_action, Action_ResetView, FW_KEY_SPACE, "Reset view... (SPACE)"); m_commonCtrl.addButton((S32*)&m_action, Action_WriteOBJ, FW_KEY_O, "Write to .obj (O)"); m_commonCtrl.addSeparator(); m_commonCtrl.addToggle((S32*)&m_curveMode, CurveMode_None, FW_KEY_NONE, "Don't draw curve"); m_commonCtrl.addToggle((S32*)&m_curveMode, CurveMode_Draw, FW_KEY_NONE, "Draw curve"); m_commonCtrl.addToggle((S32*)&m_curveMode, CurveMode_Normals, FW_KEY_NONE, "Draw normals"); m_commonCtrl.addSeparator(); m_commonCtrl.addToggle((S32*)&m_surfaceMode, SurfaceMode_None, FW_KEY_NONE, "Don't draw surface"); m_commonCtrl.addToggle((S32*)&m_surfaceMode, SurfaceMode_Draw, FW_KEY_NONE, "Draw surface"); m_commonCtrl.addToggle((S32*)&m_surfaceMode, SurfaceMode_WireFrame, FW_KEY_NONE, "Draw wireframe"); m_commonCtrl.addSeparator(); m_commonCtrl.addToggle((S32*)&m_pointMode, PointMode_False, FW_KEY_NONE, "Don't draw control points"); m_commonCtrl.addToggle((S32*)&m_pointMode, PointMode_True, FW_KEY_NONE, "Draw control points"); m_commonCtrl.addSeparator(); m_window.setTitle("basis"); m_window.addListener(this); m_window.addListener(&m_commonCtrl); m_window.getGL()->swapBuffers(); initRendering(); m_camera.SetDimensions(600, 600); m_camera.SetDistance(10); m_camera.SetCenter(Vec3f(0, 0, 0)); } //------------------------------------------------------------------------ App::~App(void) {} //------------------------------------------------------------------------ bool App::handleEvent(const Window::Event& ev) { if (ev.type == Window::EventType_Close) { m_window.showModalMessage("Exiting..."); delete this; return true; } if (ev.type == Window::EventType_KeyDown) { keyDownFunc(ev); } if (ev.type == Window::EventType_KeyUp) { keyUpFunc(ev); } if (ev.type == Window::EventType_Mouse) { motionFunc(ev); } Action action = m_action; m_action = Action_None; String name; Mat4f eye; eye.setIdentity(); switch (action) { case Action_None: break; case Action_LoadSWP: name = m_window.showFileLoadDialog("Load"); if (name.getLength()) loadObjects(name.getPtr()); makeDisplayLists(); break; case Action_ResetView: m_camera.SetRotation(eye); m_camera.SetCenter(Vec3f(0,0,0)); break; case Action_WriteOBJ: for (unsigned i=0; i<n_surfaceNames.size(); i++) { string filename = "surface_" + n_surfaceNames[i] + string(".obj"); ofstream out(filename.c_str()); if (!out) { m_commonCtrl.message(sprintf("Could not open file %s, skipping", filename.c_str())); out.close(); continue; } else { outputObjFile(out, m_surfaces[i]); m_commonCtrl.message(sprintf("Wrote %s", filename.c_str())); } } break; default: FW_ASSERT(false); break; } m_window.setVisible(true); if (ev.type == Window::EventType_Paint) { drawScene(); } m_window.repaint(); return false; } //------------------------------------------------------------------------ void App::keyDownFunc(const Window::Event& ev) { int x = ev.mousePos[0]; int y = ev.mousePos[1]; if (ev.key == FW_KEY_MOUSE_LEFT) { m_mousePressed = true; m_camera.MouseClick(Camera::LEFT, x, y); } else if (ev.key == FW_KEY_MOUSE_MIDDLE) { m_mousePressed = true; m_camera.MouseClick(Camera::MIDDLE, x, y); } else if (ev.key == FW_KEY_MOUSE_RIGHT) { m_mousePressed = true; m_camera.MouseClick(Camera::RIGHT, x, y); } } //------------------------------------------------------------------------ void App::keyUpFunc(const Window::Event& ev) { int x = ev.mousePos[0]; int y = ev.mousePos[1]; if (ev.key == FW_KEY_MOUSE_LEFT || ev.key == FW_KEY_MOUSE_MIDDLE || ev.key == FW_KEY_MOUSE_RIGHT) { m_camera.MouseRelease(x,y); m_mousePressed = false; } } //------------------------------------------------------------------------ // Called when mouse is moved. void App::motionFunc(const Window::Event& ev) { if (m_mousePressed) { int x = ev.mousePos[0]; int y = ev.mousePos[1]; m_camera.MouseDrag(x,y); } } //------------------------------------------------------------------------ // Called when the window is resized // w, h - width and height of the window in pixels. void App::reshapeFunc(int w, int h) { m_camera.SetDimensions(w,h); m_camera.SetViewport(0,0,w,h); m_camera.ApplyViewport(); // Set up a perspective view, with square aspect ratio glMatrixMode(GL_PROJECTION); glLoadIdentity(); m_camera.SetPerspective(50); m_camera.ApplyPerspective(); } //------------------------------------------------------------------------ // This function is responsible for displaying the object. void App::drawScene(void) { // Remove any shader that may be in use. glUseProgram(0); // Clear the rendering window glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); Vec2i size = m_window.getSize(); reshapeFunc(size[0], size[1]); glMatrixMode( GL_MODELVIEW ); glLoadIdentity(); // Light color (RGBA) GLfloat Lt0diff[] = {1.0,1.0,1.0,1.0}; GLfloat Lt0pos[] = {3.0,3.0,5.0,1.0}; glLightfv(GL_LIGHT0, GL_DIFFUSE, Lt0diff); glLightfv(GL_LIGHT0, GL_POSITION, Lt0pos); m_camera.ApplyModelview(); // Call the relevant display lists. if (m_surfaceMode) glCallList(m_surfaceLists[m_surfaceMode]); if (m_curveMode) glCallList(m_curveLists[m_curveMode]); // This draws the coordinate axes when you're rotating, to // keep yourself oriented. if (m_mousePressed) { glPushMatrix(); glTranslated(m_camera.GetCenter()[0], m_camera.GetCenter()[1], m_camera.GetCenter()[2]); glCallList(m_axisList); glPopMatrix(); } if (m_pointMode) glCallList(m_pointList); } //------------------------------------------------------------------------ // Initialize OpenGL's rendering modes void App::initRendering() { glEnable(GL_DEPTH_TEST); // Depth testing must be turned on glEnable(GL_LIGHTING); // Enable lighting calculations glEnable(GL_LIGHT0); // Turn on light #0. // Setup polygon drawing glShadeModel(GL_SMOOTH); glPolygonMode(GL_FRONT_AND_BACK, GL_FILL); // Antialiasing // This looks like crap /* glEnable(GL_BLEND); glEnable(GL_POINT_SMOOTH); glEnable(GL_LINE_SMOOTH); glHint(GL_POINT_SMOOTH_HINT, GL_NICEST); glHint(GL_LINE_SMOOTH_HINT, GL_NICEST); glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); */ // Clear to black glClearColor(0,0,0,1); // Base material colors (they don't change) GLfloat diffColor[] = {0.4, 0.4, 0.4, 1}; GLfloat specColor[] = {0.9, 0.9, 0.9, 1}; GLfloat shininess[] = {50.0}; glMaterialfv(GL_FRONT_AND_BACK, GL_AMBIENT_AND_DIFFUSE, diffColor); glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, specColor); glMaterialfv(GL_FRONT_AND_BACK, GL_SHININESS, shininess); m_curveLists[1] = glGenLists(1); m_curveLists[2] = glGenLists(1); m_surfaceLists[1] = glGenLists(1); m_surfaceLists[2] = glGenLists(1); m_axisList = glGenLists(1); m_pointList = glGenLists(1); } //------------------------------------------------------------------------ // Load in objects from standard input into the class member variables: // m_ctrlPoints, m_curves, m_curveNames, m_surfaces, m_surfaceNames. If // loading fails, this will exit the program. void App::loadObjects(const string& fileName) { ifstream in(fileName.c_str()); cout << endl << "*** loading and constructing curves and surfaces ***" << endl; if (!parseFile(in, m_ctrlPoints, m_curves, m_curveNames, m_surfaces, n_surfaceNames)) { cerr << "\aerror in file format\a" << endl; in.close(); exit(-1); } in.close(); cerr << endl << "*** done ***" << endl; } //------------------------------------------------------------------------ void App::writeObjects(const string& fileName) { cerr << endl << "*** writing obj files ***" << endl; string prefix (fileName.c_str()); for (unsigned i=0; i<n_surfaceNames.size(); i++) { if (n_surfaceNames[i] != ".") { string filename = prefix + string("_") + n_surfaceNames[i] + string(".obj"); ofstream out(filename.c_str()); if (!out) { cerr << "\acould not open file " << filename << ", skipping"<< endl; out.close(); continue; } else { outputObjFile(out, m_surfaces[i]); cerr << "wrote " << filename.c_str() << endl; } } } } //------------------------------------------------------------------------ void App::makeDisplayLists() { // Compile the display lists glNewList(m_curveLists[1], GL_COMPILE); { for (unsigned i=0; i<m_curves.size(); i++) drawCurve(m_curves[i], 0.0); } glEndList(); glNewList(m_curveLists[2], GL_COMPILE); { for (unsigned i=0; i<m_curves.size(); i++) drawCurve(m_curves[i], m_lineLen); } glEndList(); glNewList(m_surfaceLists[1], GL_COMPILE); { for (unsigned i=0; i<m_surfaces.size(); i++) drawSurface(m_surfaces[i], true); } glEndList(); glNewList(m_surfaceLists[2], GL_COMPILE); { for (unsigned i=0; i<m_surfaces.size(); i++) { drawSurface(m_surfaces[i], false); drawNormals(m_surfaces[i], m_lineLen); } } glEndList(); glNewList(m_axisList, GL_COMPILE); { // Save current state of OpenGL glPushAttrib(GL_ALL_ATTRIB_BITS); // This is to draw the axes when the mouse button is down glDisable(GL_LIGHTING); glLineWidth(3); glPushMatrix(); glScaled(5.0,5.0,5.0); glBegin(GL_LINES); glColor4f(1,0.5,0.5,1); glVertex3d(0,0,0); glVertex3d(1,0,0); glColor4f(0.5,1,0.5,1); glVertex3d(0,0,0); glVertex3d(0,1,0); glColor4f(0.5,0.5,1,1); glVertex3d(0,0,0); glVertex3d(0,0,1); glColor4f(0.5,0.5,0.5,1); glVertex3d(0,0,0); glVertex3d(-1,0,0); glVertex3d(0,0,0); glVertex3d(0,-1,0); glVertex3d(0,0,0); glVertex3d(0,0,-1); glEnd(); glPopMatrix(); glPopAttrib(); } glEndList(); glNewList(m_pointList, GL_COMPILE); { // Save current state of OpenGL glPushAttrib(GL_ALL_ATTRIB_BITS); // Setup for point drawing glDisable(GL_LIGHTING); glColor4f(1,1,0.0,1); glPointSize(4); glLineWidth(1); for (unsigned i=0; i<m_ctrlPoints.size(); i++) { glBegin(GL_POINTS); for (unsigned j=0; j<m_ctrlPoints[i].size(); j++) glVertex(m_ctrlPoints[i][j]); glEnd(); glBegin(GL_LINE_STRIP); for (unsigned j=0; j<m_ctrlPoints[i].size(); j++) glVertex(m_ctrlPoints[i][j]); glEnd(); } glPopAttrib(); } glEndList(); } void App::screenshot (const String& name) { // Capture image. const Vec2i& size = m_window.getGL()->getViewSize(); Image image(size, ImageFormat::R8_G8_B8_A8); glUseProgram(0); glWindowPos2i(0, 0); glReadPixels(0, 0, size.x, size.y, GL_RGBA, GL_UNSIGNED_BYTE, image.getMutablePtr()); // Display the captured image immediately. for (int i = 0; i < 3; i++) { glDrawPixels(size.x, size.y, GL_RGBA, GL_UNSIGNED_BYTE, image.getPtr()); m_window.getGL()->swapBuffers(); } glDrawPixels(size.x, size.y, GL_RGBA, GL_UNSIGNED_BYTE, image.getPtr()); // Export. image.flipY(); exportImage(name, &image); printf("Saved screenshot to '%s'", name.getPtr()); } //------------------------------------------------------------------------ void FW::init(void) { new App; } //------------------------------------------------------------------------
[ "joonas.nissinen@aalto.fi" ]
joonas.nissinen@aalto.fi
f7e504627d6b7c74c49cce35ad760eba2e9ab545
5d83739af703fb400857cecc69aadaf02e07f8d1
/Archive/9dcd29d55c6876efff4f18838f664706/main.cpp
d257fd8f38e5497f79b59bdd72f7a112117302d4
[]
no_license
WhiZTiM/coliru
3a6c4c0bdac566d1aa1c21818118ba70479b0f40
2c72c048846c082f943e6c7f9fa8d94aee76979f
refs/heads/master
2021-01-01T05:10:33.812560
2015-08-24T19:09:22
2015-08-24T19:09:22
56,789,706
3
0
null
null
null
null
UTF-8
C++
false
false
419
cpp
#include <iostream> constexpr int something_expensive(int x) { return x; } int process(int x) { switch (x) { // hard-coded for common cases case 0: return something_expensive(0); case 1: return something_expensive(2); case 2: return something_expensive(2); // default is non-optimized default: return something_expensive(x); }; } int main() { }
[ "francis.rammeloo@36614edc-3e3a-acb8-9062-c8ae0e4185df" ]
francis.rammeloo@36614edc-3e3a-acb8-9062-c8ae0e4185df
1e4ef93f96f29a8418cda2776302ed5f7d60c711
afcae84399b4745d2931f630b1a504a992eb0186
/tools/nan.cc
72676e4821ab44fd9b2e23aba46054b8d9eb9cf3
[ "Apache-2.0", "LicenseRef-scancode-proprietary-license" ]
permissive
SVRTK/SVRTK
6f97f137e06446186792f9ab91d56ab4fcec1c66
91d4e75ef0f6bcf18b830114dce1a9261e8755f2
refs/heads/master
2023-08-30T20:59:15.767601
2023-08-19T12:45:02
2023-08-19T12:45:02
153,183,935
40
6
Apache-2.0
2022-01-07T14:13:01
2018-10-15T21:26:46
C++
UTF-8
C++
false
false
3,204
cc
/* * SVRTK : SVR reconstruction based on MIRTK * * Copyright 2018- King's College London * * 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 * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ #include "mirtk/Common.h" #include "mirtk/Options.h" #include "mirtk/IOConfig.h" #include "mirtk/GenericImage.h" #include "mirtk/ImageReader.h" using namespace mirtk; using namespace std; // ============================================================================= // Auxiliary functions // ============================================================================= // ----------------------------------------------------------------------------- void usage() { cout << "Usage: nan [stack_name] [threshold] \n" << endl; cout << endl; cout << "Function for setting voxels with large (abs) and NaN values to 0." << endl; cout << endl; cout << "\t" << endl; cout << "\t" << endl; exit(0); } // ----------------------------------------------------------------------------- // ============================================================================= // Main function // ============================================================================= // ----------------------------------------------------------------------------- int main(int argc, char **argv) { if (argc < 3) usage(); const char *tmp_fname; UniquePtr<BaseImage> tmp_image; UniquePtr<ImageReader> image_reader; InitializeIOLibrary(); //------------------------------------------------------------------- RealImage main_stack; tmp_fname = argv[1]; image_reader.reset(ImageReader::TryNew(tmp_fname)); tmp_image.reset(image_reader->Run()); main_stack = *tmp_image; argc--; argv++; double lower_threshold = 0; lower_threshold = atof(argv[1]); argc--; argv++; for (int z = 0; z < main_stack.GetZ(); z++) { for (int y = 0; y < main_stack.GetY(); y++) { for (int x = 0; x < main_stack.GetX(); x++) { for (int t = 0; t < main_stack.GetT(); t++) { if (main_stack(x,y,z,t) != main_stack(x,y,z,t) || abs(main_stack(x,y,z,t)) > lower_threshold || main_stack(x,y,z,t) < 0) { main_stack(x,y,z,t) = 0; } } } } } main_stack.Write(tmp_fname); //------------------------------------------------------------------- return 0; }
[ "alena.uus@kcl.ac.uk" ]
alena.uus@kcl.ac.uk
db2b982e44641f12b40ea741094245a64af235ab
3349be5969cac6fea2327873549e9ed7e70847f4
/NYXEngine/OpenGLRenderer.h
537885d1b3a70ad5be5e21b9aceb4f069ce30e5e
[]
no_license
RayMicheau/Old-Nyx-Engine
e3f7e746863b92cbe0d9351e1b2696094951b7f2
eb3d0d6fc2c155905060439e98108efdb7b36181
refs/heads/master
2020-06-11T14:59:55.724628
2016-12-05T16:25:00
2016-12-05T16:25:00
75,643,637
0
0
null
null
null
null
UTF-8
C++
false
false
1,135
h
#pragma once #include "AbstractRenderer.h" #include <vector> #include "OpenGL\include\glew.h" #include "OpenGL\include\glut.h" #include "vgl.h" #include "glm\glm\glm.hpp" #include "glm\glm\gtc\matrix_transform.hpp" #include "LoadShaders.h" #include "Camera.h" class OpenGLRenderer : public AbstractRenderer { public: OpenGLRenderer(); ~OpenGLRenderer(); enum VAO_IDs { Triangles, NumVAOs }; enum Buffer_IDs { ArrayBuffer, NumBuffers }; enum Attrib_IDs { vPosition = 0 }; GLuint VAOs[NumVAOs]; GLuint Buffers[NumBuffers]; float CamDist = 1; GLuint location, location2, location3; Camera* CameraOne; float AminX, AmaxX, AminY, AmaxY, AminZ, AmaxZ; float BminX, BmaxX, BminY, BmaxY, BminZ, BmaxZ; float CminX, CmaxX, CminY, CmaxY, CminZ, CmaxZ; int playerScore = 0, aiScore = 0; void PreRender(); void PostRender(); void renderPrimitive(PRIMITIVETYPE prim); bool AABBTemp(); float movementX = 0.3; float movementY = 0.2f; glm::vec3 zero = glm::vec3(0, 0, 0); //bool loadOBJ(const char* path, std::vector<glm::vec3> &out_vertices, std::vector<glm::vec2> &out_uvs, std::vector<glm::vec3> &out_normals); };
[ "raymicheau@yahoo.ca" ]
raymicheau@yahoo.ca
a68df48903d8559e55546f3cc34d3309c0db12a7
18ca163c7953831d6b9147104b4d98bdb79dc9ad
/VS version/LSG/GameStatistics.h
6408fca5532b23cda08a68887175ece0078b726a
[]
no_license
chegainthegithub/LSG
27214167725a9910b423f7a55e44946c42274f05
f17aa5bf3a92a243dc22eb75bd1fb39a928b5799
refs/heads/master
2016-09-05T10:36:39.452609
2015-04-24T15:46:53
2015-04-24T15:46:53
33,578,896
0
0
null
null
null
null
UTF-8
C++
false
false
616
h
#ifndef GAMESTATISTICS_H #define GAMESTATISTICS_H class GameStatistics { public: struct statistics { int eaten ; int movesmade ; int enemieskilled ; }; statistics element; GameStatistics() { element.eaten = 0; element.movesmade = 0; element.enemieskilled = 0; } void UpdateStats(int local) { if (local) element.eaten++; element.movesmade++; } void show() { std::cout << "eaten == " << element.eaten<<std::endl; std::cout << "moves made == " << element.movesmade <<std::endl; } }; #endif // GAMESTATISTICS
[ "chegevara.4151@gmail.com" ]
chegevara.4151@gmail.com
72d33cbd2a1307e7573202a824fd08c480803cf2
f3970177529032d412b299c5cf7fc3ca51a9e66e
/EvtOmegaOmega3pi.cpp
3449f366ef2190c829a85b37cf421b7b9d542931
[]
no_license
AntonGerasimov/evtgen
a0a779d89054b5fa098e83d2081eb816aa8527a5
b5dd7bded6d535a6de2b405d6e9ba9e569e03fc5
refs/heads/master
2020-06-06T01:07:18.130797
2019-06-25T14:06:17
2019-06-25T14:06:17
192,597,148
0
1
null
2019-06-19T00:54:52
2019-06-18T19:01:13
C++
UTF-8
C++
false
false
5,963
cpp
#include "EvtGenBase/EvtPatches.hh" #include <stdlib.h> #include <iostream> #include <string> #include "EvtGenBase/EvtParticle.hh" #include "EvtGenBase/EvtPDL.hh" #include "EvtGenBase/EvtGenKine.hh" #include "EvtGenModels/EvtOmegaOmega3pi.hh" #include "EvtGenBase/EvtDiracSpinor.hh" #include "EvtGenBase/EvtReport.hh" #include "EvtGenBase/EvtVector4C.hh" #include "EvtGenBase/EvtComplex.hh" #include "EvtGenBase/EvtVector4R.hh" #include "EvtGenBase/EvtVector3R.hh" #include "EvtGenModels/EvtWHad.hh" EvtOmegaOmega3pi::~EvtOmegaOmega3pi() { f1a = 1; f1b = 1; f1c = 1; f1d = 1; f2a = 1; f2b = 1; f2c = 1; f2d = 1; g1a = 1; g1b = 1; g1c = 1; g1d = 1; g2a = 1; g2b = 1; g2c = 1; g2d = 1; } std::string EvtOmegaOmega3pi::getName(){ return "OMEGAOMEGA3PI"; } EvtDecayBase* EvtOmegaOmega3pi::clone(){ return new EvtOmegaOmega3pi; } void EvtOmegaOmega3pi::init(){ // check that there are 0 arguments checkNArg(0); checkNDaug(4); checkSpinParent(EvtSpinType::DIRAC); checkSpinDaughter(0,EvtSpinType::DIRAC); checkSpinDaughter(1,EvtSpinType::SCALAR); checkSpinDaughter(2,EvtSpinType::SCALAR); checkSpinDaughter(3,EvtSpinType::SCALAR); static EvtId idOmegaccplus = EvtPDL::getId("Omega_cc+"); static EvtId idOmegaczero = EvtPDL::getId("Omega_c0"); static EvtId idXiccplus = EvtPDL::getId("Xi_cc+"); static EvtId idXiczero = EvtPDL::getId("Xi_c0"); EvtId parnum=getParentId(); EvtId daughtnum = idOmegaczero; /*f1a = 0; f1b = 0; f1c = 0; f1d = 0; f2a = 0; f2b = 0; f2c = 0; f2d = 0; g1a = 0; g1b = 0; g1c = 0; g1d = 0; g2a = 0; g2b = 0; g2c = 0; g2d = 0;*/ if ( parnum == idOmegaccplus && daughtnum == idOmegaczero){ f1a = -0.754; f1b = 0.263; f1c = 0.047; f1d = 0.0205; f2a = -1.02; f2b = 0.225; f2c = 0.0329; f2d = 0.00381; g1a = 1.59; g1b = 0.376; g1c = 0.0926; g1d = 0.0244; g2a = 0.119; g2b = 0.671; g2c = 0.297; g2d = -0.159; } if (parnum == idXiccplus && daughtnum == idOmegaczero){ f1a = 0.914; f1b = 0.348; f1c = 0.0818; f1d = 0.0187; f2a = 0.0116; f2b = 1.31; f2c = 0.513; f2d = 0.15; g1a = 0.258; g1b = 0.208; g1c = 0.0262; g1d = -0.00028; g2a = -0.0608; g2b = 0.364; g2c = 0.289; g2d = -0.16; } } void EvtOmegaOmega3pi::initProbMax(){ setProbMax(9000.0); } void EvtOmegaOmega3pi::HadronicAmp( EvtParticle* parent, EvtParticle* child, EvtVector4C* T, const int i, const int j ) { const EvtDiracSpinor Sfinal = child->spParent(i); const EvtDiracSpinor Sinit = parent->sp(j); const EvtVector4R pp = parent->getP4Lab(); const EvtVector4R cp = child->getP4Lab(); const double pm = parent->mass(); const double cm = child->mass(); // \bar{u} \gamma^{\mu} u T[0] = EvtLeptonVCurrent( Sfinal, Sinit ); // \bar{u} \gamma^{\mu}\gamma^{5} u T[1] = EvtLeptonACurrent( Sfinal, Sinit ); // \bar{u} u T[2] = EvtLeptonSCurrent( Sfinal, Sinit ) * ((pp+cp)/pm); // \bar{u} \gamma^{5} u T[3] = EvtLeptonPCurrent( Sfinal, Sinit ) * ((pp+cp)/pm); return; } const double EvtOmegaOmega3pi::ff(const double f0, const double alpha, const double beta, const double gamma, EvtVector4R qqq){ return f0*(1 + alpha*qqq*qqq + beta*qqq*qqq*qqq*qqq + gamma*qqq*qqq*qqq*qqq*qqq*qqq); } void EvtOmegaOmega3pi::decay(EvtParticle *b1){ static EvtId TAUM=EvtPDL::getId("tau-"); b1->initializePhaseSpace(getNDaug(),getDaugs()); EvtParticle *b2, *pi1, *pi2, *pi3; b2=b1->getDaug(0); pi1 = b1->getDaug(1); pi2 = b1->getDaug(2); pi3 = b1->getDaug(3); EvtVector4R ppi1, ppi2, ppi3; //Импульсы пионов ppi1 = pi1 -> getP4Lab(); ppi2 = pi2 -> getP4Lab(); ppi3 = pi3 -> getP4Lab(); const EvtVector4R pb1 = b1->getP4Lab(); const EvtVector4R pb2 = b2->getP4Lab(); EvtVector4R q=pb1-pb2; const double m1=b1->mass(); const double m2=b2->mass(); const double f1 = ff(f1a, f1b, f1c, f1d, q); const double f2 = ff(f2a, f2b, f2c, f2d, q); const double g1 = ff(g1a, g1b, g1c, g1d, q); const double g2 = ff(g2a, g2b, g2c, g2d, q); /*const double f1 = ff(-0.754,0.263,0.047,0.0205,q); const double g1 = ff(-1.02, 0.225, 0.0329, 0.00381, q); const double f2 = ff(1.59, 0.376, 0.0926, 0.0244, q); const double g2 = ff(0.119, 0.671, 0.297, -0.159, q);*/ EvtVector4C H[2][2]; // vector current EvtVector4C T[6]; // Hadronic current for ( int i =0 ; i < 2; ++i ){ for ( int j = 0; j < 2; ++j ){ HadronicAmp( b1, b2, T, i, j ); H[i][j] = ( f1*T[0] - g1*T[1] + f2 * T[2] - f2*(m1+m2)/m1*T[0]-g2*T[3] - g2*(m1-m2)/m1*T[1]); } } //Leptonic current EvtWHad qqqqqq = EvtWHad(); EvtVector4C lep=qqqqqq.WCurrent(ppi1, ppi2, ppi3); for ( int i =0 ; i < 2; ++i ){ for ( int j = 0; j < 2; ++j ){ vertex(i,j, H[i][j]*lep); } } return; } /* EvtVector4C l1, l2, tau1, tau2; if (p->getId()==TAUM) { tau1=EvtLeptonVACurrent(nut->spParentNeutrino(),p->sp(0)); tau2=EvtLeptonVACurrent(nut->spParentNeutrino(),p->sp(1)); l1=EvtLeptonVACurrent(l->spParent(0),nul->spParentNeutrino()); l2=EvtLeptonVACurrent(l->spParent(1),nul->spParentNeutrino()); } else{ tau1=EvtLeptonVACurrent(p->sp(0),nut->spParentNeutrino()); tau2=EvtLeptonVACurrent(p->sp(1),nut->spParentNeutrino()); l1=EvtLeptonVACurrent(nul->spParentNeutrino(),l->spParent(0)); l2=EvtLeptonVACurrent(nul->spParentNeutrino(),l->spParent(1)); } vertex(0,0,tau1*l1); vertex(0,1,tau1*l2); vertex(1,0,tau2*l1); vertex(1,1,tau2*l2); return; }*/
[ "antoshkasg@gmail.com" ]
antoshkasg@gmail.com
e441d60eb61da6c5b199d6c6bf0fa93b85bd1492
4a50dedb00faee7f03d5d5615eb2104f1a32968e
/Assg9-Task1_jjennin/fractiontype.h
02b8e541aee15fa5dff99725fdfb6cfa4b017f32
[]
no_license
jjennin/odu-cs250
75b03cfe19edb3cd879497e68924d618dfb5d948
0697ec01527263e22b03c1a44a28d9b6440c34e6
refs/heads/master
2021-09-10T07:00:02.610538
2018-03-22T01:33:51
2018-03-22T01:33:51
124,950,536
2
0
null
null
null
null
UTF-8
C++
false
false
962
h
#ifndef FRACTIONTYPE_H #define FRACTIONTYPE_H #include <iostream> class fractionType{ int numerator; int denominator; friend std::ostream& operator<<(std::ostream& out, const fractionType& rightFr); friend std::istream& operator>>(std::istream& in, fractionType& rightFr); public: fractionType(){ numerator=0; denominator=1; } fractionType(int num, int den){ numerator=num; denominator=den; } bool operator==(fractionType rightFr); bool operator!=(fractionType rightFr); bool operator<=(fractionType rightFr); bool operator>=(fractionType rightFr); bool operator<(fractionType rightFr); bool operator>(fractionType rightFr); fractionType operator+(fractionType rightFr); fractionType operator-(fractionType rightFr); fractionType operator/(fractionType rightFr); fractionType operator*(fractionType rightFr); }; #endif // FRACTIONTYPE_H
[ "jjenn001@odu.edu" ]
jjenn001@odu.edu
933f0194df2b0baec1fe6589412c10b3d7b95277
6a9b877ca9b18ccf3764a999340aeda1679eb76c
/src/capengine/Point2d.h
d4dc640b0f69ec4a0735043c07521dce6733b1df
[]
no_license
calebpalmer/capengine
f63299ce55bba6621d021daa4d5857efcc12a1b4
d6851a776372e676afcb17711cec115cdcf2b392
refs/heads/master
2023-07-07T09:07:38.862127
2023-06-29T23:44:52
2023-06-29T23:44:52
8,950,745
1
0
null
null
null
null
UTF-8
C++
false
false
541
h
#ifndef POINT2D_H #define POINT2D_H //@brief - Class representing a point //@author - Caleb Palmer namespace CapEngine { class Point2d { double x; double y; private: // Making copy constructor private Point2d(const Point2d &){}; // make operator= private so that it is not used Point2d &operator=(const Point2d &) { return *this; } public: Point2d(); Point2d(double x_in, double y_in); double getX() const; double getY() const; void setX(double x_in); void setY(double y_in); }; } // namespace CapEngine #endif
[ "palmer.caleb@gmail.com" ]
palmer.caleb@gmail.com
2bedbda027981c68e32835e7eda8d06866e3326b
bf007dec921b84d205bffd2527e376bb60424f4c
/Codeforces_Submissions/1248A.cpp
abd3c69b8693abe365e69dcae0070f9a3cfbb1a7
[]
no_license
Suvrojyoti/APS-2020
257e4a94f52f5fe8adcac1ba4038cc66e81d9d26
d4de0ef098e7ce9bb40036ef55616fa1f159f7a5
refs/heads/master
2020-12-21T19:27:59.955338
2020-04-22T13:27:49
2020-04-22T13:27:49
236,534,218
0
0
null
null
null
null
UTF-8
C++
false
false
699
cpp
#include <bits/stdc++.h> #define ll long long int #define pb push_back #define MOD 1000000007 using namespace std; int main() { #ifndef ONLINE_JUDGE freopen("input.txt", "r", stdin); freopen("output.txt", "w", stdout); #endif ll n,m,test,o,e,o1,e1; cin>>test; while (test--) { cin >> n ; o=o1=e=e1=0; ll test; for (ll i = 0; i < n; i++) { cin>>test; if(test%2) o++; else { e++; } } cin>>n; for (ll i = 0; i < n; i++) { cin >> test; if (test % 2) o1++; else { e1++; } } cout<<o1*o+e1*e<<endl; } return 0; }
[ "suvrojyoti.mandal@theatom.app" ]
suvrojyoti.mandal@theatom.app
af9fbeac297c296befaeab984b12bbc324cadbdd
209779c03feff329fcc7e0898854c4ba0c6d4d16
/codeforces/codes/CF1A.cpp
7b20a7835ab55db2ae440fa96a09d79d25c513ff
[ "MIT" ]
permissive
TonyCrane/OI
76b90833a495bf491377b91e88b944e2113bc49b
562f5f45d0448f4eab77643b99b825405a123d92
refs/heads/master
2022-11-08T20:00:37.196582
2020-06-27T14:51:54
2020-06-27T14:51:54
161,732,784
3
0
null
null
null
null
UTF-8
C++
false
false
712
cpp
/************************************************************* * > File Name : CF1A.cpp * > Author : Tony_Wong * > Created Time : 2019/11/11 20:49:58 * > Algorithm : **************************************************************/ #include <bits/stdc++.h> using namespace std; typedef long long LL; inline LL read() { LL x = 0; LL f = 1; char ch = getchar(); while (!isdigit(ch)) {if (ch == '-') f = -1; ch = getchar();} while (isdigit(ch)) {x = x * 10 + ch - 48; ch = getchar();} return x * f; } LL n, m, a; int main() { n = read(); m = read(); a = read(); printf("%lld\n", (long long)(ceil(n / (double)a) * ceil(m / (double)a))); return 0; }
[ "975062472@qq.com" ]
975062472@qq.com
8b34f2994f9c78a6a168d135461e9bb9a48de98d
bb2a47d45c7c6ba774ac1b23343a26bfb34f68e7
/LeetCode/2_AddTwoNumbers.cpp
3dd67c0f914cf9b9dc3f582fa3896c01a4778bef
[]
no_license
qianfeng0/CodePractice
20e89603cd1029d77045243687e915b2bf966cdb
083eb2f5eff8a242e79a407b9354f6a155f100c8
refs/heads/master
2023-01-22T09:59:09.888463
2020-11-22T08:50:47
2020-11-22T08:50:47
89,705,189
0
0
null
null
null
null
UTF-8
C++
false
false
2,609
cpp
/** You are given two non-empty linked lists representing two non-negative integers. The digits are stored in reverse order and each of their nodes contain a single digit. Add the two numbers and return it as a linked list. You may assume the two numbers do not contain any leading zero, except the number 0 itself. Input: (2 -> 4 -> 3) + (5 -> 6 -> 4) Output: 7 -> 0 -> 8 */ /** * Definition for singly-linked list. * struct ListNode { * int val; * ListNode *next; * ListNode(int x) : val(x), next(NULL) {} * }; */ #include <stdio.h> struct ListNode { int val; ListNode *next; ListNode(int x) : val(x), next(NULL) {} }; class Solution { public: ListNode* addTwoNumbers(ListNode* l1, ListNode* l2) { ListNode* const list = new ListNode(l1->val + l2->val); ListNode* cur = list; l1 = l1->next; l2 = l2->next; while(l1 != NULL || l2 != NULL) { int sum = 0; if(l1 != NULL){ sum += l1->val; l1 = l1->next; } if(l2 != NULL){ sum += l2->val; l2 = l2->next; } cur->next = new ListNode(sum); cur = cur->next; } cur = list; while(cur) { if(cur->val >= 10) { cur->val -= 10; if(cur->next) { cur->next->val++; } else { cur->next = new ListNode(1); } } cur = cur->next; } return list; } }; int main() { //init list1 and list2 ListNode *list1, *list2; list1 = new ListNode(2); list2 = new ListNode(5); ListNode *cur; cur = list1; cur->next = new ListNode(4); cur = cur->next; cur->next = new ListNode(3); cur = list2; cur->next = new ListNode(6); cur = cur->next; cur->next = new ListNode(8); //solution Solution solution; ListNode* listAdd = solution.addTwoNumbers(list1, list2); //print out cur = listAdd; while(cur) { printf("%d ", cur->val); cur = cur->next; } printf("\n"); //delete while(list1) { cur = list1; list1 = list1->next; delete(cur); } while(list2) { cur = list2; list2 = list2->next; delete(cur); } while(listAdd) { cur = listAdd; listAdd = listAdd->next; delete(cur); } return 0; }
[ "401861566@qq.com" ]
401861566@qq.com
f532fe9721cd3402ad8c96791015d2ee5f7a7a2f
126f53c896ce80422ceb75313f6220e150f271fe
/paq3.cpp
940b6674b05767710e87b1a0628f6ee6b685a3e7
[]
no_license
andrew-epstein/paq_history
5697df624026840522ad43e0413fcf739d3dcbce
0358d74d046f580056f1c6790488bb2a3d18f914
refs/heads/master
2021-07-07T15:04:40.606990
2020-08-08T17:40:57
2020-08-08T17:40:57
168,410,720
3
0
null
null
null
null
UTF-8
C++
false
false
46,612
cpp
/* PAQ3 - File archiver and compressor. (C) 2003, Matt Mahoney, mmahoney@cs.fit.edu This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation at http://www.gnu.org/licenses/gpl.txt or (at your option) any later version. This program is distributed without any warranty. USAGE To compress: PAQ3 archive file file... (1 or more file names), or or (MSDOS): dir/b | PAQ3 archive (read file names from input) or (UNIX): ls | PAQ3 archive To decompress: PAQ3 archive To list contents: more < archive Compression: The files listed are compressed and stored in the archive, which is created. The archive must not already exist. File names may specify a path, which is stored. If there are no file names on the command line, then PAQ3 prompts for them, reading until the first blank line or end of file. Decompression: No file names are specified. The archive must exist. If a path is stored, the file is extracted to the appropriate directory, which must exist. PAQ3 does not create directories. If the file to be extracted already exists, it is not replaced; rather it is compared with the archived file, and the offset of the first difference is reported. It is not possible to add, remove, or update files in an existing archive. If you want to do this, extract the files, delete the archive, and create a new archive with just the files you want. PAQ3 is an improved version of PAQ1SSE/PAQ2 by Serge Osnach, who added SSE to my PAQ1 (both available at http://cs.fit.edu/~mmahoney/compression/ ). PAQ3 uses an improved SSE implementation, and adds update exclusion to the NonstationaryPPM and WordModel models. */ #include <algorithm> #include <cctype> #include <cmath> #include <cstdio> #include <cstdlib> #include <ctime> #include <new> #include <string> #include <vector> using std::set_new_handler; using std::string; using std::vector; const int MEM = 6; // 0-8 = 1M, 2M ... 256M memory model. 6 = 64M // 8-32 bit unsigned types, adjust as appropriate using U8 = unsigned char; using U16 = unsigned short; using U32 = unsigned int; class U24 { // 24-bit unsigned int U8 b0, b1, b2; // Low, mid, high byte public: explicit U24( int x = 0 ) : b0( x ), b1( x >> 8 ), b2( x >> 16 ) {} operator int() const { return ( ( ( b2 << 8 ) | b1 ) << 8 ) | b0; } }; // 32-bit random number generator based on r(i) = r(i-24) ^ r(i-55) class Random { U32 table[55]; // Last 55 random values int i{ 0 }; // Index of current random value in table public: Random(); U32 operator()() { // Return 32-bit random number if( ++i == 55 ) i = 0; if( i >= 24 ) return table[i] ^= table[i - 24]; return table[i] ^= table[i + 31]; } } rnd; Random::Random() { for( int j = 0; j < 55; ++j ) table[j] = 314159265 * j; for( int j = 0; j < 10000; ++j ) operator()(); } /* Model interface. A Predictor is made up of a collection of various models, whose outputs are summed to yield a prediction. Methods: Model.predict(int& n0, int& n1) - Adds to counts n0 and n1 such that it predicts the next bit will be a 1 with probability n1/(n0+n1) and confidence n0+n1. Model.update(int y) - Appends bit y (0 or 1) to the model. */ class Model { public: virtual void predict( int &n0, int &n1 ) const = 0; virtual void update( int y ) = 0; virtual ~Model() = default; }; /* Hash table element base class. It contains an 8-bit checksum to detect collisions, and a priority() method which is used to control replacement when full by replacing the element with the lowest priority (0 = unused). The derived class should supply the data to be stored and override priority(). */ class HashElement { U8 ch; // Checksum public: HashElement( int c = 0 ) : ch( c ) {} // Initialize the checksum, 0 = unused int checksum() const { return ch; } // Collision if not matched int priority() const { return static_cast<int>( ch != 0 ); } // Override: lowest replaced first }; /* 3 byte counter, shown for reference only. It implements a nonstationary pair of counters of 0s and 1s such that preference is given to recent history by discarding old bits. */ class Counter3 : public HashElement { U8 n[2]; // n[y] is the counts of ys (0s or 1s) public: Counter3( int c = 0 ) : HashElement( c ) { n[0] = n[1] = 0; } int get0() const { return n[0]; } // Return count of 0s int get1() const { return n[1]; } // Return count of 1s int priority() const { return get0() + get1(); } // For hash replacement void add( int y ) { // Add y (0 or 1) to n[y] and age the opposite count if( n[y] < 255 ) ++n[y]; if( n[1 - y] > 2 ) ( n[1 - y] /= 2 ) += 1; } }; /* Approximately equivalent 2 byte counter implementing the above. The representable counts (n0, n1) are 0-10, 12, 14, 16, 20, 24, 28, 32, 48, 64, 128, 256, 512. Both counts are represented by a single 8-bit state. Counts larger than 10 are incremented probabilistically. Although it uses 1/3 less memory, it is 8% slower and gives 0.05% worse compression than the 3 byte counter. */ class Counter : public HashElement { U8 state{ 0 }; struct E { // State table entry U16 n0, n1; // Counts represented by state U8 s00, s01; // Next state on input 0 without/with probabilistic incr. U8 s10, s11; // Next state on input 1 U32 p0, p1; // Probability of increment x 2^32-1 on inputs 0, 1 }; static E table[244]; // State table public: Counter( int c = 0 ) : HashElement( c ) {} int get0() const { return table[state].n0; } int get1() const { return table[state].n1; } int priority() const { return state; } void add( int y ) { if( y != 0 ) { if( state < 94 || rnd() < table[state].p1 ) state = table[state].s11; else state = table[state].s10; } else { if( state < 94 || rnd() < table[state].p0 ) state = table[state].s01; else state = table[state].s00; } } }; // State table generated by stategen.cpp Counter::E Counter::table[244] = { // n0 n1 s00 s01 s10 s11 p0 p1 state { 0, 0, 0, 2, 0, 1, 4294967295U, 4294967295U }, // 0 { 0, 1, 1, 4, 1, 3, 4294967295U, 4294967295U }, // 1 { 1, 0, 2, 5, 2, 4, 4294967295U, 4294967295U }, // 2 { 0, 2, 3, 7, 3, 6, 4294967295U, 4294967295U }, // 3 { 1, 1, 4, 8, 4, 7, 4294967295U, 4294967295U }, // 4 { 2, 0, 5, 9, 5, 8, 4294967295U, 4294967295U }, // 5 { 0, 3, 3, 7, 6, 10, 4294967295U, 4294967295U }, // 6 { 1, 2, 7, 12, 7, 11, 4294967295U, 4294967295U }, // 7 { 2, 1, 8, 13, 8, 12, 4294967295U, 4294967295U }, // 8 { 3, 0, 9, 14, 5, 8, 4294967295U, 4294967295U }, // 9 { 0, 4, 6, 11, 10, 15, 4294967295U, 4294967295U }, // 10 { 1, 3, 7, 12, 11, 16, 4294967295U, 4294967295U }, // 11 { 2, 2, 12, 18, 12, 17, 4294967295U, 4294967295U }, // 12 { 3, 1, 13, 19, 8, 12, 4294967295U, 4294967295U }, // 13 { 4, 0, 14, 20, 9, 13, 4294967295U, 4294967295U }, // 14 { 0, 5, 6, 11, 15, 21, 4294967295U, 4294967295U }, // 15 { 1, 4, 11, 17, 16, 22, 4294967295U, 4294967295U }, // 16 { 2, 3, 12, 18, 17, 23, 4294967295U, 4294967295U }, // 17 { 3, 2, 18, 25, 12, 17, 4294967295U, 4294967295U }, // 18 { 4, 1, 19, 26, 13, 18, 4294967295U, 4294967295U }, // 19 { 5, 0, 20, 27, 9, 13, 4294967295U, 4294967295U }, // 20 { 0, 6, 10, 16, 21, 28, 4294967295U, 4294967295U }, // 21 { 1, 5, 11, 17, 22, 29, 4294967295U, 4294967295U }, // 22 { 2, 4, 17, 24, 23, 30, 4294967295U, 4294967295U }, // 23 { 3, 3, 18, 25, 17, 23, 4294967295U, 4294967295U }, // 24 { 4, 2, 25, 33, 18, 24, 4294967295U, 4294967295U }, // 25 { 5, 1, 26, 34, 13, 18, 4294967295U, 4294967295U }, // 26 { 6, 0, 27, 35, 14, 19, 4294967295U, 4294967295U }, // 27 { 0, 7, 10, 16, 28, 36, 4294967295U, 4294967295U }, // 28 { 1, 6, 16, 23, 29, 37, 4294967295U, 4294967295U }, // 29 { 2, 5, 17, 24, 30, 38, 4294967295U, 4294967295U }, // 30 { 3, 4, 24, 32, 23, 30, 4294967295U, 4294967295U }, // 31 { 4, 3, 25, 33, 24, 31, 4294967295U, 4294967295U }, // 32 { 5, 2, 33, 42, 18, 24, 4294967295U, 4294967295U }, // 33 { 6, 1, 34, 43, 19, 25, 4294967295U, 4294967295U }, // 34 { 7, 0, 35, 44, 14, 19, 4294967295U, 4294967295U }, // 35 { 0, 8, 15, 22, 36, 45, 4294967295U, 4294967295U }, // 36 { 1, 7, 16, 23, 37, 46, 4294967295U, 4294967295U }, // 37 { 2, 6, 23, 31, 38, 47, 4294967295U, 4294967295U }, // 38 { 3, 5, 24, 32, 30, 38, 4294967295U, 4294967295U }, // 39 { 4, 4, 32, 41, 31, 39, 4294967295U, 4294967295U }, // 40 { 5, 3, 33, 42, 24, 31, 4294967295U, 4294967295U }, // 41 { 6, 2, 42, 52, 25, 32, 4294967295U, 4294967295U }, // 42 { 7, 1, 43, 53, 19, 25, 4294967295U, 4294967295U }, // 43 { 8, 0, 44, 54, 20, 26, 4294967295U, 4294967295U }, // 44 { 0, 9, 15, 22, 45, 94, 4294967295U, 4294967295U }, // 45 { 1, 8, 22, 30, 46, 55, 4294967295U, 4294967295U }, // 46 { 2, 7, 23, 31, 47, 56, 4294967295U, 4294967295U }, // 47 { 3, 6, 31, 40, 38, 47, 4294967295U, 4294967295U }, // 48 { 4, 5, 32, 41, 39, 48, 4294967295U, 4294967295U }, // 49 { 5, 4, 41, 51, 31, 39, 4294967295U, 4294967295U }, // 50 { 6, 3, 42, 52, 32, 40, 4294967295U, 4294967295U }, // 51 { 7, 2, 52, 62, 25, 32, 4294967295U, 4294967295U }, // 52 { 8, 1, 53, 63, 26, 33, 4294967295U, 4294967295U }, // 53 { 9, 0, 54, 95, 20, 26, 4294967295U, 4294967295U }, // 54 { 1, 9, 22, 30, 55, 96, 4294967295U, 4294967295U }, // 55 { 2, 8, 30, 39, 56, 64, 4294967295U, 4294967295U }, // 56 { 3, 7, 31, 40, 47, 56, 4294967295U, 4294967295U }, // 57 { 4, 6, 40, 50, 48, 57, 4294967295U, 4294967295U }, // 58 { 5, 5, 41, 51, 39, 48, 4294967295U, 4294967295U }, // 59 { 6, 4, 51, 61, 40, 49, 4294967295U, 4294967295U }, // 60 { 7, 3, 52, 62, 32, 40, 4294967295U, 4294967295U }, // 61 { 8, 2, 62, 71, 33, 41, 4294967295U, 4294967295U }, // 62 { 9, 1, 63, 97, 26, 33, 4294967295U, 4294967295U }, // 63 { 2, 9, 30, 39, 64, 99, 4294967295U, 4294967295U }, // 64 { 3, 8, 39, 49, 56, 64, 4294967295U, 4294967295U }, // 65 { 4, 7, 40, 50, 57, 65, 4294967295U, 4294967295U }, // 66 { 5, 6, 50, 60, 48, 57, 4294967295U, 4294967295U }, // 67 { 6, 5, 51, 61, 49, 58, 4294967295U, 4294967295U }, // 68 { 7, 4, 61, 70, 40, 49, 4294967295U, 4294967295U }, // 69 { 8, 3, 62, 71, 41, 50, 4294967295U, 4294967295U }, // 70 { 9, 2, 71, 100, 33, 41, 4294967295U, 4294967295U }, // 71 { 3, 9, 39, 49, 64, 99, 4294967295U, 4294967295U }, // 72 { 4, 8, 49, 59, 65, 72, 4294967295U, 4294967295U }, // 73 { 5, 7, 50, 60, 57, 65, 4294967295U, 4294967295U }, // 74 { 6, 6, 60, 69, 58, 66, 4294967295U, 4294967295U }, // 75 { 7, 5, 61, 70, 49, 58, 4294967295U, 4294967295U }, // 76 { 8, 4, 70, 78, 50, 59, 4294967295U, 4294967295U }, // 77 { 9, 3, 71, 100, 41, 50, 4294967295U, 4294967295U }, // 78 { 4, 9, 49, 59, 72, 103, 4294967295U, 4294967295U }, // 79 { 5, 8, 59, 68, 65, 72, 4294967295U, 4294967295U }, // 80 { 6, 7, 60, 69, 66, 73, 4294967295U, 4294967295U }, // 81 { 7, 6, 69, 77, 58, 66, 4294967295U, 4294967295U }, // 82 { 8, 5, 70, 78, 59, 67, 4294967295U, 4294967295U }, // 83 { 9, 4, 78, 104, 50, 59, 4294967295U, 4294967295U }, // 84 { 5, 9, 59, 68, 72, 103, 4294967295U, 4294967295U }, // 85 { 7, 7, 69, 77, 66, 73, 4294967295U, 4294967295U }, // 86 { 9, 5, 78, 104, 59, 67, 4294967295U, 4294967295U }, // 87 { 6, 9, 68, 76, 79, 108, 4294967295U, 4294967295U }, // 88 { 9, 6, 84, 109, 67, 74, 4294967295U, 4294967295U }, // 89 { 7, 9, 76, 83, 79, 108, 4294967295U, 4294967295U }, // 90 { 9, 7, 84, 109, 74, 80, 4294967295U, 4294967295U }, // 91 { 8, 9, 83, 87, 85, 114, 4294967295U, 4294967295U }, // 92 { 9, 8, 87, 115, 80, 85, 4294967295U, 4294967295U }, // 93 { 0, 10, 21, 29, 94, 98, 4294967295U, 2147483647U }, // 94 { 10, 0, 95, 101, 27, 34, 2147483647U, 4294967295U }, // 95 { 1, 10, 29, 38, 96, 102, 4294967295U, 2147483647U }, // 96 { 10, 1, 97, 105, 34, 42, 2147483647U, 4294967295U }, // 97 { 0, 12, 28, 37, 98, 106, 4294967295U, 2147483647U }, // 98 { 2, 10, 38, 48, 99, 107, 4294967295U, 2147483647U }, // 99 { 10, 2, 100, 110, 42, 51, 2147483647U, 4294967295U }, // 100 { 12, 0, 101, 111, 35, 43, 2147483647U, 4294967295U }, // 101 { 1, 12, 37, 47, 102, 112, 4294967295U, 2147483647U }, // 102 { 3, 10, 48, 58, 99, 107, 4294967295U, 2147483647U }, // 103 { 10, 3, 100, 110, 51, 60, 2147483647U, 4294967295U }, // 104 { 12, 1, 105, 117, 43, 52, 2147483647U, 4294967295U }, // 105 { 0, 14, 36, 46, 106, 118, 4294967295U, 2147483647U }, // 106 { 2, 12, 47, 57, 107, 119, 4294967295U, 2147483647U }, // 107 { 4, 10, 58, 67, 103, 113, 4294967295U, 2147483647U }, // 108 { 10, 4, 104, 116, 60, 68, 2147483647U, 4294967295U }, // 109 { 12, 2, 110, 122, 52, 61, 2147483647U, 4294967295U }, // 110 { 14, 0, 111, 123, 44, 53, 2147483647U, 4294967295U }, // 111 { 1, 14, 46, 56, 112, 124, 4294967295U, 2147483647U }, // 112 { 3, 12, 57, 66, 107, 119, 4294967295U, 2147483647U }, // 113 { 5, 10, 67, 75, 103, 113, 4294967295U, 2147483647U }, // 114 { 10, 5, 104, 116, 68, 75, 2147483647U, 4294967295U }, // 115 { 12, 3, 110, 122, 61, 69, 2147483647U, 4294967295U }, // 116 { 14, 1, 117, 129, 53, 62, 2147483647U, 4294967295U }, // 117 { 0, 16, 45, 55, 118, 138, 4294967295U, 1073741823U }, // 118 { 2, 14, 56, 65, 119, 130, 4294967295U, 2147483647U }, // 119 { 4, 12, 66, 74, 113, 125, 4294967295U, 2147483647U }, // 120 { 12, 4, 116, 128, 69, 76, 2147483647U, 4294967295U }, // 121 { 14, 2, 122, 135, 62, 70, 2147483647U, 4294967295U }, // 122 { 16, 0, 123, 141, 54, 63, 1073741823U, 4294967295U }, // 123 { 1, 16, 55, 64, 124, 142, 4294967295U, 1073741823U }, // 124 { 3, 14, 65, 73, 119, 130, 4294967295U, 2147483647U }, // 125 { 5, 12, 74, 81, 113, 125, 4294967295U, 2147483647U }, // 126 { 12, 5, 116, 128, 76, 82, 2147483647U, 4294967295U }, // 127 { 14, 3, 122, 135, 70, 77, 2147483647U, 4294967295U }, // 128 { 16, 1, 129, 145, 63, 71, 1073741823U, 4294967295U }, // 129 { 2, 16, 64, 72, 130, 146, 4294967295U, 1073741823U }, // 130 { 4, 14, 73, 80, 125, 136, 4294967295U, 2147483647U }, // 131 { 6, 12, 81, 86, 120, 131, 4294967295U, 2147483647U }, // 132 { 12, 6, 121, 134, 82, 86, 2147483647U, 4294967295U }, // 133 { 14, 4, 128, 137, 77, 83, 2147483647U, 4294967295U }, // 134 { 16, 2, 135, 149, 71, 78, 1073741823U, 4294967295U }, // 135 { 3, 16, 72, 79, 130, 146, 4294967295U, 1073741823U }, // 136 { 16, 3, 135, 149, 78, 84, 1073741823U, 4294967295U }, // 137 { 0, 20, 94, 96, 138, 154, 4294967295U, 1073741823U }, // 138 { 4, 16, 79, 85, 136, 150, 4294967295U, 1073741823U }, // 139 { 16, 4, 137, 153, 84, 87, 1073741823U, 4294967295U }, // 140 { 20, 0, 141, 157, 95, 97, 1073741823U, 4294967295U }, // 141 { 1, 20, 96, 99, 142, 158, 4294967295U, 1073741823U }, // 142 { 5, 16, 85, 88, 136, 150, 4294967295U, 1073741823U }, // 143 { 16, 5, 137, 153, 87, 89, 1073741823U, 4294967295U }, // 144 { 20, 1, 145, 159, 97, 100, 1073741823U, 4294967295U }, // 145 { 2, 20, 99, 103, 146, 160, 4294967295U, 1073741823U }, // 146 { 6, 16, 88, 90, 139, 155, 4294967295U, 1073741823U }, // 147 { 16, 6, 140, 156, 89, 91, 1073741823U, 4294967295U }, // 148 { 20, 2, 149, 161, 100, 104, 1073741823U, 4294967295U }, // 149 { 3, 20, 103, 108, 146, 160, 4294967295U, 1073741823U }, // 150 { 7, 16, 90, 92, 139, 155, 4294967295U, 1073741823U }, // 151 { 16, 7, 140, 156, 91, 93, 1073741823U, 4294967295U }, // 152 { 20, 3, 149, 161, 104, 109, 1073741823U, 4294967295U }, // 153 { 0, 24, 98, 102, 154, 164, 4294967295U, 1073741823U }, // 154 { 4, 20, 108, 114, 150, 162, 4294967295U, 1073741823U }, // 155 { 20, 4, 153, 163, 109, 115, 1073741823U, 4294967295U }, // 156 { 24, 0, 157, 167, 101, 105, 1073741823U, 4294967295U }, // 157 { 1, 24, 102, 107, 158, 168, 4294967295U, 1073741823U }, // 158 { 24, 1, 159, 171, 105, 110, 1073741823U, 4294967295U }, // 159 { 2, 24, 107, 113, 160, 172, 4294967295U, 1073741823U }, // 160 { 24, 2, 161, 173, 110, 116, 1073741823U, 4294967295U }, // 161 { 3, 24, 113, 120, 160, 172, 4294967295U, 1073741823U }, // 162 { 24, 3, 161, 173, 116, 121, 1073741823U, 4294967295U }, // 163 { 0, 28, 106, 112, 164, 176, 4294967295U, 1073741823U }, // 164 { 4, 24, 120, 126, 162, 174, 4294967295U, 1073741823U }, // 165 { 24, 4, 163, 175, 121, 127, 1073741823U, 4294967295U }, // 166 { 28, 0, 167, 177, 111, 117, 1073741823U, 4294967295U }, // 167 { 1, 28, 112, 119, 168, 178, 4294967295U, 1073741823U }, // 168 { 5, 24, 126, 132, 162, 174, 4294967295U, 1073741823U }, // 169 { 24, 5, 163, 175, 127, 133, 1073741823U, 4294967295U }, // 170 { 28, 1, 171, 179, 117, 122, 1073741823U, 4294967295U }, // 171 { 2, 28, 119, 125, 172, 180, 4294967295U, 1073741823U }, // 172 { 28, 2, 173, 181, 122, 128, 1073741823U, 4294967295U }, // 173 { 3, 28, 125, 131, 172, 180, 4294967295U, 1073741823U }, // 174 { 28, 3, 173, 181, 128, 134, 1073741823U, 4294967295U }, // 175 { 0, 32, 118, 124, 176, 190, 4294967295U, 268435455U }, // 176 { 32, 0, 177, 191, 123, 129, 268435455U, 4294967295U }, // 177 { 1, 32, 124, 130, 178, 192, 4294967295U, 268435455U }, // 178 { 32, 1, 179, 193, 129, 135, 268435455U, 4294967295U }, // 179 { 2, 32, 130, 136, 180, 194, 4294967295U, 268435455U }, // 180 { 32, 2, 181, 195, 135, 137, 268435455U, 4294967295U }, // 181 { 3, 32, 136, 139, 180, 194, 4294967295U, 268435455U }, // 182 { 32, 3, 181, 195, 137, 140, 268435455U, 4294967295U }, // 183 { 4, 32, 139, 143, 182, 196, 4294967295U, 268435455U }, // 184 { 32, 4, 183, 197, 140, 144, 268435455U, 4294967295U }, // 185 { 5, 32, 143, 147, 182, 196, 4294967295U, 268435455U }, // 186 { 32, 5, 183, 197, 144, 148, 268435455U, 4294967295U }, // 187 { 6, 32, 147, 151, 184, 198, 4294967295U, 268435455U }, // 188 { 32, 6, 185, 199, 148, 152, 268435455U, 4294967295U }, // 189 { 0, 48, 154, 158, 190, 200, 4294967295U, 268435455U }, // 190 { 48, 0, 191, 201, 157, 159, 268435455U, 4294967295U }, // 191 { 1, 48, 158, 160, 192, 202, 4294967295U, 268435455U }, // 192 { 48, 1, 193, 203, 159, 161, 268435455U, 4294967295U }, // 193 { 2, 48, 160, 162, 194, 204, 4294967295U, 268435455U }, // 194 { 48, 2, 195, 205, 161, 163, 268435455U, 4294967295U }, // 195 { 3, 48, 162, 165, 194, 204, 4294967295U, 268435455U }, // 196 { 48, 3, 195, 205, 163, 166, 268435455U, 4294967295U }, // 197 { 4, 48, 165, 169, 196, 206, 4294967295U, 268435455U }, // 198 { 48, 4, 197, 207, 166, 170, 268435455U, 4294967295U }, // 199 { 0, 64, 176, 178, 200, 212, 4294967295U, 134217727U }, // 200 { 64, 0, 201, 213, 177, 179, 134217727U, 4294967295U }, // 201 { 1, 64, 178, 180, 202, 214, 4294967295U, 134217727U }, // 202 { 64, 1, 203, 215, 179, 181, 134217727U, 4294967295U }, // 203 { 2, 64, 180, 182, 204, 216, 4294967295U, 134217727U }, // 204 { 64, 2, 205, 217, 181, 183, 134217727U, 4294967295U }, // 205 { 3, 64, 182, 184, 204, 216, 4294967295U, 134217727U }, // 206 { 64, 3, 205, 217, 183, 185, 134217727U, 4294967295U }, // 207 { 4, 64, 184, 186, 206, 218, 4294967295U, 134217727U }, // 208 { 64, 4, 207, 219, 185, 187, 134217727U, 4294967295U }, // 209 { 5, 64, 186, 188, 206, 218, 4294967295U, 134217727U }, // 210 { 64, 5, 207, 219, 187, 189, 134217727U, 4294967295U }, // 211 { 0, 96, 190, 192, 212, 220, 4294967295U, 134217727U }, // 212 { 96, 0, 213, 221, 191, 193, 134217727U, 4294967295U }, // 213 { 1, 96, 192, 194, 214, 222, 4294967295U, 134217727U }, // 214 { 96, 1, 215, 223, 193, 195, 134217727U, 4294967295U }, // 215 { 2, 96, 194, 196, 216, 224, 4294967295U, 134217727U }, // 216 { 96, 2, 217, 225, 195, 197, 134217727U, 4294967295U }, // 217 { 3, 96, 196, 198, 216, 224, 4294967295U, 134217727U }, // 218 { 96, 3, 217, 225, 197, 199, 134217727U, 4294967295U }, // 219 { 0, 128, 200, 202, 220, 230, 4294967295U, 33554431U }, // 220 { 128, 0, 221, 231, 201, 203, 33554431U, 4294967295U }, // 221 { 1, 128, 202, 204, 222, 232, 4294967295U, 33554431U }, // 222 { 128, 1, 223, 233, 203, 205, 33554431U, 4294967295U }, // 223 { 2, 128, 204, 206, 224, 234, 4294967295U, 33554431U }, // 224 { 128, 2, 225, 235, 205, 207, 33554431U, 4294967295U }, // 225 { 3, 128, 206, 208, 224, 234, 4294967295U, 33554431U }, // 226 { 128, 3, 225, 235, 207, 209, 33554431U, 4294967295U }, // 227 { 4, 128, 208, 210, 226, 236, 4294967295U, 33554431U }, // 228 { 128, 4, 227, 237, 209, 211, 33554431U, 4294967295U }, // 229 { 0, 256, 220, 222, 230, 238, 4294967295U, 16777215U }, // 230 { 256, 0, 231, 239, 221, 223, 16777215U, 4294967295U }, // 231 { 1, 256, 222, 224, 232, 240, 4294967295U, 16777215U }, // 232 { 256, 1, 233, 241, 223, 225, 16777215U, 4294967295U }, // 233 { 2, 256, 224, 226, 234, 242, 4294967295U, 16777215U }, // 234 { 256, 2, 235, 243, 225, 227, 16777215U, 4294967295U }, // 235 { 3, 256, 226, 228, 234, 242, 4294967295U, 16777215U }, // 236 { 256, 3, 235, 243, 227, 229, 16777215U, 4294967295U }, // 237 { 0, 512, 230, 232, 238, 238, 4294967295U, 0U }, // 238 { 512, 0, 239, 239, 231, 233, 0U, 4294967295U }, // 239 { 1, 512, 232, 234, 240, 240, 4294967295U, 0U }, // 240 { 512, 1, 241, 241, 233, 235, 0U, 4294967295U }, // 241 { 2, 512, 234, 236, 242, 242, 4294967295U, 0U }, // 242 { 512, 2, 243, 243, 235, 237, 0U, 4294967295U } // 243 }; /* Hashtable<T, N, M> is a hash table of 2^N elements of type T (derived from HashElement) with linear search of M elements in case of collision. If all elements collide, then the one with the lowest .priority() is replaced. Hashtable[i] returns a T& indexed by the lower bits of i whose checksum matches the upper bits of i, creating or replacing if needed. */ template <class T, int N, int M = 3> class Hashtable { private: T *table; // Array of 2^N+M elements Hashtable( const Hashtable & ) = delete; // No copy Hashtable &operator=( const Hashtable & ) = delete; // No assignment public: Hashtable() : table( new Counter[( 1 << N ) + M] ) {} T &operator[]( U32 i ); ~Hashtable() { delete[] table; } }; template <class T, int N, int M> inline T &Hashtable<T, N, M>::operator[]( U32 i ) { const U32 lb = i & ( ( 1 << N ) - 1 ); // Lower bound of search range const U32 ub = lb + M; // Upper bound + 1 const int checksum = i >> 24; int bj = lb; int bget = 1000000000; for( U32 j = lb; j < ub; ++j ) { T &c = table[j]; int g = c.priority(); if( g == 0 ) return c = T( checksum ); if( checksum == c.checksum() ) return c; if( g < bget ) { bget = g; bj = j; } } return table[bj] = T( checksum ); } /* A NonstationaryPPM model guesses the next bit by finding all matching contexts of n = 1 to 8 bytes (including the last partial byte of 0-7 bits) and guessing for each match that the next bit will be the same with weight n^2/f(age). The function f(age) decays the count of 0s or 1s for each context by half whenever there are more than 2 and the opposite bit is observed. This is an approximation of the nonstationary model, weight = 1/(t*variance) where t is the number of subsequent observations and the variance is tp(1-p) for t observations and p the probability of a 1 bit given the last t observations. The aged counts are stored in a hash table of contexts. */ class NonstationaryPPM : public Model { enum { N = 8 }; // Number of contexts int c0{ 1 }; // Current 0-7 bits of input with a leading 1 int c1{ 0 }; // Previous whole byte int cn{ 1 }; // c0 mod 53 (low bits of hash) vector<Counter> counter0; // Counters for context lengths 0 and 1 vector<Counter> counter1; Hashtable<Counter, 18 + MEM> counter2; // for lengths 2 to N-1 Counter *cp[N]; // Pointers to current counters U32 hash[N]; // Hashes of last 0 to N-1 bytes public: inline void predict( int &n0, int &n1 ) const override; // Add to counts of 0s and 1s inline void update( int y ) override; // Append bit y (0 or 1) to model NonstationaryPPM(); int getc0() const { return c0; } }; NonstationaryPPM::NonstationaryPPM() : counter0( 256 ), counter1( 65536 ) { for( int i = 0; i < N; ++i ) { cp[i] = &counter0[0]; hash[i] = 0; } } void NonstationaryPPM::predict( int &n0, int &n1 ) const { for( int i = 0; i < N; ++i ) { const int wt = ( i + 1 ) * ( i + 1 ); n0 += cp[i]->get0() * wt; n1 += cp[i]->get1() * wt; } } // Add bit y (0 or 1) to model void NonstationaryPPM::update( int y ) { // Count y by context for( int i = N - 1; i >= 0; --i ) { cp[i]->add( y ); if( ( cp[i]->get0() + cp[i]->get1() ) * i > 100 ) { // Update exclusion cp[i]->add( y ); break; } } // Store bit y cn += cn + y; if( cn >= 53 ) cn -= 53; c0 += c0 + y; if( c0 >= 256 ) { // Start new byte for( int i = N - 1; i > 0; --i ) hash[i] = ( hash[i - 1] + c0 ) * 987660757; c1 = c0 - 256; c0 = 1; cn = 1; } // Set up pointers to next counters cp[0] = &counter0[c0]; cp[1] = &counter1[c0 + ( c1 << 8 )]; for( int i = 2; i < N; ++i ) cp[i] = &counter2[hash[i] + cn + ( c0 << 24 )]; } /* A MatchModel looks for a match of length n = 8 bytes or more between the current context and previous input and guesses that the next bit will be the same with weight 3n^2. Matches are found in a 4MB rotating buffer using a 1M hash table of pointers. */ class MatchModel : public Model { vector<U8> buf; // Input buffer, wraps at end vector<U24> ptr; // Hash table of pointers U32 hash{ 0 }; // Hash of current context up to pos-1 int pos{ 0 }; // Element of buf where next bit will be stored int bpos{ 0 }; // Number of bits (0-7) stored at buf[pos] int begin{ 0 }; // Points to first matching byte (does not wrap) int end{ 0 }; // Points to last matching byte + 1, 0 if no match public: MatchModel() : buf( 0x10000 * ( 1 << MEM ) ), ptr( 0x4000 * ( 1 << MEM ) ) {} void predict( int &n0, int &n1 ) const override { if( end != 0 ) { int wt = end - begin; if( wt > 1000 ) wt = 3000000; else wt *= wt * 3; if( ( ( buf[end] >> ( 7 - bpos ) ) & 1 ) != 0 ) n1 += wt; else n0 += wt; } } // Append bit y to buf and check that it matches at the end. // After a byte is completed, compute a new hash and store it. // If there is no current match, search for one. void update( int y ) override { ( buf[pos] <<= 1 ) += y; // Store bit ++bpos; if( ( end != 0 ) && ( buf[end] >> ( 8 - bpos ) ) != buf[pos] ) // Does it match? begin = end = 0; // no if( bpos == 8 ) { // New byte bpos = 0; hash = hash * ( 16 * 123456791 ) + buf[pos] + 1; if( ++pos == int( buf.size() ) ) pos = 0; if( end != 0 ) ++end; else { // If no match, search for one U32 h = ( hash ^ ( hash >> 16 ) ) & ( ptr.size() - 1 ); end = ptr[h]; if( end > 0 ) { begin = end; int p = pos; while( begin > 0 && p > 0 && begin != p + 1 && buf[begin - 1] == buf[p - 1] ) { --begin; --p; } } if( end == begin ) // No match found begin = end = 0; ptr[h] = U24( pos ); } } } }; /* A WordModel predicts in the context of whole words (a-z, case insensitive) using a trigram model. */ class WordModel { private: U32 word1{ 0 }, word0{ 0 }; // Hash of previous and current word int ww1{ 0 }, ww0{ 0 }; // Word weights (lengths) Hashtable<Counter, 16 + MEM> t1; // Model int c1{ 0 }; // Previous char, lower case int c0{ 1 }; // 0-7 bits of current char with leading 1 bit int c0h{ 1 }; // Small hash of c0 Counter *cp0, *cp1; // Points into t1 current context int lettercount{ 0 }; // For detecting English enum { THRESHOLD = 5 }; // lettercount threshold for English public: WordModel() : cp0( &t1[0] ), cp1( &t1[0] ) {} void predict( int &n0, int &n1 ) const { if( lettercount >= THRESHOLD ) { const int wt0 = ( ww0 + 1 ) * ( ww0 + 1 ); n0 += cp0->get0() * wt0; n1 += cp0->get1() * wt0; const int wt1 = ( ww0 + ww1 + 2 ) * ( ww0 + ww1 + 2 ); n0 += cp1->get0() * wt1; n1 += cp1->get1() * wt1; } } void update( int y ) { if( lettercount >= THRESHOLD ) { cp1->add( y ); if( cp1->get0() + cp1->get1() < 100 ) cp0->add( y ); } // Update contexts with next bit c0 += c0 + y; c0h += c0h + y; if( c0h >= 59 ) c0h -= 59; if( c0 >= 256 ) { c0 -= 256; if( lettercount > 0 && ( c0 > 127 || ( c0 < 32 && c0 != '\n' && c0 != '\r' && c0 != '\t' ) ) ) --lettercount; if( isalpha( c0 ) != 0 ) { word0 = ( word0 + tolower( c0 ) + 1 ) * 234577751 * 16; if( ++ww0 > 8 ) ww0 = 8; if( lettercount < THRESHOLD * 2 ) ++lettercount; } else if( word0 != 0U ) { ww1 = ww0; ww0 = 0; word1 = word0; word0 = 0; } c1 = c0; c0 = 1; c0h = 1; } // Set up pointers to new contexts if( lettercount >= THRESHOLD ) { U32 h = word0 * 123456791 + c1 * 345689647 + c0h + ( c0 << 24 ); cp0 = &t1[h]; cp1 = &t1[word1 + h]; } } }; /* CyclicModel models data with fixed length records such as tables, databases, images, audio, binary numeric data, etc. It models runs of 0s or 1s in bit columns. A table is detected when an 8-bit pattern occurs 4 or more times in a row spaced by the same interval. The table ends after no repetition detection for the same number of bits as were in the table. */ class CyclicModel : public Model { struct E { int p{ 0 }, n{ 0 }, r{ 0 }; // Position of last match, number of matches, interval E() = default; }; vector<E> cpos; // Table of repeat patterns by char int pos{ 0 }; // Current bit position in input int c0{ 1 }; // Last 8 bits int cycle{ 0 }; // Most likely number of columns int column{ 0 }; // Column number, 0 to cycle-1 int size{ 0 }; // Number of bits before the table expires, 0 to 3*cycle Hashtable<Counter, 15> t; // Context is last 8 bits in column vector<Counter> t1; // Context is the column number only Counter *cp, *cp1; // Points to t, t1 public: CyclicModel() : cpos( 256 ), t1( 2048 ), cp( &t[0] ), cp1( &t1[0] ) {} void predict( int &n0, int &n1 ) const override { if( cycle > 0 ) { int wt = 16; n0 += cp->get0() * wt; n1 += cp->get1() * wt; wt = 4; n0 += cp1->get0() * wt; n1 += cp1->get1() * wt; } } void update( int y ) override { if( ++column >= cycle ) column = 0; if( size > 0 && --size == 0 ) cycle = 0; cp->add( y ); cp1->add( y ); c0 = ( c0 + c0 + y ) & 0xff; ++pos; E &e = cpos[c0]; if( e.p + e.r == pos ) { ++e.n; if( e.n > 3 && e.r > 8 && e.r * e.n > size ) { size = e.r * e.n; if( cycle != e.r ) { cycle = e.r; column = pos % cycle; } } } else { e.n = 1; e.r = pos - e.p; } e.p = pos; int h = column * 3 + c0 * 876546821; cp = &t[h]; cp1 = &t1[column & 2047]; } }; // Secondary source encoder struct SSEContext { U8 c1, n; // Count of 1's, count of bits U16 p() const { return U32( 65535 ) * ( c1 * 64 + 1 ) / ( n * 64 + 2 ); } void update( int y ) { if( y != 0 ) ++c1; if( ++n > 254 ) { c1 /= 2; n /= 2; } } }; const int SSE1 = 256 * 3 * 3 * 3 * 3, SSE2 = 32; // dimensions const int SSESCALE = 1024 / SSE2; SSEContext sse[SSE1][SSE2 + 1]; // [context][mapped probability] // Scale probability p (0 to 64K-1) into a context in the range 0 to 1K-1 class SSEMap { enum { N = 4096 }; U16 table[N]; public: int operator()( int p ) const { return table[p / ( 65536 / N )]; } SSEMap(); } ssemap; // global functoid SSEMap::SSEMap() { for( int i = 0; i < N; ++i ) { int p = int( 64 * log( ( i + 0.5 ) / ( N - 0.5 - i ) ) + 512 ); if( p > 1023 ) p = 1023; if( p < 0 ) p = 0; table[i] = p; } } /* A Predictor predicts the next bit given the bits so far using a collection of models. Methods: p() returns probability of a 1 being the next bit, P(y = 1) as a 16 bit number (0 to 64K-1). update(y) updates the models with bit y (0 or 1) */ class Predictor { NonstationaryPPM m1; MatchModel m2; WordModel m3; CyclicModel m4; mutable int context, ssep; public: Predictor(); ~Predictor(); U16 p() const { int n0 = 1; int n1 = n0; context = m1.getc0(); m4.predict( n0, n1 ); context = context * 3 + static_cast<int>( n0 * 2 > n1 ) + static_cast<int>( n0 > n1 * 2 ); m2.predict( n0, n1 ); context = context * 3 + static_cast<int>( n0 * 4 > n1 ) + static_cast<int>( n0 > n1 * 4 ); m3.predict( n0, n1 ); context = context * 3 + static_cast<int>( n0 * 8 > n1 ) + static_cast<int>( n0 > n1 * 8 ); m1.predict( n0, n1 ); context = context * 3 + static_cast<int>( n0 * 16 > n1 ) + static_cast<int>( n0 > n1 * 16 ); int n = n0 + n1; while( n > 32767 ) { n1 /= 16; n /= 16; } U16 pr = 65535 * n1 / n; ssep = ssemap( pr ); int wt = ssep % SSESCALE; int i = ssep / SSESCALE; return ( ( ( sse[context][i].p() * ( SSESCALE - wt ) + sse[context][i + 1].p() * wt ) / SSESCALE ) * 3 + pr ) / 4; } void update( int y ) { m1.update( y ); m2.update( y ); m3.update( y ); m4.update( y ); sse[context][ssep / SSESCALE].update( y ); sse[context][ssep / SSESCALE + 1].update( y ); } }; Predictor::Predictor() { int N = 4096; int oldp = SSE2 + 1; for( int i = N - 1; i >= 0; --i ) { int p = ( ssemap( i * 65536 / N ) + SSESCALE / 2 ) / SSESCALE; int n = 1 + N * N / ( ( i + 1 ) * ( N - i ) ); if( n > 254 ) n = 254; int c1 = ( i * n + N / 2 ) / N; for( int j = oldp - 1; j >= p; --j ) { for( auto &k: sse ) { k[j].n = n; k[j].c1 = c1; } } oldp = p; } } Predictor::~Predictor() { /* for (int i=0; i<SSE1; ++i) { for (int j=0; j<SSE2; ++j) { printf("%d/%d ", sse[i][j].c1, sse[i][j].n); } printf("\n"); } */ } /* An Encoder does arithmetic encoding. Methods: Encoder(COMPRESS, f) creates encoder for compression to archive f, which must be open for writing in binary mode Encoder(DECOMPRESS, f) creates encoder for decompression from archive f, which must be open for reading in binary mode encode(bit) in COMPRESS mode compresses bit to file f. decode() in DECOMPRESS mode returns the next decompressed bit from file f. flush() should be called when there is no more to compress */ typedef enum { COMPRESS, DECOMPRESS } Mode; class Encoder { private: Predictor predictor; const Mode mode; // Compress or decompress? FILE *archive; // Compressed data file U32 x1, x2; // Range, initially [0, 1), scaled by 2^32 U32 x; // Last 4 input bytes of archive. public: Encoder( Mode m, FILE *f ); void encode( int y ); int decode(); void flush(); }; // Constructor Encoder::Encoder( Mode m, FILE *f ) : predictor(), mode( m ), archive( f ), x1( 0 ), x2( 0xffffffff ), x( 0 ) { // In DECOMPRESS mode, initialize x to the first 4 bytes of the archive if( mode == DECOMPRESS ) { for( int i = 0; i < 4; ++i ) { int c = getc( archive ); x = ( x << 8 ) + ( c & 0xff ); } } } /* encode(y) -- Encode bit y by splitting the range [x1, x2] in proportion to P(1) and P(0) as given by the predictor and narrowing to the appropriate subrange. Output leading bytes of the range as they become known. */ inline void Encoder::encode( int y ) { // Split the range const U32 p = predictor.p(); // Probability P(1) * 64K rounded down const U32 xdiff = x2 - x1; U32 xmid = x1; // = x1+p*(x2-x1) multiply without overflow, round down if( xdiff >= 0x10000000 ) xmid += ( xdiff >> 16 ) * p; else if( xdiff >= 0x1000000 ) xmid += ( ( xdiff >> 12 ) * p ) >> 4; else if( xdiff >= 0x100000 ) xmid += ( ( xdiff >> 8 ) * p ) >> 8; else if( xdiff >= 0x10000 ) xmid += ( ( xdiff >> 4 ) * p ) >> 12; else xmid += ( xdiff * p ) >> 16; // Update the range if( y != 0 ) x2 = xmid; else x1 = xmid + 1; predictor.update( y ); // Shift equal MSB's out while( ( ( x1 ^ x2 ) & 0xff000000 ) == 0 ) { putc( x2 >> 24, archive ); x1 <<= 8; x2 = ( x2 << 8 ) + 255; } } /* Decode one bit from the archive, splitting [x1, x2] as in the encoder and returning 1 or 0 depending on which subrange the archive point x is in. */ inline int Encoder::decode() { // Split the range const U32 p = predictor.p(); // Probability P(1) * 64K rounded down const U32 xdiff = x2 - x1; U32 xmid = x1; // = x1+p*(x2-x1) multiply without overflow, round down if( xdiff >= 0x10000000 ) xmid += ( xdiff >> 16 ) * p; else if( xdiff >= 0x1000000 ) xmid += ( ( xdiff >> 12 ) * p ) >> 4; else if( xdiff >= 0x100000 ) xmid += ( ( xdiff >> 8 ) * p ) >> 8; else if( xdiff >= 0x10000 ) xmid += ( ( xdiff >> 4 ) * p ) >> 12; else xmid += ( xdiff * p ) >> 16; // Update the range int y = 0; if( x <= xmid ) { y = 1; x2 = xmid; } else x1 = xmid + 1; predictor.update( y ); // Shift equal MSB's out while( ( x1 >> 24 ) == ( x2 >> 24 ) ) { x1 <<= 8; x2 = ( x2 << 8 ) + 255; x = ( x << 8 ) + getc( archive ); } return y; } // Should be called when there is no more to compress void Encoder::flush() { // In COMPRESS mode, write out the remaining bytes of x, x1 < x < x2 if( mode == COMPRESS ) { while( ( ( x1 ^ x2 ) & 0xff000000 ) == 0 ) { putc( x2 >> 24, archive ); x1 <<= 8; x2 = ( x2 << 8 ) + 255; } putc( x2 >> 24, archive ); // First unequal byte } } // Read one byte from encoder e int decompress( Encoder &e ) { // Decompress 8 bits, MSB first int c = 0; for( int i = 0; i < 8; ++i ) c = c + c + e.decode(); return c; } // Write one byte c to encoder e void compress( Encoder &e, int c ) { for( int i = 7; i >= 0; --i ) e.encode( ( c >> i ) & 1 ); } // Fail if out of memory void handler() { printf( "Out of memory\n" ); exit( 1 ); } // Read and return a line of input from FILE f (default stdin) up to // first control character except tab. Skips CR in CR LF. string getline( FILE *f = stdin ) { int c = 0; string result; while( ( c = getc( f ) ) != EOF && ( c >= 32 || c == '\t' ) ) result += char( c ); if( c == '\r' ) ( void ) getc( f ); return result; } // User interface int main( int argc, char **argv ) { set_new_handler( handler ); // Check arguments if( argc < 2 ) { printf( "PAQ3 file compressor/archiver, (C) 2003, Matt Mahoney, mmahoney@cs.fit.edu\n" "This program is free software distributed without warranty under the terms\n" "of the GNU General Public License, see http://www.gnu.org/licenses/gpl.txt\n" "\n" "To compress: PAQ3 archive filenames... (archive will be created)\n" " or (MSDOS): dir/b | PAQ3 archive (reads file names from input)\n" "To extract/compare: PAQ3 archive (does not clobber existing files)\n" "To view contents: more < archive\n" ); return 1; } // File names and sizes from input or archive vector<string> filename; // List of names vector<long> filesize; // Size or -1 if error int start_time = clock(); int uncompressed_bytes = 0; int compressed_bytes = 0; // Input, output sizes // Extract files FILE *archive = fopen( argv[1], "rbe" ); if( archive != nullptr ) { if( argc > 2 ) { printf( "File %s already exists\n", argv[1] ); return 1; } printf( "Extracting archive %s ...\n", argv[1] ); // Read "PAQ3\r\n" at start of archive if( getline( archive ) != "PAQ3" ) { printf( "Archive file %s not in PAQ3 format\n", argv[1] ); return 1; } // Read "size filename" in "%d\t%s\r\n" format while( true ) { string s = getline( archive ); if( s.size() > 1 ) { filesize.push_back( atol( s.c_str() ) ); string::iterator tab = find( s.begin(), s.end(), '\t' ); if( tab != s.end() ) filename.emplace_back( tab + 1, s.end() ); else filename.emplace_back( "" ); } else break; } // Test end of header for "\f\0" { int c1 = 0; int c2 = 0; if( ( c1 = getc( archive ) ) != '\f' || ( c2 = getc( archive ) ) != 0 ) { printf( "%s: Bad PAQ3 header format %d %d\n", argv[1], c1, c2 ); return 1; } } // Extract files from archive data Encoder e( DECOMPRESS, archive ); for( int i = 0; i < int( filename.size() ); ++i ) { printf( "%10ld %s: ", filesize[i], filename[i].c_str() ); // Compare with existing file FILE *f = fopen( filename[i].c_str(), "rbe" ); const long size = filesize[i]; uncompressed_bytes += size; if( f != nullptr ) { bool different = false; for( long j = 0; j < size; ++j ) { int c1 = decompress( e ); int c2 = getc( f ); if( !different && c1 != c2 ) { printf( "differ at offset %ld, archive=%d file=%d\n", j, c1, c2 ); different = true; } } if( !different ) printf( "identical\n" ); fclose( f ); } // Extract to new file else { f = fopen( filename[i].c_str(), "wbe" ); if( f == nullptr ) printf( "cannot create, skipping...\n" ); for( long j = 0; j < size; ++j ) { int c = decompress( e ); if( f != nullptr ) putc( c, f ); } if( f != nullptr ) { printf( "extracted\n" ); fclose( f ); } } } compressed_bytes = ftell( archive ); fclose( archive ); } // Compress files else { // Read file names from command line or input if( argc > 2 ) for( int i = 2; i < argc; ++i ) filename.emplace_back( argv[i] ); else { printf( "Enter names of files to compress, followed by blank line or EOF.\n" ); while( true ) { string s = getline( stdin ); if( s.empty() ) break; filename.push_back( s ); } } // Get file sizes for( auto &i: filename ) { FILE *f = fopen( i.c_str(), "rbe" ); if( f == nullptr ) { printf( "File not found, skipping: %s\n", i.c_str() ); filesize.push_back( -1 ); } else { fseek( f, 0L, SEEK_END ); filesize.push_back( ftell( f ) ); fclose( f ); } } if( filesize.empty() || *max_element( filesize.begin(), filesize.end() ) < 0 ) { printf( "No files to compress, no archive created.\n" ); return 1; } // Write header archive = fopen( argv[1], "wbe" ); if( archive == nullptr ) { printf( "Cannot create archive: %s\n", argv[1] ); return 1; } fprintf( archive, "PAQ3\r\n" ); for( int i = 0; i < int( filename.size() ); ++i ) { if( filesize[i] >= 0 ) fprintf( archive, "%ld\t%s\r\n", filesize[i], filename[i].c_str() ); } putc( 032, archive ); // MSDOS EOF putc( '\f', archive ); putc( 0, archive ); // Write data Encoder e( COMPRESS, archive ); long file_start = ftell( archive ); for( int i = 0; i < int( filename.size() ); ++i ) { const long size = filesize[i]; if( size >= 0 ) { uncompressed_bytes += size; printf( "%-23s %10ld -> ", filename[i].c_str(), size ); FILE *f = fopen( filename[i].c_str(), "rbe" ); int c = 0; for( long j = 0; j < size; ++j ) { if( f != nullptr ) c = getc( f ); else c = 0; compress( e, c ); } if( f != nullptr ) fclose( f ); printf( "%ld\n", ftell( archive ) - file_start ); file_start = ftell( archive ); } } e.flush(); compressed_bytes = ftell( archive ); fclose( archive ); } // Report statistics const double elapsed_time = double( clock() - start_time ) / CLOCKS_PER_SEC; printf( "%d/%d in %1.2f sec.", compressed_bytes, uncompressed_bytes, elapsed_time ); if( uncompressed_bytes > 0 && elapsed_time > 0 ) { printf( " (%1.4f bpc, %1.2f%% at %1.0f KB/s)", compressed_bytes * 8.0 / uncompressed_bytes, compressed_bytes * 100.0 / uncompressed_bytes, uncompressed_bytes / ( elapsed_time * 1000.0 ) ); } printf( "\n" ); return 0; }
[ "a.epstein@elsevier.com" ]
a.epstein@elsevier.com
0d15c5740aeb90eca37f14cfc1fed5542fecb759
d875df6d3ab5161475156661777aabfa01cef560
/uva/uva12786.cpp
d33736752a98258e7ec2a10e2e7284fcee02903e
[ "BSD-2-Clause" ]
permissive
partho222/programming
385de1c86e203d305e89543d7590012367dec41c
98a87b6a04f39c343125cf5f0dd85e0f1c37d56c
refs/heads/master
2021-01-10T05:23:46.470483
2015-11-24T15:35:36
2015-11-24T15:35:36
46,603,152
0
0
null
null
null
null
UTF-8
C++
false
false
2,335
cpp
/* Tariq ahmed khan - Daffodil */ #include <bits/stdc++.h> #define pi 2*acos(0.0) #define scan(x) scanf("%d",&x) #define sf scanf #define pf printf #define pb push_back #define memoclr(n,x) memset(n,x,sizeof(n) ) #define INF 1 << 30 #define foo(i,j,k) for(int (x)=(i);(x)<(j);(x)+=(k)) #define ffoo(i,j,k) for(int (x)=(i);(x)<=(j);(x)+=(k)) typedef long long LLI; typedef unsigned long long LLU; template<class T> T gcd(T x, T y){if (y==0) return x; return gcd(y,x%y);} template<class T> T lcm(T x, T y){return ((x/gcd(x,y))*y);} template<class T> T maxt(T x, T y){if (x > y) return x; else return y;} template<class T> T mint(T x, T y){if (x < y) return x; else return y;} template<class T> T power(T x, T y){T res=1,a = x; while(y){if(y&1){res*=a;}a*=a;y>>=1;}return res;} template<class T> T bigmod(T x,T y,T mod){T res=1,a=x; while(y){if(y&1){res=(res*a)%mod;}a=((a%mod)*(a%mod))%mod;y>>=1;}return res;} int dir[8][2]={{-1,0} ,{1,0} ,{0,-1} ,{0,1} ,{-1,-1} ,{-1,1} ,{1,-1} ,{1,1}}; using namespace std; bool comp (const int &a, const int &b){ return a>b; } int main() { #ifdef partho222 freopen("input.txt","r",stdin); //freopen("output.txt","w",stdout); #endif int n; while(scan(n) == 1){ int ary[n]; for(int i=0 ; i<n ; i++){ scan(ary[i]); } int f=0; sort(ary+0,ary+n,comp); for(int i=0 ; i<n ; i++){ /*for(int m=0 ; m<n ; m++){ cout << ary[m] << endl; } cout << endl;*/ int x = ary[i]; for(int j=i+1 ; j<n && x>0 ; j++ , x--){ ary[j]--; } /*for(int m=0 ; m<n ; m++){ cout << ary[m] << endl; } cout << endl;*/ sort(ary+i,ary+n,comp); /*if(x < 0 ){ f = 1; break; }*/ } for(int i = 0 ; i<n ; i++){ if(ary[i] < 0) f=1; } if(f == 1){ pf("0\n"); } else{ pf("1\n"); } } return 0; }
[ "partho222@gmail.com" ]
partho222@gmail.com
e8ea70bee5e8183d8ca78562deaa8fd72dff09ba
e7048e0c504bf52660214efedae436952d082111
/ca/communityconfigurationproject_e/AI_DisabledATLauncherUseAgainstInfantry/config.cpp
8ced17a4728caaef219029b49dd68213c1962252
[]
no_license
RomKaz/work-in-progress
cf08e95636309c4b66701857bd3ae78ea96c8a3b
61acddd17411055f3706e8cde95e10f4a4949e67
refs/heads/master
2020-12-30T10:23:10.094084
2015-06-29T22:44:08
2015-06-29T22:44:08
38,160,476
0
0
null
null
null
null
UTF-8
C++
false
false
1,081
cpp
//////////////////////////////////////////////////////////////////// //DeRap: Produced from mikero's Dos Tools Dll version 4.65 //Fri Oct 31 06:13:56 2014 : Source 'file' date Fri Oct 31 06:13:56 2014 //http://dev-heaven.net/projects/list_files/mikero-pbodll //////////////////////////////////////////////////////////////////// #define _ARMA_ //Class CommunityConfigurationProject_E : AI_DisabledATLauncherUseAgainstInfantry\config.bin{ class cfgPatches { class CA_CommunityConfigurationProject_E_AI_DisabledATLauncherUseAgainstInfantry { units[] = {}; weapons[] = {}; requiredVersion = 0.1; requiredAddons[] = {"CA_CommunityConfigurationProject_E"}; }; }; class CfgAmmo { class RocketBase; class R_SMAW_HEDP; class R_M136_AT: RocketBase { irLock = 1; }; class R_RPG18_AT: RocketBase { irLock = 1; }; class R_PG7V_AT: RocketBase { irLock = 1; }; class R_OG7_AT: R_PG7V_AT { irLock = 0; }; class R_PG9_AT: RocketBase { irLock = 1; }; class R_OG9_HE: R_PG9_AT { irLock = 0; }; class R_SMAW_HEAA: R_SMAW_HEDP { irLock = 1; }; }; //};
[ "romkaz1978@gmail.com" ]
romkaz1978@gmail.com
4012df275ec063383264019d5d6b6c197615e14a
55d560fe6678a3edc9232ef14de8fafd7b7ece12
/libs/hana/example/pair/orderable.cpp
cf78b347d0d47583af8eba0ca60e8fbc4ce7178c
[ "BSL-1.0", "LicenseRef-scancode-unknown-license-reference" ]
permissive
stardog-union/boost
ec3abeeef1b45389228df031bf25b470d3d123c5
caa4a540db892caa92e5346e0094c63dea51cbfb
refs/heads/stardog/develop
2021-06-25T02:15:10.697006
2020-11-17T19:50:35
2020-11-17T19:50:35
148,681,713
0
0
BSL-1.0
2020-11-17T19:50:36
2018-09-13T18:38:54
C++
UTF-8
C++
false
false
517
cpp
// Copyright Louis Dionne 2013-2017 // Distributed under the Boost Software License, Version 1.0. // (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt) #include <boost/hana/less.hpp> #include <boost/hana/pair.hpp> namespace hana = boost::hana; static_assert(hana::make_pair(1, 'x') < hana::make_pair(1, 'y'), ""); static_assert(hana::make_pair(1, 'x') < hana::make_pair(10, 'x'), ""); static_assert(hana::make_pair(1, 'y') < hana::make_pair(10, 'x'), ""); int main() { }
[ "james.pack@stardog.com" ]
james.pack@stardog.com
00f5b125f44565863e19de57baebd186c6a5aa85
f7c622b72bc3297df87350897c055ad5b38475ae
/practice/cpp/findsinglenumber/findSingleNumber.cpp
7333e8e82170d217077e4daaf208abaee2f24971
[]
no_license
xinnige/practice
c88f30afae502beac9046686dfd0b10baec83f55
ef627bc4a5031054e8f7144ea6df04dc7e95be73
refs/heads/master
2023-01-12T01:54:49.340274
2020-11-20T06:56:57
2020-11-20T06:56:57
21,447,704
0
0
null
null
null
null
UTF-8
C++
false
false
315
cpp
#include "stdlib.h" #include "stdio.h" int singleNumber(int A[], int n) { int sum = 0; for (int i=0; i<n; i++){ sum ^= A[i]; } return sum; } int main() { int a[]={-11,2,3,4,5,6,7,8,9,3,4,5,6,7,8,9,-11}; int single = singleNumber(a,17); printf("%d\n",single); return 0; }
[ "xinni.ge1990@gmail.com" ]
xinni.ge1990@gmail.com
d02a2edfce8b098f11f39323a66ff301d7a1bc9a
ab9324a08e91a44e14204240b57b3085366a1b6f
/Renderer/RendererRuntime/src/Resource/Detail/IResource.cpp
d299f85b7b2b515a93ebed2ff7e61d1c1cd7bd1f
[ "MIT" ]
permissive
CitrusForks/unrimp
fe78fe19e5d9ad37135a1eaea652aadb679be7c9
94b68b773999d152667891bd4742910968aefbad
refs/heads/master
2021-01-02T22:46:12.212430
2017-07-30T06:41:50
2017-07-30T10:03:53
null
0
0
null
null
null
null
UTF-8
C++
false
false
6,992
cpp
/*********************************************************\ * Copyright (c) 2012-2017 The Unrimp Team * * Permission is hereby granted, free of charge, to any person obtaining a copy of this software * and associated documentation files (the "Software"), to deal in the Software without * restriction, including without limitation the rights to use, copy, modify, merge, publish, * distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the * Software is furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included in all copies or * substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING * BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \*********************************************************/ //[-------------------------------------------------------] //[ Includes ] //[-------------------------------------------------------] #include "RendererRuntime/PrecompiledHeader.h" #include "RendererRuntime/Resource/Detail/IResource.h" #include "RendererRuntime/Resource/IResourceListener.h" #include <algorithm> //[-------------------------------------------------------] //[ Anonymous detail namespace ] //[-------------------------------------------------------] namespace { namespace detail { //[-------------------------------------------------------] //[ Global functions ] //[-------------------------------------------------------] inline bool orderByResourceListener(RendererRuntime::IResourceListener* left, RendererRuntime::IResourceListener* right) { return (left < right); } //[-------------------------------------------------------] //[ Anonymous detail namespace ] //[-------------------------------------------------------] } // detail } //[-------------------------------------------------------] //[ Namespace ] //[-------------------------------------------------------] namespace RendererRuntime { //[-------------------------------------------------------] //[ Public methods ] //[-------------------------------------------------------] void IResource::connectResourceListener(IResourceListener& resourceListener) { SortedResourceListeners::iterator iterator = std::lower_bound(mSortedResourceListeners.begin(), mSortedResourceListeners.end(), &resourceListener, ::detail::orderByResourceListener); if (iterator == mSortedResourceListeners.end() || *iterator != &resourceListener) { mSortedResourceListeners.insert(iterator, &resourceListener); resourceListener.mResourceConnections.emplace_back(IResourceListener::ResourceConnection(mResourceManager, mResourceId)); resourceListener.onLoadingStateChange(*this); } } void IResource::disconnectResourceListener(IResourceListener& resourceListener) { SortedResourceListeners::iterator iterator = std::lower_bound(mSortedResourceListeners.begin(), mSortedResourceListeners.end(), &resourceListener, ::detail::orderByResourceListener); if (iterator != mSortedResourceListeners.end() && *iterator == &resourceListener) { { // TODO(co) If this turns out to be a performance problem, we might want to use e.g. a sorted vector const IResourceListener::ResourceConnection resourceConnection(mResourceManager, mResourceId); IResourceListener::ResourceConnections::iterator connectionIterator = std::find_if(resourceListener.mResourceConnections.begin(), resourceListener.mResourceConnections.end(), [resourceConnection](const IResourceListener::ResourceConnection& currentResourceConnection) { return (currentResourceConnection.resourceManager == resourceConnection.resourceManager && currentResourceConnection.resourceId == resourceConnection.resourceId); } ); assert(connectionIterator != resourceListener.mResourceConnections.end()); resourceListener.mResourceConnections.erase(connectionIterator); } mSortedResourceListeners.erase(iterator); } } //[-------------------------------------------------------] //[ Protected methods ] //[-------------------------------------------------------] IResource& IResource::operator=(IResource&& resource) { // Swap data std::swap(mResourceManager, resource.mResourceManager); std::swap(mResourceId, resource.mResourceId); std::swap(mAssetId, resource.mAssetId); std::swap(mLoadingState, resource.mLoadingState); std::swap(mSortedResourceListeners, resource.mSortedResourceListeners); // This is fine, resource listeners store a resource ID instead of a raw pointer // Done return *this; } void IResource::setLoadingState(LoadingState loadingState) { mLoadingState = loadingState; for (IResourceListener* resourceListener : mSortedResourceListeners) { resourceListener->onLoadingStateChange(*this); } } void IResource::deinitializeElement() { // Sanity check assert((LoadingState::LOADED == mLoadingState || LoadingState::UNLOADED == mLoadingState) && "Resource deinitialized while in-flight inside the resource streamer"); // Disconnect all resource listeners const IResourceListener::ResourceConnection resourceConnection(mResourceManager, mResourceId); for (IResourceListener* resourceListener : mSortedResourceListeners) { // TODO(co) If this turns out to be a performance problem, we might want to use e.g. a sorted vector IResourceListener::ResourceConnections::iterator connectionIterator = std::find_if(resourceListener->mResourceConnections.begin(), resourceListener->mResourceConnections.end(), [resourceConnection](const IResourceListener::ResourceConnection& currentResourceConnection) { return (currentResourceConnection.resourceManager == resourceConnection.resourceManager && currentResourceConnection.resourceId == resourceConnection.resourceId); } ); assert(connectionIterator != resourceListener->mResourceConnections.end()); resourceListener->mResourceConnections.erase(connectionIterator); } // Reset everything mResourceManager = nullptr; setUninitialized(mResourceId); setUninitialized(mAssetId); mLoadingState = LoadingState::UNLOADED; mSortedResourceListeners.clear(); } //[-------------------------------------------------------] //[ Namespace ] //[-------------------------------------------------------] } // RendererRuntime
[ "cofenberg@gmail.com" ]
cofenberg@gmail.com
73811e40a8af61b59c5d96f270291687ede4d60e
2f6f4953d35e53d3d86ad4e959d9f032d4bb3c4c
/base_lib/LocalManBiz/ConfigureHelper.h
f4ff3b4883e347ce1dae6ca27da3916acf8a93be
[ "MIT" ]
permissive
xuepingiw/open_source_startalk
c9b6866b736d51798394486de2b6181a49f38466
44d962b04039f5660ec47a10313876a0754d3e72
refs/heads/master
2020-04-29T03:00:00.190179
2019-03-27T07:01:40
2019-03-27T07:01:40
175,791,902
0
0
MIT
2019-03-15T09:43:22
2019-03-15T09:43:18
null
UTF-8
C++
false
false
6,598
h
#ifndef CONFIGUREHELPER_H #define CONFIGUREHELPER_H #include "CoreObject.h" #include "ISerializeable.h" #include <QIcon> namespace Biz { class AccountData; class UserSettingData; class AccountList; class GroupListData; class SystemConfigData; class AllUserSettingData; class EmotionPackageListModule; class EditableSettings; class CheckConfigInfo; class ImSelfPerson; class LoginNavConfigInfo; class AdverConfigInfo; class DomainListInfo; class LoginAccountConfigInfo; class NavConfigInfo; class ConfigureHelper : public QObject { public: // 域列表存取 static DomainListInfo* loadDomainListConfigData(); static void saveDomainListConfigData(DomainListInfo& domainsinfo); //广告信息存取 static AdverConfigInfo*loadAdvConfigureData(const QString&userID); static void saveAdvConfigureData(const QString& userID, AdverConfigInfo& adverconfig); // 获取配置信息 static CheckConfigInfo* loadCheckConfigureData( const QString& userID ); static void saveCheckConfigureData( const QString& userID, CheckConfigInfo& configure ); // 获取登陆导航,多账户共享,同accountdata static LoginNavConfigInfo* loadNavConfigureData(); static void saveNavConfigureData( LoginNavConfigInfo& configure ); static void deleteNavConfigureFile(); static void deleteRsaPubKey(); //删除文件夹中的所有文件,不管后缀名了(只要是名称一样的,都必须给删掉) static void user_DeleteAllPortraitPath(const QString& userID, const QString& peerID); static void user_DeleteAllRawPortraitPath(const QString& userID, const QString& peerID); // 最近使用过的表情 static QString getEmoticonsCachePath(); static QString getUserSLPath(const QString& userID); static QString GetSettingConfigurePath(); static QString QuickReplyListConfigurePath(const QString& userID); static QString user_DatabasePath(const QString&); static QString user_PortraitPath(const QString& userID, const QString& peerID, const QString& strsuffer=""); static QString user_RawPortraitPath(const QString& userID, const QString& peerID, const QString& strsuffer=""); static QString user_ImagesPath( const QString& userID); static void saveAccount(AccountData& accountData); static AccountData* loadAccountData(); static void removeAccount(); static QString ThemePath(); static QString UserTempPath(const QString& userID); static QString SystemTempPath(); static UserSettingData* loadConfigureData( const QString& userID ); static void saveConfigureData( const QString& userID, UserSettingData& configure ); static QString appVersionInfo(); static void saveAccountList(AccountList& accountData); static AccountList* loadAccountList(); static void saveGroupList( const QString& userID, GroupListData& accountList); static GroupListData* loadGroupList(const QString& userID); static void saveSystemConfig( SystemConfigData& config); static SystemConfigData* loadSystemConfig(); static SystemConfigData* loadSystemConfig(bool bBeta); static AllUserSettingData* loadSettingConfig(int,int); static void saveSettingConfig( AllUserSettingData& configData); static EditableSettings* loadEditableSettings(); static void saveEditSettings(EditableSettings& data); static QString getServerVersion(); static void setServerVersion(const QString& ver); static QString GetBufferMD5(const QString& ver); static QString GetFileMD5(const QString& strfilePath); static bool IsPicFile(const QString& strfilePath); static QIcon GetFileIcon(const QString& file_name); static QString getLogsDir(); static QString getRootDir(); static QString getQunarDataDir(); static QString getDeskWindowPath(); static QString getRsaDataDir(); static QString getOrginFromPath(const QString&path,QString&fileName,QString& strFileFiler); static void SaveEmotionList(const QString& userID, EmotionPackageListModule& emotionList); static EmotionPackageListModule *loadEmotionList(const QString& userID); static QString GetDebugOrReleasePath(const QString& path); static void DeleteGroupLstPathFile(const QString&UserID); static bool IsValidateEmail(const QString&stremail); static bool IsValidateMobile(const QString&strmobile); static QString getDisplayName(const QSharedPointer<Biz::ImSelfPerson>& person); static bool IsFullPathFileorImage(const QString& url); static QString getLocalSavePath(const QString & strLocalPath); static void parseLoginNavInfo(const QString& value, bool bret=false); static void parseLoginSecondNavInfo(const QString& value); static QString makeFullUrl(const QString& strUrl); static QString bubbleConfigPath(const QString& userID); static void removeNavFile(); static QString getSufferfromImageUrl(const QString& url); static QString getImageLocalSavePath(const QString& url,const QString& conversationId); static QString getImageLocalSaveName(const QString& url); static bool IsValidFile(const QString&filePath); static QList<QSharedPointer<Biz::LoginAccountConfigInfo>> loadLoginAccountConfigInforList(bool bEncrypt); static void saveLoginAccountConfigInforList(const QList<QSharedPointer<Biz::LoginAccountConfigInfo>>& loginAccountlist, bool bEncrypt); static QList<QSharedPointer<Biz::NavConfigInfo>> loadNavConfigInforList(bool bEncrypt); static void saveNavConfigInforList(const QList<QSharedPointer<Biz::NavConfigInfo>>& Navlist, bool bEncrypt); static void WirteFile(const QString& fileName, const QString& Path, const QString&content); private: static void innerSaveData(const QString& path, ISerializeable& ,bool bEncrypt=false); static void innerLoadData(const QString& path, ISerializeable** pData, bool bEncrypt = false); static QString mServerVersion; static QString getfileName( const QString& strfilename ); //在文件夹中根据id查找该文件 static QString getfileNameFromDir( const QString&userid, const QString& strfileDir); //获取该文件夹中的所有文件信息 static QFileInfoList getFileListFromDir(const QString& strfileDir); }; } #endif // CONFIGUREHELPER_H
[ "20832776@qunar.com" ]
20832776@qunar.com
666b858d7c06eba09414207b7e5c41513820ce59
196a89c3dc4fcef9492a233cb58423b3a3f49829
/QT/Maze/maze_page.h
79c5045e0246b5eb0c0afaa279ef6de69537ce61
[]
no_license
Mostafa-Hamidifard/midterm_project
e52fedb4734bbd230379532a32a6764d9bf53b43
806bcdebb2e3c1428e7edd322256084d80061e08
refs/heads/main
2023-05-28T13:56:17.968227
2021-06-05T19:50:10
2021-06-05T19:50:10
365,745,843
0
0
null
null
null
null
UTF-8
C++
false
false
599
h
#ifndef MAZE_PAGE_H #define MAZE_PAGE_H #include <QDialog> #include"maze.h" #include "rectnode.h" namespace Ui { class maze_page; } class maze_page : public QDialog { Q_OBJECT public: Maze *maze; explicit maze_page(QWidget *parent = nullptr,int m=10,int n=20); ~maze_page(); private slots: void on_pushButton_5_clicked(); void on_pad_up_clicked(); void on_pad_right_clicked(); void on_pad_down_clicked(); void on_pad_left_clicked(); void on_btn_bfs_clicked(); void on_btn_dfs_clicked(); private: Ui::maze_page *ui; }; #endif // MAZE_PAGE_H
[ "79892356+Mostafa-Hamidifard@users.noreply.github.com" ]
79892356+Mostafa-Hamidifard@users.noreply.github.com
65d08a049bdb5ac65955ae5d31c76ffbeb3681cc
353aa7e8c742ed640eba5bbe7c40ec2c67002a88
/include/subject_events.hpp
6fe5cc9d2d8a734f9b631fb2e863a323488082df
[]
no_license
bennykr/observers
a3e1eff71fc30619d6f74b7dc25e6dcaa1ff9ddc
a632bbc1eb7773b51ddbcf04bdce4b7a8d2bad0e
refs/heads/master
2022-12-07T19:55:25.113942
2020-09-03T11:27:17
2020-09-03T11:27:17
288,672,725
0
0
null
null
null
null
UTF-8
C++
false
false
1,784
hpp
/* * subject_events.hpp * * Created on: Aug 19, 2020 * Author: benny */ #ifndef OBSERVERS_SUBJECT_EVENTS_HPP_ #define OBSERVERS_SUBJECT_EVENTS_HPP_ #include "logging.hpp" #include "event_handle.hpp" #include <set> #include <string> namespace observers { // Forward deceleration, for the purpose of declaring 'Subject' a friend template <typename TDerived> class SubjectBase; template <typename TSubject> class SubjectEvents{ private: // Observers are attached (detached) in EventHandlesContainer // using `SubjectBase::attach_event_handle(event_handle)`, which // refers the attachment (detachment) operation to its `events` object. // For this purpose it needs to be a friend of the 'SubjectEvents' class. template <typename TDerived> friend class SubjectBase; // One events handle per attached data structure parameterized on TAxis std::set<EventHandle<TSubject>*> attached_event_handles; void attach_event_handle(EventHandle<TSubject> & event_handle){ assert(attached_event_handles.count(&event_handle) == 0); attached_event_handles.insert(&event_handle); } // Called by base class BaseAxis of TAxis void detach_event_handle(EventHandle<TSubject> & event_handle){ assert(attached_event_handles.count(&event_handle) > 0); attached_event_handles.erase(&event_handle); } // Used to make sure TSubject can safely be deleted. // Also used for tests. size_t number_of_attached_handles() const { return attached_event_handles.size(); } void notify(std::string const & message){ for(EventHandle<TSubject> * event_handle : attached_event_handles){ event_handle->notify(message); } } }; } // namespace observers #endif /* OBSERVERS_SUBJECT_EVENTS_HPP_ */
[ "kramerbenny@gmail.com" ]
kramerbenny@gmail.com
0fa80a241e1717d539a9f060eeb3829bcb04a477
f6444ed7644d96919e7adbca2938a7a69e0b28de
/cpp/10976.cpp
ff93eb3ee052849528967fb59cb6995f5a232237
[]
no_license
jullytta/UVAOnlineJudge
1a9ec1fb39ed394e30bef05c549acec647efd2d2
780995adaf748779011c4af7caa62d915fd93281
refs/heads/master
2021-06-24T08:19:53.166525
2017-03-21T21:31:23
2017-03-21T21:31:23
37,727,161
0
0
null
null
null
null
UTF-8
C++
false
false
398
cpp
#include<iostream> using namespace std; int main (void){ int k, x, y, pairs; while(cin >> k){ pairs = 0; for(y = k+1; y <= 2*k; y++){ if(((k*y)%(y-k)) == 0) pairs++; } cout << pairs << endl; for(y = k+1; y <= 2*k; y++){ if(((k*y)%(y-k)) == 0){ x = (k*y)/(y-k); cout << "1/" << k << " = 1/" << x << " + 1/" << y << endl; } } } return 0; }
[ "jullyanavycas@gmail.com" ]
jullyanavycas@gmail.com
4d4fa9d5b439fe75638522c55dcca30245ba340a
884095154dba2b000accf139cf6ae3518f58ff7d
/Pony_Class_Provider.h
5ad088cfaf18252e9c1f339691f2e9e6e7d8499b
[ "MIT" ]
permissive
bielawb/LinPony
7273526ecff98c72747d8ab7debb9121146f247e
eefd8fc3d7ddcde128591212e5b071b0333d52cf
refs/heads/master
2021-01-15T11:48:49.402314
2016-12-16T10:27:14
2016-12-16T10:27:14
33,498,111
1
0
null
null
null
null
UTF-8
C++
false
false
1,611
h
/* @migen@ */ #ifndef _Pony_Class_Provider_h #define _Pony_Class_Provider_h #include "Pony.h" #ifdef __cplusplus # include <micxx/micxx.h> # include "module.h" MI_BEGIN_NAMESPACE /* **============================================================================== ** ** Pony provider class declaration ** **============================================================================== */ class Pony_Class_Provider { /* @MIGEN.BEGIN@ CAUTION: PLEASE DO NOT EDIT OR DELETE THIS LINE. */ private: Module* m_Module; public: Pony_Class_Provider( Module* module); ~Pony_Class_Provider(); void Load( Context& context); void Unload( Context& context); void EnumerateInstances( Context& context, const String& nameSpace, const PropertySet& propertySet, bool keysOnly, const MI_Filter* filter); void GetInstance( Context& context, const String& nameSpace, const Pony_Class& instance, const PropertySet& propertySet); void CreateInstance( Context& context, const String& nameSpace, const Pony_Class& newInstance); void ModifyInstance( Context& context, const String& nameSpace, const Pony_Class& modifiedInstance, const PropertySet& propertySet); void DeleteInstance( Context& context, const String& nameSpace, const Pony_Class& instance); /* @MIGEN.END@ CAUTION: PLEASE DO NOT EDIT OR DELETE THIS LINE. */ }; MI_END_NAMESPACE #endif /* __cplusplus */ #endif /* _Pony_Class_Provider_h */
[ "bartek.bielawski@live.com" ]
bartek.bielawski@live.com
57a4d802a96d646f5d6c8c5b1b45a6159cdab29f
1a2a02df6ee42f8a97e975a8afc89e271016aad6
/src/hog.h
1576e82b79698fee4e9d7dfe93242be4ea3d1a6f
[]
no_license
netphoebus/mgraph02-pedestrians
63838ecd1293b1b3a441d79f15c8ef167afb816c
67d141b0d51861e1cf03f89882d0b897d3400829
refs/heads/master
2020-12-25T08:50:11.488314
2011-10-17T22:00:56
2011-10-17T22:00:56
null
0
0
null
null
null
null
UTF-8
C++
false
false
400
h
#ifndef HOG_H #define HOG_H #include "matrix.h" #include "gradhistogram.h" #include "gradient.h" class HOG: public Matrix<GradHistogram> { public: HOG(const Matrix<Polar> &gr, const QRect &rect); HOG &normalize(); QVector<double> serialize() const { return serialize(0, 0, width(), height()); } QVector<double> serialize(int x1, int y1, int w, int h) const; }; #endif // HOG_H
[ "borisov.mikhail@gmail.com" ]
borisov.mikhail@gmail.com
789b9ee0a55b298b34b2f248ce3fde5da0770d43
255eaad3f286c3d2e483d288e9d3ac39dc9a72f0
/c++/cpp11/ch3/3.5/3.5.1/3-31.cpp
ef78989c09bf1e8a968f2ee213cd8e82f18d11cd
[]
no_license
worsun/study
40a2f1b2894243a6dcde19ae4807620ae634fac9
d85d8d13f792e38c6d4a9848319adfa99103a39c
refs/heads/master
2022-07-23T17:15:51.146155
2022-07-10T03:12:27
2022-07-10T03:12:27
206,750,431
1
2
null
null
null
null
UTF-8
C++
false
false
238
cpp
// Copyright (c) 2020 Tencent Inc. All rights reserved. // Author: worsunwang // Date: 2022-02-28 17:48:21 #include <initializer_list> using namespace std; void Fun(initializer_list<int> iv) {} int main() { Fun({1, 2}); Fun({}); }
[ "worsunwang@tencent.com" ]
worsunwang@tencent.com
00c79ca41736e6d4f9c20a4e62b6032c40aa3231
28cb75c35dfc1391f4cb22e5e729037dab191704
/sources/libborc/felide/Version.cpp
237fd58449a8279f40ee9c788e37bb5be61bcfe6
[]
no_license
fapablazacl-old/felide.old
eeb9cd9abdebe67e87bc0963619ea1ee2616731f
2fc7a118b68fb844b97f2e940a803a38bf2dfebb
refs/heads/master
2021-08-26T06:59:03.461014
2017-05-17T17:49:15
2017-05-17T17:49:15
null
0
0
null
null
null
null
UTF-8
C++
false
false
698
cpp
#include "Version.hpp" namespace borc { bool operator== (const Version &v1, const Version &v2) { if (v1.major!=v2.major) { return false; } if (v1.minor!=v2.minor) { return false; } if (v1.build!=v2.build) { return false; } return true; } bool operator< (const Version &v1, const Version &v2) { if (v1.major>=v2.major) { return false; } if (v1.minor>=v2.minor) { return false; } if (v1.build>=v2.build) { return false; } return true; } }
[ "fapablaza@outlier.cl" ]
fapablaza@outlier.cl
b255f55d1976255fd4e3f4565fa40754c5dd8e42
96a3c2e24fc632a02c254c59725e1db3de15d0ce
/01String/43MultiplyStrings.cpp
028240c12af831635bacddfb7d09592177df703b
[]
no_license
ludandandan/LeetCode
d237e8da7857f6f0dafaa51e81a2f334e4d5d5f6
b30b79f8ea9208624a1e0973ed21414d1943b487
refs/heads/master
2020-05-22T06:30:42.120050
2019-06-24T03:04:22
2019-06-24T03:04:22
186,255,433
0
0
null
null
null
null
UTF-8
C++
false
false
1,677
cpp
#include <cstdio> #include <iostream> #include <vector> #include <algorithm> #include <cmath> using namespace std; class Solution{ public: //将两个字符串表示的整数相乘 string mulStrings(string num1, string num2) { if(num1.empty() || num2.empty()) return ""; string res; int n1 = num1.size(); int n2 = num2.size(); //定义一个vector,大小为n1+n2,存放结果的从高位到低位 //索引越小,位数越高,只有0~9 vector<int> resV(n1+n2, 0);//初始化各个位都是0 //乘法要从低位开始算,所以要对num1和num2倒着取 for(int i=n1-1; i>=0; i--) { for(int j=n2-1; j>=0; j--) { int i0 = num1[i]-'0'; int j0 = num2[j]-'0'; int mul = i0*j0; //乘积先加到低位上,除以10商加到高位上,余数留在低位上 int p1 = i+j;//高位 int p2 = i+j+1; //低位 resV[p2] += mul; resV[p1] += resV[p2]/10; resV[p2] = resV[p2]%10; } } //从vector中取出来放到string里 for(int n: resV) { //先出高位再出低位,注意不要0开头 if(!(res.empty() && n==0)) { char c = n+'0'; res += c; } } return res.empty()?"0":res;//结果若是空的,那么返回0 } }; int main() { Solution s; string str1, str2; cin >> str1; cin >> str2; string res = s.mulStrings(str1, str2); cout << res << endl; }
[ "ludandandan1994@gmail.com" ]
ludandandan1994@gmail.com
3f8f279866c6ff668e3e605b5d16487f77f96365
acf2dad34dcabfad047b4c95d37b6167be33bf02
/pool/poolfactory.h
1bd0a1b8caaefe002e95501a6dd557abee753c36
[]
no_license
drazovicfilip/ObjectOriented
17608efff6b70d94b1440e2b2ce05e3143933ea6
dafab420aeef68df67a8b129d6f4661d9819adde
refs/heads/master
2021-04-06T16:53:42.361108
2018-06-07T08:45:07
2018-06-07T08:45:07
125,306,123
0
0
null
null
null
null
UTF-8
C++
false
false
938
h
#ifndef POOLFACTORY_H #define POOLFACTORY_H #include "abstractfactory.h" /** * @brief The PoolFactory is a concrete implementation of the abstract factory. * * @author Filip Drazovic * @date April 2018 * * It will make balls and a table. * It will be called upon by the builder (and thus by the director) when creating the pool game. */ class PoolFactory : public AbstractFactory { public: using AbstractFactory::createBall; Ball* createBall(Coordinate coordinate, std::string color, float mass, float radius, float xVelocity, float yVelocity) override{ return new Ball(coordinate, color, mass, radius, xVelocity, yVelocity); } using AbstractFactory::createTable; Table* createTable(float length, float height, float thickness, float space, float friction, std::string color) override{ return new Table(length, height, thickness, space, friction, color); } }; #endif // POOLFACTORY_H
[ "" ]
96dc9cbc2f143af9344be24c80da203123170734
8f2df8703d772fc435671d507756d350ad2ce252
/externals/include/boost/fiber/detail/data.hpp
268c86cbb236db859910ef102dae87176d2c7b86
[ "MIT" ]
permissive
akamilkhan/cpp2python
1108e2991db80c7356700a0dc9a07bd1f4346295
ae384cc6e6cb89ed93679903549d91d61c708469
refs/heads/master
2020-04-23T12:05:20.033988
2020-01-24T11:22:20
2020-01-24T11:22:20
171,157,748
2
0
null
null
null
null
UTF-8
C++
false
false
1,529
hpp
// Copyright Oliver Kowalke 2013. // 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) #ifndef BOOST_FIBERS_DETAIL_DATA_H #define BOOST_FIBERS_DETAIL_DATA_H #include <boost/config.hpp> #include <boost/fiber/detail/config.hpp> #include <boost/fiber/detail/spinlock.hpp> #ifdef BOOST_HAS_ABI_HEADERS # include BOOST_ABI_PREFIX #endif namespace boost { namespace fibers { class context; namespace detail { #if (BOOST_EXECUTION_CONTEXT==1) struct data_t { spinlock_lock * lk{ nullptr }; context * ctx{ nullptr }; data_t() = default; explicit data_t( spinlock_lock * lk_) noexcept : lk{ lk_ } { } explicit data_t( context * ctx_) noexcept : ctx{ ctx_ } { } }; #else struct data_t { spinlock_lock * lk{ nullptr }; context * ctx{ nullptr }; context * from; explicit data_t( context * from_) noexcept : from{ from_ } { } explicit data_t( spinlock_lock * lk_, context * from_) noexcept : lk{ lk_ }, from{ from_ } { } explicit data_t( context * ctx_, context * from_) noexcept : ctx{ ctx_ }, from{ from_ } { } }; #endif }}} #ifdef BOOST_HAS_ABI_HEADERS # include BOOST_ABI_SUFFIX #endif #endif // BOOST_FIBERS_DETAIL_DATA_H
[ "kamil.khan@emumba.com" ]
kamil.khan@emumba.com