repo_name stringlengths 5 122 | path stringlengths 3 232 | text stringlengths 6 1.05M |
|---|---|---|
chenwhql/ovs | datapath-windows/ovsext/Datapath.c | /*
* Copyright (c) 2014 VMware, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agre... |
chenwhql/ovs | lib/netdev-dpdk.h | /*
* Copyright (c) 2014, 2015, 2016 Nicira, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable... |
chenwhql/ovs | datapath/linux/compat/include/net/udp_tunnel.h | <reponame>chenwhql/ovs
#ifndef __NET_UDP_TUNNEL_WRAPPER_H
#define __NET_UDP_TUNNEL_WRAPPER_H
#include <linux/version.h>
#include <linux/kconfig.h>
#include <net/dst_metadata.h>
#include <linux/netdev_features.h>
#ifdef HAVE_UDP_TUNNEL_IPV6
#include_next <net/udp_tunnel.h>
static inline struct sk_buff *
rpl_udp_tunne... |
chenwhql/ovs | tests/test-hash.c | /*
* Copyright (c) 2009, 2012, 2014, 2015 Nicira, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by appl... |
chenwhql/ovs | ovn/controller/pinctrl.c |
/* Copyright (c) 2015 Red Hat, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agree... |
chenwhql/ovs | datapath/linux/compat/include/net/netfilter/ipv6/nf_defrag_ipv6.h | #ifndef _NF_DEFRAG_IPV6_WRAPPER_H
#define _NF_DEFRAG_IPV6_WRAPPER_H
#include <linux/kconfig.h>
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,37)
#include_next <net/netfilter/ipv6/nf_defrag_ipv6.h>
#endif
/* Upstream commit 029f7f3b8701 ("netfilter: ipv6: nf_defrag: avoid/free clone
* operations") changed the semanti... |
chenwhql/ovs | datapath/tt.h | <filename>datapath/tt.h
/*
* Copyright (c) 2018-2019 Tsinghua University, Inc.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the... |
chenwhql/ovs | datapath-windows/ovsext/User.c | /*
* Copyright (c) 2014 VMware, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agre... |
chenwhql/ovs | datapath/linux/compat/include/linux/netdev_features.h | #ifndef __LINUX_NETDEV_FEATURES_WRAPPER_H
#define __LINUX_NETDEV_FEATURES_WRAPPER_H
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3,3,0)
#include_next <linux/netdev_features.h>
#endif
#if RHEL_RELEASE_CODE < RHEL_RELEASE_VERSION(7,0)
/* On RHEL 6, netdev features are defined in netdevice.h header. */
#include <linux/netde... |
chenwhql/ovs | datapath-windows/ovsext/Gre.h | /*
* Copyright (c) 2015 Cloudbase Solutions Srl
*
* 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 l... |
chenwhql/ovs | lib/ofp-errors.h | /*
* Copyright (c) 2008, 2009, 2010, 2011, 2012, 2013, 2014, 2015 Nicira, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
*... |
chenwhql/ovs | datapath/compat.h | <filename>datapath/compat.h
/*
* Copyright (c) 2007-2015 Nicira, Inc.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it wi... |
chenwhql/ovs | lib/ct-dpif.c | /*
* Copyright (c) 2015 Nicira, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agre... |
chenwhql/ovs | datapath/linux/compat/include/net/ip6_tunnel.h | #ifndef _NET_IP6_TUNNEL_WRAPER_H
#define _NET_IP6_TUNNEL_WRAPER_H
#include <linux/ipv6.h>
#include <linux/netdevice.h>
#include <linux/if_tunnel.h>
#include <linux/ip6_tunnel.h>
#include_next <net/ip6_tunnel.h>
#include "gso.h"
#define ip6tunnel_xmit rpl_ip6tunnel_xmit
static inline void ip6tunnel_xmit(struct sock *... |
chenwhql/ovs | datapath-windows/ovsext/Netlink/Netlink.h | /*
* Copyright (c) 2008, 2009, 2010, 2011, 2013, 2014 Nicira, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless requ... |
chenwhql/ovs | lib/ovs-lldp.h | /*
* Copyright (c) 2015 Nicira, Inc.
* Copyright (c) 2014 Wind River Systems, Inc.
* Copyright (c) 2015 Avaya, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apa... |
chenwhql/ovs | datapath/linux/compat/include/net/netfilter/nf_conntrack_labels.h | <reponame>chenwhql/ovs
#ifndef _NF_CONNTRACK_LABELS_WRAPPER_H
#define _NF_CONNTRACK_LABELS_WRAPPER_H
#include <linux/kconfig.h>
#include <linux/version.h>
#include_next <net/netfilter/nf_conntrack_labels.h>
#ifndef HAVE_NF_CONNLABELS_GET
#if IS_ENABLED(CONFIG_NF_CONNTRACK_LABELS)
#ifndef NF_CT_LABELS_MAX_SIZE
#defin... |
chenwhql/ovs | ovn/lib/actions.h | /*
* Copyright (c) 2015 Nicira, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agre... |
chenwhql/ovs | lib/rtnetlink.c | /*
* Copyright (c) 2009, 2010, 2013, 2015 Nicira, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by appl... |
chenwhql/ovs | datapath/linux/compat/include/linux/ipv6.h | #ifndef __LINUX_IPV6_WRAPPER_H
#define __LINUX_IPV6_WRAPPER_H 1
#include_next <linux/ipv6.h>
struct frag_queue;
struct inet_frags;
#ifndef HAVE_SKBUFF_HEADER_HELPERS
static inline struct ipv6hdr *ipv6_hdr(const struct sk_buff *skb)
{
return (struct ipv6hdr *)skb_network_header(skb);
}
#endif
#if LINUX_VERSION_CODE... |
chenwhql/ovs | datapath/linux/compat/ip_tunnel.c | /*
* Copyright (c) 2013 Nicira, Inc.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the hope that it will be useful, but
* WITHOUT ANY ... |
chenwhql/ovs | lib/ovs-rcu.c | <filename>lib/ovs-rcu.c
/*
* Copyright (c) 2014 Nicira, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required b... |
chenwhql/ovs | datapath-windows/ovsext/Debug.h | /*
* Copyright (c) 2014 VMware, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agre... |
chenwhql/ovs | datapath/linux/compat/include/net/ipv6.h | <filename>datapath/linux/compat/include/net/ipv6.h
#ifndef __NET_IPV6_WRAPPER_H
#define __NET_IPV6_WRAPPER_H 1
#include <linux/version.h>
#include_next <net/ipv6.h>
#ifndef NEXTHDR_SCTP
#define NEXTHDR_SCTP 132 /* Stream Control Transport Protocol */
#endif
#if LINUX_VERSION_CODE < KERNEL_VERSION(3,3,0)
#define ... |
chenwhql/ovs | datapath/tt.c | <filename>datapath/tt.c
/*
* Copyright (c) 2018-2019 Tsinghua University, Inc.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of version 2 of the GNU General Public
* License as published by the Free Software Foundation.
*
* This program is distributed in the... |
chenwhql/ovs | ovn/lib/lex.h | /*
* Copyright (c) 2015 Nicira, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agre... |
chenwhql/ovs | datapath-windows/ovsext/Driver.c | /*
* Copyright (c) 2014 VMware, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agre... |
chenwhql/ovs | datapath-windows/ovsext/PacketIO.c | /*
* Copyright (c) 2014 VMware, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agre... |
chenwhql/ovs | include/openflow/onf-tt-ext.h | /*
* Copyright (c) 2018 Tsinghua University, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicabl... |
chenwhql/ovs | datapath/linux/compat/include/net/netfilter/nf_conntrack_core.h | #ifndef _NF_CONNTRACK_CORE_WRAPPER_H
#define _NF_CONNTRACK_CORE_WRAPPER_H
#include_next <net/netfilter/nf_conntrack_core.h>
#ifndef HAVE_NF_CT_TMPL_ALLOC_TAKES_STRUCT_ZONE
#include <net/netfilter/nf_conntrack_zones.h>
#define nf_ct_tmpl_alloc rpl_nf_ct_tmpl_alloc
/* Released via destroy_conntrack() */
static inline... |
chenwhql/ovs | lib/hmap.h | /*
* Copyright (c) 2008, 2009, 2010, 2012, 2013, 2015 Nicira, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless requ... |
chenwhql/ovs | lib/nx-match.h | /*
* Copyright (c) 2010, 2011, 2012, 2013, 2014 Nicira, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required b... |
chenwhql/ovs | ovn/controller/ofctrl.c | /* Copyright (c) 2015 Nicira, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed ... |
chenwhql/ovs | datapath/linux/compat/ip_output.c | /*
* IP fragmentation backport, heavily based on linux/net/ipv4/ip_output.c,
* copied from Linux ae7ef81ef000 ("skbuff: introduce skb_gso_validate_mtu")
*
* INET An implementation of the TCP/IP protocol suite for the LINUX
* operating system. INET is implemented using the BSD Socket
* interface as the means ... |
chenwhql/ovs | datapath/linux/compat/include/net/dst_metadata.h | #ifndef __NET_DST_METADATA_WRAPPER_H
#define __NET_DST_METADATA_WRAPPER_H 1
#ifdef HAVE_METADATA_DST
#include_next <net/dst_metadata.h>
#else
#include <linux/skbuff.h>
#include <net/ip_tunnels.h>
#include <net/dst.h>
struct metadata_dst {
unsigned long dst;
union {
struct ip_tunnel_info tun_info;
} u;
};
static... |
chenwhql/ovs | ovn/controller-vtep/binding.c | <filename>ovn/controller-vtep/binding.c
/* Copyright (c) 2015 Nicira, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at:
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unle... |
svenslaggare/texteditor | src/rendering/common/shadercompiler.h | #pragma once
#include <string>
#define GLEW_STATIC
#include <GL/glew.h>
/**
* Represents a shader compiler
*/
namespace ShaderCompiler {
/**
* Pre-process the given shader
* @param content The content of the shader
* @return The output of the pre-processor
*/
std::string preProcessShader(const std::string... |
svenslaggare/texteditor | src/text/textloader.h | <reponame>svenslaggare/texteditor
#pragma once
#include <memory>
#include "text.h"
class FormatterRules;
struct LoadedText {
Text text;
std::unique_ptr<FormatterRules> rules;
};
/**
* Represents a text loader
*/
class TextLoader {
public:
/**
* Loads the text from the given filename
* @param fileName The fi... |
svenslaggare/texteditor | src/text/helpers.h | #pragma once
#include <vector>
#include <functional>
#include <iostream>
#include <unordered_set>
#include "../external/tsl/array_set.h"
#include "text.h"
/**
* Represents a circular buffer
* @tparam T
*/
template<typename T>
class CircularBuffer {
private:
std::vector<T> mData;
std::size_t mMaxSize;
std::size_t... |
svenslaggare/texteditor | src/rendering/common/glhelpers.h | <reponame>svenslaggare/texteditor<gh_stars>1-10
#pragma once
#define GLEW_STATIC
#include <GL/glew.h>
#include <cstddef>
#include <memory>
#include <vector>
struct GLUniform {
std::size_t index;
std::string name;
GLint size;
GLenum type;
};
std::ostream& operator<<(std::ostream& stream, const GLUniform& uniform);... |
svenslaggare/texteditor | src/text/text.h | <reponame>svenslaggare/texteditor
#pragma once
#include <string>
#include <vector>
#include <functional>
class Font;
struct RenderStyle;
//using Char = char;
//using String = std::string;
using Char = char16_t;
using String = std::u16string;
/**
* Represents a text selection
*/
struct TextSelection {
std::size_t ... |
svenslaggare/texteditor | src/text/formattedtext.h | <reponame>svenslaggare/texteditor
#pragma once
#include "text.h"
#include <list>
#include <unordered_map>
/**
* The type of a token
*/
enum class TokenType : std::uint8_t {
Text,
Number,
Keyword,
String,
Comment
};
/**
* Represents a token
*/
struct Token {
TokenType type = TokenType::Text;
String text;
}... |
svenslaggare/texteditor | src/interface/inputmanager.h | <filename>src/interface/inputmanager.h
#pragma once
#include "../helpers.h"
#include <glm/vec2.hpp>
#include <unordered_map>
#include <vector>
#include <unordered_set>
struct GLFWwindow;
class WindowState;
struct RenderViewPort;
class Font;
/**
* Represents an input manager
*/
class InputManager {
private:
GLFWwi... |
svenslaggare/texteditor | src/text/formatters/text.h | #pragma once
#include "../textformatter.h"
/**
* Defines text formatting rules
*/
class TextFormatterRules : public FormatterRules {
private:
String mEmpty;
public:
virtual FormatMode mode() const override;
virtual bool isKeyword(const String& string) const override;
virtual const String& lineCommentStart() c... |
svenslaggare/texteditor | src/rendering/textrender.h | #pragma once
#include "../text/text.h"
#include <string>
#include <glm/vec2.hpp>
#include <glm/vec3.hpp>
#define GLEW_STATIC
#include <GL/glew.h>
#include <GLFW/glfw3.h>
#include <functional>
class Font;
struct RenderStyle;
struct RenderViewPort;
class BaseFormattedText;
struct InputState;
class TextMetrics;
class ... |
svenslaggare/texteditor | src/windowstate.h | #pragma once
#include <vector>
#include <glm/mat4x4.hpp>
using CodePoint = unsigned int;
struct GLFWwindow;
/**
* Represents the state of the window
*/
class WindowState {
private:
int mWidth = 1280;
int mHeight = 720;
bool mChangedWindowSize = false;
double mScrollValueY = 0.0;
bool mScrollValueChanged = fal... |
svenslaggare/texteditor | src/text/formatters/cpp.h | #pragma once
#include "../textformatter.h"
/**
* Defines C++ formatting rules
*/
class CppFormatterRules : public FormatterRules {
private:
KeywordList mKeywords;
String mLineCommentStart = u"//";
String mBlockCommentStart = u"/*";
String mBlockCommentEnd = u"*/";
public:
CppFormatterRules();
virtual ~CppForma... |
svenslaggare/texteditor | src/rendering/font.h | <filename>src/rendering/font.h
#pragma once
#include <unordered_map>
#include <memory>
#include <glm/vec2.hpp>
#define GLEW_STATIC
#include <GL/glew.h>
#include <GLFW/glfw3.h>
#include <ft2build.h>
#include FT_FREETYPE_H
#include "../text/text.h"
/**
* Represents a character for a font
*/
struct FontCharacter {
... |
svenslaggare/texteditor | src/interface/textview.h | #pragma once
#include "../helpers.h"
#include "inputmanager.h"
#include "../text/textformatter.h"
#include "../rendering/renderviewport.h"
#include "../rendering/textmetrics.h"
#include "../rendering/textselectionrender.h"
#include "../text/incrementalformattedtext.h"
#include "textoperations.h"
#include <string>
#inc... |
svenslaggare/texteditor | src/interface/textoperations.h | #pragma once
#include <cstdint>
#include <utility>
#include <memory>
#include "../text/formattedtext.h"
#include "../rendering/renderviewport.h"
#include "../rendering/textmetrics.h"
#include "../text/textformatter.h"
#include "../text/incrementalformattedtext.h"
enum class PerformFormattingType : std::uint32_t;
stru... |
svenslaggare/texteditor | src/rendering/textmetrics.h | #pragma once
#include <cstddef>
struct FormattedLine;
class Font;
struct RenderStyle;
class BaseFormattedText;
/**
* Represents a text metrics calculator
*/
class TextMetrics {
private:
const Font& mFont;
const RenderStyle& mRenderStyle;
public:
/**
* Creates a new metrics calculator
* @param font The font
... |
svenslaggare/texteditor | src/text/textformatter.h | <filename>src/text/textformatter.h
#pragma once
#include "text.h"
#include "formattedtext.h"
#include "helpers.h"
#include "formatterrules.h"
#include <string>
#include <vector>
#include <iostream>
class Font;
struct RenderViewPort;
struct RenderStyle;
class Text;
using FormattedLines = std::vector<FormattedLine>;
... |
svenslaggare/texteditor | src/text/formatterrules.h | #pragma once
#include "text.h"
/**
* The format mode
*/
enum class FormatMode : std::uint8_t {
Text,
Code
};
/**
* The rules formatting
*/
class FormatterRules {
public:
virtual ~FormatterRules() = default;
/**
* Returns the mode
*/
virtual FormatMode mode() const = 0;
/**
* Indicates if the given s... |
svenslaggare/texteditor | src/rendering/textselectionrender.h | #pragma once
#include "common/shaderprogram.h"
#include <GL/glew.h>
#include <glm/vec2.hpp>
class WindowState;
class Font;
struct RenderStyle;
struct RenderViewPort;
class TextMetrics;
struct InputState;
class BaseFormattedText;
/**
* Represents a render for text selections
*/
class TextSelectionRender {
private:
... |
svenslaggare/texteditor | src/rendering/renderstyle.h | <gh_stars>1-10
#pragma once
#include <glm/vec3.hpp>
#include "../text/text.h"
#include "font.h"
struct Token;
class Font;
/**
* The render style
*/
struct RenderStyle {
float sideSpacing = 10.0f;
float topSpacing = 5.0f;
float bottomSpacing = 0.0f;
std::size_t spacesPerTab = 4;
bool wordWrap = false;
glm::v... |
svenslaggare/texteditor | src/rendering/common/shaderprogram.h | <reponame>svenslaggare/texteditor
#pragma once
#include <string>
#include <unordered_map>
#define GLEW_STATIC
#include <GL/glew.h>
#include <vector>
#include <glm/mat4x4.hpp>
/**
* The type of the shader parameter
*/
enum class ShaderParameterType {
Unknown,
Texture2D,
Float,
Float2,
Float3,
Float4,
Float4x4... |
svenslaggare/texteditor | src/external/tsl/array_hash.h | /**
* MIT License
*
* Copyright (c) 2017 Tessil
*
* 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... |
svenslaggare/texteditor | src/helpers.h | <filename>src/helpers.h<gh_stars>1-10
#pragma once
#include "text/text.h"
#include <string>
#include <chrono>
#include <codecvt>
#include <locale>
using TimePoint = std::chrono::time_point<std::chrono::system_clock>;
namespace Helpers {
/**
* Returns the content of the given file as UTF-8 string
* @param fileNa... |
svenslaggare/texteditor | src/text/incrementalformattedtext.h | <gh_stars>1-10
#pragma once
#include "textformatter.h"
class Text;
class Font;
struct RenderStyle;
struct RenderViewPort;
/**
* Represents an incremental formatted text
*/
class IncrementalFormattedText : public BaseFormattedText {
public:
/**
* The current input state
*/
struct InputState {
std::size_t li... |
svenslaggare/texteditor | src/rendering/common/framebuffer.h | #pragma once
#define GLEW_STATIC
#include <GL/glew.h>
/**
* Represents a frame buffer
*/
class FrameBuffer {
private:
int mWidth;
int mHeight;
GLuint mFrameBuffer;
GLuint mTextureColorBuffer;
public:
/**
* Creates a new frame buffer
* @param width The width of the frame buffer
* @param height The height o... |
svenslaggare/texteditor | src/rendering/texturerender.h | #pragma once
#define GLEW_STATIC
#include <GL/glew.h>
/**
* Represents a texture render
*/
class TextureRender {
private:
GLuint mVAO;
GLuint mVBO;
GLuint mShaderProgram;
public:
/**
* Creates a new texture render
* @param shaderProgram The shader program to render with
*/
explicit TextureRender(GLuint s... |
svenslaggare/texteditor | src/rendering/renderviewport.h | <gh_stars>1-10
#pragma once
#include <glm/vec2.hpp>
struct RenderViewPort {
glm::vec2 position;
float width;
float height;
/**
* Returns the top Y position
*/
float top() const;
/**
* Returns the bottom Y position
*/
float bottom() const;
}; |
673697831/pod | Example/Pods/Target Support Files/pod1/pod1-umbrella.h | #ifdef __OBJC__
#import <UIKit/UIKit.h>
#else
#ifndef FOUNDATION_EXPORT
#if defined(__cplusplus)
#define FOUNDATION_EXPORT extern "C"
#else
#define FOUNDATION_EXPORT extern
#endif
#endif
#endif
#import "YYAlertView.h"
#import "TestProject2.h"
#import "YYTestLibrary.h"
FOUNDATION_EXPORT double pod1VersionNumber;
FOUND... |
673697831/pod | Classes/YYAlertView.h | <filename>Classes/YYAlertView.h<gh_stars>0
//
// YYAlertView.h
// Pods-pod1_Example
//
// Created by ouzhirui on 2017/12/12.
//
#import <UIKit/UIKit.h>
@interface YYAlertView : UIView
+ (void)showText1;
+ (void)showText2;
@end
|
673697831/pod | Library/TestProject1.framework/Headers/YYTestFramework.h | //
// YYTestFramework.h
// TestProject1
//
// Created by ouzhirui on 2017/12/7.
// Copyright © 2017年 ozr. All rights reserved.
//
#import <Foundation/Foundation.h>
@interface YYTestFramework : NSObject
+ (NSString *)helloWorld;
@end
|
673697831/pod | Library/YYTestLibrary.h | //
// YYTestLibrary.h
// TestProject2
//
// Created by ouzhirui on 2017/12/7.
// Copyright © 2017年 ozr. All rights reserved.
//
#import <Foundation/Foundation.h>
@interface YYTestLibrary : NSObject
+ (NSString *)helloWorld;
@end
|
673697831/pod | Library/TestProject2.h | //
// TestProject2.h
// TestProject2
//
// Created by ouzhirui on 2017/12/7.
// Copyright © 2017年 ozr. All rights reserved.
//
#import "YYTestLibrary.h"
|
673697831/pod | Library/TestProject1.framework/Headers/TestProject1.h | //
// TestProject1.h
// TestProject1
//
// Created by ouzhirui on 2017/12/7.
// Copyright © 2017年 ozr. All rights reserved.
//
#import <UIKit/UIKit.h>
//! Project version number for TestProject1.
FOUNDATION_EXPORT double TestProject1VersionNumber;
//! Project version string for TestProject1.
FOUNDATION_EXPORT co... |
673697831/pod | Example/pod1/YYViewController.h | //
// YYViewController.h
// pod1
//
// Created by 673697831 on 12/12/2017.
// Copyright (c) 2017 673697831. All rights reserved.
//
@import UIKit;
@interface YYViewController : UIViewController
@end
|
673697831/pod | Example/pod1/YYAppDelegate.h | //
// YYAppDelegate.h
// pod1
//
// Created by 673697831 on 12/12/2017.
// Copyright (c) 2017 673697831. All rights reserved.
//
@import UIKit;
@interface YYAppDelegate : UIResponder <UIApplicationDelegate>
@property (strong, nonatomic) UIWindow *window;
@end
|
kipiberbatov/idec | src/algebra/matrix_sparse_array_fscan.c | #include <errno.h>
#include <stdlib.h>
#include <string.h>
#include "matrix_sparse.h"
matrix_sparse ** matrix_sparse_array_fscan(
FILE * in, int n, const char * format)
{
int i;
matrix_sparse ** a;
a = (matrix_sparse **) malloc(sizeof(matrix_sparse *) * n);
if (errno)
{
perror("matrix_sparse_array_f... |
kipiberbatov/idec | src/array/jagged3_fprint_curly.c | <filename>src/array/jagged3_fprint_curly.c
#include "array_fprint.h"
#include "jagged_private.h"
void jagged3_fprint_curly(FILE * out, const jagged3 * arr)
{
array_fprint3(out, arr->a0, arr->a1, arr->a2, arr->a3);
fputc('\n', out);
}
|
kipiberbatov/idec | include/array/jagged.h | <reponame>kipiberbatov/idec
#ifndef JAGGED_H
#define JAGGED_H
#include <stdio.h>
/********************************** jagged1 ***********************************/
typedef struct jagged1
{
int a0;
int * a1;
} jagged1;
void jagged1_free(jagged1 * arr);
jagged1 * jagged1_fscan(FILE * in, const char * format);
void j... |
kipiberbatov/idec | src/mesh/forman_cf_a4.c | #include <errno.h>
#include <stdlib.h>
#include <string.h>
#include "forman_private.h"
#include "int.h"
void forman_cf_a4(int * m_forman_cf_a4, const mesh * m, const int * m_forman_cn)
{
int ind, i_f, m_dim, m_forman_cn_p_f, p_f, q_f, r_f, vertices_number;
int m_forman_cell_to_faces[12]; /* 12 = max(vertices_numbe... |
kipiberbatov/idec | src/mesh/mesh_qc_hodge_p_values.c | #include "mesh_qc_private.h"
static void mesh_qc_hodge_p_values_d(
double * m_hodge_p_values, const mesh * m,
const double * m_inner_q, const double * m_coeff_q)
{
int d_exp, i, ind, j, j_loc, m_cn_d;
jagged1 m_cf_d_0_i;
jagged2 m_cf_d_0;
d_exp = 1 << m->dim;
m_cn_d = m->cn[m->dim];
mesh_cf_part2(&m... |
kipiberbatov/idec | src/algebra/vector_sparse_array2_fprint.c | #include "vector_sparse.h"
void vector_sparse_array2_fprint(
FILE * out, int a0, const int * a1,
vector_sparse *** arr, const char * format)
{
int i;
for (i = 0; i < a0; ++i)
vector_sparse_array_fprint(out, a1[i], arr[i], format);
}
|
kipiberbatov/idec | src/mesh/mesh_qc_perpendicular.c | <filename>src/mesh/mesh_qc_perpendicular.c
#include "mesh_qc_private.h"
/* Let c[d, k] be a volume around c[p, i].
* Finds the combinatorially perpendicular cells of c[p, i] with respect to
* c[d, k] and the nodes they intersect at.
*/
void mesh_qc_perpendicular(
int * nodes, int * perp, const jagged2 * m_cf_d_q,... |
kipiberbatov/idec | include/array/array_indexed.h | #ifndef ARRAY_INDEXED_H
#define ARRAY_INDEXED_H
typedef struct array_indexed
{
int * positions;
int * values;
} array_indexed;
void array_indexed_merge_sort(array_indexed * a, int n);
#endif /* ARRAY_INDEXED_H */
|
kipiberbatov/idec | src/array/double_matrix_fprint.c | #include <errno.h>
#include <string.h>
#include "double_private.h"
void double_matrix_fprint(
FILE * out, int m, int n, const double * a, const char * format)
{
int i;
for (i = 0; i < DOUBLE_MATRIX_FPRINT_FORMAT_TOTAL; ++i)
if (!strcmp(format, double_matrix_fprint_format[i]))
{
double_matrix_fpr... |
kipiberbatov/idec | src/algebra/matrix_sparse_laplacian_symmetric.c | <filename>src/algebra/matrix_sparse_laplacian_symmetric.c<gh_stars>0
#include <math.h>
#include "matrix_sparse.h"
static void matrix_sparse_laplacian_symmetric_p(
matrix_sparse * delta_p, const double * m_inner_p)
{
int delta_p_cols, i, i_loc, j;
int * delta_p_cols_total, * delta_p_row_indices;
double * delta_... |
kipiberbatov/idec | src/mesh/mesh_brick_cn.c | <filename>src/mesh/mesh_brick_cn.c
#include <errno.h>
#include <stdlib.h>
#include "int.h"
#include "mesh_brick_private.h"
/* calculation in the case of a regular grid */
/*
void mesh_brick_cn(int * m_cn, int m_dim, int n)
{
int p;
for (p = 0; p <= m_dim; ++p)
m_cn[p] =
int_binomial(m_dim, p) * int_powe... |
kipiberbatov/idec | src/array/double_array2_fscan.c | #include <errno.h>
#include <stdlib.h>
#include <string.h>
#include "double_private.h"
double ** double_array2_fscan(
FILE * in, int a0, const int * a1, const char * format)
{
int i;
double ** a;
for (i = 0; i < DOUBLE_ARRAY2_FSCAN_FORMAT_TOTAL; ++i)
if (!strcmp(format, double_array2_fscan_format[i]))
... |
kipiberbatov/idec | include/region/quasi_cube.h | <filename>include/region/quasi_cube.h
#ifndef QUASI_CUBE_H
#define QUASI_CUBE_H
#include <stdio.h>
typedef struct quasi_cube
{
int dim_embedded;
int dim;
double * coord;
} quasi_cube;
void quasi_cube_free(quasi_cube * s);
quasi_cube * quasi_cube_fscan(FILE * in);
void quasi_cube_fprint(FILE * out, const quasi_... |
kipiberbatov/idec | main/array/main_jagged4.c | #include <errno.h>
#include "jagged.h"
int main()
{
jagged4 * arr;
arr = jagged4_fscan(stdin, "--raw");
if (errno)
{
fputs("main - cannot scan arr\n", stderr);
return errno;
}
jagged4_fprint(stdout, arr, "--curly");
jagged4_free(arr);
return 0;
}
|
kipiberbatov/idec | src/array/double_private.h | <gh_stars>0
#ifndef DOUBLE_PRIVATE_H
#define DOUBLE_PRIVATE_H
#include "double.h"
/***************************** double_array_fscan *****************************/
double * double_array_fscan_raw(FILE * in, int n);
#define DOUBLE_ARRAY_FSCAN_FORMAT_TOTAL 1
static const char * double_array_fscan_format[DOUBLE_ARRAY_F... |
kipiberbatov/idec | src/mesh/mesh_fc.c | <reponame>kipiberbatov/idec
#include <errno.h>
#include <stdlib.h>
#include "int.h"
#include "mesh.h"
static void mesh_fc_a1(int * m_fc_a1, int m_dim)
{
int q;
for (q = 0; q <= m_dim; ++q)
m_fc_a1[q] = m_dim - q;
}
static void mesh_fc_a2(int * m_fc_a2, int m_dim, const int * m_cn)
{
int ind, m_cn_q, p, q... |
kipiberbatov/idec | src/mesh/mesh_qc_hodge_p_cols_total.c | <filename>src/mesh/mesh_qc_hodge_p_cols_total.c
#include "mesh_qc_private.h"
static void mesh_qc_hodge_p_cols_total_d(
int * m_hodge_p_cols_total, const mesh * m)
{
int i, m_cn_d, d_exp;
m_cn_d = m->cn[m->dim];
d_exp = 1 << m->dim;
for (i = 0; i <= m_cn_d; ++i)
m_hodge_p_cols_total[i] = d_exp * i;
}
... |
kipiberbatov/idec | src/mesh/forman_polytope_vertices.c | <reponame>kipiberbatov/idec<filename>src/mesh/forman_polytope_vertices.c
#include "forman_private.h"
void forman_polytope_vertices(
int * m_forman_cell_to_faces, const mesh * m, const jagged2 * m_forman_u,
const jagged3 * m_forman_v, const jagged2 * m_forman_fi,
const jagged3 * m_forman_si, int p_f, int q_f, int... |
kipiberbatov/idec | src/region/line.c | <filename>src/region/line.c
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include "line.h"
line * line_new(double * p_x0, double * p_x1)
{
line * p;
p = (line *) malloc(sizeof(line));
/* NULL pointer check */
memcpy(p->x0, p_x0, sizeof(double) * 2);
memcpy(p->x1, p_x1, sizeof(double) * 2);
... |
kipiberbatov/idec | main/mesh/main_mesh_qc_cbd_star.c | <filename>main/mesh/main_mesh_qc_cbd_star.c
#include "double.h"
#include "mesh_qc.h"
static void mesh_qc_cbd_star_fprint_raw(
FILE * out, const mesh_qc * m, matrix_sparse ** m_bd, double ** m_inner)
{
int m_cbd_star_p_nonzero_max, m_dim, p;
int * m_cn;
matrix_sparse * m_cbd_star_p;
m_dim = m->dim;
m_cn ... |
kipiberbatov/idec | src/algebra/vector_sparse_fprint.c | #include <errno.h>
#include <string.h>
#include "vector_sparse_private.h"
void vector_sparse_fprint(
FILE * out, const vector_sparse * a, const char * format)
{
int i;
for (i = 0; i < VECTOR_SPARSE_FPRINT_FORMAT_TOTAL; ++i)
if (!strcmp(format, vector_sparse_fprint_format[i]))
{
vector_sparse_fpr... |
kipiberbatov/idec | src/mesh/forman_cf.c | #include <errno.h>
#include <stdlib.h>
#include <string.h>
#include "forman_private.h"
#include "int.h"
#include "mesh_private.h"
jagged4 * forman_cf(const mesh * m, const int * m_forman_cn)
{
int m_forman_cf_a2_size, m_forman_cf_a3_size, m_forman_cf_a4_size;
jagged4 * m_forman_cf;
m_forman_cf = (jagged4 *) m... |
kipiberbatov/idec | src/algebra/matrix_sparse_linear_solve.c | #include <errno.h>
#include <string.h>
#include "matrix_sparse_private.h"
void matrix_sparse_linear_solve(
const matrix_sparse * a, double * b, const char * method)
{
int i;
for (i = 0; i < MATRIX_SPARSE_LINEAR_SOLVE_METHOD_TOTAL; ++i)
if (!strcmp(method, matrix_sparse_linear_solve_method[i]))
{
... |
kipiberbatov/idec | main/algebra/main_matrix_sparse_constrained_solve_cholesky.c | <reponame>kipiberbatov/idec
#include <errno.h>
#include <stdlib.h>
#include "matrix_sparse.h"
#include "double.h"
static void matrix_sparse_constrained_solve_cholesky_fprint(
FILE * out, const matrix_sparse * a, const double * b, const jagged1 * rows)
{
double * x;
x = matrix_sparse_constrained_solve_cholesky... |
kipiberbatov/idec | src/mesh/mesh_brick_assign_n_bar.c | <filename>src/mesh/mesh_brick_assign_n_bar.c
#include "int.h"
#include "mesh_brick_private.h"
void mesh_brick_assign_n_bar(
int * n_bar, int d, const int * n, int p, const int * a)
{
int r;
for (r = 0; r < d; ++r)
n_bar[r] = (int_array_member(p, a, r)) ? n[r] : (n[r] + 1);
}
|
kipiberbatov/idec | main/mesh/main_mesh_qc_hodge_coeff.c | #include "mesh_qc.h"
static void mesh_qc_hodge_coeff_fprint_raw(FILE * out, const mesh * m)
{
int i, m_dim, p;
int * m_cn;
m_dim = m->dim;
m_cn = m->cn;
for (p = 0; p <= m_dim; ++p)
{
for (i = 0; i < m_cn[p] - 1; ++i)
fprintf(out, "%g ", 1.);
fprintf(out, "%g\n", 1.);
}
}
int main()
{
... |
kipiberbatov/idec | src/algebra/matrix_sparse_add.c | <filename>src/algebra/matrix_sparse_add.c
#include <errno.h>
#include <stdio.h>
#include "matrix_sparse.h"
matrix_sparse * matrix_sparse_add(
const matrix_sparse * a, const matrix_sparse * b)
{
matrix_sparse * c;
c = matrix_sparse_linear_combination(a, b, 1., 1.);
if (errno)
{
perror("Cannot add matri... |
kipiberbatov/idec | src/algebra/matrix_sparse_private.h | #ifndef MATRIX_SPARSE_PRIVATE_H
#define MATRIX_SPARSE_PRIVATE_H
#include "matrix_sparse.h"
#include "cs.h"
/**************************** matrix_sparse_wrapper ***************************/
void matrix_sparse_to_cs(cs * a0, const matrix_sparse * a);
void matrix_sparse_from_cs(matrix_sparse * a, const cs * a0);
/******... |
kipiberbatov/idec | src/mesh/forman_fi.c | <reponame>kipiberbatov/idec<filename>src/mesh/forman_fi.c
#include <errno.h>
#include <stdlib.h>
#include "forman_private.h"
#include "int.h"
static void forman_fi_a1(int * m_forman_fi_a1, int m_dim)
{
int q_f;
for (q_f = 0; q_f <= m_dim; ++q_f)
m_forman_fi_a1[q_f] = m_dim - q_f + 2;
}
static void forman_f... |
kipiberbatov/idec | src/array/jagged1.c | <filename>src/array/jagged1.c
#include <errno.h>
#include <stdlib.h>
#include "int.h"
#include "jagged.h"
int jagged1_total_sum(const jagged1 * arr)
{
return int_array_total_sum(arr->a0, arr->a1);
}
/* finds the complement of arr with respect to {0, ..., n - 1} */
// jagged1 * jagged1_complement(int n, const jagged... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.