This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <emscripten/bind.h> | |
#include <emscripten/val.h> | |
val print_test(const char* infile, const char* outfile) | |
{ | |
val ret = val::object(); | |
//processing | |
ret.set("res", 0); | |
return ret; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Description: Set up mirrors for Gradle Globally | |
*/ | |
val MAVEN_REPOSITORY_URL = "https://mirrors.cloud.tencent.com/nexus/repository/maven-public" | |
val CENTER_REPOSITORY_URL = "https://maven.aliyun.com/repository/jcenter" | |
val GOOGLE_REPOSITORY_URL = "https://maven.aliyun.com/repository/google" | |
val GRADLE_PLUGIN_REPOSITORY_URL = "https://maven.aliyun.com/repository/gradle-plugin" | |
gradle.settingsEvaluated { | |
pluginManagement { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import 'package:flutter/material.dart'; | |
import 'pages.dart'; | |
void main() { | |
runApp(const CPMain()); | |
} | |
// ignore: must_be_immutable | |
class CPMain extends StatefulWidget { | |
const CPMain({super.key}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <string.h> | |
#include <stdarg.h> | |
#include <stdio.h> | |
#include <stdlib.h> | |
void str_printf(char *str, const char *fmt, ...); | |
int main() | |
{ | |
char *str = (cahr*)malloc(256); | |
str_printf(str, "p:%.3f %d\n", 1.23, 1234); | |
printf(str); |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import {parse as parseSVG} from "./nanosvg.js" | |
let svg = fs.readFileSync(svg_url).toString(); | |
let res = parseSVG(svg,"mm",72); | |
let canvas = document.getElementById("canvas"); | |
let ctx = canvas.getContext("2d"); | |
for (let shape = shapes; shape != null; shape = shape.next) { | |
if(shape.fill.type==1) | |
{ | |
let color = shape.fill.color; | |
let r = Number(color&0xff); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <Arduino.h> | |
#include "esp_jpeg_enc.h" | |
int esp_jpeg_enc_demo1() | |
{ | |
/// configure encoder | |
jpeg_enc_info_t info = DEFAULT_JPEG_ENC_CONFIG(); | |
info.quality = 80; | |
info.src_type = JPEG_RAW_TYPE_RGB888; | |
/// allocate input buffer to fill original image stream. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt-get install liblz4-tool |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"build": { | |
"arduino":{ | |
"ldscript": "esp32s3_out.ld", | |
"partitions": "default_8MB.csv", | |
"memory_type": "qio_opi" | |
}, | |
"core": "esp32", | |
"extra_flags": [ | |
"-DARDUINO_ESP32S3_DEV", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
'use strict'; | |
var Jimp = require('jimp'); | |
var Bitmap = require('./types/Bitmap'); | |
var Curve = require('./types/Curve'); | |
var Point = require('./types/Point'); | |
var Path = require('./types/Path'); | |
var Quad = require('./types/Quad'); | |
var Sum = require('./types/Sum'); | |
var Opti = require('./types/Opti'); |
NewerOlder