Skip to content

Instantly share code, notes, and snippets.

View Gavin0x0's full-sized avatar
🍄
No mushroom!

Gavin Gavin0x0

🍄
No mushroom!
View GitHub Profile
@Gavin0x0
Gavin0x0 / test_api.dart
Created November 22, 2023 06:23
Test Snapshot API
import 'dart:async';
import 'dart:convert';
import 'dart:io';
import 'package:flutter/foundation.dart';
import 'package:flutter/material.dart';
import 'package:provider/provider.dart';
import 'package:trtc_demo/debug/GenerateTestUserSig.dart';
import 'package:trtc_demo/models/meeting.dart';
import 'package:tencent_trtc_cloud/trtc_cloud.dart';
import 'package:tencent_trtc_cloud/tx_beauty_manager.dart';
@Gavin0x0
Gavin0x0 / queryDevices.js
Last active March 20, 2023 08:57
获取所有设备【已解决】
// ***SOLVED***
var globalStream;
navigator.mediaDevices.getUserMedia({
audio: true,
video: true
})
.then(function(stream) {
globalStream = stream;
})
.catch(function(err) {
@Gavin0x0
Gavin0x0 / wave.js
Created March 17, 2023 05:49
5交错着绕X轴旋转的正弦波曲线
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8" />
<title>5交错着绕X轴旋转的正弦波曲线</title>
<style>
body {
margin: 0;
padding: 0;
overflow: hidden;
@Gavin0x0
Gavin0x0 / script.js
Created March 15, 2023 12:52
MantisBT Helper
// ==UserScript==
// @name MantisBT Helper
// @namespace http://tampermonkey.net/
// @version 0.3
// @description Copy the text of a link to the clipboard when a button next to it is clicked
// @author Gavin
// @match http://dist.ius.plus/flyinsono/*
// @grant none
// ==/UserScript==
(function () {
@Gavin0x0
Gavin0x0 / chatgpt-chat-snapshot.js
Last active February 20, 2023 19:37
Adds a button to ChatGPT to take a screenshot of the conversation
// ==UserScript==
// @name Chat Snapshot
// @namespace ChatGPT_Plugin
// @version 1
// @author Gavin
// @description Adds a button to ChatGPT to take a screenshot of the conversation
// @match https://chat.openai.com/*
// @grant GM_download
// @require https://cdnjs.cloudflare.com/ajax/libs/html2canvas/1.4.0/html2canvas.min.js
// ==/UserScript==
import 'dart:io';
import 'package:flutter/foundation.dart';
import 'package:flutter/gestures.dart';
import 'package:flutter/material.dart';
import 'package:flutter/rendering.dart';
import 'package:flutter/services.dart';
import 'trtc_cloud_def.dart';
/// @nodoc
/// MethodChannel identifier
@Gavin0x0
Gavin0x0 / main.dart
Last active November 24, 2022 14:42
Center Input example
import 'package:flutter/material.dart';
void main() => runApp(MyApp());
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Flutter Demo',
debugShowCheckedModeBanner: false,
@Gavin0x0
Gavin0x0 / main.dart
Created October 17, 2022 16:21
zealous-lantern-8672
import 'dart:convert';
import 'dart:math';
import 'dart:typed_data';
import 'dart:ui' as ui;
import 'package:flutter/material.dart';
import 'package:flutter/rendering.dart';
void main() => runApp(const MyApp());
fetch("http://api2.flyinsono.com/IRemedicalService", {
"headers": {
"accept": "*/*",
"accept-language": "zh-CN,zh;q=0.9",
"content-type": "text/plain",
"proxy-connection": "keep-alive"
},
"referrer": "http://127.0.0.1:8080/",
"referrerPolicy": "strict-origin-when-cross-origin",
"body": "{\"jsonrpc\":\"2.0\",\"method\":\"GetMeasureApplicationAsync\",\"params\":[{\"Token\":\"41BAC80D90674B40ACC1A02011821CD0\",\"ApplicationName\":\"Carotid\",\"CategoryName\":\"VAS\",\"MeasureModes\":[\"Tissue\"]}],\"id\":959773799}",
@Gavin0x0
Gavin0x0 / data.json
Created August 19, 2022 08:01
Carotid Data
[{
"CarotidScanType": 0,
"CarotidScanDirection": 0,
"SurfaceFile": "https://flyinsono-bj-1300984704.cos.ap-beijing.myqcloud.com/C80889E875B449A2AD6168C63EB3D901.surface",
"MdlFile": "https://flyinsono-bj-1300984704.cos.ap-beijing.myqcloud.com/ED26E08310674E06BAECF9452A9D904C.model",
"MeasureImageFiles": [
{
"ImageType": 0,
"ImageFile": "https://flyinsono-bj-1300984704.cos.ap-beijing.myqcloud.com/E2AB8D8A22C34805A70B1AD6A2A2A304.jpg"
}