repo_name
stringlengths
5
122
path
stringlengths
3
232
text
stringlengths
6
1.05M
MicroEJ/FreeRTOS
FreeRTOS-Labs/Source/mbedtls/library/x509_crt.c
/* * X.509 certificate parsing and verification * * Copyright (C) 2006-2015, ARM Limited, All Rights Reserved * SPDX-License-Identifier: Apache-2.0 * * Licensed under the Apache License, Version 2.0 (the "License"); you may * not use this file except in compliance with the License. * You may obtai...
MicroEJ/FreeRTOS
FreeRTOS-Labs/Source/FreeRTOS-Plus-FAT/include/ff_string.h
<reponame>MicroEJ/FreeRTOS /* * FreeRTOS+FAT build 191128 - Note: FreeRTOS+FAT is still in the lab! * Copyright (C) 2018 Amazon.com, Inc. or its affiliates. All Rights Reserved. * Authors include <NAME>, <NAME> and <NAME> * * Permission is hereby granted, free of charge, to any person obtaining a copy of ...
MicroEJ/FreeRTOS
FreeRTOS-Labs/Demo/FreeRTOS_IoT_Libraries/include/https_demo_profile.h
/* * FreeRTOS Kernel V10.3.0 * Copyright (C) 2020 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * 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, ...
MicroEJ/FreeRTOS
FreeRTOS-Labs/Source/FreeRTOS-Plus-FAT/portable/ATSAM4E/ff_sddisk.c
<filename>FreeRTOS-Labs/Source/FreeRTOS-Plus-FAT/portable/ATSAM4E/ff_sddisk.c /* * FreeRTOS+FAT build 191128 - Note: FreeRTOS+FAT is still in the lab! * Copyright (C) 2018 Amazon.com, Inc. or its affiliates. All Rights Reserved. * Authors include <NAME>, <NAME> and <NAME> * * Permission is hereby granted, f...
avrora-robotics/ur_hardware_driver
src/uniorhwinterface.h
<reponame>avrora-robotics/ur_hardware_driver<gh_stars>1-10 /********************************************************************* * Software License Agreement (BSD License) * * Copyright (c) 2016, AVRORA ROBOTICS LLC * * Redistribution and use in source and binary forms, with or without * modification, are per...
avrora-robotics/ur_hardware_driver
src/umotoudpinterface.h
<filename>src/umotoudpinterface.h<gh_stars>1-10 /********************************************************************* * Software License Agreement (BSD License) * * Copyright (c) 2016, AVRORA ROBOTICS LLC * * Redistribution and use in source and binary forms, with or without * modification, are permitted prov...
avrora-robotics/ur_hardware_driver
src/umototypes.h
/********************************************************************* * Software License Agreement (BSD License) * * Copyright (c) 2016, AVRORA ROBOTICS LLC * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: ...
avrora-robotics/ur_hardware_driver
src/umotopackets.h
/********************************************************************* * Software License Agreement (BSD License) * * Copyright (c) 2016, AVRORA ROBOTICS LLC * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: ...
avrora-robotics/ur_hardware_driver
src/ur_hardware_driver_config.h
<gh_stars>1-10 #ifndef UR_HARDWARE_DRIVER_CONFIG_H #define UR_HARDWARE_DRIVER_CONFIG_H /** ATTENTION This file was generated from the config file ur_hardware_driver_config.yaml and contains set of _default_ parameters. DO NOT DARE TO EDIT ANY OF THIS */ #include "ros/ros.h" class UrHardwareDriverConfig { public: ...
rafaello7/nanopi-load
main.c
#include <stdio.h> #include <string.h> #include <stdlib.h> #include <libusb.h> #include <errno.h> #include <unistd.h> #include "s5p_usb.h" #include "s5p_boot.h" #define BUF_MAX (50 * 1024 * 1024) #define MIN(A, B) (((A) < (B)) ? (A) : (B)) typedef unsigned char uint8; typedef unsigned int uint32; static unsigned c...
cnlohr/ws2812esp8266
user/user_main.c
<gh_stars>100-1000 #include "mem.h" #include "c_types.h" #include "user_interface.h" #include "ets_sys.h" #include "driver/uart.h" #include "osapi.h" #include "espconn.h" #include "mystuff.h" #define PORT 7777 #define SERVER_TIMEOUT 1500 #define MAX_CONNS 5 #define MAX_FRAME 2000 #define procTaskPrio 0 #define...
cnlohr/ws2812esp8266
top/top.c
<filename>top/top.c<gh_stars>100-1000 #include <sys/socket.h> #include <netinet/in.h> #include <stdio.h> #include <string.h> #include <math.h> int sockfd; struct sockaddr_in servaddr; unsigned long HSVtoHEX( float hue, float sat, float value ) { float pr = 0; float pg = 0; float pb = 0; short ora = 0; short o...
cnlohr/ws2812esp8266
user/ws2812.c
#include "ws2812.h" #include "ets_sys.h" #include "mystuff.h" #include "osapi.h" #define GPIO_OUTPUT_SET(gpio_no, bit_value) \ gpio_output_set(bit_value<<gpio_no, ((~bit_value)&0x01)<<gpio_no, 1<<gpio_no,0) //I just used a scope to figure out the right time periods. void SEND_WS_0() { uint8_t time; time = 3; wh...
cnlohr/ws2812esp8266
user/ws2812.h
#ifndef _WS2812_H #define _WS2812_H #define WSGPIO 0 #include "c_types.h" #include "user_interface.h" #include "ets_sys.h" #include "gpio.h" //You will have to os_intr_lock(); os_intr_unlock(); void WS2812OutBuffer( uint8_t * buffer, uint16_t length ); #endif
ngagesdk/nrpg
src/ngine.h
<gh_stars>1-10 /** @file ngine.h * * N-GINE, a portable game engine which is being developed specifically * for the Nokia N-Gage. * * API definition. * * Copyright (c) 2022, <NAME>. All rights reserved. * SPDX-License-Identifier: MIT * **/ #ifndef NGINE_H #define NGINE_H #include "ngtypes.h" #ifndef F...
ngagesdk/nrpg
src/pfs.c
/** @file pfs.c * * Packed file system implementation. * Adapted version, originally from The Mistral Report: * https://montyontherun.itch.io/the-mistral-report * * Copyright (c) 2019, <NAME>. All rights reserved. * SPDX-License-Identifier: BSD-2-Clause * **/ #include <SDL.h> #include <stdio.h> #include ...
ngagesdk/nrpg
src/utils.c
/** @file utils.c * * N-GINE, a portable game engine which is being developed specifically * for the Nokia N-Gage. * * Utility functions. * * Copyright (c) 2022, <NAME>. All rights reserved. * SPDX-License-Identifier: MIT * **/ #include <SDL.h> #include <stb_sprintf.h> #include "ngine.h" static void ge...
ngagesdk/nrpg
src/core.c
<reponame>ngagesdk/nrpg /** @file core.c * * N-GINE, a portable game engine which is being developed specifically * for the Nokia N-Gage. * * Engine core implementation. * * Copyright (c) 2022, <NAME>. All rights reserved. * SPDX-License-Identifier: MIT * **/ #include <SDL.h> #include "ngine.h" #include...
ngagesdk/nrpg
src/ngtypes.h
<filename>src/ngtypes.h /** @file ngtypes.h * * N-GINE, a portable game engine which is being developed specifically * for the Nokia N-Gage. * * Internal type definitions. * * Copyright (c) 2022, <NAME>. All rights reserved. * SPDX-License-Identifier: MIT * **/ #ifndef NGTYPES_H #define NGTYPES_H #incl...
ngagesdk/nrpg
src/ngine.c
<gh_stars>1-10 /** @file ngine.c * * N-GINE, a portable game engine which is being developed specifically * for the Nokia N-Gage. * * API implementation. * * Copyright (c) 2022, <NAME>. All rights reserved. * SPDX-License-Identifier: MIT * **/ #include <SDL.h> #include "ngine.h" status_t ng_init(const ...
ngagesdk/nrpg
src/main.c
/** @file main.c * * N-GINE, a portable game engine which is being developed specifically * for the Nokia N-Gage. * * Minimal launcher implementation. * * Copyright (c) 2022, <NAME>. All rights reserved. * SPDX-License-Identifier: MIT * **/ #include "ngine.h" #if defined __SYMBIAN32__ #define RES_FILE ...
skeeto/makefile-game-of-life
lifegen.c
<gh_stars>1-10 #include <ctype.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <stdbool.h> #include <getopt.h> #define FATAL(s) \ do { \ fprintf(stderr, "%s: " s " -- %s\n", argv...
edparsons/com.speedshare.cordova.htmlviewer
src/ios/htmlViewerPlugin.h
// // SpeedsharePlugin.h // // Copyright (c) 2015 Osix Corp. All rights reserved. // Please see the LICENSE included with this distribution for details. // #import <Cordova/CDVPlugin.h> #import <WebKit/WebKit.h> @interface HtmlViewerPlugin : CDVPlugin <WKNavigationDelegate, WKScriptMessageHandler> - (void)startS...
Sensirion/raspberry-pi-i2c-sgp41
sensirion_common.h
<filename>sensirion_common.h /* * Copyright (c) 2018, Sensirion AG * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyright notic...
Sensirion/raspberry-pi-i2c-sgp41
sensirion_common.c
/* * Copyright (c) 2018, Sensirion AG * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redistributions of source code must retain the above copyright notice, this * list of conditio...
Sensirion/raspberry-pi-i2c-sgp41
sgp41_i2c.h
/* * THIS FILE IS AUTOMATICALLY GENERATED * * I2C-Generator: 0.3.0 * Yaml Version: 0.1.0 * Template Version: 0.7.0-62-g3d691f9 */ /* * Copyright (c) 2021, Sensirion AG * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the...
Sensirion/raspberry-pi-i2c-sgp41
sgp41_i2c_example_usage.c
/* * I2C-Generator: 0.3.0 * Yaml Version: 0.1.0 * Template Version: 0.7.0-62-g3d691f9 */ /* * Copyright (c) 2021, Sensirion AG * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * * Redi...
Harjas12/instagram
instagram/Header.h
// // Header.h // instagram // // Created by <NAME> on 2/2/18. // Copyright © 2018 <NAME>. All rights reserved. // #ifndef Header_h #define Header_h #import <Parse/Parse.h> #import <Bolts/BFTask.h> #endif /* Header_h */
polopoints/polopoints
src/noui.h
<reponame>polopoints/polopoints // Copyright (c) 2013 The DACRS developers // Copyright (c) 2016 The Polopoints developers // Distributed under the MIT/X11 software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #ifndef POLOPOINTS_NOUI_H #define POLOPOINTS_NO...
polopoints/polopoints
src/wallet/walletdb.h
// Copyright (c) 2009-2010 <NAME> // Copyright (c) 2009-2013 The Dacrs developers // Distributed under the MIT/X11 software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #ifndef POLOPOINTS_WALLETDB_H #define POLOPOINTS_WALLETDB_H #include "key.h" #incl...
polopoints/polopoints
src/vm/testmcu.h
<reponame>polopoints/polopoints /* * TestMcu.h * * Created on: Aug 6, 2014 * Author: ranger.shi */ #ifndef TESTMCU_H_ #define TESTMCU_H_ #include <boost/format.hpp> #include "vm8051.h" #include <stdio.h> #include <string.h> #include <iostream> using namespace boost; class CTestMcu { CVm...
rickytan/RTIconButton
Example/RTIconButton/RTTableViewController.h
<reponame>rickytan/RTIconButton // // RTTableViewController.h // RTIconButton // // Created by Ricky on 2017/7/25. // Copyright © 2017年 rickytan. All rights reserved. // #import <UIKit/UIKit.h> @interface RTTableViewController : UITableViewController @end
rickytan/RTIconButton
Example/RTIconButton/RTViewController.h
<gh_stars>10-100 // // RTViewController.h // RTIconButton // // Created by rickytan on 09/28/2015. // Copyright (c) 2015 rickytan. All rights reserved. // @import UIKit; @interface RTViewController : UIViewController @end
dk-dev/bitlash
src/eeprom.c
/*** eeprom.c: minimal eeprom interface The author can be reached at: <EMAIL> Copyright (C) 2008-2012 <NAME> 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...
lasiqueira/8080emu
main.c
<filename>main.c #include <stdio.h> #include <stdlib.h> int disassemble_8080_op(unsigned char *code_buffer, int pos); void unimplemented_instruction(State8080* state); int emulate_8080_op(State8080* state); int parity(int x, int size); typedef struct ConditionCodes{ uint8_t z:1; uint8_t s:1; uint8_t p:1; ...
Schumbi/mqtt-schalter
src/schalter.h
#ifndef SCHALTER_H #define SCHALTER_H #include <Arduino.h> #include <ESP8266HTTPUpdateServer.h> #include <ESP8266WebServer.h> #include <ESP8266WiFi.h> #include <ESP8266mDNS.h> #include <PubSubClient.h> #include <TickerScheduler.h> #include <WiFiUdp.h> #include "conf.hpp" #define STARTDATE 1514761200l // net_dev sta...
qwqw3qee/cryptography_with_c
MD5/MD5.h
<reponame>qwqw3qee/cryptography_with_c<filename>MD5/MD5.h #ifndef MD5_H_INCLUDED #define MD5_H_INCLUDED /** https://blog.csdn.net/chudongfang2015/article/details/51736426 **/ #include <stdio.h> #include <math.h> #include <string.h> #define ROTATE_LEFT(x,n) (((x) << (n)) | ((x) >> (32-(n)))) #define F(x,y,z) (((x)&(y))...
qwqw3qee/cryptography_with_c
ELGamal/ELGamal.h
<filename>ELGamal/ELGamal.h #ifndef ELGAMAL_H_INCLUDED #define ELGAMAL_H_INCLUDED #include <stdio.h> #include <stdlib.h> #include <string.h> #include "BIGNUM_BIN_32.h" #include "BASE64.h" #include "MD5.h" #define KEYSIZE 512 typedef struct elgamalkey { int type; BIGNUM y,g,p; BIGNUM x; }ELGKEY,*pELGKEY; t...
dj95/fn-notify
src/config.h
#define BG_COLOR "A0171717" #define FG_COLOR "FFFFFFFF" #define FG_MUTED "FF5D5D5D"
dj95/fn-notify
src/fn-notify.c
<gh_stars>1-10 /* * * fn-notify * * (c) 2017 <NAME> */ #include <string.h> #include <stdio.h> #include <stdlib.h> #include <unistd.h> #include <pwd.h> #include <math.h> #include <signal.h> #include <pthread.h> #include <sys/types.h> #include <fcntl.h> #include <errno.h> #include "draw.h" #define MAX(a,b) ...
dj95/fn-notify
src/draw.h
<reponame>dj95/fn-notify #include <stdlib.h> #include <X11/X.h> #include <X11/Xlib.h> #include <X11/Xatom.h> #include <X11/Xutil.h> #include <X11/Xresource.h> #include <X11/extensions/shape.h> #include "config.h" void drawBrightnessIcon(); void drawVolumeIcon(); void drawVolumeIconMuted();
dj95/fn-notify
src/draw.c
#include "draw.h" extern Display *display; extern Window window; extern GC gc; void drawBrightnessIcon() { // get window attributes for width and height XWindowAttributes win_attr; XGetWindowAttributes(display, window, &win_attr); // extract window width and height int width = win_attr.width; ...
YChungHsu/hid_rw_register
src/hid_rw_registers.c
<filename>src/hid_rw_registers.c #include <stdint.h> #include <stdio.h> #include <linux/hidraw.h> #include <fcntl.h> #include <sys/types.h> #include <string.h> #include <sys/ioctl.h> #include <sys/stat.h> #include <unistd.h> void set_feature(int fd, uint8_t report_id, uint8_t *data, int length) { int ret; uint...
thetrapest/TheSuperTinyCompilerInJava
src/main/resources/HelloWorld.c
#include <stdio.h> int sum(int, int); int sum(int a, int b){ return a+b; } int main(int argc, char** argv){ int x = 10, y = 20; int z = sum(x,y); printf("sum is: %d\n", z); return 0; }
dotsimon/openssl
crypto/evp/keymgmt_lib.c
<gh_stars>1-10 /* * Copyright 2019 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LICENSE in the source distribution or at * https://www.openssl.or...
dotsimon/openssl
providers/implementations/serializers/serializer_rsa.c
<filename>providers/implementations/serializers/serializer_rsa.c<gh_stars>1-10 /* * Copyright 2019 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LI...
dotsimon/openssl
include/crypto/dsa.h
/* * Copyright 2019 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LICENSE in the source distribution or at * https://www.openssl.org/source/licens...
dotsimon/openssl
crypto/dsa/dsa_aid.c
<filename>crypto/dsa/dsa_aid.c /* * Copyright 2020 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LICENSE in the source distribution or at * https:...
dotsimon/openssl
crypto/http/http_client.c
/* * Copyright 2001-2020 The OpenSSL Project Authors. All Rights Reserved. * Copyright Siemens AG 2018-2020 * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LICENSE in the source distribution or at ...
dotsimon/openssl
providers/fips/self_test_kats.c
/* * Copyright 2019-2020 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the OpenSSL license (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LICENSE in the source distribution or at * https://www.openssl.org/source/lice...
dotsimon/openssl
providers/implementations/serializers/serializer_local.h
/* * Copyright 2019 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LICENSE in the source distribution or at * https://www.openssl.org/source/licens...
dotsimon/openssl
test/evp_pkey_provided_test.c
<gh_stars>1-10 /* * Copyright 2019 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LICENSE in the source distribution or at * https://www.openssl.or...
dotsimon/openssl
crypto/asn1/i2d_pr.c
<gh_stars>1-10 /* * Copyright 1995-2016 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LICENSE in the source distribution or at * https://www.opens...
dotsimon/openssl
providers/implementations/asymciphers/rsa_enc.c
<filename>providers/implementations/asymciphers/rsa_enc.c /* * Copyright 2019 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LICENSE in the source d...
dotsimon/openssl
test/cmp_msg_test.c
<gh_stars>1-10 /* * Copyright 2007-2019 The OpenSSL Project Authors. All Rights Reserved. * Copyright Nokia 2007-2019 * Copyright Siemens AG 2015-2019 * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the fil...
dotsimon/openssl
providers/implementations/serializers/serializer_dh_pub.c
<filename>providers/implementations/serializers/serializer_dh_pub.c /* * Copyright 2019 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LICENSE in th...
dotsimon/openssl
providers/fips/self_test_event.c
/* * Copyright 2019 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the OpenSSL license (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LICENSE in the source distribution or at * https://www.openssl.org/source/license.h...
dotsimon/openssl
crypto/bio/b_sock.c
<reponame>dotsimon/openssl /* * Copyright 1995-2018 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LICENSE in the source distribution or at * https...
dotsimon/openssl
crypto/ec/curve448/curve448_local.h
/* * Copyright 2017-2018 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LICENSE in the source distribution or at * https://www.openssl.org/source/l...
dotsimon/openssl
crypto/self_test_core.c
/* * Copyright 2019 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the Apache License 2.0 (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LICENSE in the source distribution or at * https://www.openssl.org/source/licens...
dotsimon/openssl
providers/fips/self_test.h
/* * Copyright 2019 The OpenSSL Project Authors. All Rights Reserved. * * Licensed under the OpenSSL license (the "License"). You may not use * this file except in compliance with the License. You can obtain a copy * in the file LICENSE in the source distribution or at * https://www.openssl.org/source/license.h...
hervey-su/home
notebook/demo/src/funs.c
<filename>notebook/demo/src/funs.c #include "funs.h" // x[0]*x[1]*...*x[n-1] double dprod(double *x, int n) { double y = 1.0; for (int i = 0; i < n; i++) { y *= x[i]; } return y; } // The factorial of a positive integer n, denoted by n!, is the product of all positive integers less than o...
hervey-su/home
notebook/demo/src/SumArray.h
#ifndef SUMARRAY_H #define SUMARRAY_H int sum(int array[], int size); #endif
hervey-su/home
notebook/demo/src/hello.c
<filename>notebook/demo/src/hello.c<gh_stars>1-10 /* gcc -o hello hello.c */ #include <stdio.h> int main() { printf("Hello, world!\n"); return 0; }
southmountain/CrossScalePatchMatch
CSPM/ca_filter/GuidedFilter.h
#pragma once #include "..\CommFunc.h" // to use fast inverse method #define FAST_INV // cum sum like cumsum in matlab Mat CumSum( const Mat& src, const int d ); // % BOXFILTER O(1) time box filtering using cumulative sum // % // % - Definition imDst(x, y)=sum(sum(imSrc(x-r:x+r,y-r:y+r))); // % - Running tim...
southmountain/CrossScalePatchMatch
CSPM/get_method.h
<reponame>southmountain/CrossScalePatchMatch<filename>CSPM/get_method.h /////////////////////////////////////////////////////// // File: GetMethod // Desc: Get all the method interface by name // // Author: <NAME> // Date: 2013/09/06 /////////////////////////////////////////////////////// #pragma once #include "CC/Grd...
southmountain/CrossScalePatchMatch
CSPM/plane_cost/pre_cs_pc.h
/////////////////////////////////////////////////////// // File: pre_cs_pc.h // Desc: precompute cost volume // for cross-scale plane cost // // Author: rookiepig // Date: 2014/05/19 // /////////////////////////////////////////////////////// #pragma once #include"../commfunc.h" #include"i_plane_cost.h" #include"....
southmountain/CrossScalePatchMatch
CSPM/plane_cost/grd_pc.h
<filename>CSPM/plane_cost/grd_pc.h /////////////////////////////////////////////////////// // File: grd_pc.h // Desc: gradient + color plane cost // // Author: rookiepig // Date: 2014/04/03 // /////////////////////////////////////////////////////// #pragma once #include"../commfunc.h" #include"i_plane_cost.h" #define...
southmountain/CrossScalePatchMatch
CSPM/cc_method.h
/////////////////////////////////////////////////////// // File: cc_method.h // Desc: Interface for Cost Computation // // Author: rookiepig // Date: 2014/05/16 // /////////////////////////////////////////////////////// #pragma once #include "commfunc.h" // // Interface for Cost Computation // class CCMethod { public...
southmountain/CrossScalePatchMatch
CSPM/plane_cost/pre_ss_pc.h
/////////////////////////////////////////////////////// // File: pre_ss_pc.h // Desc: precompute cost volume // for single-scale plane cost // // Author: rookiepig // Date: 2014/05/19 // /////////////////////////////////////////////////////// #pragma once #include"../commfunc.h" #include"i_plane_cost.h" #include"...
southmountain/CrossScalePatchMatch
CSPM/commfunc.h
<filename>CSPM/commfunc.h /////////////////////////////////////////////////////// // File: commfunc.h // Desc: global functions, constants and headers // // Author: <NAME> // Date: 2013/09/06 /////////////////////////////////////////////////////// #pragma once #include<opencv2/opencv.hpp> #include<string> #include<ios...
southmountain/CrossScalePatchMatch
CSPM/plane.h
<filename>CSPM/plane.h<gh_stars>10-100 /////////////////////////////////////////////////////// // File: Plane.h // Desc: Simple plane class to record plane param for // for each pixel // // Author: rookiepig // Date: 2014/04/01 /////////////////////////////////////////////////////// #pragma once #include"commfunc...
southmountain/CrossScalePatchMatch
CSPM/plane_cost/i_plane_cost.h
/////////////////////////////////////////////////////// // File: i_plane_cost.h // Desc: interface for calculating plane cost // // Author: rookiepig // Date: 2014/04/02 // /////////////////////////////////////////////////////// #pragma once #include"../commfunc.h" #include"../plane.h" class IPlaneCost { public: ...
southmountain/CrossScalePatchMatch
CSPM/ca_method.h
<reponame>southmountain/CrossScalePatchMatch #pragma once #include "commfunc.h" // // Interface for Cost Aggregtation // class CAMethod { public: CAMethod(void) {} virtual ~CAMethod(void) {} public: /////////////////////////////////////////////////////// // Func: aggreCV // Desc: aggregate cost volume // In: /...
southmountain/CrossScalePatchMatch
CSPM/plane_cost/cspc.h
<gh_stars>10-100 /////////////////////////////////////////////////////// // File: cspc.h // Desc: corss scale cost aggregation // // Author: rookiepig // Date: 2014/04/03 // /////////////////////////////////////////////////////// #pragma once #include"../commfunc.h" #include"i_plane_cost.h" #define COST_ALPHA 0.1 #de...
voohoo2000/chadwm
chadwm/config.def.h
/* See LICENSE file for copyright and license details. */ #define XF86XK_MonBrightnessDown 0x1008ff03 #define XF86XK_MonBrightnessUp 0x1008ff02 #define XF86XK_AudioLowerVolume 0x1008FF11 #define XF86XK_AudioMute 0x1008FF12 #define XF86XK_AudioRaiseVolume 0x1008FF13 #define XF86XK_AudioMicMute 0x1008FFB2 /* appearance...
IT1050-2022-Feb/tutorial-01-IT21289484
Tute04.c
<filename>Tute04.c /*Exercise 4 - Functions Implement the three functions minimum(), maximum() and multiply() below the main() function. Do not change the code given in the main() function when you are implementing your solution.*/ #include <stdio.h> int max(int no1,int no2); int min(int no1,int no2); int mul(int no...
jtk33/Vulkan
include/gf3d_texture.h
<filename>include/gf3d_texture.h<gh_stars>0 #ifndef __GF3D_TEXTURE_H__ #define __GF3D_TEXTURE_H__ #include <vulkan/vulkan.h> #include "gfc_types.h" #include "gfc_text.h" typedef struct { Uint8 _inuse; Uint32 _refcount; Uint32 width, height; TextLine filename; Vk...
jtk33/Vulkan
src/gf3d_enemy.c
#include "simple_logger.h" #include "gf3d_enemy.h" #include "gf3d_player.h" #include "SDL_keycode.h" #include "SDL_events.h" typedef struct { float speed; /**It's a mystery what this one does*/ float jumpheight; /**Self explanatory, again, have fun*/ float gravity; /**Enemy gravity.*/ enum state hostile; ...
jtk33/Vulkan
src/gf3d_gltf_load.c
#include <string.h> #include "simple_logger.h" #include "simple_json.h" #include "simple_json_list.h" #include "simple_json_parse.h" #include "gf3d_gltf_load.h" GLB_File *simple_glb_new() { GLB_File *glbFile = NULL; glbFile = (GLB_File*)malloc(sizeof(GLB_File)); if (!glbFile) { slog("failed to allocate space f...
jtk33/Vulkan
include/gf3d_player.h
<filename>include/gf3d_player.h #ifndef __GF3D_PLAYER_H__ #define __GF3D_PLAYER_H__ #include "gfc_types.h" #include "gfc_matrix.h" #include "gf3d_model.h" #include "gf3d_entity.h" #include "gf3d_vgraphics.h" #include "SDL_keycode.h" #include "SDL_events.h" /** * @purpose this is the file to access the the player */ ...
jtk33/Vulkan
include/gf3d_sprite.h
#ifndef __GF3D_SPRITE_H__ #define __GF3D_SPRITE_H__ /** * gf3d_sprite * @license The MIT License (MIT) @copyright Copyright (c) 2019 EngineerOfLies 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 ...
jtk33/Vulkan
include/gf3d_enemy.h
<filename>include/gf3d_enemy.h #ifndef __GF3D_ENEMY_H__ #define __GF3D_ENEMY_H__ #include "gfc_types.h" #include "gfc_matrix.h" #include "gf3d_model.h" #include "gf3d_entity.h" #include "gf3d_vgraphics.h" #include "SDL_keycode.h" #include "SDL_events.h" /** * @purpose this is the file to access the the enemy */ voi...
jtk33/Vulkan
src/game.c
<reponame>jtk33/Vulkan #include <SDL.h> #include "simple_logger.h" #include "gfc_vector.h" #include "gfc_matrix.h" #include "gf3d_vgraphics.h" #include "gf3d_pipeline.h" #include "gf3d_swapchain.h" #include "gf3d_model.h" #include "gf3d_camera.h" #include "gf3d_texture.h" #include "gf3d_entity.h" #include...
jtk33/Vulkan
include/gf3d_gltf_load.h
#ifndef __GF3D_GLTF_LOAD_H__ #define __GF3D_GLTF_LOAD_H__ #include <stdio.h> #include <stdlib.h> #include <stdint.h> #include "simple_json.h" #include "gf3d_mesh.h" typedef struct { uint32_t magic; /**<equals 0x46546C67. It is ASCII string glTF*/ uint32_t version; /**<indicates the version of the Binary ...
jtk33/Vulkan
src/gf3d_entity.c
#include "simple_logger.h" #include "gf3d_entity.h" #include "gf3d_player.h" #include "gf3d_enemy.h" typedef struct { Entity *entity_list; /**<My big ole list of entities*/ Uint32 entity_count; /**<upper limit for concurrent active entities*/ }EntityManager; static EntityManager gf3d_entity = {0}; void gf3d_enti...
jtk33/Vulkan
include/gf3d_boss.h
#ifndef __GF3D_BOSS_H__ #define __GF3D_BOSS_H__ #include "gfc_types.h" #include "gfc_matrix.h" #include "gf3d_model.h" #include "gf3d_entity.h" #include "gf3d_vgraphics.h" #include "SDL_keycode.h" #include "SDL_events.h" /** * @purpose this is the file to access the the enemy */ void gf3d_boss_init(); void gf3d_bos...
jtk33/Vulkan
src/gf3d_player.c
#include "simple_logger.h" #include "simple_json.h" #include "gf3d_player.h" #include "SDL_keycode.h" #include "SDL_events.h" enum form{ stealth = 0, platformer = 1 }; typedef struct { enum form form; /**Stealth or Platformer?*/ float speed; /**It's a mystery what this one does*/ float jumpheight; /**Self ex...
jtk33/Vulkan
include/gf3d_entity.h
#ifndef __GF3D_ENTITY_H__ #define __GF3D_ENTITY_H__ #include "gfc_types.h" #include "gfc_matrix.h" #include "gf3d_model.h" /** * @purpose this is the file to access the entity management system */ enum state{ yes = 0, no = 1 }; typedef struct Entity_S { Uint8 _inuse; /**<flag to make sure entities are not re-assig...
jtk33/Vulkan
src/gf3d_boss.c
#include "simple_logger.h" #include "gf3d_enemy.h" #include "gf3d_player.h" #include "SDL_keycode.h" #include "SDL_events.h" void gf3d_boss_init() { } void gf3d_boss_think(Entity *self) { if (!self)return; gfc_matrix_translate( self->modelMatrix, vector3d(-0.1, 0, 0)); gfc_matrix_rotate( self->modelMatrix...
Akshat69/SFML-RPG
SFML-RPG/GUI.h
#pragma once #include "stdafx.h" namespace GUI { enum Button_State { IDLE = 0, HOVER, PRESSED }; class Button { private: short unsigned buttonState; sf::RectangleShape shape; sf::Font* font; sf::Text text; sf::Color idleColorButton, hoverColorButton, activeColorButton; sf::Color idleColorTe...
Akshat69/SFML-RPG
SFML-RPG/Tile.h
<gh_stars>0 #pragma once class Tile { private: protected: sf::RectangleShape shape; public: Tile(); Tile(float x, float y, float gridSizeF); ~Tile(); void Update(const float& DeltaTime); void Render(sf::RenderTarget* target); };
Akshat69/SFML-RPG
SFML-RPG/GameState.h
#pragma once #include "PauseMenuState.h" #include "TileMap.h" class GameState : public State { private: Character* player; TileMap* map; public: GameState(sf::RenderWindow* window, std::map<std::string, int>* supportedKeys, std::stack<State*>* states); //Functions void initTileMap(); void initKeybinds(); vo...
Akshat69/SFML-RPG
SFML-RPG/AnimationComponent.h
#pragma once #include "AudioComponent.h" class AnimationComponent { private: class Animation { public: bool done; float animationTimer; float timer; int width; int height; sf::Sprite& sprite; sf::Texture& textureSheet; sf::IntRect startRect, endRect, currentRect; const bool& Play(const float&...
Akshat69/SFML-RPG
SFML-RPG/EditorState.h
#include "SettingState.h" #include "Tile.h" #include "GUI.h" class EditorState : public State { private: sf::Font font; std::map<std::string, GUI::Button*> buttons; std::map<std::string, std::vector<Tile*>> tiles; void initFonts(); void initKeybinds(); void initButtons(); //void initComponents(); public: ...
Akshat69/SFML-RPG
SFML-RPG/SettingState.h
#pragma once #include "GameState.h" #include "GUI.h" class SettingState : public State { private: sf::RectangleShape background; sf::Texture backgroundTexture; sf::Font font; std::map<std::string, sf::Text*> settings; std::map<std::string, GUI::Button*> buttons; std::map<std::string, GUI::SlideBox*> sliderBo...
Akshat69/SFML-RPG
SFML-RPG/HitboxComponent.h
#pragma once #include "stdafx.h" class HitboxComponent { private: sf::Sprite& sprite; sf::RectangleShape hitbox; sf::Vector2f offset; public: bool render = false; HitboxComponent(sf::Sprite& sprite, sf::Vector2f offset, sf::Vector2f size); ~HitboxComponent(); //Functions void Update(const float& DeltaTime)...
Akshat69/SFML-RPG
SFML-RPG/Game.h
#pragma once #include "MainMenuState.h" class Game { private: class GraphicsSettings { public: GraphicsSettings() { this->resolution = sf::VideoMode::getDesktopMode(); this->fullScreen = false; this->verticalSync = false; this->FrameRateLimit = 120.0; this->contextSettings.antialiasingLevel = 0;...
Akshat69/SFML-RPG
SFML-RPG/State.h
#include "Character.h" class State { protected: sf::RenderWindow* window; std::map<std::string, sf::Texture> textures; std::map<std::string, int>* supportedKeys; std::map<std::string, int> keyBinds; std::stack<State*>* states; AudioComponent* audioComponent = nullptr; bool quit = false; float keytime; float...
Akshat69/SFML-RPG
SFML-RPG/Character.h
#pragma once #include "Entity.h" class Character : public Entity { private: //Variables bool isAttacking; //Initializers void initVariables(); public: Character(float posX, float posY, sf::Texture* texture_sheet, sf::RenderWindow* window); ~Character(); //Functions void Update(cons...