This file contains 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 <stdio.h> | |
#include <libavformat/avformat.h> | |
#include <libavutil/dict.h> | |
int main (int argc, char **argv) | |
{ | |
AVFormatContext *fmt_ctx = NULL; | |
AVDictionaryEntry *tag = NULL; | |
int ret; |
This file contains 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
/** | |
* @file | |
* libavcodec API use example. | |
* | |
* @example decoding_encoding.c | |
* Note that libavcodec only handles codecs (MPEG, MPEG-4, etc...), | |
* not file formats (AVI, VOB, MP4, MOV, MKV, MXF, FLV, MPEG-TS, MPEG-PS, etc...). | |
* See library 'libavformat' for the format handling | |
*/ |
This file contains 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
pragma solidity ^0.4.24; | |
//============================================================================== | |
// _ _ _ _|_ _ . | |
// (/_\/(/_| | | _\ . | |
//============================================================================== | |
contract F3Devents { | |
// fired whenever a player registers a name | |
event onNewName | |
( | |
uint256 indexed playerID, |
This file contains 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
pragma solidity ^0.4.24; | |
import "./ERC20Basic.sol"; | |
/** | |
* @title ERC20 interface | |
* @dev Enhanced interface with allowance functions. | |
* See https://github.com/ethereum/EIPs/issues/20 | |
*/ |
This file contains 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 Vue from 'vue' | |
import BootstrapVue from 'bootstrap-vue' // Here | |
import 'bootstrap/dist/css/bootstrap.css' // Here | |
import 'bootstrap-vue/dist/bootstrap-vue.css' // Here | |
import App from './App.vue' | |
Vue.use(BootstrapVue) // Here | |
Vue.config.productionTip = false |
This file contains 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
<template> | |
<div id="app"> | |
<div> | |
<b-card style="max-width: 30rem;" header="My Address Here"> | |
<p>My Amount Here <span class="text-primary">VTHO</span></p> | |
<b-form-group label="To Address:" label-for="toaddress"> | |
<b-form-input id="toaddress" v-model.trim="toaddress"></b-form-input> | |
</b-form-group> |
This file contains 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
/** | |
* Get token amount of holder from a contract. | |
* @param {String} addressContract 0x started address. | |
* @param {String} addressHolder 0x started address. | |
*/ | |
async function getTokenBalance (addressContract, addressHolder) { | |
const balanceOfABI = { | |
'constant': true, | |
'inputs': [ | |
{ |
This file contains 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
/** | |
* Transfer token from one to another. | |
* @param {String} addressContract Contract address. | |
* @param {String} signerAddress Enforce who signs the transaction. | |
* @param {String} toAddress Receiver of transfer. | |
* @param {String} amountEVM Big number in string. | |
* @param {Number} amountHuman Normal number in Javascript. | |
* @param {String} symbol Symbol of token. | |
*/ | |
async function transferToken (addressContract, signerAddress, toAddress, amountEVM, amountHuman, symbol) { |
This file contains 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
export { | |
getTokenBalance, | |
transferToken | |
} |
This file contains 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
const BigNumber = require('bignumber.js') | |
const DECIMALS = function (points) { | |
return new BigNumber(10 ** points) // Decimals = 18 on VTHO and most contracts. | |
} | |
/** | |
* Turn a string to big number. | |
* @param {String} aString a number string. | |
*/ | |
const makeBN = function (aString) { |
OlderNewer