blob_id stringlengths 40 40 | directory_id stringlengths 40 40 | path stringlengths 3 264 | content_id stringlengths 40 40 | detected_licenses listlengths 0 85 | license_type stringclasses 2
values | repo_name stringlengths 5 140 | snapshot_id stringlengths 40 40 | revision_id stringlengths 40 40 | branch_name stringclasses 905
values | visit_date timestamp[us]date 2015-08-09 11:21:18 2023-09-06 10:45:07 | revision_date timestamp[us]date 1997-09-14 05:04:47 2023-09-17 19:19:19 | committer_date timestamp[us]date 1997-09-14 05:04:47 2023-09-06 06:22:19 | github_id int64 3.89k 681M โ | star_events_count int64 0 209k | fork_events_count int64 0 110k | gha_license_id stringclasses 22
values | gha_event_created_at timestamp[us]date 2012-06-07 00:51:45 2023-09-14 21:58:39 โ | gha_created_at timestamp[us]date 2008-03-27 23:40:48 2023-08-21 23:17:38 โ | gha_language stringclasses 141
values | src_encoding stringclasses 34
values | language stringclasses 1
value | is_vendor bool 1
class | is_generated bool 2
classes | length_bytes int64 3 10.4M | extension stringclasses 115
values | content stringlengths 3 10.4M | authors listlengths 1 1 | author_id stringlengths 0 158 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
d63a0db323c182c1ec1a577d059ea377ddfa283d | a437bc72452f07c66b14ca7d01a530742b8d46f3 | /d03/ex02/ClapTrap.cpp | 90ebf08c090141141b9a9163a83ede3483e49816 | [] | no_license | armou/piscine_cpp | b73086a1411d3c7fab713ea442b3ac14bf7e1309 | 69e315ffdce8ae2ff0d9bb24dc3bc92b22d16ed0 | refs/heads/master | 2022-11-22T08:55:37.813096 | 2020-07-27T14:07:16 | 2020-07-27T14:07:16 | 282,916,084 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,471 | cpp | #include "ClapTrap.hpp"
ClapTrap::ClapTrap ( void ) {
this->_init();
this->_name = "Rick the Default ClapTrap";
std::cout << this->_name << "(ClapTrap) : Introduction." << std::endl;
return;
}
ClapTrap::ClapTrap ( std::string name ) {
this->_init();
this->_name = name;
std::cout << this->_name << "(ClapTrap) : Introduction." << std::endl;
return;
}
ClapTrap::ClapTrap ( ClapTrap const & src ) {
std::cout << "(ClapTrap) : BLIP BLIP!!!" << std::endl;
*this = src;
return;
}
ClapTrap::~ClapTrap ( void ) {
std::cout << this->_name << "(ClapTrap): Bye bye." << std::endl;
return;
}
void ClapTrap::_init ( void ) {
srand(time(NULL));
this->_hitPoints = 100;
this->_maxHitPoints = 100;
this->_energyPoints = 100;
this->_maxEnergyPoints = 100;
this->_level = 1;
this->_meleeADmg = 30;
this->_rangedADmg = 20;
this->_armorDmgReduc = 5;
}
void ClapTrap::_init ( ClapTrap const & rhs ) {
this->_hitPoints = rhs.getHitPoints();
this->_maxHitPoints = rhs.getMaxHitPoints();
this->_energyPoints = rhs.getEnergyPoints();
this->_maxEnergyPoints = rhs.getMaxEnergyPoints();
this->_level = rhs.getLevel();
this->_meleeADmg = rhs.getMeleeADmg();
this->_rangedADmg = rhs.getRangedADmg();
this->_armorDmgReduc = rhs.getArmorDmgReduc();
this->_name = rhs.getName();
}
ClapTrap & ClapTrap::operator= ( ClapTrap const & rhs ) {
std::cout << "(ClapTrap) Assignation operator called" << std::endl;
this->_hitPoints = rhs.getHitPoints();
this->_maxHitPoints = rhs.getMaxHitPoints();
this->_energyPoints = rhs.getEnergyPoints();
this->_maxEnergyPoints = rhs.getMaxEnergyPoints();
this->_level = rhs.getLevel();
this->_meleeADmg = rhs.getMeleeADmg();
this->_rangedADmg = rhs.getRangedADmg();
this->_armorDmgReduc = rhs.getArmorDmgReduc();
this->_name = rhs.getName();
return *this;
}
int ClapTrap::rangedAttack(std::string const & target) {
if (this->_hitPoints == 0) {
std::cout << this->_name << " is already dead." << std::endl;
return 0;
}
std::cout << this->_name << " attacks " << target << " with a ranged attack." << std::endl;
return this->_rangedADmg;
}
int ClapTrap::meleeAttack(std::string const & target) {
if (this->_hitPoints == 0) {
std::cout << this->_name << " is already dead." << std::endl;
return 0;
}
std::cout << this->_name << " attacks " << target << " with a melee attack." << std::endl;
return this->_meleeADmg;
}
void ClapTrap::takeDamage(unsigned int amount) {
if (this->_hitPoints == 0) {
std::cout << this->_name << " is already dead." << std::endl;
} else if (amount - this->_armorDmgReduc == 0) {
std::cout << this->_name << " take 0 damage.";
} else {
this->_hitPoints = this->_hitPoints - (amount - this->_armorDmgReduc);
if (this->_hitPoints < 0) {
this->_hitPoints = 0;
}
if (this->_hitPoints <= 0) {
std::cout << this->_name << " shut down. RIP" << std::endl;
} else {
std::cout << this->_name << " take " << amount << " damage. Reduced by ";
std::cout << this->_armorDmgReduc << std::endl;
std::cout << this->_name << " now has " << this->_hitPoints << " hp." << std::endl;
}
}
}
void ClapTrap::beRepaired(unsigned int amount) {
this->_hitPoints += amount;
if (this->_hitPoints > this->_maxHitPoints) {
this->_hitPoints = this->_maxHitPoints;
}
std::cout << this->_name << " get repaired of " << amount << " hp.";
std::cout << " He has now " << this->_hitPoints << " hp." << std::endl;
}
int ClapTrap::getHitPoints() const{
return this->_hitPoints;
}
int ClapTrap::getMaxHitPoints() const{
return this->_maxHitPoints;
}
int ClapTrap::getEnergyPoints() const{
return this->_energyPoints;
}
int ClapTrap::getMaxEnergyPoints() const{
return this->_maxEnergyPoints;
}
std::string ClapTrap::getName() const{
return this->_name;
}
int ClapTrap::getLevel() const{
return this->_level;
}
int ClapTrap::getMeleeADmg() const{
return this->_meleeADmg;
}
int ClapTrap::getRangedADmg() const{
return this->_rangedADmg;
}
int ClapTrap::getArmorDmgReduc() const{
return this->_armorDmgReduc;
}
void ClapTrap::setName(std::string name) {
this->_name = name;
} | [
"aoudin@e2r6p18.42.fr"
] | aoudin@e2r6p18.42.fr |
6ecf889d4170b7c45b6d50f00fca255ba4d72612 | 9028516ff0b2d95b8000b9fc4c44c29aa73c926c | /src/wallet/walletdb.cpp | a2ec603929ba00bd0ff8a54f747d13360e0a915a | [
"MIT"
] | permissive | lycion/TripOne | a9e546eac9ad6179c0b6bd4f868162f70930b6ac | c6ae7d9163ef4095fe0e143d26f3311182551147 | refs/heads/master | 2020-03-28T22:29:06.119551 | 2018-09-18T06:07:06 | 2018-09-18T06:07:06 | 149,236,186 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 36,000 | cpp | // Copyright (c) 2009-2010 Satoshi Nakamoto
// Copyright (c) 2009-2015 The Bitcoin Core developers
// Copyright (c) 2015-2018 The Bitcoin Unlimited developers
// Copyright (c) 2017 The Bitcoin developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "wallet/walletdb.h"
#include "base58.h"
#include "consensus/tx_verify.h"
#include "consensus/validation.h"
#include "dstencode.h"
#include "fs.h"
#include "main.h" // For CheckTransaction
#include "protocol.h"
#include "serialize.h"
#include "sync.h"
#include "util.h"
#include "utiltime.h"
#include "wallet/wallet.h"
#include <boost/scoped_ptr.hpp>
#include <boost/thread.hpp>
#include <boost/version.hpp>
#include <fstream>
using namespace std;
static uint64_t nAccountingEntryNumber = 0;
//
// CWalletDB
//
bool CWalletDB::WriteName(const CTxDestination &address, const std::string &strName)
{
if (!IsValidDestination(address))
return false;
nWalletDBUpdated++;
return Write(std::make_pair(std::string("name"), EncodeLegacyAddr(address, Params())), strName);
}
bool CWalletDB::EraseName(const CTxDestination &address)
{
// This should only be used for sending addresses, never for receiving
// addresses, receiving addresses must always have an address book entry if
// they're not change return.
if (!IsValidDestination(address))
return false;
nWalletDBUpdated++;
return Erase(std::make_pair(std::string("name"), EncodeLegacyAddr(address, Params())));
}
bool CWalletDB::WritePurpose(const CTxDestination &address, const std::string &strPurpose)
{
if (!IsValidDestination(address))
return false;
nWalletDBUpdated++;
return Write(std::make_pair(std::string("purpose"), EncodeLegacyAddr(address, Params())), strPurpose);
}
bool CWalletDB::ErasePurpose(const CTxDestination &address)
{
if (!IsValidDestination(address))
return false;
nWalletDBUpdated++;
return Erase(std::make_pair(std::string("purpose"), EncodeLegacyAddr(address, Params())));
}
bool CWalletDB::WriteTx(uint256 hash, const CWalletTx &wtx)
{
nWalletDBUpdated++;
return Write(std::make_pair(std::string("tx"), hash), wtx);
}
bool CWalletDB::EraseTx(uint256 hash)
{
nWalletDBUpdated++;
return Erase(std::make_pair(std::string("tx"), hash));
}
bool CWalletDB::WriteKey(const CPubKey &vchPubKey, const CPrivKey &vchPrivKey, const CKeyMetadata &keyMeta)
{
nWalletDBUpdated++;
if (!Write(std::make_pair(std::string("keymeta"), vchPubKey), keyMeta, false))
return false;
// hash pubkey/privkey to accelerate wallet load
std::vector<unsigned char> vchKey;
vchKey.reserve(vchPubKey.size() + vchPrivKey.size());
vchKey.insert(vchKey.end(), vchPubKey.begin(), vchPubKey.end());
vchKey.insert(vchKey.end(), vchPrivKey.begin(), vchPrivKey.end());
return Write(std::make_pair(std::string("key"), vchPubKey),
std::make_pair(vchPrivKey, Hash(vchKey.begin(), vchKey.end())), false);
}
bool CWalletDB::WriteCryptedKey(const CPubKey &vchPubKey,
const std::vector<unsigned char> &vchCryptedSecret,
const CKeyMetadata &keyMeta)
{
const bool fEraseUnencryptedKey = true;
nWalletDBUpdated++;
if (!Write(std::make_pair(std::string("keymeta"), vchPubKey), keyMeta))
return false;
if (!Write(std::make_pair(std::string("ckey"), vchPubKey), vchCryptedSecret, false))
return false;
if (fEraseUnencryptedKey)
{
Erase(std::make_pair(std::string("key"), vchPubKey));
Erase(std::make_pair(std::string("wkey"), vchPubKey));
}
return true;
}
bool CWalletDB::WriteMasterKey(unsigned int nID, const CMasterKey &kMasterKey)
{
nWalletDBUpdated++;
return Write(std::make_pair(std::string("mkey"), nID), kMasterKey, true);
}
bool CWalletDB::WriteCScript(const uint160 &hash, const CScript &redeemScript)
{
nWalletDBUpdated++;
return Write(std::make_pair(std::string("cscript"), hash), *(const CScriptBase *)(&redeemScript), false);
}
bool CWalletDB::WriteWatchOnly(const CScript &dest)
{
nWalletDBUpdated++;
return Write(std::make_pair(std::string("watchs"), *(const CScriptBase *)(&dest)), '1');
}
bool CWalletDB::EraseWatchOnly(const CScript &dest)
{
nWalletDBUpdated++;
return Erase(std::make_pair(std::string("watchs"), *(const CScriptBase *)(&dest)));
}
bool CWalletDB::WriteBestBlock(const CBlockLocator &locator)
{
nWalletDBUpdated++;
// Write empty block locator so versions that require a merkle branch automatically rescan
Write(std::string("bestblock"), CBlockLocator());
return Write(std::string("bestblock_nomerkle"), locator);
}
bool CWalletDB::ReadBestBlock(CBlockLocator &locator)
{
if (Read(std::string("bestblock"), locator) && !locator.vHave.empty())
return true;
return Read(std::string("bestblock_nomerkle"), locator);
}
bool CWalletDB::WriteOrderPosNext(int64_t nOrderPosNext)
{
nWalletDBUpdated++;
return Write(std::string("orderposnext"), nOrderPosNext);
}
bool CWalletDB::WriteDefaultKey(const CPubKey &vchPubKey)
{
nWalletDBUpdated++;
return Write(std::string("defaultkey"), vchPubKey);
}
bool CWalletDB::ReadPool(int64_t nPool, CKeyPool &keypool)
{
return Read(std::make_pair(std::string("pool"), nPool), keypool);
}
bool CWalletDB::WritePool(int64_t nPool, const CKeyPool &keypool)
{
nWalletDBUpdated++;
return Write(std::make_pair(std::string("pool"), nPool), keypool);
}
bool CWalletDB::ErasePool(int64_t nPool)
{
nWalletDBUpdated++;
return Erase(std::make_pair(std::string("pool"), nPool));
}
bool CWalletDB::WriteMinVersion(int nVersion) { return Write(std::string("minversion"), nVersion); }
bool CWalletDB::ReadAccount(const string &strAccount, CAccount &account)
{
account.SetNull();
return Read(make_pair(string("acc"), strAccount), account);
}
bool CWalletDB::WriteAccount(const string &strAccount, const CAccount &account)
{
return Write(make_pair(string("acc"), strAccount), account);
}
bool CWalletDB::WriteAccountingEntry(const uint64_t nAccEntryNum, const CAccountingEntry &acentry)
{
return Write(std::make_pair(std::string("acentry"), std::make_pair(acentry.strAccount, nAccEntryNum)), acentry);
}
bool CWalletDB::WriteAccountingEntry_Backend(const CAccountingEntry &acentry)
{
return WriteAccountingEntry(++nAccountingEntryNumber, acentry);
}
CAmount CWalletDB::GetAccountCreditDebit(const string &strAccount)
{
list<CAccountingEntry> entries;
ListAccountCreditDebit(strAccount, entries);
CAmount nCreditDebit = 0;
for (const CAccountingEntry &entry : entries)
{
nCreditDebit += entry.nCreditDebit;
}
return nCreditDebit;
}
void CWalletDB::ListAccountCreditDebit(const string &strAccount, list<CAccountingEntry> &entries)
{
bool fAllAccounts = (strAccount == "*");
Dbc *pcursor = GetCursor();
if (!pcursor)
throw runtime_error("CWalletDB::ListAccountCreditDebit(): cannot create DB cursor");
unsigned int fFlags = DB_SET_RANGE;
while (true)
{
// Read next record
CDataStream ssKey(SER_DISK, CLIENT_VERSION);
if (fFlags == DB_SET_RANGE)
ssKey << std::make_pair(
std::string("acentry"), std::make_pair((fAllAccounts ? string("") : strAccount), uint64_t(0)));
CDataStream ssValue(SER_DISK, CLIENT_VERSION);
int ret = ReadAtCursor(pcursor, ssKey, ssValue, fFlags);
fFlags = DB_NEXT;
if (ret == DB_NOTFOUND)
break;
else if (ret != 0)
{
pcursor->close();
throw runtime_error("CWalletDB::ListAccountCreditDebit(): error scanning DB");
}
// Unserialize
string strType;
ssKey >> strType;
if (strType != "acentry")
break;
CAccountingEntry acentry;
ssKey >> acentry.strAccount;
if (!fAllAccounts && acentry.strAccount != strAccount)
break;
ssValue >> acentry;
ssKey >> acentry.nEntryNo;
entries.push_back(acentry);
}
pcursor->close();
}
DBErrors CWalletDB::ReorderTransactions(CWallet *pwallet)
{
LOCK(pwallet->cs_wallet);
// Old wallets didn't have any defined order for transactions
// Probably a bad idea to change the output of this
// First: get all CWalletTx and CAccountingEntry into a sorted-by-time multimap.
typedef pair<CWalletTx *, CAccountingEntry *> TxPair;
typedef multimap<int64_t, TxPair> TxItems;
TxItems txByTime;
for (map<uint256, CWalletTx>::iterator it = pwallet->mapWallet.begin(); it != pwallet->mapWallet.end(); ++it)
{
CWalletTx *wtx = &((*it).second);
txByTime.insert(make_pair(wtx->nTimeReceived, TxPair(wtx, (CAccountingEntry *)0)));
}
list<CAccountingEntry> acentries;
ListAccountCreditDebit("", acentries);
for (CAccountingEntry &entry : acentries)
{
txByTime.insert(make_pair(entry.nTime, TxPair((CWalletTx *)0, &entry)));
}
int64_t &nOrderPosNext = pwallet->nOrderPosNext;
nOrderPosNext = 0;
std::vector<int64_t> nOrderPosOffsets;
for (TxItems::iterator it = txByTime.begin(); it != txByTime.end(); ++it)
{
CWalletTx *const pwtx = (*it).second.first;
CAccountingEntry *const pacentry = (*it).second.second;
int64_t &nOrderPos = (pwtx != 0) ? pwtx->nOrderPos : pacentry->nOrderPos;
if (nOrderPos == -1)
{
nOrderPos = nOrderPosNext++;
nOrderPosOffsets.push_back(nOrderPos);
if (pwtx)
{
if (!WriteTx(pwtx->GetHash(), *pwtx))
return DB_LOAD_FAIL;
}
else if (!WriteAccountingEntry(pacentry->nEntryNo, *pacentry))
return DB_LOAD_FAIL;
}
else
{
int64_t nOrderPosOff = 0;
for (const int64_t &nOffsetStart : nOrderPosOffsets)
{
if (nOrderPos >= nOffsetStart)
++nOrderPosOff;
}
nOrderPos += nOrderPosOff;
nOrderPosNext = std::max(nOrderPosNext, nOrderPos + 1);
if (!nOrderPosOff)
continue;
// Since we're changing the order, write it back
if (pwtx)
{
if (!WriteTx(pwtx->GetHash(), *pwtx))
return DB_LOAD_FAIL;
}
else if (!WriteAccountingEntry(pacentry->nEntryNo, *pacentry))
return DB_LOAD_FAIL;
}
}
WriteOrderPosNext(nOrderPosNext);
return DB_LOAD_OK;
}
class CWalletScanState
{
public:
unsigned int nKeys;
unsigned int nCKeys;
unsigned int nKeyMeta;
bool fIsEncrypted;
bool fAnyUnordered;
int nFileVersion;
vector<uint256> vWalletUpgrade;
CWalletScanState()
{
nKeys = nCKeys = nKeyMeta = 0;
fIsEncrypted = false;
fAnyUnordered = false;
nFileVersion = 0;
}
};
bool ReadKeyValue(CWallet *pwallet,
CDataStream &ssKey,
CDataStream &ssValue,
CWalletScanState &wss,
string &strType,
string &strErr)
{
try
{
// Unserialize
// Taking advantage of the fact that pair serialization
// is just the two items serialized one after the other
ssKey >> strType;
if (strType == "name")
{
string strAddress;
ssKey >> strAddress;
ssValue >> pwallet->mapAddressBook[DecodeDestination(strAddress)].name;
}
else if (strType == "purpose")
{
std::string strAddress;
ssKey >> strAddress;
ssValue >> pwallet->mapAddressBook[DecodeDestination(strAddress)].purpose;
}
else if (strType == "tx")
{
uint256 hash;
ssKey >> hash;
CWalletTx wtx;
ssValue >> wtx;
CValidationState state;
if (!(CheckTransaction(wtx, state) && (wtx.GetHash() == hash) && state.IsValid()))
return false;
// Undo serialize changes in 31600
if (31404 <= wtx.fTimeReceivedIsTxTime && wtx.fTimeReceivedIsTxTime <= 31703)
{
if (!ssValue.empty())
{
char fTmp;
char fUnused;
ssValue >> fTmp >> fUnused >> wtx.strFromAccount;
strErr = strprintf("LoadWallet() upgrading tx ver=%d %d '%s' %s", wtx.fTimeReceivedIsTxTime, fTmp,
wtx.strFromAccount, hash.ToString());
wtx.fTimeReceivedIsTxTime = fTmp;
}
else
{
strErr =
strprintf("LoadWallet() repairing tx ver=%d %s", wtx.fTimeReceivedIsTxTime, hash.ToString());
wtx.fTimeReceivedIsTxTime = 0;
}
wss.vWalletUpgrade.push_back(hash);
}
if (wtx.nOrderPos == -1)
wss.fAnyUnordered = true;
pwallet->AddToWallet(wtx, true, nullptr);
}
else if (strType == "acentry")
{
string strAccount;
ssKey >> strAccount;
uint64_t nNumber;
ssKey >> nNumber;
if (nNumber > nAccountingEntryNumber)
nAccountingEntryNumber = nNumber;
if (!wss.fAnyUnordered)
{
CAccountingEntry acentry;
ssValue >> acentry;
if (acentry.nOrderPos == -1)
wss.fAnyUnordered = true;
}
}
else if (strType == "watchs")
{
CScript script;
ssKey >> *(CScriptBase *)(&script);
char fYes;
ssValue >> fYes;
if (fYes == '1')
pwallet->LoadWatchOnly(script);
// Watch-only addresses have no birthday information for now,
// so set the wallet birthday to the beginning of time.
pwallet->nTimeFirstKey = 1;
}
else if (strType == "key" || strType == "wkey")
{
CPubKey vchPubKey;
ssKey >> vchPubKey;
if (!vchPubKey.IsValid())
{
strErr = "Error reading wallet database: CPubKey corrupt";
return false;
}
CKey key;
CPrivKey pkey;
uint256 hash;
if (strType == "key")
{
wss.nKeys++;
ssValue >> pkey;
}
else
{
CWalletKey wkey;
ssValue >> wkey;
pkey = wkey.vchPrivKey;
}
// Old wallets store keys as "key" [pubkey] => [privkey]
// ... which was slow for wallets with lots of keys, because the public key is re-derived from the private
// key
// using EC operations as a checksum.
// Newer wallets store keys as "key"[pubkey] => [privkey][hash(pubkey,privkey)], which is much faster while
// remaining backwards-compatible.
try
{
ssValue >> hash;
}
catch (...)
{
}
bool fSkipCheck = false;
if (!hash.IsNull())
{
// hash pubkey/privkey to accelerate wallet load
std::vector<unsigned char> vchKey;
vchKey.reserve(vchPubKey.size() + pkey.size());
vchKey.insert(vchKey.end(), vchPubKey.begin(), vchPubKey.end());
vchKey.insert(vchKey.end(), pkey.begin(), pkey.end());
if (Hash(vchKey.begin(), vchKey.end()) != hash)
{
strErr = "Error reading wallet database: CPubKey/CPrivKey corrupt";
return false;
}
fSkipCheck = true;
}
if (!key.Load(pkey, vchPubKey, fSkipCheck))
{
strErr = "Error reading wallet database: CPrivKey corrupt";
return false;
}
if (!pwallet->LoadKey(key, vchPubKey))
{
strErr = "Error reading wallet database: LoadKey failed";
return false;
}
}
else if (strType == "mkey")
{
unsigned int nID;
ssKey >> nID;
CMasterKey kMasterKey;
ssValue >> kMasterKey;
if (pwallet->mapMasterKeys.count(nID) != 0)
{
strErr = strprintf("Error reading wallet database: duplicate CMasterKey id %u", nID);
return false;
}
pwallet->mapMasterKeys[nID] = kMasterKey;
if (pwallet->nMasterKeyMaxID < nID)
pwallet->nMasterKeyMaxID = nID;
}
else if (strType == "ckey")
{
CPubKey vchPubKey;
ssKey >> vchPubKey;
if (!vchPubKey.IsValid())
{
strErr = "Error reading wallet database: CPubKey corrupt";
return false;
}
vector<unsigned char> vchPrivKey;
ssValue >> vchPrivKey;
wss.nCKeys++;
if (!pwallet->LoadCryptedKey(vchPubKey, vchPrivKey))
{
strErr = "Error reading wallet database: LoadCryptedKey failed";
return false;
}
wss.fIsEncrypted = true;
}
else if (strType == "keymeta")
{
CPubKey vchPubKey;
ssKey >> vchPubKey;
CKeyMetadata keyMeta;
ssValue >> keyMeta;
wss.nKeyMeta++;
pwallet->LoadKeyMetadata(vchPubKey, keyMeta);
// find earliest key creation time, as wallet birthday
if (!pwallet->nTimeFirstKey || (keyMeta.nCreateTime < pwallet->nTimeFirstKey))
pwallet->nTimeFirstKey = keyMeta.nCreateTime;
}
else if (strType == "defaultkey")
{
ssValue >> pwallet->vchDefaultKey;
}
else if (strType == "pool")
{
int64_t nIndex;
ssKey >> nIndex;
CKeyPool keypool;
ssValue >> keypool;
pwallet->setKeyPool.insert(nIndex);
// If no metadata exists yet, create a default with the pool key's
// creation time. Note that this may be overwritten by actually
// stored metadata for that key later, which is fine.
CKeyID keyid = keypool.vchPubKey.GetID();
if (pwallet->mapKeyMetadata.count(keyid) == 0)
pwallet->mapKeyMetadata[keyid] = CKeyMetadata(keypool.nTime);
}
else if (strType == "version")
{
ssValue >> wss.nFileVersion;
if (wss.nFileVersion == 10300)
wss.nFileVersion = 300;
}
else if (strType == "cscript")
{
uint160 hash;
ssKey >> hash;
CScript script;
ssValue >> *(CScriptBase *)(&script);
if (!pwallet->LoadCScript(script))
{
strErr = "Error reading wallet database: LoadCScript failed";
return false;
}
}
else if (strType == "orderposnext")
{
ssValue >> pwallet->nOrderPosNext;
}
else if (strType == "destdata")
{
std::string strAddress, strKey, strValue;
ssKey >> strAddress;
ssKey >> strKey;
ssValue >> strValue;
if (!pwallet->LoadDestData(DecodeDestination(strAddress), strKey, strValue))
{
strErr = "Error reading wallet database: LoadDestData failed";
return false;
}
}
else if (strType == "hdchain")
{
CHDChain chain;
ssValue >> chain;
if (!pwallet->SetHDChain(chain, true))
{
strErr = "Error reading wallet database: SetHDChain failed";
return false;
}
}
}
catch (...)
{
return false;
}
return true;
}
static bool IsKeyType(string strType)
{
return (strType == "key" || strType == "wkey" || strType == "mkey" || strType == "ckey");
}
DBErrors CWalletDB::LoadWallet(CWallet *pwallet)
{
pwallet->vchDefaultKey = CPubKey();
CWalletScanState wss;
bool fNoncriticalErrors = false;
DBErrors result = DB_LOAD_OK;
LOCK2(cs_main, pwallet->cs_wallet);
try
{
int nMinVersion = 0;
if (Read((string) "minversion", nMinVersion))
{
if (nMinVersion > CLIENT_VERSION)
return DB_TOO_NEW;
pwallet->LoadMinVersion(nMinVersion);
}
// Get cursor
Dbc *pcursor = GetCursor();
if (!pcursor)
{
LOGA("Error getting wallet database cursor\n");
return DB_CORRUPT;
}
while (true)
{
// Read next record
CDataStream ssKey(SER_DISK, CLIENT_VERSION);
CDataStream ssValue(SER_DISK, CLIENT_VERSION);
int ret = ReadAtCursor(pcursor, ssKey, ssValue);
if (ret == DB_NOTFOUND)
break;
else if (ret != 0)
{
LOGA("Error reading next record from wallet database\n");
return DB_CORRUPT;
}
// Try to be tolerant of single corrupt records:
string strType, strErr;
if (!ReadKeyValue(pwallet, ssKey, ssValue, wss, strType, strErr))
{
// losing keys is considered a catastrophic error, anything else
// we assume the user can live with:
if (IsKeyType(strType))
result = DB_CORRUPT;
else
{
// Leave other errors alone, if we try to fix them we might make things worse.
fNoncriticalErrors = true; // ... but do warn the user there is something wrong.
if (strType == "tx")
// Rescan if there is a bad transaction record:
SoftSetBoolArg("-rescan", true);
}
}
if (!strErr.empty())
LOGA("%s\n", strErr);
}
pcursor->close();
}
catch (const boost::thread_interrupted &)
{
throw;
}
catch (...)
{
result = DB_CORRUPT;
}
if (fNoncriticalErrors && result == DB_LOAD_OK)
result = DB_NONCRITICAL_ERROR;
// Any wallet corruption at all: skip any rewriting or
// upgrading, we don't want to make it worse.
if (result != DB_LOAD_OK)
return result;
LOGA("nFileVersion = %d\n", wss.nFileVersion);
LOGA("Keys: %u plaintext, %u encrypted, %u w/ metadata, %u total\n", wss.nKeys, wss.nCKeys, wss.nKeyMeta,
wss.nKeys + wss.nCKeys);
// nTimeFirstKey is only reliable if all keys have metadata
if ((wss.nKeys + wss.nCKeys) != wss.nKeyMeta)
pwallet->nTimeFirstKey = 1; // 0 would be considered 'no value'
for (uint256 &hash : wss.vWalletUpgrade)
{
WriteTx(hash, pwallet->mapWallet[hash]);
}
// Rewrite encrypted wallets of versions 0.4.0 and 0.5.0rc:
if (wss.fIsEncrypted && (wss.nFileVersion == 40000 || wss.nFileVersion == 50000))
return DB_NEED_REWRITE;
if (wss.nFileVersion < CLIENT_VERSION) // Update
WriteVersion(CLIENT_VERSION);
if (wss.fAnyUnordered)
result = ReorderTransactions(pwallet);
pwallet->laccentries.clear();
ListAccountCreditDebit("*", pwallet->laccentries);
for (CAccountingEntry &entry : pwallet->laccentries)
{
pwallet->wtxOrdered.insert(make_pair(entry.nOrderPos, CWallet::TxPair((CWalletTx *)0, &entry)));
}
return result;
}
DBErrors CWalletDB::FindWalletTx(CWallet *pwallet, vector<uint256> &vTxHash, vector<CWalletTx> &vWtx)
{
pwallet->vchDefaultKey = CPubKey();
bool fNoncriticalErrors = false;
DBErrors result = DB_LOAD_OK;
LOCK(pwallet->cs_wallet);
try
{
int nMinVersion = 0;
if (Read((string) "minversion", nMinVersion))
{
if (nMinVersion > CLIENT_VERSION)
return DB_TOO_NEW;
pwallet->LoadMinVersion(nMinVersion);
}
// Get cursor
Dbc *pcursor = GetCursor();
if (!pcursor)
{
LOGA("Error getting wallet database cursor\n");
return DB_CORRUPT;
}
while (true)
{
// Read next record
CDataStream ssKey(SER_DISK, CLIENT_VERSION);
CDataStream ssValue(SER_DISK, CLIENT_VERSION);
int ret = ReadAtCursor(pcursor, ssKey, ssValue);
if (ret == DB_NOTFOUND)
break;
else if (ret != 0)
{
LOGA("Error reading next record from wallet database\n");
return DB_CORRUPT;
}
string strType;
ssKey >> strType;
if (strType == "tx")
{
uint256 hash;
ssKey >> hash;
CWalletTx wtx;
ssValue >> wtx;
vTxHash.push_back(hash);
vWtx.push_back(wtx);
}
}
pcursor->close();
}
catch (const boost::thread_interrupted &)
{
throw;
}
catch (...)
{
result = DB_CORRUPT;
}
if (fNoncriticalErrors && result == DB_LOAD_OK)
result = DB_NONCRITICAL_ERROR;
return result;
}
DBErrors CWalletDB::ZapSelectTx(CWallet *pwallet, vector<uint256> &vTxHashIn, vector<uint256> &vTxHashOut)
{
// build list of wallet TXs and hashes
vector<uint256> vTxHash;
vector<CWalletTx> vWtx;
DBErrors err = FindWalletTx(pwallet, vTxHash, vWtx);
if (err != DB_LOAD_OK)
{
return err;
}
std::sort(vTxHash.begin(), vTxHash.end());
std::sort(vTxHashIn.begin(), vTxHashIn.end());
// erase each matching wallet TX
bool delerror = false;
vector<uint256>::iterator it = vTxHashIn.begin();
for (uint256 hash : vTxHash)
{
while (it < vTxHashIn.end() && (*it) < hash)
{
it++;
}
if (it == vTxHashIn.end())
{
break;
}
else if ((*it) == hash)
{
pwallet->mapWallet.erase(hash);
if (!EraseTx(hash))
{
LOG(DBASE, "Transaction was found for deletion but returned database error: %s\n", hash.GetHex());
delerror = true;
}
vTxHashOut.push_back(hash);
}
}
if (delerror)
{
return DB_CORRUPT;
}
return DB_LOAD_OK;
}
DBErrors CWalletDB::ZapWalletTx(CWallet *pwallet, vector<CWalletTx> &vWtx)
{
// build list of wallet TXs
vector<uint256> vTxHash;
DBErrors err = FindWalletTx(pwallet, vTxHash, vWtx);
if (err != DB_LOAD_OK)
return err;
// erase each wallet TX
for (uint256 &hash : vTxHash)
{
if (!EraseTx(hash))
return DB_CORRUPT;
}
return DB_LOAD_OK;
}
void ThreadFlushWalletDB(const string &strFile)
{
// Make this thread recognisable as the wallet flushing thread
RenameThread("tripone-wallet");
static bool fOneThread;
if (fOneThread)
return;
fOneThread = true;
if (!GetBoolArg("-flushwallet", DEFAULT_FLUSHWALLET))
return;
unsigned int nLastSeen = nWalletDBUpdated;
unsigned int nLastFlushed = nWalletDBUpdated;
int64_t nLastWalletUpdate = GetTime();
while (true)
{
MilliSleep(500);
if (nLastSeen != nWalletDBUpdated)
{
nLastSeen = nWalletDBUpdated;
nLastWalletUpdate = GetTime();
}
if (nLastFlushed != nWalletDBUpdated && GetTime() - nLastWalletUpdate >= 2)
{
TRY_LOCK(bitdb.cs_db, lockDb);
if (lockDb)
{
// Don't do this if any databases are in use
int nRefCount = 0;
map<string, int>::iterator mi = bitdb.mapFileUseCount.begin();
while (mi != bitdb.mapFileUseCount.end())
{
nRefCount += (*mi).second;
mi++;
}
if (nRefCount == 0)
{
boost::this_thread::interruption_point();
map<string, int>::iterator mi2 = bitdb.mapFileUseCount.find(strFile);
if (mi2 != bitdb.mapFileUseCount.end())
{
LOG(DBASE, "Flushing wallet.dat\n");
nLastFlushed = nWalletDBUpdated;
int64_t nStart = GetTimeMillis();
// Flush wallet.dat so it's self contained
bitdb.CloseDb(strFile);
bitdb.CheckpointLSN(strFile);
bitdb.mapFileUseCount.erase(mi2++);
LOG(DBASE, "Flushed wallet.dat %dms\n", GetTimeMillis() - nStart);
}
}
}
}
}
}
bool BackupWallet(const CWallet &wallet, const string &strDest)
{
if (!wallet.fFileBacked)
return false;
while (true)
{
{
LOCK(bitdb.cs_db);
if (!bitdb.mapFileUseCount.count(wallet.strWalletFile) || bitdb.mapFileUseCount[wallet.strWalletFile] == 0)
{
// Flush log data to the dat file
bitdb.CloseDb(wallet.strWalletFile);
bitdb.CheckpointLSN(wallet.strWalletFile);
bitdb.mapFileUseCount.erase(wallet.strWalletFile);
// Copy wallet.dat
boost::filesystem::path pathSrc = GetDataDir() / wallet.strWalletFile;
boost::filesystem::path pathDest(strDest);
if (boost::filesystem::is_directory(pathDest))
pathDest /= wallet.strWalletFile;
// BU copy_file does not work with c++11, due to a link error in many versions of boost. Return this
// code to use when the default boost version in most distros fix this bug.
// try {
//#if BOOST_VERSION >= 104000
// boost::filesystem::copy_file(pathSrc, pathDest,
// boost::filesystem::copy_option::overwrite_if_exists);
//#else
// boost::filesystem::copy_file(pathSrc, pathDest);
//#endif
// LOGA("copied wallet.dat to %s\n", pathDest.string());
// return true;
// } catch (const boost::filesystem::filesystem_error& e) {
// LOGA("error copying wallet.dat to %s - %s\n", pathDest.string(), e.what());
// return false;
// }
// Replacement copy code
try
{
ifstream source(pathSrc.string(), ios::binary);
ofstream dest(pathDest.string(), ios::binary);
if (!source)
{
LOGA("error opening source wallet file %s\n", pathSrc.string());
return false;
}
if (!dest)
{
LOGA("error opening destination wallet file %s\n", pathDest.string());
return false;
}
dest << source.rdbuf();
return true;
}
catch (std::ios_base::failure &e)
{
LOGA("error copying wallet from %s to %s - %s\n", pathSrc.string(), pathDest.string(), e.what());
return false;
}
// end replacement copy code
}
}
MilliSleep(100);
}
return false;
}
//
// Try to (very carefully!) recover wallet.dat if there is a problem.
//
bool CWalletDB::Recover(CDBEnv &dbenv, const std::string &filename, bool fOnlyKeys)
{
// Recovery procedure:
// move wallet.dat to wallet.timestamp.bak
// Call Salvage with fAggressive=true to
// get as much data as possible.
// Rewrite salvaged data to wallet.dat
// Set -rescan so any missing transactions will be
// found.
int64_t now = GetTime();
std::string newFilename = strprintf("wallet.%d.bak", now);
int result = dbenv.dbenv->dbrename(nullptr, filename.c_str(), nullptr, newFilename.c_str(), DB_AUTO_COMMIT);
if (result == 0)
LOGA("Renamed %s to %s\n", filename, newFilename);
else
{
LOGA("Failed to rename %s to %s\n", filename, newFilename);
return false;
}
std::vector<CDBEnv::KeyValPair> salvagedData;
bool fSuccess = dbenv.Salvage(newFilename, true, salvagedData);
if (salvagedData.empty())
{
LOGA("Salvage(aggressive) found no records in %s.\n", newFilename);
return false;
}
LOGA("Salvage(aggressive) found %u records\n", salvagedData.size());
boost::scoped_ptr<Db> pdbCopy(new Db(dbenv.dbenv, 0));
int ret = pdbCopy->open(nullptr, // Txn pointer
filename.c_str(), // Filename
"main", // Logical db name
DB_BTREE, // Database type
DB_CREATE, // Flags
0);
if (ret > 0)
{
LOGA("Cannot create database file %s\n", filename);
return false;
}
CWallet dummyWallet;
CWalletScanState wss;
DbTxn *ptxn = dbenv.TxnBegin();
for (CDBEnv::KeyValPair &row : salvagedData)
{
if (fOnlyKeys)
{
CDataStream ssKey(row.first, SER_DISK, CLIENT_VERSION);
CDataStream ssValue(row.second, SER_DISK, CLIENT_VERSION);
string strType, strErr;
bool fReadOK;
{
// Required in LoadKeyMetadata():
LOCK(dummyWallet.cs_wallet);
fReadOK = ReadKeyValue(&dummyWallet, ssKey, ssValue, wss, strType, strErr);
}
if (!IsKeyType(strType))
continue;
if (!fReadOK)
{
LOGA("WARNING: CWalletDB::Recover skipping %s: %s\n", strType, strErr);
continue;
}
}
Dbt datKey(&row.first[0], row.first.size());
Dbt datValue(&row.second[0], row.second.size());
int ret2 = pdbCopy->put(ptxn, &datKey, &datValue, DB_NOOVERWRITE);
if (ret2 > 0)
fSuccess = false;
}
ptxn->commit(0);
pdbCopy->close(0);
return fSuccess;
}
bool CWalletDB::Recover(CDBEnv &dbenv, const std::string &filename)
{
return CWalletDB::Recover(dbenv, filename, false);
}
bool CWalletDB::WriteDestData(const CTxDestination &address, const std::string &key, const std::string &value)
{
if (!IsValidDestination(address))
return false;
nWalletDBUpdated++;
return Write(
std::make_pair(std::string("destdata"), std::make_pair(EncodeLegacyAddr(address, Params()), key)), value);
}
bool CWalletDB::EraseDestData(const CTxDestination &address, const std::string &key)
{
if (!IsValidDestination(address))
return false;
nWalletDBUpdated++;
return Erase(std::make_pair(std::string("destdata"), std::make_pair(EncodeLegacyAddr(address, Params()), key)));
}
bool CWalletDB::WriteHDChain(const CHDChain &chain)
{
nWalletDBUpdated++;
return Write(std::string("hdchain"), chain);
}
| [
"lycion@gmail.com"
] | lycion@gmail.com |
e25fab947e04640a6b01d3891156423f5b01ba5a | c3ad6263554e6b5c8b7c4ff969d9296f708778fa | /HW_Project_9/homework_1572887168/Lesson9_1/Lesson9_1/Lesson9_1.cpp | 9aa83491a0da5b83b5e0f1244a961e82177de1e4 | [] | no_license | Cybr0/C_Cpp__Part-3 | 47b5f4bd1b069e678a08848cdf5e95c4c05b86c5 | 5015c285b6735e7de7b4f84300e585b8f80e2b6c | refs/heads/master | 2022-10-19T05:09:30.976833 | 2020-06-12T12:20:16 | 2020-06-12T12:20:16 | 271,791,390 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 920 | cpp | ๏ปฟ#include <iostream>
#include <sstream>
#include "Array.h"
void check_true(bool v) {
if (v) {
std::cout << "OK" << std::endl;
}
else {
std::cout << "FAIL" << std::endl;
}
}
bool compare(double a, double b) {
return (fabs(a - b) < DBL_EPSILON);
}
int main() {
Array arr;
arr.push_back(1);
arr.push_back(2);
arr.push_back(3);
arr.push_back(4);
check_true(arr[0] == 1);
check_true(arr[1] == 2);
check_true(arr[2] == 3);
check_true(arr[3] == 4);
check_true(arr.size() == 4);
check_true(arr.capacity() == 10);
arr[0] = 10;
arr.operator[](1) = 20;
arr[2] = 30;
arr[3] = 40;
check_true(arr[0] == 10);
check_true(arr[1] == 20);
check_true(arr[2] == 30);
check_true(arr[3] == 40);
arr(6);
check_true(arr[0] == 16);
check_true(arr[1] == 26);
check_true(arr[2] == 36);
check_true(arr[3] == 46);
std::stringstream ss;
ss << arr;
check_true(ss.str() == std::string("16 26 36 46 "));
} | [
"44771809+Cybr0@users.noreply.github.com"
] | 44771809+Cybr0@users.noreply.github.com |
9543a0b91d1e8d4113d8cea4119dc6ab3edc2b52 | 1038d0511ab29f6bc2e50c5328823730e49bc4c5 | /datacombobox.hxx | 249fe1ab3472d2ee95c8d8feb2a24d91addca682 | [] | no_license | johanneslochmann/datacollector | 9a23f8186ac247d13af50af4a365946259dd228c | 77b7d675ef8a15fda0bd6b512026a8f1afffc616 | refs/heads/master | 2021-01-10T09:52:08.135378 | 2016-02-19T20:07:38 | 2016-02-19T20:07:38 | 45,186,142 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 439 | hxx | #pragma once
#include <QComboBox>
#include "storable.hxx"
class DataComboBox : public QComboBox
{
Q_OBJECT
public:
explicit DataComboBox(QWidget* p);
signals:
void datasetActivated(const StorableSPtr s);
public slots:
void onItemActivated(const QString& txt);
void reload() { implReload(); }
protected:
virtual StorableSPtr storableForText(const QString& txt) const = 0;
virtual void implReload() = 0;
};
| [
"johannes.lochmann@gmail.com"
] | johannes.lochmann@gmail.com |
c7738e67597c88d33a6e68a153141cb1678bf987 | 7dedb11bd6620b14004d2fead3d0d47daf2b98bf | /CodeForces/cf-653b.cpp | 8a77a3eeead9e34ec899ea5485645f3fcd059de7 | [] | no_license | nickzuck/Competitive-Programming | 2899d6601e2cfeac919276e437a77697ac9be922 | 5abb02a527dd4cc379bb48061f60501fc22da476 | refs/heads/master | 2021-01-15T09:19:34.607887 | 2016-06-01T20:38:45 | 2016-06-01T20:38:45 | 65,146,214 | 1 | 0 | null | 2016-08-07T17:44:47 | 2016-08-07T17:44:44 | null | UTF-8 | C++ | false | false | 969 | cpp | #include <iostream>
#include <cstdio>
#include <string>
#include <sstream>
#include <vector>
#include <list>
#include <set>
#include <map>
#include <queue>
#include <stack>
#include <bitset>
#include <numeric>
#include <iterator>
#include <algorithm>
#include <cmath>
#include <chrono>
#include <cassert>
using namespace std;
using ll = long long;
using ld = long double;
using ii = pair<ll, ll>;
using vi = vector<ll>;
using vb = vector<bool>;
using vvi = vector<vi>;
using vii = vector<ii>;
using vvii = vector<vii>;
const int INF = 2000000000;
const ll LLINF = 9000000000000000000;
ll dfs(int i, vvi &E, int c) {
if (c == 0) return 1LL;
ll ret = 0;
for (int j : E[i])
ret += dfs(j, E, c - 1);
return ret;
}
int main() {
ios::sync_with_stdio(false);
cin.tie(NULL);
int N, Q;
cin >> N >> Q;
vvi E(6, vi());
while (Q--) {
string a, b;
cin >> a >> b;
E[b[0] - 'a'].push_back(a[0] - 'a');
}
cout << dfs(0, E, N - 1) << endl;
return 0;
}
| [
"timonknigge@live.nl"
] | timonknigge@live.nl |
4338c536ffdc6ee00f19a12cd2d8cb61b5938ce5 | c6df5d16f8d0d81f8eb10a0d6934567af755aa38 | /Sigma/Stations/MachineControl/MachineControl/Class/SigCLib/CTimeLib.cpp | 48d16a8e2094b1ddd848baf792f942717ddb5cfe | [] | no_license | Strosel/T4Exjobb | 9b6b380ec3b3a9222981b202f9013b52bc7f2335 | 7257ef722639881660877671b8d87eaefe3512ae | refs/heads/master | 2020-05-02T04:27:37.618992 | 2019-04-23T08:09:26 | 2019-04-23T08:09:26 | 177,750,346 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 61,998 | cpp | //{{LSL_ENCRYPTION 16#800
151A52AEF342212FF2412A957A14F9951AA6DF12D5310040D0233BAA85AFE3D6402A9029FE51EAC05C3321FA075FA164C4C51EA98B4E340364329B110105DCDDC73BF48BD995F7DF7FAD87BB00832C2D002C7AC0D56326E4D39A33562F89A9400367E185
BA374CAD0061F886595D6A64BC74CAB63F012E7529FC3F04CDC0CEC4D00D8F7B1E71669A6B7A579E28F3AAE3B02A38151EA2CCC31F4B7B11F0DA855F8D16F59498A6405C161749F6615D23E8F09B201DA03337E34A2374F223C3423F7A4F9A58D158B4B4
44F8F11E3DB1E6A812F79A36F4C7FF9E2372171C2343FC8CDC4C787878D8B15143CA2CF08BF7817A535FBEE89BFCAA1F4F10279C734C032326D1C1F8DBFC931A30BE5FBD8F1F8BE54225834A67FFE3056D8A16D35BD0C98337BE0412F7BACD9C55B204FF
E4E3AF57A2751EA16CBFB4EF324E6CC228704A81D69B042C2A5C9BD7A09BADA73AD203EB198EF017C522CC5E2181D7E9CD63E0F193C394CE7351D33FDC5A28600E92841966A0FEDFB259AADEA8563D2A7B59161377633799C5AE9B220DF1248D4A537665
5719888B09E92120E6392C734598B362E6E718DEBB75CAB81C5B7222AB05056025CAE0449255312C5FF2B8E94315407D5D39574D5CB8B53F839C640EB3AE9B42E9259B37809CEDA72764637164689838D8C6A4C4161AE6890CE1388F92942A1A43CF7115
CBA81E950DA704D32731D66D0820FC54360A93794045B1CFC34D204BA8F01B0FD2AD7321B2AFA15B3F92031FEF8209D8448497C7F80F70C8A4271A6D77FC5BA1A110B9B9CB0D366175E467693D2DD294C142186422D9843385FA94BDF77EBFACD89AEEF3
1907BD95D32A6EC5C70FE0BE10A891C3E4DE8B315CF7813F88948844647AB7281A09D00DC240D916DE8C2D3728FB67E1B215F2A433453ECEA6883FBCDB6CCA70C9CA5B827014D12A2BBFC070D114A0BFD8DB348A93609A6E31A786D87FB4103DBC9CC2C5
8744C19EC51631241B7B139FB7F8F147D3377324B70ED127B7F547E8975715E6F8DB31414E04AB64D18CC12B228E0DF8F598993921A8AB40817DA71BFE311AE39076EB55A221184224E2EF8A41FC0DB7DAEB349E8C76BB4CD66BE54594897062FEF32BC4
B6379E337292BA976ED8122E64A34DEEB654C70695780304C4BA522E2CFE46639F17B06D3D579C786611B3E54516A10CF2AB9A5FAE5224D48A503A167243AC4DEC25AFC9061D671D3DCB418D30063063055CDE0B1922E17C02E0404E341520284C77B497
88EA3AFC41C2C3C8A8BD467ADB558B1F2E3CDABCD01F1A8D9B82CFC090F34DCE7567B01E4CC98F0B6AF3BD59C780A08C3CECE25A8730B6DF89B95F16DB4FF572DC6DD84971A2CE5681736D5443E7158E73826D05D2D6F7E769C8DB999D35CBC3186FEE0D
811D48BAA62705CA16C05453FFE67AEBE17BC2BFAE989A854E2400F8E87CA14FD8FC8B00C5BD96967411AF11E45D7EA03B20C7657A79C238C6CD731AA9F86F4783CBC2A1CC21AAF133808B204EEB18C33315AF49DAFE5BB7E3ADDDC850B9CE33A326D29B
0CDC5ED3EAC592C93980B896F498100A28F972638EAF828C4244F9E2DF9D9FCE62E709CAACF1850784D3548BAE601525B7736FAE83D1045E1E6A65CBCCBBA06EB38A60ADF8A839EB88A6C3FE7644449BDA857457345120409A3E322C8143C881E9FB9F0C
B341CBCDEBE65050C39E79D5ED7A971B81692D80C282DE8934384114067D8999D0094229BF968CDC1803710D0A20F6D9A8640603795E7DE422A5CC624446A3F50687EC5B904FB5A845460DBFB894C4E91884DD2A594E1635E0FD3CA9D152899AA093067E
FEE7A65D004104547EDB7FEB8672EE4B065228DC1B442DE3C47DE093CA8A73330510F7EE039D099D969ADABEE064CDA0D8D67DB9EAA17AFB36B76D3C4C0E380C3021FB3FC0A1F7DD0F8612A18E0CF2D5DEF402A892ECC3E10A6960E33AAB72F093363246
EEFA9934D0AA0B9E7CF0EDB2E227BEED6A3BB78A570097BA34A222754F715129FBCE03B1B29450A7D5189CAA62D7A87B1C3DF506401341F022DA190E9F6A938B1231DA3D67528B81C9A5F7718C0F79FC0B45CB74FAE88D92D79038357ED6C7F492457F56
87FE8E9B522D97ED00D6856B6451AEAA7C412F6128396CCFB55D7F9C21EE9B599BD62CE4A658D86E230FDE453C18A04C714806DE175BAE3F40AA16A9980DCFE85F5D0598652F2271264A42E5C3FF7FCBDA2AFCB6B6A0FBBE9E0B9BB6D4821880627F973D
23C40EA25005CF1F7037E33F62ED1F94DA5B01270DA3F7F6CDF1749063C84A7A6EE626F46919A567B7DBA228E17B33460799569A0D41ABA216930D953CF54E61C2367DDAD57A0C50F045D58678E8340F9F07894841D6FF45B1005302CBC540EC39C1CD7E
914E71398767409C0CD41A893CE4B725BCB96CAEF58988E58EF3D712AAC66C2FE35DEDFD241DEAC16D9CB0FBA232FFCCB07804D3E79C528F04AF1E4CAAB1DB9E8A27DAF187B0A73CB076E76706B348EA43564F10DF33046C49F3E3C87B3A16FC82D4D71B
67854033752B4E788974AB5597789109DB2EFCFFE9F8FBFDEB19EAEF1BFFA4BEFDBD7084575F9AF0C5299852FB25EF92AA68CD968D98E218E18A9B966CF8609D0A7952CFD82850FBA5D46AEC4457BC45934555486B1E5BCBA2BE82BD97088556B3ECDAB7
AD18471038E68E5F0BE00E062B30B23CA59D8822B84D7716AF24B6C0D5E4B1136ED4C25912755461D3F13518D49C2F796B2F9BA5A2F502C34853F5F074A26D0D51F2733B8B8F263E1A1D76D2DB804DE68C7F60B08258F2512AAF781D86BA0EBC178DD24B
CA971357D7C4123F0E99BB93C57F2FA909AB728A85ADEA59BAC372A8D7FFB6196385917111723CB4C5362FD66D6FB240E041A8A107A4DE5C18B2F7B68CA2BACDCE19635975B83FA0530924C42E781721CFAAD77C35707CABE77A084F31405C65A4A90508
D6F0A9F12C7B2A3AD8A6E70CE278C240F9A66D8B3772A9FA62A14A96751C007200004D39554D53BD4BD1EA690D929BE83290DBE6C99507525327962D58146A02C1947A12C7437C34E12BFC29875C51EF72D70D609F8748F9DB811DC14EC6F9DD6DBC4930
BADF97A6A84FE727124A945DE74C5D64F1AF2D39D6DDEF8E4F69A6B2A3A5F20E3B591F743712B7E225CED788A8A3E9256F1AAB30C26C84E40C91C4876C5AE6A55909D607DE2BDA96D50226E7A4953721300133D7A98213EA135E7FBB716C50FED5E0EA58
54F1F223D23E4E5B7304B2E0FC0805692AA4E90699CCB89CDC1E7CBE017E2CB6E79DBAF81A4E27DD07AC568375CE0848688608A4FDC39871202BA646A60E2C41A6F553A47D9E412903FD9D17C3F464BB0A2A854E725F52CFFEAFC048EF571BC79FA3B86A
0214C0A24E404DDDE0CF71C9CCFE63C9020BC2DAC33A6DDF227471F7573D1B8B6E5490A44F8A2B92CE0A63417DE2F9FACB99B0485E05311A02727D0317487CE29687FA90A290F4B38DE8BC0BB58716D11565C1A177272D7AE67DE158C8A2CAE82C7436AE
9BCDDEF5341B55FB0001821D9A3EA263D727181D7A913487B1C6A64A70F91B0CAD60B09DCCB93B3F42863E50B4F0860CAD16DCD82068779A6887CAF3205CBD355EE94D0385B5A157A39B9DC03C06080AD7050287EF89E026271B8612B96D8F81614EACB6
2A1685E113FDCC7030CE93AF845D097A064958EA23711C154BBD2B5A7C9A04CA2E16F21D2E12B401EA2250FC23108F76CA845FC49572F375A60CA8D50E999316AE24088EA0C46309CA68A8556DE3D447A008FED99F29DAACEB56397AD28F61EFB8473B70
CA2B80EEA0048B061FCB6589835BB640FEAC6725E355BA8413F7F482FD99E59EBD564C13C226F3DFC34C61DC5A8E069211C8CC7FD6B5423676BB1C6EA6C5E8D9E822FAB8AA06BAB54C437960237D801D84B238EEE7E7EEA814C9FD8E912ABA366E4BDFBB
547733DFBA2DBF58E3B0BD9DF0F528CC6A59EF7B8B7A64234320399E150843A48061375E3147879BB0F51081AD3D4BAC46A811EAC7B60BB51CC7361350BB04593D8931152334AB17FCB4600107F5685F0F60838AB53F9F03C460115CE2621390A4B49402
66658D8DBB9D5A14C9F32C7110E3985D5A672B114D0D82FC136C807F281E39F8EFE42CA1A2F5E50EBE8D9D1DC6AF717CC1781B9E168EF331F0D51076105E5D62EBB27AB70D87CBBC1AAE9DFE8802DA5B2A10C35751F4F95C2C3358F7DC754CE5D632E145
9605BC93A71189105D350804EB342DE0CF2F2EEAE42E102E3C08B02435C5B0EFEC502254B422E65396A921920347A1CB5204A25535469606482F9EB5B964E6DACF5B33E9BBDADCC3BC8EFDABABB903856F07F1DD2F5385D60224E1EFCE5C65318223B915
57DEAA9923B18484F5EEBAA7180F0DC476B17BBC5386B017212B454DA0C6E228B0CF1E94065749D54AD984FB8ADC39044C8829CBADFD2776B099C21368AB75A90F773C2970BC2D74DD9D3E4BBCA1C86A090D43F8D9DD2297D155BF9B2C2058BE03A6550E
37B694F3170B13F3CF77EF861F30305CB5641671A0144564FE2B559980D92DC55FE3515FAD046906E33F242AAE0A609049E680D95FD451EF45CE98BB38ECEA407AF9BB81A8AA57255F6854F20115F08F5D1B6A5027FC1129261BB3C0E0172E4973A8FA11
459068FBD2EBE67A6F4DCF7F1D1F0DA147EBE4B6C9286F14E119B91FE592BE71B4270CE16289D2BD1067C7DC71976C55DA3D4F353C2DA3AC7671124EF12BE27AE045FC66E2C03B134A583947DB771CB7A9266016BB7D44BD3F7620907ACEC21C3E62FA8D
BF54CD7AB8F3E5CCC3439740B654B33CF445B05763C8A3480545B66D83354C80D0FC52F219EA146436EFFAA13FDBB4A165FFE73292DB828D669BB18EB7A3343823CFE919EF8C0CA217604B117189E59D5517AEB3D5212CB7A08E50C752D15C30B8D672F5
3810D54A8AFA987425F6160F3ABDCCD5E96678F04F45D7972F3B9EFD055DB97B6AAA277FF1E7AE1619853393C567C7AAED1F3CB5C9390DCD979B217DE122F3F1916737A0A424D783220D5A30C2B42C84742ADA90E185B685222F0752EC7BFAC7D44A0F47
DF517E8A5B443B524F8325CEE3B4335A3FC8E6C506504FB2F35AFD63BA9798D5360F9C646ED2DC5DE448C6F0383B5C24BAB1B87F9DD35224E9497798243A44E38C60C7326C770FE1ACF0074CFC6266876044E8A10CA81DAADC818235646496199B36C925
7045F6DC3839155BC36A4B9774572FDBBEA22D1AE64CCCC05C3D3B5BFC235B7537D1C674CCDE9080CAA7337B342F7DE4AEFD5EBA75DCA62BD203E24A7E9E3E1E7A73129DEAC6ED950944942C0FF954181FBAEF0677DF443D55BDF8CAB9DCEC717921F3E1
76E288BACFF3D08B34600AE32BB2C7DC0AE00171F2AAADBDC6CC2FD1D675E72B8EEE43CEDF32B885E63FA7200A2BDB6740F59AE96300E88E4284CBAC175DEE7B362CC60F13EFDCAD80802ABF2B2C1C2F3AC70FE6021354B45F67E34B3BCDAF298FCD8FF5
078C68A7D9C629292738D66DCFDCBB8A14ACB4F602AA4565583EC780C79540E4F9EFE8E3FDB91844C93D882C308215B87BBACEAD48D03447CE74D29221F1C27006B93B77B51FD055A48DDD80F6F9C1763C1794174E2B30BA9D0BE29531A12C07EE36BD4B
5D231859800A1621C3AAA090A185348316260EF40D6D765529FEBC68AACD6016E01DC21CBE9B562736AA3FC160CDFDD6BCF9995352608467F9D5EC11C9995A10C2DE8AC47A2789223B8D3EAAE43E10F5703F497AEF548AB77E9B2ED6D6985B9A773A3914
5F941130AB51AB1ECD149E5FCC47A578B247DB378AB76C880477E3E900DB742CCA719DB857025717CE0389DAC4A1328F938262E1FAB2E55FB09554AAD4718E901896A8BDBAC52F9993DFE3EBF0A8A76FEFDA53980B538655E6FE4A433159A9832C24D8C8
5EF4F6318B6BB31CC78CAB2ED8700FA6FD2EA8948135911F768EEA865B54B42972FE152AFE6147ED6CEB1186D2BC00467186E472C048713BD263173D8050C5E042BC59ABA712805F6E04FCDD21D2A094194D4EA0F2AE79BA914EBCDB54DFE9190E136CE1
B512DC42ED3D9B828E894DBE9C0DFCE612A5C42C109FFE52CA49A669FB6FCD0D35ACB3AB5BA0341463D113E9D3D57562088D29277CC963BFAF42CDE3D446C6E5510F367C4C2C19FEBE7F75773F59A71CB35FD81F99B26E0A4D55C53EE3D9229A9D045911
546C71066FC4D88CD3F4B5A7CBF25CD897B297CD925EB0F94FA800EB2693030EF075336C0C046F8DB8587DF97042A151420D692C07BA4C85111FBEEE02C03B1B013FEF05BCBE373A03310AF74BF3AFC670B2A19AD5837148B9691D5FA9BFD4A780EA62ED
3917E197FF01BD85E03CFF149A265FE4C0B684C05B5B2EA9529522CC44312A37E27541747159DEC1211FE1E8C938E03A5E566C5620DC949355C02AD7D57800A652AFC814A8ACD7DBA8DACB55A1951BD4F4991FA13A06D6A9B2F23CCFED90FED1392ED375
095CF3ACF6F6DCBA535EC0B5586C099D1D507A93782C779A68C60777D583E2ECCD9CBB1061382E2AED67D1C71A1D8538BE81BD348BEB919DDD13E9E2F88611BED14C17C72AC2DE9EDBBCC15BA3E6DAAC7C4C44F59ACFAE386D4B3A9D138511B453751591
369451F38A9B36279AC1854B3C0E924AAD61AB135930005036966F4DCB9B034BACCCF13B15F84D734230A97574E7DA234BE9501A607A70027F88AB1CF264EBDE22309E1F384ECD201E8B75671871F2B456E4D459017120E4451E0EB009B7034035259830
3E8C10B1A9368496F900408A83F2FA6FBE09DD5385428C387CAB40F744669908636A8E2DC674935F64203003D81715132272BE6E3C19FBCCBF2119492EBB49C6BE811DEE2CB574E051748C7FBCDAF0AE48A73B52C6EB5BAF98E66CE0DD69220D6ED71913
A45D8B7FF22162875C7FCBEEAC8DF6D496BF9962EB1DDB57534B9C30CCB1384BE28555611171A0563F308E3063647DC4DF7E4CDAEA75160EC489B6E5C03B646FF20C6A331C7E84091FA06A630BE16BE207683A37A13A49A094494A6AAC4244989CC84471
BD68EDD35D157BB8ADDC74D52392795789E6233EE49E09C4826795B9D201E825C4A629EBAD959035D77DEDE959468A8A00BAA13BBC947C2276E3E173C395BB25B00189804ACD77CA800ECAEC05E5F66E7B4D4DC5FB4795B93F075AF6EC4B9B4AEC11CC19
A4A3D579816B48536F0608A0FEDAF5A15501E2E337E3BB799348C2D4B3E4F7B5F9E9638ABAA1BC220F4174663C39AE79717587D4B0BA7E49E5832A50D0DFEA8184656513A9402C72668E867D51C1DB6DCAD3F42564FF02376190259FBE5ACB4B9C371187
F56A038C883272E6A88A8ABD11F673A5A1C39CEF8B1102B389C181CA466189E16CF67316C2AF72AA0AA58870CA55F08F5B880728C86FE4E810CCFBCCDB8B4260DC39FE07B10818A5CA15259B55897DC5D60E319FBAD70BB898F1A9670809A0432129375D
E4EB3D7C19E11E5CE305BDC3D3ADC23A7DE3918EEDA1F08E58FD7A9F995291ACE3F0FB228C89066C3BEA0EC7B4B267FA4F5BA8FAED20B8ED00AAE9447DD0A42B9E6B3C3E0005B2F3BBAA8E4308AF419E0E64A732B78C49727A561088EB640EF723E1AA7B
BFCB42869B7C2C9B7E523D424FFFD33C935764677E89034E96A4F304C30514FD316A4E5C5E57242C92491105E254E8715D4F530DFB464298BEC729FF9BA5B1CF3C0126FAF3824B8D3350348F189AF103A26075BC2E3ED3264E261F5C6B14D91C44E07F1B
BDEAB82156637EE83BE490B24F979462375D2CC2C372D63F6F9A15F466902C9E4771574EAF0AA7973DC5B05C45C0EF86ABACD596EC4D552D0078C086D254ADB06ECD7D946FF89BE4449876B6C5BA0E32DD860DE3D53F732D744D084BB1B80FCE278153D5
63AB0720193B4D2D80AD31EBA2CAF5A77352EA0E9E6B1BE464EC8A423A773B15D7E28C9588F3AED5AA1C1EECDEDCE720C7A3882ECFC1DD47BABF4E35AD47FAEDAF725E9B8CDAF3690EC46C7DA53A2C5052652761DBCD781F4D2EBD963180873698DC2697
8B28AF428E07E9B3D2E126BEC125389184ABD54147577A05394D62E0450F5AD979BE29865F6563C233FD41A7341941FA2048AF533A065B9BEEB7DEC5880E42687C4F452CA8C4D54691C7F7E2671B4726B2EF5421930F22A3F3FB88E4506858A547CE3A16
D27B26EA759F8D1CFAAD085F6B9972120FCD8A7408CE574FA18FC1CB3CB7755BF243E29CFD467779CD6E13F1D4B3D549F3FC399C0322989794930C3D33078CE930D16D2490CE25CE2AE25C0BD21A80B5D38B58E2E407265A5474D18F406B7CEB46F8988A
6FD245DA5A9F8A09916B7B7EA28822B31E26821931A5E3F6B7E4086E8EE4F0647710967BE6F15149FE7F143C07AFE643420660C98A873AFE5DDE528B11DFDD6F024505DA90651C2044267715A9948FA29A1C347EF47DA86FEECEA2F9D192B27C12689DC6
58105AC3DA0950637883ADA5B5848F1B0BBF577890DA6D7CBE40A1FAED324B90CB83F75E33BB938AD25612A8830852E1899D51441C1981B11F6B0704B4DC41B118DE1F86F94DF8C2F497BF10A42E754DBEE9CF48A3C0CE8E9F000C0A3DEF4235016F3AD4
3B1B8021EE83C89620B9CC069AE60B37E2C9CD209D6C69E6B5E90A47185167102019A1A10BBB0187BE522587EAF6F9F4131DAAD6A6528E1217FB8E1B53D0861333D2F5B6A8C7451D22232FFD62D51BD617E25FF2B2C99E5BEECCB6063A5EF11D324D4549
63B8034D87A3BAD52435C8DE2E48A241F7BB5E4E40EA8C2DA1837C2CF260352CBC4A4FB82DF02E4E08393F08647FFAACFAD1C4BBA71346E2D398C9D353E5EB7BAB7E8EA9E27C86AC33A903FAEF8C87FC4A900FA0026F6F6B0FC1FCAC57DAF32E71EE4BAC
4E917000A28563DAC46973CA68927F311A83B52575118B9371DD6DD3E3BB658DC2C1D9F06B079649A1F984D19993A1573445EA4CBFEB398C4BC2B33855723105C886C088E2A70A3CE5EBFB68A91F652A80BFCE15AF4ED7E082EB7A873426BFEFA90FDF27
9DC8518AD2B20582D3A06B008CAC1DBDDBD29A8156CCDB58C43EADB2365042437F7568210DD2729566607086264330BB1E40E3D4218BF473731B512A9DA3DB4A45578E1D7DC11B9DF024405A329A23F862DEEA23151C2FAF21CEFB12A3BD2887F4E2AE9F
44F31136966882A4C60EC1E4A9F46EBC8CA0C4C18CACF1DD3198E8FFCA6C616025A023E4FA1EF311ECE508C73F3CA1ACB8AFC56FCC24AB3E74009FA55751947C0970ADD63AA24E628FFD9DB4E5DFC202AB94FDA7BD1B9833A2B1D0F12B9DDE1E4B8AEB21
EFFBADB906960BE6395EBA00D14ED4FCE6FD0A3FD65DE13E3774413B0D69D074035F5267EEEC105F449BA6B01835DF55C9CAE31AEE6245230C4693879A1EFAAF237448F022AB868BAF62DC2A7C979981A880A42612E580329EC1AC8D6333171F3A1CD802
5D2280D947FFDE6BAD8422BE296BCA33BE0BB3762894E6A9773452CD5625056C0138DFAF723583325FA9AEB0F2ADA171C6D7991F743F0D69D730921D6D820786DFC54398FC12B17CADF52B8005FE20A7D67ED2C00B5C5EA452356CB4F65A295B536B9C56
1135C7BECD038D836006C6B4D4144E4595C245D8844148D063A9F33B29FD5ECFD0610AB8EF578D31C69275FD3257A9556B9ABCA81BE3D7BAE9248A9E1FF88F3EEDE2B3C6C957E61CC3432D6A043A6A6F885680666A2721FC4A0171431B1DF8C456E6B922
D3DB89D5FF05A1870389A7EE5B1E4386B654DF8B6FA6A490D445E6A6D28331DC073B248DBC1C0424346DD5A8D892057849E0F6399F408C3B29AF2771C3F5BF2ABCCCB7B54255D8D6AA11BB94F87A821644907D2A506D8E28049C42FB2732540EEF334EBC
B52B9598FC081F8CCAA457967634CFA8F29B494E84062AAAD57D96F61E189D52A19BD6980E8F52BCABF77A3583CBD5A8C664B68765FB69433B616A2ECCF5A775758F9CB9FBA843C6C288B35326771A0E6D92145CAC5A6D59C8EEF10879ACCC799D53FFCE
CB01EAC49FB612E102C5CBB535B123E5E009F1080F62AC98A9BFECC72A01F00BBF74C49C1F0BDD119E7120DAE3EC6F7D76E4370183ABC6A8A79B03E6818451F347F6CBDB44E2942050DA750CECB6001139723D6E8DF8471B731B71ECC12486240AD0AA63
31468EA7E506F05E394A77BD19B0BA4A40D9B615A8BF89E3DDBCD0FEAA703E00488B7CBFE35018708DBC44FB86A230D7E2B0BFD87A365448270E110F514C0EC23A3CC3ABADAAE8370C1827D418907BF424F133D98C1C907C5FC347E7B80457CCA50B922E
677EA2215656456AFCC8FEE8174ABCE8576B98DBDA5F15DE25D907080550AEC7C453B97D2EC4C0EE5D2FE54F5C82F84B0B35DAE8BC81803B094BDC1FB70FBB6597BAE0BE05FD83ABAF969C602AA379EC738D0B97D08AF9FA567EA82992393DBD91B6DCD3
924E96B9B3170355468DC6670E47E93253547A8789475CAFAD19166CDD27FC6A7AADF1236FB501D97AB7605331EE8DC0CB37861D6B2C5FBB62B17868DA6A877E4CCFE798729441EC1AE1EE424B487934ADA27F421A43BD5F4256669EBC2CF4C2F2472CD1
ADF866605872DAF57BD3C6B76B061115B6A5AA1182B08A9A3CD882EBFA7FCB165EEF622382E276A4CAC29E25C94BA7B92F96B1168401E22F69A7FE148C9CE2EA95155A097B5F84FDDCAB8F567C8DE8629A98A07AFFD01D3573B7129806BD1E24F10D2160
DF6E9E61F6C275BB9A985C76818F8077769848B3381E4105946BCF1326E553B366CEC23D2B6A1BA81FCE44C18C20A8DC35331040F852ADC1014B9FB83FD5AAA0F8FDD97BCEE093CB5903ABEC3DB525BDE27744557AB63BB6A1F431FD2AD4372B29C10535
D2E642151E00BCBFA978A39D49C40ECA62BF1DDDCEFAFEAD02BDE1C9E577C7877038327603375AE309DD0980EDEA2711F825CEDF231F7D687CC911B3BEC1C030CFBD92850FAD02E3E17CB0F40A6FBED20BC7AC6C885057E977F6275D1A38B75A28C90B3D
20E85E3EE00653BEC0BAC542BD413EDDCC54117B6B37C14EFCF690D41D7BD951DA2021553246246F0BF02B936B42C04EB998C4DF91AEB998541D1C5932ED23A7B637FC9B0CDA4DEE0B3524A2264B3C6325F69008C5A3A74141E1D029F7C829422D06077D
2CEC6A80FC04818C23E4F0229C692F5FA1789B4A179735D82F7F6E5ADC08D22E714C01EDA5981ABC10FBBECC560D63C06FB7B8FE0A4FAAC22532AA0167ECBBD75BD5E63A19793858AD73C91694497CA3D57B97158EA1B7A49F7D06C66ED64F8EEDEC466E
3B4F2D14F82EB3BC9E9CE8153C6C934CF747B1CD6F576847971C1A7187AD51D8749437380FD48CA4D4E0B820DA034BD67E1B0DFE1CB9437C4F3F3D2A616E1007C9DE1155AE02DAFD8D2E10E0DA989F046DA24707EA1ACC744E813B2A6317280CE7271A34
3A6EF6074BE0AA728B2144ADFE00E4AA83168457874E7C361A5951EB8D3D870A062FD8C8EEBF122265EA2545625384B422DDF5B82AC9F1B478ACA4F3D3A333E4629CD11B4D298B22D7E98B2EC54C41FCB11EEA0C5A902BA2A0B30900E22C28EED459042A
A3CC4F464357389DF889CED4CB844DDC66E714B90A6C446FF775362036725B8F46824B88E66D858995B1A46DC1C3A4568985E30332ED635C9B425F450478FEEA3A33E7221C162CD5958B4FD44CA9326C551DF83D4510747443B4524FA6B2AD07A5A71A7E
257FD25E7C16D4DAEF90D86983DA254FC0B1A6F215CA6F6504995BAF6979240B15F99FD4BDE6FB568A0C6919B0A165B87AAB2A52CA4393BA7E46660D5960A1EC05509EA044EB4E49937711921D5AB83F4976BD5F8113F409BBB8E48620A6A5B9CB8E73FF
2B76A1529E7865BE8A0E5E53AEDFD77B4694696B5ADA0B35C337331F719920D766392576FC6EE797274805DD419E154E923DB23DF10E43FBB0DA117091785E3CDB6457C9EE5AFC58EB168D7C63C004D0301254ED536B6A5F3FB590BDF301E01780BC470D
B2917912880BD9BF3711001D979BFF69A55E114AF7702B3A4A5973D952C2CDFF371313006CE988ABF9D360E90FA624D92544C6D267EC423DC4508743817B381E5B988C84456124665241D6111A177AA6F73FFA858BA15277A582D2518C7E9652A379EDE4
CE25215696362478A82AC93FEA6EE6DE303A7638FBF8D36C1E7C26266497E90AB9AAABA35ACCDC9DF7A11F32C645D861B381321866DD5CDDF01F3002AB66C54994CAEBF205F097078B59550D905146E78BD1FF4844BF8FE0FD52ACA08FB0231C988EDA68
94A37E21E3C1F38C495FAA5EAC3501A27D759F0FA7A8724A4583F834558E0ECACBC79E6E7232201604438AA0EABEC8026D926D8BDC0D834A667F8B18E4DAD6BB6F3B4830E1712865AB9802CF85D4A04F62862FE660189BEF17DA08DCA9E163C369ECA62F
EB7EC8B5196F2E36CCD27FD5E67953664EF09B609B8AD06F43C4465E755B1A2CAC6064EB8BF2E5C1447CF7E3AE5DE689C968C7AD36B657A2B04BB21A27AFFC54467D2665C2D41DD3BE49924FF7E67F846F007D42428525D3E3025841E65D55AB75900DC0
A92CB13F15D0027F353490EBF898E1570CFC11AFF7AE863342700B8059494D668F409F2DBB1A45E301ADF1F8D247FE847A75DEC40BB5D04F093B05B58CA6057346F1E73704ADF0AC9D5D5DEBD7FD61C283E840E464423B3F2F748DBD798668BA05568F48
150BC04D38092E3B841851FD257712C2C2BF890FD4FC8048922358586CF85A5AD754533DF4B27524D51467C5D2E2273B3AA5D1185DC9D882D98AB8987434CF4945EE6E93520EE67901EAEA00F5DC7F0B854D9CAC51772133AC699C923141BC48B298090A
A2D7537C0F52EBD803361166EE78737F466EDCBDC4AC9BEE4BC14A76253E16E41D9BE806DAA3DDD0E6D680384BE140E9DE095ADF9B8EA61E796BFCB67457BA91452167F5059CB4B4B418793EC940E0C8F991805512C48A2A81DCB1CF6C2BCAAADE2ECBCD
1254F1CADDD14F538FF2BAEDDF1C0C2F0234C2D8D1614227C2DA4428199119C18785A16CD412E633091758A9D84BCD20E8DB73B6681D592618C2BB109AA67FAD6B592DBF3D8077444B90D9791AC2347331D5DDAB3CC732F232E6D872610585E18EA61B6D
848A3BB0594E6F17F68BEC78097A338F7E2DA4C12E2196BBA619CD378049256DD00EB524279FADDA4F2507D8965946FB31C85C192E86BBD5CA281EEF56283950BE41BEE88E520FE6A60C5838EC846AACE658019D0665F2555BC0FF02DE8B18657D6C364B
9073BD8C0DABB8EE06770FA2CA9CA793367BC5FFE10074AC4AB95EA9F75C10A9B5D9B77829CFE8B7B9C089337BB882D08F34FFEBB3501980E50BA6C59F5705F9F2B7A3641AE058D200E9F8F80EC1E2D601D1FEC0A9F3F29BA4C903EEC51047102353F198
37CD8BA3B38CFD2C40558F98C4311D79F340565CD41F2B1855A66AEAB8BAB8F23371859EDEFA14ADDAB1C048DC9706192B4A975DFF9D07C6187EA67599DB377CB37DF44A11CB4FD516214F1DC71E1CB1B042B9ED199A8BBA0A184EF409083F88AE4CD552
BFFAEA56F6B449B82637917823A77E58DB14EE7090D8F20993CCDBCC48EE30E9929EA746D92B7A0D1322C456D4AFFA1138CDD2462A8EBCA13819E0EA82757B0ADDE62A3069DCACD884144EBE0BC2AFB6653BCDC381B8F88CD1BECC22B8DE0A708619E194
0D34CB39643FCB280C168EFD8C47A3C7E5AFE83D200A909661BADB072054BFE55CDE85B7CE485A3A422EB83F46B611DD278C1BCCE130771855AB857A3791A46B892DE32F7A584FD0DFCC23CE7547C12F1E45DD41D6E9F45C0CFFDFA4732DEC0D162EFCB6
36649D67EA659D785233D352A722F9523138DE3ACEC8A5BC19166404679FFF399CCF660BCFCEA15580876C83ED6F55CCA3374F4CE3D8B18FE81626CF1BB6EC3F0CD9ABB7CC6FB72DAC46FD530DA53680940329CBD84AF167A2CC74BDA02409069ACE3B14
1E61C5B3DCD3B2293A67AAAA1EE21B3FE77767F39B8F5A4E0AD3AA191FBB07F1CB001C2D492A5E6F49F892922EE6AFEA3362F49686B2BAB8DA8087EDC33E712640DA253B5D20F25FBEC1FE70E77A0552DFF276E4007E4209C2CEAC9AA749B8DCDEAD3F82
7509D5F0D748A07A9C84E63BF72EDB13AC9333E101620947F051516324AE4C957086370FCF450CD528CD63A8BE9EFCE5A022A59EBB49D543356649F58C590D853673F7C27ED453236880612B51B4C15990FFE4E4F13AFA1280EDBC18F6853004AC45EC3D
0AA37FFBA3DFF3B47B44E887EE97691006B33E16316A367FBA440CCDF97F64DC738F458551153D19D616BC20D64BC44BFB8A9E823D42ECD5C4B63914E777BF9198F4A6AD289CC52FC771820BDA2056D2A616E6A5D48DA53C0240B226ED454D2EA072E24C
FCE4E4E9C295B7A79ED017288B17F6B1F57EC7A4809E7C8EEA769BCFA07931B4B27D9861F56D46D9CF624161FD1DC60DFB897BBBA85262F4BCB7C44E0BC39499EB7C6212FCA0487A3EC4FFFA25B49910172664D1A0F4F15ECE7294C84A13403B30741158
0160010C556A8C679C19927436EC295110AE7CFAF94493512BFC3EEC4E23A6CF212D167F5750B8BA8DFA771C60D2D6CA9FA3A2893EA2C59F500DAA39DF6B09A09F2EAC7B8833F4D7029258B5694E146F6BEA54A53C8626784638B34DF8294971C0D01F4B
9E61ACCFA05531B755416F5A9A8EE86CBDA74F3A1EB9BC1CF4D44138887800B764B0A018327EF34EC7EB6D664968F1C6848A252C4C9DDAD22D988ABF41996F5AFC76859BDFE0846BF8C35B17F1F221FB57967C003A2833748B9F043FAFE0D50F46020779
3BA8CCA51B65D33A73D4056B1186A049459545A0731024066F49C2EEF5C9830839692802433C3C2A42F58E42A4D2EC540852528E829137E005EA73D5CD110F8AF1DEF325F9003BD87545B3E85990A372C9D003562E01329FD6D301E0AC473CD4DA2A5E26
6552C208211411ECAE1CEBD1A991C9CF734D7CCB013F5862EF8E192F7C11A94026C57622904D38804548AE6F5086CBCA89505A6427C44C0DCC78C0EBC4E40037A1ABDC15DF7C2A7BB13BEF262E2895393B32F173176550D829C2C72102FB9D4CFD852A01
085CA98FF45F0652CE74464699B88E337D290801F3E733B893DCEEF9BF2AAD9B6F08300D8548B915C7381FDEA49066DD211585541F9C71AC6C0D1DF9C3698D6FFE57115306CB0D9FC482EF67524008B853083E21EED3177F0C10CE0F3CC4AAB4D9132950
874EDDAE27B0A4CA1D48C97E50DFEDD9C68F111C58F82DFD731105417B41898DAFBB1CC6385B838AA47386BDD7AE5A5A885E44C8ACF23D5E21149A9CAA6D9D3D845233EA2E6D2A7DBB29418A16443DC02D98A9ABB30BFE33FBB28642BE6DBBFF6EE56B12
C7E379AA4DD02A92C58F5F4EAE9AB2F010DFA63A43EE21532F7D24945DBFDC2B7D1281B88129A35D8B41321CE46D937D7A57C612E60F42B51F06610CF35447EA905114617D5614D732AB633CFEC958516E5E45734C4FF09BBD27ECF7B3A2F8FC24F6CB18
6249E66B101A3F9598DC02872B24A7F5A2B4741A90644BDEBE46015181549C5009492AAAB77E5FCB1AFBBC5968FDA9CE7345F949C423098134114773F89FF6FC8AE99A5284D2CD3C267ECF24E4501BA733CDBE1B76038F30DC2E57617E43BD2EAF3852B7
79F67E71D81E2ECBFB5679A5542AEFB937A04060A4760CFA1A035256108482E14763BFF92213B0241141D5796D836590D124DA189D44AEC97D83CF26428C6CCFF3AF9357ED2AEA5FFB61B117BE2E3B869A5F0A4C788117E6B0CBC753D0583B233798021C
CE22667F5BED8BCC3E1997631DFA0B9CE9BDF977264D8E8A4E8CD8374C110B26FB2B85F30CBCCCAE2BA70A8D31C8E8AB726287CD4405453C2652033432189F080323C401A09EEBA72899ACCAF27EEDF5B87A31506E46FB3D5B8F4727415317EBE36842AB
99415BDE7D74CA6383EA24B45A81A7E5AA6D2E28140E78873064B0161F30DB4C8CBA565D1FA4B3519AE56D9D9458293BB011778D5BA312603F9ABA3F8D80FD1531F11579F2E6C815D2E284504042E4CFD498DD32437E6A19158102E7890490AECC5C7C7C
F9E119D77DDF4E29E9BD8C50B6F0BF078F09A11D3C4CC8589C4D9CAB6AAB35AC231AE044B0DA06173715270C09BC5E2DE95E7851D98E7858626C52E70B0AFF0294E248C9F2FABBE7FCEE0E12974689901743DDBD141541E4BFCCAE1D3183BCE28EF1F6E2
B427EEEC3163888E06AAEE7C25A964EE95BA153F7E719ED62C47B1BC0E947DE59FEDFD0918A5919685463168BAFA945857A2D0007608BD9687198A3564E0C27C41556F394063BFEAD5526C0BDC63AC3A7DA06A125B765145EBDFFCA22FB717404DC1001B
063D9FB3C5567038390278CD6AEA336BEFCC2F7219F1F9DE3BCECD7A4EBFD642F54D7D8C6DBBCDAE7C3E1E95EAA969BB651538974B4CFC9A4FEAA268A935EA5718BB36B80124639E4265310760E9ADB3FA5F23433DCE4314DCFA2E0B656E50AB1E8E9187
F663997ADA433267C3BF7DCB06552C19D56A0E8331AE36EEFAEF2F1BF1ACA5594ACF21BC56AA544DD1D8C1E10F4B019B561A449F0E41385199DA2D172AFB5E2DF1BA8EC6F280E6EBEDA33A0223871046E8B0EFCE613DB8DF5E68A3EE48F14455EDA6B551
7E9F84D4394D8C5CD6C92B4D3FC5EA5FC56A02D24803DC626B13EFD824B657B08D9F77579FD3FB13344EFEAA0407B07804A5F5086F631E81E35C743AEF8A49E2DF3188D213FA861F7B32FF1E9808C2B49B893A98F7B7C25826528A8109B90D75BFB377EF
BEDB0E473F9D6F9ECA4A1122C43FFA9A686092A4A37500B544CCE4C3A95695D9E5C2ED14FFF462CD0D07177FF53A240637177C7C87E2CD003AC8F05782BE307C8651078DE8B13DA0DA24E39A39926AF96098BD7625E26890179A036E518D53532AA861AB
9FDEA1737B34D9009CC71343FE1F865BD5DAB6D34D9AD87D378BC44144D165C2989CFA3F3B0584BCFBDC471A80E91B20E47E433A97C19A748BD448A2AC93BF0048FAE398F357ABA261DF0149DE9DB25B179C7FA0C042AA3313F69E6D54B5D2601467E76A
C0A0476034E88725B0515D65BDE79C31B6501EF8824EDBBF32BBDE5C6B50748651E11608DD5CF619A09A0507B54161538B1F42D2D885A475D16A68CAA79C32DDD218BA37F5A82D875D76AC1D8021A14EDFE79F28DD9526783A8E56C77F7590390DFE0D14
759BEEC24A31668063C36C7F58C2AFE65AC5D5331BDE623F80B66974F8F841F920B864E09F38F2479E750A900A566C7BDC72957B9E1911AB93C5F2B847AB815D02E41B1D93CEB529C28AD7403D1225FE664FCF1244D206B85330D982C0DEF842C55850B2
2BC16934373914ADB4DFFFAA77CBDA487647884A98A1AD01251E5F9A0C898772F5069E7D37300F4D2EC00B52C0A50F0FA7CD1A47F116FD63FD19312DF308B59B84BE916A3B879528C14976D61CA52D981974034491F2ACDDBE9DEBFA12A8D2AA94C24881
044199CCF2668C063A754DBE57652FE6FB49D397678633F05517E14867948E29468699047CE70B7C27F2F68343D07CD784A5708883A320FE8C1AD6CAB62E3112AB8EB0179D53A42DF88DB078995271063FD6F2D96FCAD56A7D3FAE137CB7ADD7F76310A6
E4A7B2C4E8AB6EBA53E24035644C56B31A7E20BF349AA163FADF3C7DD1A2D1DDE7CDF2A39E59D52110C9A1A812B2854AAE2F197B7C7C2091EB5F50EC61C686BA10FDF06EE6785C06FB412FDD52C7D742EAC59E826CA3850C258C0E39BCCDEDA987D3A489
540127564A744F90AB74715AEA9B44BFB05C9D4CD534F27D4473E6478580C891FA7093253A0034C66B25F358A27C3FB48233363AFFEE3271AC168C49D6E0058187F27377AEB87D8D9D4EB73A8036FD2A503AFA3F5E030D409355EE12578046DDACB111FB
28E6BB5883889F0B6658B1E7A01A203DCB29A54780FCC88F45625380BA50E838403E7CB01272718867E8B9CEF1DA9DB0CD42FC8D85398B71BC710D88D438A940126AE2A3E2D157EFE9CE357048B8314A79B7DFA8DA55F0C921FF9576CBD9BE657BF3F1B2
2B8649F354839CACC6C3FD666CD12E68A3F9CB1A30079399685555E8EE8E7FD80360C6AF041A0EC4F0CCBAC8E8833EB3FC4D668260D2C5C3B17EA1F807515A42267871AE6CC8D4E15C935899A39D926063FCCCC7D21DF5D679D82A8DDD6DA952A55F9080
EE3B1884D554C10A9588824192117D401813F91AB750456205A6D48EA5CB0789134F3BC8D3198F727933C13D88F178EF57292250DB480B4DC27650294FAD7BA89C79B5D10B386BE4B0C9A2230590CB8C95499F02E690618241364D2D0AC4EE4A16C80DE3
225DF5F9BFE9EA27C2859C4CA7B7DB2CB18A9398155B08A3C8C5665C9A0AADF85F8DDD5044B746F527BB351540AF0D1B3023FEBCC1EBA276827FCD40DD0211C387B62D70F3EA25B360FE6D70D6BAF6C8E7FC76B45ACEEB335696301CE20D14DE2037A93C
351611940FFBB28F561EC3F41273B1090398934CBADD5BBD4EBD428642928D6899A3EED5A61E5FC6F0E2F76729DF6CA8095E718BFCE45D9D33CE24C3FEB0DE5567123EC91BEED094C1269FEA260D9F63D2F4834EF16306A4EE0195B0E6F97F2634725DC5
D01602983E04BA27B5C1E5364282725CF4CD184659BCD8EA7CD08BA0CEB50210C60B258D632FE6A4A6397E73096BD2F75396518AD6AC346A9C35CA2F0DE23EC1E5055E9F0415EB2327EDDD5F43E6F1A703186941B9520A5B138325D54DE5977AF4DEB387
6490F12EA02A56239277A279DCA589ACAEF642D8AF687F557F6FCCF6151E8A1BD11FD22FAFB554B673660262F798C64481A9DC2933408873E6CB49A031F543FA1C528EBF9D8A0F7BD50443E1252053C22479E0B82952C3CA94D900741CD6460A2020BE04
D7B3317B697365F0C639E26CA0B4800D2D30F2517E384AD5B812388C8C6E61C6AF8A7FCCF1295313FAD79950B4F194B033E1A013C91910CDF6E1E1906989AA2848D8E9738C0B2F88F932011D6668E7543038EEEA76979F17E967B6CD25BB71399B5B4158
7728AB83D189E967C94001D57DEC30FBAFBDDE4E9396800FE9874A510A602F2B41BCC152CB2AF5D320B8B63B9DFDF2E2F344A033DFB2DD6614C91ADC2FBFF031BB1E6CCB85750A26B47A8A2EE01ED587E281AC378FF23264DAE9EF49E2208C3932DE03C1
51ECDA9CA2F945D9F9BB663F5847D5AE9227214FA8149ABC92FEE080B0E4DB7C006F34162192D212FE1F0FF3F653D4483B2141FBEAE16A664B25BCE07BF7FECD3F6ACD1736202E00F43658450E9560FC9087CAF206D5061ED5357F7FF744F9ECECA1B15A
086F2EE31D4CF608883CC86ECC485FC8131E4A1CADE132D563E947C9C471FE9B45A7CEBF9F2ED549E33BAF267ECB90A313DF20EA903E1DA6CB5F70644B30A21AE4F26C525FA2C6EEB7E5E3C28F310E515B3A7D1CCE95337E8E058CA3391BE75FD5E17E84
41905B075B15F121AECDC45185135496996AFD6A842326A7768FEF16AB63DD9C966C642F81962A97442782521CFE467DF191E2F81B84DA0E07A2CB280EFB84B87C9A465786B74CDA8045D135F3E2638EFBF65485AD1941ADE1717910B589B5D89E2FFE6B
3994AC95B63F0A8F46ED267DBA7BB5FEE23E987FF381C3D15CCE5F5F4C0B0649E09BE7AEE10280158D46E3F93CA66F1A3CC1751108FE320C850D04DE6209A5245BC691922ED563A9B5400515354C4B437F3E16D0FBCFBE407F3F9BA346F79A751BA1A569
B4AD7631997E352AA65A38FD4D4A4026DB839490E8409A4454CDFE41DF8C797FA21BCF715B5C78C11CFE7381D34BB40E21CBDF2C02B6956A852C3C3E6ADFD187C76D505922F93E6ADF1EB1E29C393D26C36EEED3992649D73A9629B2CB827055BAB27397
C9C63F0FFC1D44606CDF373363590048052E754F0A15A3DF1BBE7FA4FD6907C883A6EF794F4FE0E190DCEF2F33B073ABDBBC9B4547A9D1127BFC9E72B81BB21D06F5E55B09BA6B2DD07526F58341F016CEDBCC3F98378DD85053D107E910A2A3CC489622
190E9BD8BD02784638EA2BD4F937E068A6916857419AFAD1E7F4A538AC8B47F0FE2A0DC094427C5842F522623A30CC19C728439FC0C41C8D31F763E7716E752FFCF98C81CF4FE9CE8A94F733929E130FF691BAFEEB027418E56DB4FC08D8F6E5457CE34E
C4BEC9A08FD1A514D194C96013E3156ABEFF4C279FE153557BF76BF1BFB45A144B0398390AA3BE286AF984BC22B41BF1AACCBCDA618F0AD42DD14F00C3C549686E9F7A04CD709999C8A420CE3FA6CF6A4B12059F3AAA8B6D501B5592DA2AB5144619CF12
0EDE210B9B8BE9E0BBFCCC15C9C779CB7604AE50B3C21BA116168408107335F0AC63D78BC83D178A0374E575E7444B78562B85CFEE1B2B14A44AB3EA4BDDC985294B3ADF7CB1D8B1CC1C79C2F472A0872D4C6C06FB7726444F1835D853AF64D9593346BC
A7F3A0755E59429FE8380A3DCB150F2F2AFECC6EF106C5E2903F5C79237C661A770D69F8C23DBE6B919718B784284B75007A45A3DC6CC597C68BAB48CE938D74C18476F0B7130280B9CE5243F9452E65AFB3FAD4524D086F2DD4D319896F932C583C9E64
5EBDAD53DE4CFD6374A4965ECCCF4EF29AF0282286F068627DE06727DCDDD0EF0A79311509F61BCD139722E585985A392175353281F2CF85B8459535EE37FB26DEB05F7FC34E28509EB3BF7E0A75E8C7836478756F5495CBC99A14AB5459DC8B8A5CCAF3
1ECAA9C75F1D3446784463DF724CEB3F5A47D848900E248F573753A2FCA93719B2778957F32D3CA937248A30350D069387C9E4075107D5FB83F354DD5B2DE6D05B6A8FAAB1AAFE2B9206F3D2E7F2800FD8E702AA92C7E0666F9593F8459F5615559CFE30
2DEA467DB07FFCD6110E01898EF68A63608AB3E72A9DEF92A190F950463FE6BB3495332CC8148DCD037AEE5A158E50C5AC077E1BD0455B9D12892A31CCE0E86C9B0E16A38B198CCD5320B52692CC9FE9F23762715501FE5182432AABDDEC8631E5635D56
75AA8C3287A1D25BA1B562FFACC9C48DE24BCBED7FA37477825C591CA1CF4E117ED774AB36EA3FF09936351F6081AAB8EF481AC42C2F59AD123EFA9258942FFC2F2BD9D09449247A828762BDF038DE222ADB8DF33EC9A99B5E4CF97A6B233CD5283CD287
562D3633ED21FAAA7EADAA1D445B8F011E655F2659F0AF7BE702A1BAFB94C4FF9C4CB1F24788DBC44439AFA383F9C6D719BEE93312A3F4606E23AC2EC2CB62F76EDFB8E0077F165CE4E8471B7E6D1316D2F3F3710D5145B5184588EB3BF75B4D8D80C64C
F085B303D254B34F8ADE6A9F5D6A9BAB4AE70BDC392371227F3EF14F95414CB6D345A205274F6CA636D50CF248EB8DFCA970C9DDB83A9CDA562800A4240A5069E2F5C093E03D4FE58DC04A654375117E0BFB3E728456DE8518E39BB014597662C95DBD90
B1633F43A843FB7E89947AEC455D513ECDBE5E537D561B407DB5F2C146F36B880DC1542769F366BB709B7D645209614274FF7DC6BD87AEC17D9B19054A330883615F8E0F9E3EEAFCDCD79527519E54D1CE079FD11B7B92A2C9044AEB6BCE2BC08DAC8F0A
3FAC8091EAAADF838DC75FFE236E4E21B0A9D0A454595912E74E98DD7F9FC519A5E2C7CE2BF771A12B5AFC8E1441DB07DF271A885464A45871287F38F65CF34A65CE58D8A19771744B2CF2F850279F3C3D51A900FF0A3061916FA82FBCC2C5EBA73DD3CA
D1EF8CBDCF308DC0A826A318CF569D17D522A1B2C251402B2AB2DD87A74939CA3C1FF198BDF5026E512E0E0C8F5AAB6C6B88F91BCEB07DF9A0CDF09041C51FCAC70DC895AA9264D69A50D884CE79644CA96592FE77D12DE8B8B1E30384366FB00177A726
49AE14A14DEF8658056BDD9170F41AAF2395C9B50DE107A2D1C2B4D2D5EB521A41671DCF6E945C8E5BBE238A57B5D82A913DAB3FB04117C5B4E8A4775C8A696FDC84B29526358119A2BEFDB7AEF969F3DCB25F91DF081C383766E69DD964F2AC4B04970B
ABE417E360EBAB4875CA61FBC8440A56D76679B4DC1D7AACDA90274064D2C667EFA9B70DB393185E0F7B9DFEEB0C499829914C6B3384C85B6CE94105BB5EE6BD6A9E159C6DCC1205838157D986DD5BD119DD3A8E9583A34536BC9FF1A2CF946BAB082D5C
FBEF5C00736226573AE39355E98F5D8D16217ABB0C9D6D640B93BCF0A51758CB198B90EDC93884E6C06FF73209A9C48181D877B5FBFA73CD3AE38F7ACF5BD07169C6F091D8981C943C7B10E9F8C3EFD4A2D1F4C28D873D22A63B56505C44A899057BA8DC
34C2F19EF38F7E246BB7506DE8702D2E6A08572988F6835D8827369CA198D4C54A95224BE6DB3F039392913FEC6D376E00E42DC778897D9E80CC6A2264BC8009F8DD63AA5E8B8CDEE0CA64FA82AB67BB68E28AAE8BF000AD42DBD747D01070A6AB7E7B85
49447E6829F1EA4CCEA35F06FF59D6C4E6243505D2AB0B3C9D450EB24FA6412CB3E7B093D0B2D29CB7FDC14EA31D180EF10AAFE32648F85B5829490283DC2108F08FC34EFE1615C7EFCC25D2592A68981B7372FA15F5A56062A52598F9FFF7D4FF6A7EE0
88961332301478CA049A92B5A2DAC02899F8E2DEEFBEA914AA2C225F538B1DC2752B16052CD31E66A67DF1D688B21430C38C7D19CB4B4312EE4EE9E59DBFE3D4B2754E468A4DA18C868718ABC10A1A83837C71FB0EBD7C2B720A1C3D27F821EB6D129200
5D1C38F8902C23DAB4A4096452365038E3102AECD3F50845631947758909B0D9404D0CBA2F9445D48A2E7FF2D3C8AE0CC425FB740FEC0116ECA9C4CC36D1A2A6402BE793A09F9144F1BA003B43FB41937ADD9F5D7BB48365A4A12C0FE45CA5CAEAFCC975
1414CD5CB296795BF80403A5161D87EAB1AFADD23EAF5C5A54B3A5A2981E4CB1CC03973A0C39F71BC920B165F100F7DBD3A25767173861D3F9412BDB437F8FEE69FEEBCF0EB00616C0D96F6B9809B0117FF95ACC24B2B0230152DBC1308C6B28FB3F9462
2EED3A8288CFFF0BB000D9B19328C35C450DD0F9B1D8C1A3FB4160035EC63E753D94356C542D49568F71D780C286362CB48FFDAAF07037388D578EDED6EDCBF3FEC41D3BE60CC739AC8B0744C2C4C180FEEE8C398CB8396C3B8050C681635B5A48C83421
CDF811EF78402A45525F42A42EF41DC1ABA7DD42F7323E314B088DBFC6A009A70D5D8E8610FB8263F336505BAFDABF79618858238E11E1FE3ACCDFC2849212D86D03A4A621B2451DF70F2BF3246F6A8A93FC41E16CDFD0C26F910A5BC3BAC48BFB72E735
98B74E00905DE31447602FE8724A835D9865C8C8E611AA903102ECB6862DF0DA24361E3BD8FA845796F73F56B16CDB5CED43712394DA1D3CDAA5BD32FE0296BCE7BAADD86607DC16B7696E4A4D8E2192F9EF268645CE09F87D19CE364039335B2F8E4883
86A99610942799B8D8D421AD05C68F51BBD079859D0C0BA348B1ACA6DA7569C5217253FD1368959FA3B6367D081A666EC40461836EDC9E830C5A1C305743733E837EEB60F22902DB4355E7E5A08B7E9E6F61F7031DFBF2D0AB070419FBC5141B8ED039CF
EBE5B207DE74AF0487FA90271E209D92DB9893C8BCF525B548CAA3EE30381DCFFC4981FCBC3C66A1B01B462EB06D65C7F0F8E9EF7492FB079746ADB9EDC0886202EAB6C00A6CDCC02FAA0B5E8B7D119E4C3DFF02818FD21ECBC69753E0183230497A2517
AFFCC0E618BA6450D27498F0F3EA4A557AB817AA89CF5E2021AF1423A5BEFF48D52D27A29562233CDF319BE848D9E31938825360921CEF41E18BE9F2EB7F78E8EFE0992795305CDAC1A70DD05F5CAA0A78A72A1AFC6C6444A1E0546577CCC4D12E4A6542
2AD821A7A7C9D5547A5B9A80AAB9E1A84C058D11C814388438FEF50284E6CA3CCCBFDC371A707496E5435DE193201054122FC6763563E2EA739D80A6D1DE137DF7A66C6460313666DE96F357A068FB1F916EAB0852F3D1362841F4F3CEC5589341541EAE
60F0CEEE1C9F3F9100F880E203B27B56863F56CA633B71B789C15523C52DC0E1CB801480E3FE837BA2BB9AA759D5F6C601EAB9E89FD1612E7911628994630EF91F1B65065235F38775DB3E7A77D0A699F63F0ABC8EE018EB96625EE0066B624118AEF3C9
B1CA0067FAE3BAE4DF38BBBFE186C98C8E17D3050A38332DA7660659794E41F9FB1EF0BACE0ABE061AF29DBA6E7645C1EF14422026491049B29478BA746829EACD50C0332F36AC90A28CB82A93752A6451A49CFB4FF766F9769A97259C9DBF603FBE46ED
FDB28701EAC8F9B63F2EE7B2C665545AF2BB1930CC6EE7163FC7092603CFC8CF08FAB6DD5603C8F04C1EFE350C0DAA63D9C2C2CB91619AB48033A24CB38D75345FAA23133683E0675FD5EB63EB37290B957BF9A4CEDE15702FDC270DBF47487FE9951026
903274B82F973710E6DEF5F68EDFE00FDE4A00C52A7587B07DFE1D196FDCDBE852992AFC71A6701C0F7B050653736891CAC06B27CA462F4D418E129285F4F4EE0CABF503D921D2EC810F2C0AA685F789A99FFDB5F9E3E3BB248DF048F89E51157BF82306
25B5D617625F73C55CA6C59600EBFB9DF5C942630134070ADB9310A57E4F0C1778ED96EA979E7EF01815E3535F3192E47ED7EBA13E9590CCE631E13E2C8BBBB4F95687237E81F754CC100D4117B7DDFAEB08464ACE9292C1538AFC84A40DA0EB96EBFA7F
5F52C6E42DB37C05A871436CFE277FDACA1BF830BEF92337247F46109ABACB68E12B436D8412909A199EB68D0FE8476D75C8BC6939221D13454527FE4F8EFEE4DB663E1C9E1462CDB13326CFBDD684CB34BC643D96B124F0B2C89B0B51C7DB59B3622357
570F9F4FC3E85DB29D63DBE55D0BF722F4E024E232D83806241A3CA0A963F57E794C9778E5CFD278A677F11FBFCD61B9F8AEF5081CBD4763D0F84CF49FDBCC9D49C2413BBEA90A120B553CC943419E7BE4CB52F498EA6CC65019EEE12D79D95A067CEDB2
023BD3DD441CD64F204EAA826680FFDA47FB93FBD864637FBF53988B5D65C43F6F69E5262783B3EFC133F9B5198DDB29B0C6A5DDC5AFF585F200CB37C12EC466073F82059C2CC22CA8BB382A36669E3969E683049FE365CA67E902BBF28FE6F7564B0BAE
45B43918845148DB4640474DD7AEF8746A87AC1155D9E2B54044D678E30977A6005B75095EF933FE0813DB416A116560D798FB3826F46AD2E44F63E133F1FC73F06B6851F17914BF6338D970C17EDB49E7CE2B85D494F1BFEB62F7225B4A2383FD981A1E
EAAE23409B20CDBDA3711D10BA694B02682C86947AEC4909BF787A199F018567E3967FD5D4A4411845CDD42756F6D7C88197D40443973550D0830C7EDB99D8951ABF87A6FF5C2EDDBEC636B2232D51D59135A7F53730AAD39DC76B8258E48971895CF0C2
FFCE5DFDB3E8A5FDD75FAB57A2936FE9B5853DD0EEF6C37CAF0F7B40EA7088BF667B0FDEFD24FE0E4FC096FDC3C3DF37A6BB98433482823D3583B0A88EE6E8487D99D95A3C8692BB1D1D072F4745314256D157ACDCF0C47B9F59937291D8BE0CF09E9989
7790AE7C6EC403BF2DC1A19097A9DA7D7EBABCD6E7D29E756A992AC868F63F35D53F971ECF44CAEBAEF7DA1EC612DA50B16955EA7B01869DBE993E5C8E0659A0BBC78CAF982010F9F3B6175DB5E0B1955E4E8302857F08A56D2A93E5164A9198245998CE
985713808BE8F7AE8C4FEA50D2B31D4544073DB08F9D2986C877B6023EA3550CB643A57E2B4172FE29AAECD45F5EE5F859A0472B2A0D2CC9DEE7E43766994B7000E0F1FBF0957CE4E590E9DE195283E072C62E0B7EFE0ADBE9138222FAB72E9DB13A5B83
080F19F14BB52BA742D82BD8ECC8B667972AEAAD44B06F093D19D1E15AB55EDCF7A89EC256436E524241269624364BD4E9B8D01CA79D9A4EAEF7375AB717B035E37B105E31A9E394D3A3E940D88E08E8E78468AA855CE6570D47DE5C93E9D2377D96E41A
4C094E545034DCE7028B0048E966FA4B9EF87D879F76B46BCD0FDD73F03C03B068E6C18FED9CAF7F02B3223807B97B7FC1439FF5B6AC1BDC453F43C88CAA3BF7793823CF7C19F57593BD4B782AB3678D760F824B6EAA0B595F5336587F36A542C5040F98
E5A238513458582FC205531C56D0B3A8D955136CE8633B34556A9746500C81E0BEC9A8A40E419F87225657E747B03ECDBF8DCDC3AADE5FE0E0B0BA6095F7C4C3BD5BFD9535C2517E9D2BBF747B8A1ABEDA5FE603424C21EABC07D17AD57873F15A1C9730
142350DD3AA8BA67A578B8D09A3CF0DDAE156411FF71F8367DFA6502E71E5C022B529C1E653CAB2F7B591DAB7CB1680B9A143374624625406915D3112376C97972A157ACF55CAB414D190582F7C6B6BC4AC04222416B5D17DA8EE23BEBCADDDD2165E97D
C12B5093B2C81A2753467D8593207398FAD96A03993DF367A04700A80832AC28FCF7FA03B5560C4E8B8DB68F3F9EF0B2669FAF9B7A9BF46ED1B1BA6A0D71A3357E4E047290A0D936FA88CAC6A2A900F3562BDC28AE3C67AE3FD621BEEBDD726BABF531CA
3D4A3F94F5FF0184D155961F35EE239DC0B4ADD43BCF422EE1D93094CB0B5111CB52C354A5AA53A0A0CF584F77096CF07B98E35E3DFCE9E2137E418D60EFE0E40566FFF1B41F2BAEDE77F47D8F7EFB10E2371A8D14E383B15FC2EE0A7693DAFF572D4653
6D8D4AA179D2AEAEBDAC559832BD00A3DA4BEB6422119365CD09F8CBB0EDB107BC8FD73229324679DC2795C31B2F53684E85965BBED5154995F9938177D61B15C23CE8FBAFFA3180EA95BB440731429071F376E6603A7D5052A9EBAFD1AD16453C1F40A4
E6F8E310022BC7493445C7818CF430DB80928B9107DCD6AC350D3AEFEC1A7F9351BF62F49FA442DAFFEB942B71E63FB6064C8F87D748588E62C764E7AE7520D57A4783C7633F4B920B4DD36CA48FB725F5BE587C6F76816F99F1686A371366F95CE204E2
3571EE7CB0C45010EE292783A5A0AA35EABC4688E3944FADA05AE4C6B1361110A5E897821FD93E5C26F5020472DCA58B0EC02AAB68B8469311C46B436B0897D0D8B9CB54BE2D7A2170AC1516DC78A237DED62C8D78D6532E808958D028D847F77D4348B0
BF6A315EC5D22AF7CD71F7CBB6FC3E35CFBA1AE636A860786A0152CA336C68BCBD0AAB3C5F3CD60A208017914D39788DE413A03BFDFC5A1C6F85F834838FF4CBF04C5ED3CA645B4087DD4106A9C8F97C21628DFB19F09B3EE52FBFE36256D435A45F192E
2F3A768CAA3AE20DFE626499C892D77C5CE6C6791544CDF76D0899514BD9C3876D506B85C61945B14A27C18F31EB23EBA8B3EBCB3A0DF10021479C4FC8289CE80CBA8C885F55312E882F5D642F4F15D0433F7ACDA4AA059CD4FA6BE88A023F740A7094A6
7216D145FFF7540B51229971F7231A5630F278530D56FB1E7FA2D9724230B58915BFF2D573018335F50CD72439EE175A92983EC046F269177A9C916F7DF61439912791921F5FC894E965A4ED794A5433E7F67753B19C32B1009E5A2C19045C923E3E542D
9159DF96E54258BF3384ECC1FC7E7BA704E454B382DB2AD74ACC7E853F650848E42B97B64CCE353041D7A849B07AC8EBE1F10B463F42B405684334B9201299DC73BB6EE925D400DA4172428FFE960BDE2A7FE22A86221B9858C7E38ED1622FF84183E3A2
94B33891C560E01F749DA7520035EB77E78A85BE7ABB37B2810962DE199EA32F9DCE7D1B9EC6EF66610EB27C97146999A23C756EF6084C344A20220E53DD41E0A734B03191A408CF3D6E448575DFEB5B35FD7F8AF8F92F315CEB1FCFC56066859B5F4328
E89FE3A91FAB1967DFE60031B47F8DB4B0EDB8EFD4D7A9904BA6F4D1F572AC75123A141761102B59C24D59DAA6D89B026D5EBACB63E68BE266AB2A77D9CE28349529F760BA7A0789F8E3174F86E9327AD62B4EAFD406F16035B030B52357CD0D291DC5D9
15A02E9EB21983798BA385405A75F992819E42EEE8E15AE530C0A813282DE9F8853F8C7A53BD75DAEBD127B991F10D38BAB3797135C00DF8F0C0CF7DD2E419CCFCA856BEDF1CC7C5509378918B23D5F6FC0B7F5F811FF5EC2E35E7924D363570DE43D236
3D39EFB7F8E0ED7D19D8DBC29A65C11166FE0BF2D971BF26A67083B174FA1450175C819035D5E0D31C2A53898D5B3DE476250DCDB24A7D2DAE577F2F4BA6BB7E55EB86DE229EFB87518D9A81D595EFD76D43ABA9EB5FE4A5FDBD7200A56E3B3BE56A70DF
680867DE6293CA4E8BF3CB69B37ADAB6E88B9D280B8974C9DC70C24F83493E56551A39351E2EB9A2A9E0DB8EABBC4A9775DCB8F40C08E7926D3976F9C1FA22D0A3E5A53D24E2883BD7BA435AC8575FEB2902870D0457C31C6567F6D7B570DFF49B0F7543
4907166E12F715D654B392D25DFD095B30CD9EF1D4D510F893D2DA51C2E5D4ED867F6E004781A12877FA745002247843CE3C6BE25D863FD00FC55C5E15A86CF80C87F04FDD5AFEF0A51C681455ABC505C975E6443E0ECE43F4479587C81F4002970D04FD
1B1D6CBF2A61A916E767CB942C0EA66C8CBC6FDB692C0AEC8466BE3F68EA62681BCA0F982F2EBB6DD283DEC4E17F7B5C445E91CC77AE9A296AE99EE9376034DAB54F26B36338276EF428C34F28C289809EC6C2EB41124E055FE0482D586117CCEF9AFE03
061C7F5FFC1F5765343F977C0D6CF2B637EB71BA467FFE8B820FCCE7421229995179472F11B2DFCF3217D72688DAA2EB1B71526767FACA8D7CD2BEEDCEC9AB2D8DFFA169B3F9EA704BFDB8353F682F46481101E1B246DABBF78A6A6585A9E66B3C14A9A9
27D9A951CA9FE6B0A7D0506CEDE63B38736577B26A296F50EBB16FD8335F5686CEA973A2D118DF30C05CA81CB9E21D35800B77DE04C132EBE6E2E5378C4D608C3E6520ACBF1C1EA10D403E0121E58115C95E888193B2EF52232B8012708E1924BE9D3F8F
543C34A388DA50FDDBC09632E6CB5D484FDCEAF2E59167FAF7AEA44800142256E73D900485E14FCF84FF03277CE46684CFCF71D372B498288FB1D5CB5D4A8C8D47AB835944E82E076E3A57F35744D1751F8F995BAC687378E8EB662F4A63DE596A27E265
3FCAEBE9495C1A40194C4EDA3B8575C1E7147AC4561011764A5E09E1E7D6EFF78AA66221878ADF6F63B43A93A1D3DABDE73557A778412E44547FE65081D4E8A4D26FA1AEC96261A507E12D4A1A1C1BBD8E86D6319B97E56D56AA68618686A3CBA0F818D8
116CDCF2AB22EBE0E9BB47A0E7108BA7AA3C1037CF4EBD7CAABEF56CBEAD91B74C5BE5A7679834CA8594DF9CD61517907B74947C3CF05340FC495CAF93194335FEBDCF6B6882E25535A6DDD28AED5107BBEFE59183DB907E0E2641CDB312E9FC49E6DF76
C701718D25C6B69A55CEA9DB8F3313E66EDC4825D6A4C4E6739D995D7A7BD6DD4F9FA68DE4895C4B4FC38E4C6A090A62D0A22586CD491E7AE70D3AB8C65000B4D39A1AD876757BCE1B05B0CC36A659ED28E6AFAE44F04B460BB1F5C4ED26E965FA9F1705
9EC09C5131954589284D67C28DA726035359332B1C8362A87605C4640A7A7D7DA33D291FB01E189F88285B79AEA41E7DDD13BF76F814F15E57D087D811492216EAAF531EB16351FAD0059CDC560859164377655A20A7DD9E3A3076A66CC36C28D42CEE6A
53DD2C4068FBC315714B14FEA3A80A5CDD8B67BCD44DAED0732B56EFAD40CDD7107B067686681367C3E7573204A4E1CCC92D460B9DF710DB28B754848AE2749405F66C8C729C2500B82A3A869F6A6E619F5759532917379D135AA551D2B616F8507D5A9A
351C1F22E0FE4557F85F8982247FFD65084AAA202F9C4062473746048AAE3D5F296CF0BA7462A55F242F514896E2B88FBCEB1DA00A61B8CE2A94D190AD1AD70AEE50F22F310AFFB0FD367D37BB63EF6D2AFD60AE7FB12416DF30A272E3F12A11BC84C416
78ED665C43EE123BD149458ABEA0FD8AF0AF68BACA18F2BA362E283664E231284DC891C7E3A336F02FD0D6EB11ED096CF3B918E9F12E57896ACCAE4444F99A3DFE4BA461FDC7556F30BEBF588745B39AAD2351FD4B953164375CBC2EF5F45ED26F024217
A9FC5075FE72E479A6402D7AC79C784B2FB98FEAB8404DBD69E28DD12CB70695FD5D40DBA9FDF371E4E29EE6B74D47C1C3F1E9E5A65E30EFA6326DD0A5B13858FAF86FB168CE5B4A03783D92E82A242D8EB355C5A272A8BF1BF2580842E1101D3D9121B3
47E173766BB04969AAD0C44143ED2F1BB1D9AF544736A7F0C766DE9DC59B9D0AEDEB7D96A1D5EE7973968EBF7CF433AF40632A3AC38A04808A6BB4F6C02EF9A8EDFD669B1564A5DF87C6B7593ED855D5FC574F3E5A45BCC89BA267A45A184FDABB274DC3
F1BDB18E31FBFD33604FA016B742D49D551CBFC40B95C35D6D299ACB18CAF6C231331EFE8F20AA198122027F7EC92A3F9C6C0B0BD6D99BC5665034910DE7A0BBD8D88095940C958420939CF015F3DE7E0B2B7DC553567CEBE25D6D9D87976AE78B0940C3
0A31DC2CCDBAD4561B32F984C24C31C6F97D3F6DF9CC78248CABE5B4CE73053E4212717EEF7E0BA119C92FD5AEAB23F295825850128CA5023CD1DE73BBA8157E4CF02A37C8AA7E854DAB0C323DA6231D2B9615DB93714EA3AD1A53618FEBF49443AD9523
F27B557EB3B985CC5A806FB6D09D0DFE224F4DEAC11B115D27BB55122CBADF1DB4E9D289ECE4FF9A9283593E208DDA9448CCCA375D9CA4AE7FD0A8A0767018F53C97E177C066EC2DFC482CE0631DEA760AB074F8092E662F7343447A267538E3356D9ED2
8B39995D39FE8A64D3698FB2734C320F31D0C096E422BC8E38AE0DF227A6D1CD3A3497703A6CFB8DD9868AEA5DB0F0D826583920909409D311305904794C3E0B7B37A4FF1522FFA64DCA6B4ED1F9F2C6B9BDE6809ACDDA2DED7DB4441F827809AB698D76
0A24D4B1AF5DCC199AD3EA616F195FF61910EB24509385E294EE15B1AC3F993F16D0050263E4A1F3AB4A5A3AEDCA66A00BDF21352C3B90AD630C5C22EA54AFB37D60A6A872CA8E920B9740894A325E278DD4371E4580F8C5456874B5A9F767486EE6EB9E
8F5DC4A037DB65D3EFC3CFAADBA5A397B7886D143B615F6BD3278FB06FC91EFFB9EE175547B8DAB8416B392DB413C57E900E08E478D37ACCD971FCFDF75D6ED93EA7E4C0602AAADBB19DDF1AFB18B2738C5BA94E48F366C889BDB81582FD1BEABC486AC9
7D58D4E2FEAB28135D7ED749E5CB7B1F7EBAC80F1F1D435F688F6B416258F3DDDC76E4CC591BBE3E9CD1DA956127EA4687EB2ED58F0DE7E313C515F086F9078A186CD4E94B98847F9A802C73245B1CE99141248C88536A95C74545BD5DA68B16849FDF2C
3A30608470E9155745F772BC6AED34C8F1431073C842F0AD94A02BAB1C32E986DDBDA1D48EEC9DFB15E1A4D7143D0A9A91D7DFB874EC1F714DD4D1A5CBF88CE57FD2D23DEBEDEC24F4592D5597D14770B462345445784A2DBE7640A85DC96E05E082B56D
3939699FA29EB87B16926EB708D7C8C7BF0B9257462B5CB8FE1E973ECA163AD1ED6D649B1BAFF6CC1B705068FB0D76A03675179873A899E0F89B480D162F99FF4E1C9F07A8A1E594AB2BF2A914364ADE93BB2A15D4311A01EE4B5D3341044A89D175C23D
C29E8ECF10F65CE27512FFC240589D723934FB661F1370E28A8EA18E15A631BB954643D235AD7810F8E6AD27A525CEB456B295F9817027887AE3FBD99C3BD44E290C99C6B309702C9299D4E62C8C169451701D01D473E84E1DC881298AB69A17B3DC0462
EB489FBE569E21EFA4BA0A6CDA070537BC99AFC0040CC310D2F94B1CB6228957EAE5A29C3DFCBF2E6103C8521C674E3D7D40774784D753CC79FCC9B30B849C3CF0423EA266BB670F52925ABD7B71263B3B8FE84B5F1D96A217B2926E77988B428BB96265
B221B677366E91A3B8EBCE1A9E7E98A21E901D402E40E79D69A06EF3182AAA47ACCBDBA61C1D0EF275040F360D3DE0FBA12ECB9FDA2AA58B87281A9399004A14CB5CAE70752C47598D8921967647CA34766B5FF2E8A1EE6587AF1359FDCAFE0F7D6A139C
FE92A9548B447BA9680A4A8537B8A83545CE03A3A5CB6846F876509DADF682065048402CA48737386533CC85F3A1DBDB8009F2B40355D01A3BFF567F2F8D555EDCAF0A144DD72B0665FB44B1BBEDAB7F78F70B7C656B13BB3475DB632AF73CE6D5635C6E
302BC09BFD20613218641BACDC92EA16C192FFEBFC8C9F7FFA3C3A1BD3D30FA4734C4CEC5F92161F45F4077C72DBE69DE349B340FE0A79CB56CADD75AC10AD4AB72CE7CB30CE0665CA10434ED09CF4AF2E49E133B77590293EAFD0DEACE65E2FAE34A91F
34F497006C426968E6AD66B06A27EC201BF2C40D2DF44B14C82360D74D703F8444C373FC05EE0ED7C9124C5F7E6AF34376264C54042461B883776FD749D244A0B4013E070B2201C7E28A23DDCD560CF05B5E931AB19E17558707EFEA9545D78FEFB24212
2D91D55EDF15DC0756F8E05B5E9798596DD8543EFC0C37F8E82B3E02706C641CA0616A44784679FAF5CF12D39499CD9C263B544C23CBE50BA3E7A9B0031E5F3196E7467B1CFEDEFD7D80BF782673A8C69F39F9AD76D523DECB4E59C8EBE93F1CFDDFAAA5
B6D05518CAD8FB4009BC569D5FBA1419A0DF1D6B1BA6EC93E7523925D97CB0B533DE1608F4C60CAE4907D46FEF0DBCB6C9C7E19CA5A5C059E424E7791D407BD76D6D09521ACCCCEA59C35DD8F2AFE289B6CDADFCA90F345110119FD2EFAE217CAAF87591
2E46078E6FB2A8FB9B97FC80FAA4FE42CAC5EE1F4C1029A8719940F03BF03E43AF83C2E7245B6FC86F42126ECACCC93B2DFFAAA7F85264719E13BDE696E8A9D641E72CA863DD0F42F3A9EB90C9B29CF0682423F0409D3602B6FFC5F766A94D831BEA5692
8811E8C29991702B86027B225BCA1F5699993757AF10CA8DD80DF762935766EA61421701000A9B253DFB40FA6CF7BB42D2DAFF330FD9E1CC709A84DE6483F69F14334C8EE4D1CFD783505F1E43AB0AECC216357FD37C7DB5B4B775BAD848E4E5DE2E2A54
A41EB0A8E9525BEB0F4886BDFBFFC99A7E5A786280B8F21038E95E910362D3666AE90C24C223BF9443492C0370292CCECB0EBFBA8C2ECA6390A47C587FB9B5C49472B0D6E3C90B495887AE8EDA1DC6C00859E913E69F0C6309CD1A7FCAD8AF3EE13F374A
FAB203C6E6ACEA617198F4CD69F3C30CD1F9AFA501B05875E274BC2745B7CE760F9BE82A4C899300C66E20D7FCC63E1CEAA3644CABB82B247219B0D4FE1FFF44F91FB567D8190012675A7202C852AA722834D2EA34CC5B9007EF2B488E571E41492CFD10
8F1CE99B82CDF4A06320EF922EE37F1B9C9A7567F789D6E23B3A9DC6B6FD335D05E6CF66D5B9D28B68002E7C83DFA5674DBF7E8224C642A3AAA03C845F1757EA7DBAAC389A31731CB7D7861DABB2EDE8542F692299A15D5FEAAF7147A57E1D5FA654A1DF
EDE2AD3653C1C05F7AA8681480082B3CC4AC069C168CE5E1EDE5AB58DCEDC5F84B80DA84DFC34D5A15F171BC583AD58381E4027082A073856A7EACF6F5B315520CCA07AC01D20011B34DB5B4D4B1A08BD5BF0DDE57381740D794E6BA278B21F6A453D78C
3E6E3BFB9D8D8270A104644AAC1AF5A067BE39051C3AB7631A043B85DD454D4E7B4593E73B5819167B96BDD426819CA3E8BCA77CA97473BB7A815C3869BB55D81198B89B6F0A461AD464C88B10F71AFDE2BB6BA046F8B1D61615D0988C2BF5CE1064C212
A7C7EABFD6B0FA290971F9C0FDD73A612A0EB80966866BB3C25DC4EA6F46AAFEB11C30FDE72C0AA6057A304A75A2F0A988F0EC543B900C14BE17140BCBB52FE8593231344EEC18FBE84432F0F2F326512FD3339CC24751E55AAA2331F24D3B1F706B5E0B
43FA0C1C32E52928F2EEBB7A15783D8B9783FFA5E892975AE75665390FB3D3C779390FDA7560E83065715D9EE40B9EA2A4350EA379E3D44F4714D3787DEB2D11E4CE178C5E6EF4FD3EBF4A0B4688D7B095D0F160EC87C9620C5BB4881268C0231662F56F
AEAED70F249AA4F9B2C8789E487F7E0EFC1482242A7AEE26FD8AEDC93D9EECDCF7580DBC2FB97F5FF3848A3C83FBF7CF207BD465D588E991F3CB869388116BE8733C0CC3AFF2F0208AB3966397A41719A7F474ABEF32043D8567697653A86C80FC39F47B
737D8485CA4104153D69FBD5D9CDC3F5F3F0068840C03FFE987BAF09577E2AEE2AA001C186319895E18DFA8CA135B476510998F08CA8F89559A16C4C1A3E102C865CE12D7CAD32E78C4C6AFC413438E18572B912A88080BC5BA8F59F6F54D26BBFB8F883
64A5B32087820D2E2AE5374C4CCD47EAD7332004B2B6584F44D7F20EF75C6804618E7912694CBB2EA5C7A812BABFDED5CACFD6FE457C216FE73335B577F0DBEE94788E90B1FEC62DD1B3C9D863AC83DF8FAECDA2AA1D7DCFC4AD5CE0DE892C500722A82D
0CF5E06D8D9ACEEF3505057CA1CE967AB640FB183161FA269FA9B9B70903FFD374AB9D1016D1C5B15A7261EEBE924C4302B455E01597953D26FCAAC07E4172CCB20EAF5A2F2C1C0EDBDC9DDAF526F876AEB6AAB43B79744CC575E7108A257CC390BA456A
941C6F69ED00EE0C00E6FB017901329E63C96B6E095A5948990EF3A2A3D5AD240D56B0C00F46A44D62A226E465E7176A5D0A605F02493EFAC21F096FD25E4593602985E6FC0F631F4EE4405089726AF0B84B251BBC49D09491CEF64B6D79A0F59964DD4D
7EC2AB431D916C77075AB266FE4832CD26B4A6188BA3C16694CD934B53085FFECCCD12E161B44C26299945118F814F4DBFDD7DD0954F4524F4C9056642EBD3DE96FEB8368E826BE94B2C5DC90258F9D5D3240310FBE247570FA8AC12B1CE21B4FCF68B60
0BBADCC3A56D2F89E98658F18A57FF550A3FDEDCA200EA9EBB9E4B37A9002CDDBB9775E5A62E1DEC63A52660383D63983A5C7A72F73B87C7BB5FB10A9AD8E65E4461C040662452F1EE861E70BC713A1F00099F459B11C7DE4657ED45492ECC1B856DE80C
801F0B4E3223ECAED2BD8ECBD798BBAFBA8B82F2738CCEC85F9C624BBBEAD0653A5808E21EDFC34FE1BB46A21B794B6FB6297EA1078A40981DBD27A5B2122B584AB7062088EDF41DE82D743EEE559D7208C0EE70C7A58049C7DA01BD2B51F2BB50041C74
9C41E2D6BF2BC1DDD062C1A48DE802F9305B30FEDB5CF4C28428A5B3CB954155C6F09C5B86BCDF2460ACD968CB1D8EA9D857BE752CD6421F385E0E46C6E06AAA530B638D69C84F4AEA2962D09ACDBB7DF00AB69DFDA826C2D3F741EFF57C5BA7367EB32C
22FB39D6F99CF6AE894575AA3BCA6C34A055DC081A12034D2AFB8B4CABDE40F77CB95FFFF02ECD2FB91C4C3A67D52C1C4848D5CB2F1BAE4500DCA25F2C380A8552AFEC176B7218E3D42B969987BB901BA136A0F9028FF9255071AD83439AFC48CBBCB7DF
C3A0143F1DF27552E227D4CC623D1BE2B46E3588A766F9F98CEEE93155646C51A23339873519B4A67BF71F24CE2F9F67631DDE7E43D120E5D1D7D2AF04920051AC414C2C9A7E45E6B8F5D58C754DD3D248D82DE2AA473F1E53D1493941CD931AEA1C2441
E4DAA14345477920F397E99CCC2F5D4CFBFC392AE6DC34F9514459F0078D57DD7212983E3336D64B6D0FDCC21941B571A6CCA7F3653DB022F190268BCB1AF01CB2EC13AC76C8DD66C9AC8C6AAFC58AC4D4FFF17A105D4FE6ECB92910DA1885E5B0627E5A
9674D1D3A262EFDEE33AD9610BD27B38F87BADD3417CBA969FCDBFB0E455BCC1BED423B03824BAD876B5CCF50ECB99F44A1B0F72709CF313EDCAAD090DFDD813C75357D7F5499E4D6872AF7B88415B2A5C987CF73FFDD7164B2FD60A54FE4BB262C6C246
A31DD263D989B00FB88FC60FE6754C3F8C48896FB53FED8F027ED119AD679EF40BBF1C1139C8731EA943F5B5E7E82EF083DFFBD71FF77D76475E99D48B8DABA9F4180BA9946BCA52C4E0DAFB4F74D32282BA14A349231C45E378502D721236C24526E964
3DDF13EDFE11C0BE1CE9AED1848CC9EFDD0AA8FB380B93F763F7F76765B1A1364203682E1BE6901E81F25D7A9779C9CA5D28E27C39D4BF7059DDA7009C9064B9D5C80A6C7C923D833C8302B26075B81F9BC93D39162533DD1525D6CF28FDFD6CB5F02A38
B78B3A9375245A758AF4D4DB024A2D57567993A0C31A1772C33649C9C8BDD543B58A0CC1E309AB4780FCE5801F458C21B766BC08A5354F0BD6E8CDC1EB5E6CA7D2DDF108DDA3ACD22194AF0BAB500FB1318A9DABEC6DA363845A6934C1AF7BE9DA249D3F
1E89170C11838E26E0E17C0214E446965C4AAC25F5593E7B57CBA960041E2BEADF9B23138D2CAC540B04E5F1EF0C68CB3D68C406B65BD9273726EE2FB4066B5D38857B85DCD3311DC652AA6AFD3A7D8CCBEAFAB2C882867FBBB8C09446F25E55AE9B6E52
9CBA8E463301C893FDFF4C61DE6A6E65835A29FA510742058B6302F3FCF00E9F64FC5621DB63B478D9951084C37E881380E755C37F350632561328574F1C90C911A8C4F00C46664DDFD074F4E9360C91704B1264967295559E08B4EFBE6BF0940AED253A
41CF3A7932D533C4356F7003793983BA93A377D749CB81F5970DBB7FCBA40AC42D78E2BA951A4E14CD57D26E405D9BDFEAB59FDE9E7E2A366DC2383DEFDAE32E0A6F1DC526B5283E6F436F4E5F1419A617BCC63C8964ED2DEE23DD66A61C641C3DEAB6AC
FD4ED21E84C4D549BFE5A620C0BFC832AF599BBAEEE51EC31FF2E3E79DCA06661DBD4386CF032E71894687FC22D7E3BC571BA6307778B6432FCF50E99092A3C05048193F89F9C813157533B3A4D50DEB678A3D8078620B48FFDC490B6F12A51C94606E0B
2F8C9F829E843A5338890B82587C6DAFE461551B0A361A73DCA971B564496E3B0155A1B85CFF69EA9CE86FDE9FFD81C63C46FD6166FA1FF6318DDC7648DC1EFDD21A17A47045B3544473ED124BFD7E47A6FC95B1D46AA9842DC19CCE75675B0E190FC20B
F0E7A6B66001C7FB8F015DE0AB752BEC701F90499A8D6A4B068E377E4968F84632FBA3F5685E609AD93DB283C8491FEFF6D182FF1FDF9D7D7BC2898F5C06D627C4CEC17AA01890EBEDAD7D14A578527D78C673B7A02DEF11A4B586E8F4E5F9F9B6950ECF
6A3AC6734F90C59F7642F1996988B94A31F2A18CF0D651FCD767D3D230F77EA81021A6088D1FE8E464DE5D62DD54E8F9E86BEB219661887F5468A7F2FF42F690B4BC1A3A7C78EED9F0CBF43B706EF479CBD426681ABF7A59A005E87DEFE4ACEAE246A2E2
8B29E947F537C74E7BAC7B800D3BE85559075562D4CB86F6837ED0E3D8565760B4A45D26D173CDB39248C9727CFBA7E7E46C97F150D63714387C4894B3B291DEA8BC0593D5E691FE5D854F299A69115888721664373E69D3CF70AD0C7CFF5163E5E34A8E
C9E949268C6907CA63792737F183CD2AEA5AE86EC1FBA08421D2636A32D2D531D42F9E28CD1A9F88DB7F7CC8B77C1A28FDAFAED1C28B055360EA55516E94E3CF0017AC0305F46E8F82061CEE71D9F33ABA2454BDCDDA87D720D2AB76CEC786AA91FC97F7
CCDCAB247589D9B5BA31E4F0C6B0FEB50A064554D7EB75AC668066E50EFD6D17B1C37AFF8B1E337616B32CFC311C87A3D7BBD130D179575E6BFAB5313E8D6901D2FE45ECD86D5B22904EE64F928B735FCCE409F76891256A5E3CB29A0D6C5A4D62889557
748E6BBB6FF5E9B6BF78432DB41F13CDA7761072A0091681C4F1DCDC8E2172D3398210A4F51D1B27CDFEC9999862EEFDADEDFBDC459866BD2A031A07EC20FE89734C35C83B2983322C020559C2899B1D1443C0785D38DA2AAE55E8054979004B48438CFE
AF9873C42CF33FF63693E7C9EB110BED409246CAA8D76910A3EDFD3B3DA1A519CDD47EAA237FD53DA08EE97D2E783339BF94E60E3A3A1A80C7B2A0E294D9B25664FA885A5324A1F6929BFD5BEB5D5A2F67972C9F247A4DE05D1140125B42DEE1A6434B93
C16CDEED1D203295C38087EF8A0845FB37221104E39C7BF2BDE5A0EBCE6924D15BBCA6B03CF7805E33F02FC0BCB7C62ABB82422C9E837B9A58BF121CF066362D5ACAD86D80635C74F040693ACC5416D4E6456812A48BFFD3CDCDB1F4FBD574F1F955D2AC
7799C65BDDE8BBB265A598DC0660413F3D73D832F1F3CDC5F7DBF1BC867948AA78B7ECD2F5206FE454A108F7D16215FE2E0CC93FA5BE0D919A7D76FED5C1CD646F3630DFF91649BD47D5FD3E4A12BBD15F19C8383FCF716C7428F43F75C5F88D1BD53901
338F2313E44D5EEF142FD09C2EF0A936EAF179DFB961E54CA8DE64F41538DC031F6EE5DCE1CA36B226F6E145089F13A76796C1202CEB44A2AEAAC91CE274F49B81325B19A6B37696F8FE5CAAF16DBFCEF838BCA34519CE6A530310D1FE2D9628D2CE1853
B82F69E1CD5222CBA5B948D9937425712BC97B0728BA8FA411A5A7B585BA7D3EF2E864DDD6B20580D82407961F0AF771D6555EFB388EBCB476474A8A9256C85875AD1D0B073E81BDD0AD610E2462C7E716FD316A5679CF2816E1588CD2383048483B9319
C38F5ACFFEAA41C185D500F68A2E8EA1FF47B5D7DC49FEF2CC253FC58BA98DFDA6CD013C94A28BFDAEC5629280DF08EE4DAFEAC5C94F5A08BD3BC5857CBBE3FFBCE212975500128CF38CA9DC8C4E3DA572F67BD6C7C8349D1FAC7A4E82816BBDB03A1D78
261EA1FD5DDA4F317AEDAD4AEFB72FC04EA02790276190F835CE619D28D4A31E6D30F87C87A87DC8835C4B0E98677AE318B08FB8A27F30FF717D2FA40B306EF66083AE6C9DA8F255BEBF4023FC319AE74BC8C7D198EC218C63EB1F2BD985CDC2A9DC907F
FF9431E9EA821441D988B8C05BB09D38C072C76A0F90D343BF84F15933ADC4ECAB171F759041DEF4EF0AC22167318A53FE258C41A21D6D32308386137954873589155E13AEC1B1F81B0CD531E379B2D601229B946440B0C5ED91B9F5D70622BB5C02867A
096D5668C87B56BA976ADB523BB93E60F05DAD32F2EDC9F2AA7486D827B66F9A1B39CEFB57ACEE303CD187D7D8AE15A9041F15ADA80A972948A28A38690C98C14697DB2EAF7B658586F319391BAE6F762AB49C1C0EDCDF880CBCB78AFB15D06A5BE8BB15
DB17D940C5FD5FB948CBC2476B3BD91C8BEE5C194A265AD3EA39017125E2E07754172BDCE7FEEABAB26235C380642CDD8AFB5273F6EF44B2F1AD5E73F816135C7D552BD12D02A8D6E27A2F81DBB134A4856205A827C3FD3E6DFE32A23142CEA75D415087
64D6EA17ED6CA04A504FABD96DE718BC1CD7CBCDABD75FC97FA059A252EB0B4CBED8A29D2AC7AC10520294BB31478D5EB640D6E9CAA54A03F3746BE0FA10316C76BA632AD8C5A183B23CF2483FDDA7DCACA05E8EC83C5AD0CA2C2487C0D6FD7443105A67
A13B33ECBABA20E3ECDB4E4AA762547DB11531578BF6D769C558E131F309447A6C90BEC79CA04AA35618265EBB4273E4F8A48071DA76FF8D6ED499029607D3457094D27F465D1F3391A160330118F42516B6D4A59A05BC5B3C47AF75ABB96DB3ACB114AC
FF6855A09C73B382CEBECAF6AF438EBD59F2F5D1292B2001AC88B72B4C465FBA213CAC5BA561E675509F5C5E2CD09219C2095989C1BDE8046F40BA5103C5E653170E2B4D660F93602A288A774A6E944350D373F074510AD8EA7F2EF4A39D118D018FEC44
0093C631DBB51CBE434BD2FF6A0E5EC999ADF30A0E49EB32A52FBD626E8A29A28CCF00B15A861493912A018D8B12F17C4BF528DA56B56D413F4A1312A539EEFA000EBEE7E9CA904414AD777FB0A6C8C486519BC8D6CA1EB9DCF0E8A152537FE3EA3A0AFD
16F19AC923D257268D65152A71FBE4618E237FE84159E9CEDB97F071C16631E769CB5F8DBFE316D57E6974A3DD3AF13DD9A61A159D6BC8D0C66D24089D1352FC5B52DB5ABF50E73F198B5177261ECB953165B62F894A9BD8E4B4677C8A35AA9EB384EFB3
37163BEC6DF8AE5C2D20355A3E188EA1D49C55B53C75A86C9A5703E39C691153E66B3BAE47F6EA576B9DF2D5B3E88C32EC097C9A06D19E3C309094DB862656C8EA4BC5BA67443FC2FD600B7BA7C3E09FB35AD9E7A310B25D754C49A770650565282B9763
B91565C68C2559C45EE849771D0C6CD9A1AB93DA28F0EE5B77A11975AE40DBDF5AB1E982268FCED577180FF2287041038412CD22FBE9D2B24FF4608F469193C6160AFE7C0D2D3673407DA0D3EE32E45407E04C32834278C716BFAD8C8894D357C3757CEF
6668806BB326E05DCC781473775CA30565794E31989AF7139A7563085EB2DE30855E12B439C547D0AED718711508A86922C46FC681674D6D73412F6765BAE1347CD6F888C84EF2FE64AFEFA348FA3532FD08E43C9794467A12BD2D69201CC56F699FD69D
BB72E8C8CBC432AFB6A63D6A93A7FD256952244C14BBE715DC42BF0FCDE9AE0567B844A474A0F9302AC3FBEE6051C7D7A67764900829F1489419028C880E66E22770F5BBC800F204268A975CD7B07B833DDAF00F12397E19F25F6BC122216B51909976DE
4E36C3542793E7DA34AE35B1AAFDA6DAF6B9526F5D484BD63EED4F534970D42B7259867CA700CAA0F2C7B14775B02EE542249C3391B1DD9E3F051C5A3779FDB9E62DEC30BB0693EC3D59AAB1EE05A52D8B86631E2EBBB66B3ED2A826B080CC913BA30975
03EE94E2EF57FABBD025824C807B71431FE9980BEDA407302A028BFED92181D952E58795CE463FA579FB0D14E54B325B0E1B81089CEADA77E0EA7CDF082929CCA8C6C9C4759ED6397743E646285426D4493C4818CC5CD3F5DFCA5916EA1CED572B7726F7
64FCEC6339EA738E42715DC21C710308665C0585798CAC9F052502AB2442DA302C43EF8FDB105A2875B0658FB1CAC0E7C8D09DB4611076399DD836FFB3477CDBCA4F5C29E0290899D419AB3044DBB787991ABAB6472FF4CE4813DFD3E947F5BEF449611B
BADCDFDC933766AEF18859FFAC92F5652372AC84A369FD40C9C30CC4B2F870511880986B2ED5C514A2CC27895FDD92324DE799F29215462CD8661E2BFA4E8D51C0C004F56F34DEBEB3406A9E7242B628B0AE8FA7004F1BAC09AA080290D5D226974AF2DE
3CB57EA4DDEE1141E4A93FAE7A1445C4FD3BC1BEABD75CC42892EE3CE3A124982ABC327CFBCA113487328D6DAD55AC6334FE03D0B9ED5D73527E2446C3EB5E6388156F97853A25A387A888E364704264012924F962E2F4169770E9B32CBF7DFA60E18862
18A1E4C02E43D778E583FBB265159DADB64284CCD8ACC6C72A534CB5E644DDF0D6CEDD8B0F715801FC20535AAE42F263F51D443F793D0E2BF3BA0CC5AF4F2ADE959E97AB699BA28EC9FF7F7E71E8F9092C1465534320AE9B8B16FF7FD5CDF28EA5FBB32A
B2589DDDB21FCE1A2F7BE3E8BF3B2DB9C7E5F371321F9DE98102A9602F23D445FE9FF92AFA496957EAA3D9190755640D92B6F3302E26CF1AACE16BC0313714196F4F26B2B95ABDF48125086ADE6432FAAE103A68066A16D4A87FF3648C74ECDFD01D58E7
7D6125E62DB87C67812724D8B82BEF311E2D563CB4475213DAEE7F935AE5B66A8C44B4741E24EFED7D51F2244E7796C9029429EBC4E85DFBBE21CB4000A4AD51A1CDCCE08312FF938069275BAD1E909923C977FCA5466FF25EC1FE4C5C437D569AEBCE6C
73A29E02F239C89703736FB0F43E34F97DBBA4EA2052AD8161C012CFB09F3A8343779CB133AD5494F99E7F2EAE3DA0BC11C2A817690890AED2BA695E84FF9A889E946C774520F966B8E8301057A4DBD218CB0C2BA496308BF923CDEE66AEB7511DB7A69E
F1CB8201062049137EFD8E87725A80C6CDC8F533BFE919EBDC859E557EB31496A970D74EFFCB8037F7DB1AA626CD972A32A8FF70782FCFDDF6907D944C570F7A0ECC5862AA5FBEDEBA590E701EE002F16435DDD7E43E6AB96AF5EC09D1E0E4AA5AE0D110
90237981168D111E0463065ABA40FC1742CD87B52E5C7C47E6D41CE800865DFE2DE2AF8F7220A9CCEF085218BD036D8C587B0280E1AACF7FC4F2E08C8B7D2ECA4915009584E80DC4DF51F423CDB9C316D85CC1703C589A5418E5454FFAB94A4DC29A6839
850AB4125B57A2A67F8C0025C8AD9D4B33ABC9C7E035F8CFB0FAFD0916D0C255197BBBB94B6EF2B8F19CF6F9D86A2B9CF8E5ABEC2E003CA184633FEA3B6440330038228337703D711523C7975EF7994ACE4C2990E4432EB02892DB14936D8B0AC881AB56
0426750B3959A261452C1868765A26810747D8C4F42B7D15BCAE2629069BB1AB959A27ED3A16E122D672B1F047A99062D28385C624220ECB8A9381F31EBB9FC5650594C7E32E9DF09959F68396AAB4A9E65AEE336E168DD2B919B23A40958D0C0C84B757
B223EE7C74C6D91FE8D7C70506E5295A77FD6BBE9900EE79C6C56C5896043B31A112EDF00944A4995FA16E2E4B350BAC1E59E5F96CA22A3E75AA723B28C1616ECC18340BB9D0B24E20B1F40667D642851187446A1325C2EC341B71F6FA5066C103D6AEC9
950AD5DEBE78784DA80CC753AF11B7B4BCD3E167695B5C11478F881ADC107BD70103BA6D905096C191A0EEA3E47B28061B8EB18C33823CC95EDF96C5D789B19914B76C753C7D3BCF7DBFDFAF25077FD29374F24E6E3408C26A4DB56E7FFFDDC26238976E
78C0162F4DDAA39C1D5655540EACE0EFC4DBCF786F4F768A58200A6A295ECF52B269FC60B098E76FD4460DA21AE00F9D3880F9732D37F3CD084E4FE1955E2C404D32851850A0A500882961E5AAD22D72B891FF3B1B26AECA5CAD54253D2F5A90F3511BDB
3D68D3B80A2ADBFAFAEEE26E5509B7098D39F9AEF962E913F801642FAFAD04816F7B23DCC31A87F701EF88A127EBC8D69E06133D043780A44AF4B7C0270ED1E0F540D2F40C183AF2F670F3A06705938513D879BB36F6CBA54BE9EAFCB5442BBC303BE093
3BF5BF5AB2BFD4416B6F9E2D1C6F641C467C0DF82847B469605279DD4D48799C27ADB70DF85062E989A3C8260CB6F7E2B6A1A6D56DB22A704D5F6B94640BA64A03F6732048F312CCD3973B5BBA12686E3273422CFB56CAF358E07C56125AA044FE762169
7841CFF95C33E8C3FA290BADE720BC63126042F7855AAF56D786FE7F66B4039EA2386441F9C04FAFB6B53701FEE00D5A88E06A9D561B456FE8DBC152865399FA4DAB77746144CF8BA7B8D178D61F0BEF04CB5770A8E8DFBA9404F313E43359E2AC611667
0F7FE520B1AB3ED168210477F28E034FF7D2E563E016F2A4CB605137E182DA6FC045D6C7830E941573E246FBE8CB10C9955B5B3D1E93389282FA6BE4230EF9A2AB256EB22F82B6E61237FFF14B2C51DE787BB705CC2AD81B8F484CE93195BCA9E33FE59B
F1A2EC7AB6B5A86B3DD370D835BBAAC6C5492BB8DBD5597A9595ABF63BE9F70A8ACBC28EC87640076A48206E3A2905D6C69E736C378064664F365A8884D7A824CD18956D042A0FDB15FD402D622484AF9D777436F47C9002208C93CC19B57F6CD9DEC228
59E54564FD4A0061BEA86A2551C4236CDB20E3801F98C6842468B5E1E1A56CC1 | [
"axel.paulander@gmail.com"
] | axel.paulander@gmail.com |
93d3814d967a5a3e9c1dbd8cfa6662e97b32fd5a | 534cd3948c3bc665363e04826e1a42200e81cb1b | /code/baseDiscrete.h | 98e72db5781a90b9db05ffe41f7191b2d254c04e | [] | no_license | yunpeng5/UpdateRandom | 191a27e7e5619133e9c2d86da93dbc2855e212f7 | d7a6f6260ab908bb4767617beebfc0e7e8eddcd0 | refs/heads/master | 2020-09-25T06:28:43.712826 | 2019-12-05T04:48:28 | 2019-12-05T04:48:28 | 225,938,093 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 385 | h | #ifndef MbaseDiscrete
#define MbaseDiscrete
class baseDiscrete
{
public:
//using for starting generating method
virtual ~baseDiscrete()=0;
//using for giving the generating result
virtual int ransample()=0;
//using for change the distribution
virtual void change(int index,double weight)=0;
};
inline baseDiscrete::~baseDiscrete(){};
#endif // MbaseDiscrete
| [
"yunpeng5@ualberta.ca"
] | yunpeng5@ualberta.ca |
3c5b11582811bd14f8a18d04ccb21db42e6cb779 | f2eeceec70af215dfc9a0181aa2696b710cad7ac | /mod03/ex03/ClapTrap.cpp | f06626b08da1d04e469a8fcb900d6c92448ad333 | [] | no_license | a-cha/cpp_beginning | 034ca58a2f3029c651405e9515a1eb0faa2e3506 | 15860bf225793c94e86dfc86702b81856682c44b | refs/heads/master | 2023-03-13T13:14:20.750910 | 2021-03-26T09:00:55 | 2021-03-26T09:00:55 | 339,658,733 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,257 | cpp | //
// Created by Skipjack Adolph on 2/20/21.
//
#include "ClapTrap.hpp"
#include "print.hpp"
ClapTrap::ClapTrap() :
hitPoints(),
maxHitPoints(),
energyPoints(),
maxEnergyPoints(),
level(),
meleeAttackDamage(),
rangedAttackDamage(),
armorDamageReduction()
{
std::cout << BLUE "Parent ClapTrap" STD << " has constructed\n";
}
ClapTrap::ClapTrap(const ClapTrap &other)
{
*this = other;
}
ClapTrap::~ClapTrap()
{
std::cout << BLUE "Parent ClapTrap" STD << " has destructed\n";
}
ClapTrap &ClapTrap::operator=(const ClapTrap &other)
{
if (this != &other)
{
this->name = other.name;
this->hitPoints = other.hitPoints;
this->maxHitPoints = other.maxHitPoints;
this->energyPoints = other.energyPoints;
this->maxEnergyPoints = other.maxEnergyPoints;
this->level = other.level;
this->meleeAttackDamage = other.meleeAttackDamage;
this->rangedAttackDamage = other.rangedAttackDamage;
this->armorDamageReduction = other.armorDamageReduction;
}
return *this;
}
void ClapTrap::rangedAttack(const std::string &target)
{
std::cout << BLUE "<" << this->name << ">" STD <<
" attacks <" BLUE << target << STD "> at range, causing <" <<
RED << this->rangedAttackDamage << STD << "> points of damage!" << std::endl;
}
void ClapTrap::meleeAttack(const std::string &target)
{
std::cout << BLUE "<" << this->name << ">" STD <<
" attacks melee <" BLUE << target << STD ">, causing <" <<
RED << this->meleeAttackDamage << STD << "> points of damage!" << std::endl;
}
void ClapTrap::takeDamage(unsigned int amount)
{
if (hitPoints > amount)
{
if (armorDamageReduction < amount)
this->hitPoints -= (amount - armorDamageReduction);
std::cout << BLUE "<" << this->name << ">" STD << " still alive with <" <<
GREEN << this->hitPoints << STD "> hit points" << std::endl;
}
else
{
hitPoints = 0;
std::cout << BLUE "<" << this->name << ">" STD <<
RED " is about to die" STD << std::endl;
}
}
void ClapTrap::beRepaired(unsigned int amount)
{
hitPoints += amount;
if (hitPoints > maxHitPoints)
hitPoints = maxHitPoints;
std::cout << BLUE "<" << this->name << ">" STD <<
" has been repaired for <" GREEN << amount << STD "> points" << std::endl;
}
std::string ClapTrap::getName()
{
return name;
}
| [
"chaparin.anton@gmail.com"
] | chaparin.anton@gmail.com |
830684dcde0d6ab8ce421350975e178b5fe291d6 | ef97d8c9d304180803fac6c90695a0df240cbbab | /Hough_Transform_on_FPGAs_Using_oneAPI/01_FPGA_Emulation_Using_Intel_oneAPI_Base_Toolkit/src/split/hough_transform_kernel.hpp | c398f9347fee88c6b6cb8240b0fa072ede2d2e81 | [
"MIT"
] | permissive | deepikagoel1/intel-ai | ec3b6e528b72866c948240ba06a807af6bd079d3 | 96504dcd7b3e73708eeefbcd5e8bace08dcfece5 | refs/heads/main | 2023-06-02T19:56:00.093291 | 2021-06-24T19:06:48 | 2021-06-24T19:06:48 | 380,021,530 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 628 | hpp | //==============================================================
// Copyright ยฉ 2020 Intel Corporation
//
// SPDX-License-Identifier: MIT
// =============================================================
#include <vector>
#include <CL/sycl.hpp>
#include <CL/sycl/INTEL/fpga_extensions.hpp>
#include "../../util/sin_cos_values.h"
#define WIDTH 180
#define HEIGHT 120
#define IMAGE_SIZE WIDTH*HEIGHT
#define THETAS 180
#define RHOS 217 //Size of the image diagonally: (sqrt(180^2+120^2))
#define NS (1000000000.0) // number of nanoseconds in a second
using namespace sycl;
void RunKernel(char pixels[], short accumulators[]);
| [
"u78986@s001-n001.aidevcloud"
] | u78986@s001-n001.aidevcloud |
120c5ccae2bafb5d304c4952ceac8e56506cd961 | b3960efcf7b3d22b1f175e642e0a672166d88eb1 | /MiniOpocio.cpp | e1c9d75f8e6188f342727351af9f542458478ced | [] | no_license | LucaPizzagalli/chemotaxis-pathfinding | 170c03e67276f4a116310e4c12cedc13c11a8630 | 462bed4192f22eb2f1fe1a4330d7b8aed64f0557 | refs/heads/master | 2020-05-03T04:27:42.872482 | 2019-03-29T16:32:05 | 2019-03-29T16:32:05 | 178,422,128 | 3 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,900 | cpp | #include <math.h>
#include <algorithm>
#include <stdio.h>
#include "functions.h"
#include "Mappa.h"
#include "Opocio.h"
#include "MiniOpocio.h"
#define VITA_INIZIALE 1
#define INFANZIA 2000
#define SMELL 0.4
MiniOpocio::MiniOpocio(Mappa *in_mappa, float in_posx, float in_posy)
{
dim = 0.4;
speed = 0.2;
vita = VITA_INIZIALE;
infanzia = INFANZIA;
color[0] = 0;
color[1] = 0;
color[2] = 155;
mappa = in_mappa;
posx = in_posx;
posy = in_posy;
calpestato = mappa->get_space(int(posx), int(posy));
left_steps = 0;
extra_step = false;
last_smell = 0.0;
mappa->set_space(int(posx), int(posy), this);
generate_meta();
}
Oggetto* MiniOpocio::live()
{
///physiological stuff
if (vita <= 0)
return this;
infanzia--;
if (infanzia <= 0)
{
mappa->set_space(int(posx), int(posy), calpestato);
calpestato = new Opocio(mappa, posx, posy);
return calpestato;
}
mappa->add_smell(posx, posy, SMELL);
///act according to the situation
if (left_steps <= 0)
{
if (extra_step)
generate_meta();
else
{ ///////////////tune value
float new_smell = mappa->get_smell(posx, posy);
if (new_smell > last_smell)
left_steps = 8;
else
left_steps = 1;
//left_steps = rand()%std::max(1,3+int((new_smell-last_smell)/new_smell));
extra_step = true;
}
}
if(!move())
generate_meta();
return nullptr;
}
void MiniOpocio::generate_meta()
{
float angle = rand()*2*M_PI/RAND_MAX;
velx = speed*cos(angle);
vely = speed*sin(angle);
left_steps = 10;///////////////tune value
last_smell = mappa->get_smell(posx, posy);
extra_step = false;
}
bool MiniOpocio::move()
{
mappa->set_space(int(posx), int(posy), calpestato);
Oggetto *vicino = mappa->get_space(int(posx+velx), int(posy+vely));
if (vicino && vicino->get_type() != cibo_type)
{
mappa->set_space(int(posx), int(posy), this);
return false;
}
calpestato = vicino;
posx += velx;
posy += vely;
left_steps--;
mappa->set_space(int(posx), int(posy), this);
return true;
}
void MiniOpocio::injured(Oggetto *in_enemy, int damage)
{
vita -= damage;
}
void MiniOpocio::draw_1(unsigned char screen_color[SCREEN_HEIGHT][SCREEN_WIDTH][4], int player_posx, int player_posy)
{
int x = int(posx) - player_posx;
int y = int(posy) - player_posy;
screen_color[y][x][2] = color[0];
screen_color[y][x][1] = color[1];
screen_color[y][x][0] = color[2];
}
void MiniOpocio::draw(unsigned char screen_color[SCREEN_HEIGHT][SCREEN_WIDTH][4], float zoom_level, float player_posx, float player_posy)
{
if(calpestato)
calpestato->draw(screen_color, zoom_level, player_posx, player_posy);
int screenx = int((posx - player_posx) * zoom_level);
int screeny = int((posy - player_posy) * zoom_level);
int x_min = int_max(0,screenx-int(zoom_level/2+0.55));
int x_max = int_min(SCREEN_WIDTH-1,screenx+int(zoom_level/2+0.55));
int y_min = int_max(0,screeny-int(zoom_level/2+0.55));
int y_max = int_min(SCREEN_HEIGHT-1,screeny+int(zoom_level/2+0.55));
for (int x = x_min; x <= x_max; x++)
for (int y = y_min; y <= y_max; y++)
if ((x-screenx) * (x-screenx) + (y-screeny) * (y-screeny) <= dim * dim * zoom_level * zoom_level)
{
screen_color[y][x][2] = color[0];
screen_color[y][x][1] = color[1];
screen_color[y][x][0] = color[2];
}
}
Object_type MiniOpocio::get_type()
{
return miniopocio_type;
}
MiniOpocio::~MiniOpocio()
{
if(mappa->get_space(posx, posy) == this)
mappa->set_space(int(posx), int(posy), calpestato);
}
| [
"lucapizzagalli@gmail.com"
] | lucapizzagalli@gmail.com |
8a3c39af6374a8fc32b985e7aa94969ff2d2ed18 | 013545d017d2e9d2ff1109385810413366959bf4 | /main.cpp | f01dc70d58b87a0c0eeec76425785edd8d1a2d6f | [] | no_license | ahorovit/Chess_AI | 9a296fbef7a5dc208dcd6958a12512ea79f4ef3a | d6ea8e37aa68806596622b85ae590450d52933a7 | refs/heads/master | 2020-12-25T15:19:22.695835 | 2016-06-14T05:54:14 | 2016-06-14T05:54:14 | 61,095,355 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,048 | cpp | /*
* File: main.cpp
* Author: arit
*
* Created on March 18, 2015, 6:24 PM
*/
#include <cstdlib>
#include <iostream>
#include "chessBoard.h"
#include "chessPlayer.h"
#include "myPlayer.h"
using namespace std;
/*
* Usage: chess with no arguments makes the player white.
* chess with any arguments make the player black.
*/
int main(int argc, char** argv) {
// Declare and initialize variables
chessBoard gameBoard; // the official game board
// ... player is White, unless an argument is passed
chessBoard::colorType playerColor=chessBoard::White;
if (argc>1)
playerColor=chessBoard::Black;
chessPlayer *player = new myPlayer(playerColor); // the computer player
chessBoard::square from, to;
cout << "Welcome to Homework Six simplified chess." << endl
<< " Please enter your moves in the format 'e2-e3'." << endl
<< " You are playing " << (playerColor==chessBoard::White?"White":"Black") << "." << endl << endl;
// Make chess moves until the game ends.
chessBoard::colorType toMove = chessBoard::White; // the color to move
try {
for (;
!gameBoard.gameOverQ();
toMove = (toMove == chessBoard::White ? chessBoard::Black : chessBoard::White)) {
if (playerColor == toMove) { // get a move
char spacer;
cout << gameBoard.print() << endl; // show the game board
// cout << "Valid moves are: " << endl << gameBoard.printMoves() << endl;
cout << "Please enter your move: ";
cin >> from.col >> from.row >> spacer >> to.col >> to.row;
chessBoard::move playerMove = chessBoard::move(from, to);
try {
gameBoard.makeMove(playerMove); // enact the move
player->enemyMove(playerMove); // record the move with the computer player
}
catch (chessBoard::InvalidMoveException e) {
cout << e.badMove.print() << " is an invalid move!" << endl;
cout << "Valid moves were: " << endl << gameBoard.printMoves() << endl;
// give another chance (skip enemy turn)
toMove = (toMove == chessBoard::White ? chessBoard::Black : chessBoard::White);
continue;
}
} else {
chessBoard::move computerMove;
try {
computerMove = player->getMove();
} catch (exception e) { cout << "EXCEPTION2" << endl;} // we ignore the player's exceptions, but you shouldn't
cout << "I move: " << computerMove.print() << endl;
gameBoard.makeMove(computerMove); // make the computer's move
}
}
}
catch (exception e) { cout << "EXCEPTION1" << endl;} // we ignore the player's exceptions, but you shouldn't
// We got here because the game is over ... see who wins
cout << endl << "Game Over: " << (toMove==chessBoard::White?"Black":"White") << " wins!" << endl;
return toMove;
}
| [
"ahorovit@gmail.com"
] | ahorovit@gmail.com |
ad54c973fe477e9c01d2c20f550dd95517d04913 | 78db2b7e7c0575bc39e2cbc4c679d13c48fe4aa1 | /Source/NZGame/Item/NZDroppedPickup.cpp | a50fa0b7d0833b3b2e22187381680fc38ee104f0 | [] | no_license | cloudjiang/NZGame | 77641257405dbf4adb564ee5965f3e47c88eadb2 | 0e637494c49187937683b9ffd063c5db9e97efe7 | refs/heads/master | 2020-12-01T11:47:01.445948 | 2016-08-21T08:02:59 | 2016-08-21T08:02:59 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 11,610 | cpp | // Fill out your copyright notice in the Description page of Project Settings.
#include "NZGame.h"
#include "NZDroppedPickup.h"
#include "NZInventory.h"
#include "NZGameMode.h"
#include "NZProjectileMovementComponent.h"
#include "UnrealNetwork.h"
#include "NZRecastNavMesh.h"
#include "NZWorldSettings.h"
#include "NZPickupMessage.h"
// Sets default values
ANZDroppedPickup::ANZDroppedPickup()
{
// Set this actor to call Tick() every frame. You can turn this off to improve performance if you don't need it.
PrimaryActorTick.bCanEverTick = true;
PrimaryActorTick.bStartWithTickEnabled = true;
InitialLifeSpan = 15.0f;
Collision = CreateDefaultSubobject<UCapsuleComponent>(TEXT("Capsule"));
Collision->SetCollisionProfileName(FName(TEXT("Pickup")));
Collision->InitCapsuleSize(64.0f, 30.0f);
Collision->OnComponentBeginOverlap.AddDynamic(this, &ANZDroppedPickup::OnOverlapBegin);
RootComponent = Collision;
Movement = CreateDefaultSubobject<UNZProjectileMovementComponent>(TEXT("Movement"));
Movement->HitZStopSimulatingThreshold = 0.7f;
Movement->UpdatedComponent = Collision;
Movement->OnProjectileStop.AddDynamic(this, &ANZDroppedPickup::PhysicsStopped);
SetReplicates(true);
bReplicateMovement = true;
NetUpdateFrequency = 1.0f;
}
// Called when the game starts or when spawned
void ANZDroppedPickup::BeginPlay()
{
Super::BeginPlay();
if (!IsPendingKillPending())
{
// Don't allow Instigator to touch until a little time has passed so a live player throwing an item doesn't immediately pick it back up again
GetWorld()->GetTimerManager().SetTimer(EnableInstigatorTouchHandle, this, &ANZDroppedPickup::EnableInstigatorTouch, 1.0f, false);
}
}
void ANZDroppedPickup::EndPlay(const EEndPlayReason::Type EndPlayReason)
{
Super::EndPlay(EndPlayReason);
// todo:
/* ANZRecastNavMesh* NavData = GetNZNavData(GetWorld());
if (NavData != NULL)
{
NavData->RemoveFromNavigation(false);
}
if (Inventory != NULL && !Inventory->IsPendingKillPending())
{
Inventory->Destroy();
}
GetWorldTimerManager().ClearAllTimersForObject(this);*/
}
void ANZDroppedPickup::PostNetReceiveVelocity(const FVector& NewVelocity)
{
Movement->Velocity = NewVelocity;
}
void ANZDroppedPickup::GetLifetimeReplicatedProps(TArray<FLifetimeProperty>& OutLifetimeProps) const
{
Super::GetLifetimeReplicatedProps(OutLifetimeProps);
DOREPLIFETIME_CONDITION(ANZDroppedPickup, InventoryType, COND_None);
//DOREPLIFETIME_CONDITION(ANZDroppedPickup, WeaponSkin, COND_None);
}
USoundBase* ANZDroppedPickup::GetPickupSound_Implementation() const
{
if (Inventory != NULL)
{
return Inventory->PickupSound;
}
else if (InventoryType != NULL)
{
return InventoryType.GetDefaultObject()->PickupSound;
}
else
{
return NULL;
}
}
void ANZDroppedPickup::SetInventory(ANZInventory* NewInventory)
{
Inventory = NewInventory;
InventoryType = (NewInventory != NULL) ? NewInventory->GetClass() : NULL;
InventoryTypeUpdated();
bFullyInitialized = true;
CheckTouching();
}
void ANZDroppedPickup::InventoryTypeUpdated_Implementation()
{
//ANZPickupInventory::CreatePickupMesh(this, Mesh, InventoryType, 0.0f, FRotator::ZeroRotator, false);
}
void ANZDroppedPickup::OnOverlapBegin(UPrimitiveComponent* ThisComp, AActor* OtherActor, UPrimitiveComponent* OtherComp, int32 OtherBodyIndex, bool bFromSweep, const FHitResult& SweepResult)
{
if (bFullyInitialized && (OtherActor != Instigator || !GetWorld()->GetTimerManager().IsTimerActive(EnableInstigatorTouchHandle)))
{
APawn* P = Cast<APawn>(OtherActor);
if (P != NULL && !P->bTearOff && !GetWorld()->LineTraceTestByChannel(P->GetActorLocation(), GetActorLocation(), ECC_Pawn, FCollisionQueryParams(), WorldResponseParams))
{
ProcessTouch(P);
}
}
}
void ANZDroppedPickup::PhysicsStopped(const FHitResult& ImpactResult)
{
// It we landed on a mover, attach to it
if (ImpactResult.Component != NULL && ImpactResult.Component->Mobility == EComponentMobility::Movable)
{
//Collision->AttachTo(ImpactResult.Component.Get(), NAME_None, EAttachLocation::KeepWorldPosition);
Collision->AttachToComponent(ImpactResult.Component.Get(), FAttachmentTransformRules::KeepWorldTransform);
}
ANZRecastNavMesh* NavData = GetNZNavData(GetWorld());
if (NavData != NULL)
{
NavData->AddToNavigation(this);
}
}
bool ANZDroppedPickup::AllowPickupBy_Implementation(APawn* Other, bool bDefaultAllowPickup)
{
ANZCharacter* NZC = Cast<ANZCharacter>(Other);
bDefaultAllowPickup = bDefaultAllowPickup && NZC != NULL && NZC->bCanPickupItems && !NZC->IsRagdoll();
bool bAllowPickup = bDefaultAllowPickup;
ANZGameMode* NZGameMode = GetWorld()->GetAuthGameMode<ANZGameMode>();
return (NZGameMode == NULL || !NZGameMode->OverridePickupQuery(Other, InventoryType, this, bAllowPickup)) ? bDefaultAllowPickup : bAllowPickup;
}
void ANZDroppedPickup::ProcessTouch_Implementation(APawn* TouchedBy)
{
if (Role == ROLE_Authority && TouchedBy->Controller != NULL && AllowPickupBy(TouchedBy, true))
{
PlayTakenEffects(TouchedBy); // First allows PlayTakenEffects() to work off Inventory instead of InventoryType if it wants
GiveTo(TouchedBy);
ANZGameMode* NZGame = GetWorld()->GetAuthGameMode<ANZGameMode>();
if (NZGame != NULL && NZGame->NumBots > 0)
{
float Radius = 0.0f;
USoundBase* PickupSound = GetPickupSound();
if (PickupSound)
{
Radius = PickupSound->GetMaxAudibleDistance();
const FAttenuationSettings* Settings = PickupSound->GetAttenuationSettingsToApply();
if (Settings != NULL)
{
Radius = FMath::Max<float>(Radius, Settings->GetMaxDimension());
}
}
// todo:
/* for (FConstControllerIterator It = GetWorld()->GetControllerIterator(); It; ++It)
{
if (It->IsValid())
{
ANZBot* B = Cast<ANZBot>(It->Get());
if (B != NULL)
{
B->NotifyPickup(TouchedBy, this, Radius);
}
}
}*/
}
Destroy();
}
}
void ANZDroppedPickup::GiveTo_Implementation(APawn* Target)
{
if (Inventory != NULL && !Inventory->IsPendingKillPending())
{
ANZCharacter* C = Cast<ANZCharacter>(Target);
if (C != NULL)
{
ANZInventory* Duplicate = C->FindInventoryType<ANZInventory>(Inventory->GetClass(), true);
if (Duplicate == NULL || !Duplicate->StackPickup(Inventory))
{
C->AddInventory(Inventory, true);
/* ANZWeapon* WeaponInv = Cast<ANZWeapon>(Inventory);
if (WeaponInv)
{
if (WeaponSkin)
{
C->SetSkinForWeapon(WeaponSkin);
}
else
{
FString WeaponPathName = WeaponInv->GetPathName();
bool bFoundSkin = false;
// Set character's skin back to what the NZPlayerState has
ANZPlayerState* PS = Cast<ANZPLayerState>(C->PlayerState);
if (PS)
{
for (int32 i = 0; i < PS->WeaponSkins.Num(); i++)
{
if (PS->WeaponSkins[i]->WeaponType == WeaponPathName)
{
C->SetSkinForWeapon(PS->WeaponSkin[i]);
bFoundSkin = true;
break;
}
}
}
if (!bFoundSkin)
{
for (int32 i = 0; i < C->WeaponSkins.Num(); i++)
{
if (C->WeaponSkins[i]->WeaponType == WeaponPathName)
{
C->WeaponSkins.RemoveAt(i);
break;
}
}
}
}
}*/
if (Cast<APlayerController>(Target->GetController()) &&
(!Cast<ANZWeapon>(Inventory) || !C->GetPendingWeapon() || (C->GetPendingWeapon()->GetClass() != Inventory->GetClass())))
{
Cast<APlayerController>(Target->GetController())->ClientReceiveLocalizedMessage(UNZPickupMessage::StaticClass(), 0, NULL, NULL, Inventory->GetClass());
}
Inventory = NULL;
}
else
{
if (Cast<APlayerController>(Target->GetController()))
{
Cast<APlayerController>(Target->GetController())->ClientReceiveLocalizedMessage(UNZPickupMessage::StaticClass(), 0, NULL, NULL, Inventory->GetClass());
}
Inventory->Destroy();
}
}
}
}
void ANZDroppedPickup::PlayTakenEffects_Implementation(APawn* TakenBy)
{
USoundBase* PickupSound = GetPickupSound();
if (PickupSound != NULL)
{
UNZGameplayStatics::NZPlaySound(GetWorld(), PickupSound, TakenBy, SRT_All, false, GetActorLocation(), NULL, NULL, false);
}
if (GetNetMode() != NM_DedicatedServer)
{
UParticleSystem* ParticleTemplate = NULL;
if (Inventory != NULL)
{
ParticleTemplate = Inventory->PickupEffect;
}
else if (InventoryType != NULL)
{
ParticleTemplate = InventoryType.GetDefaultObject()->PickupEffect;
}
if (ParticleTemplate != NULL)
{
ANZWorldSettings* WS = Cast<ANZWorldSettings>(GetWorld()->GetWorldSettings());
if (WS == NULL || WS->EffectIsRelevant(this, GetActorLocation(), true, false, 10000.0f, 1000.0f))
{
UGameplayStatics::SpawnEmitterAtLocation(this, ParticleTemplate, GetActorLocation(), GetActorRotation());
}
}
}
}
void ANZDroppedPickup::EnableInstigatorTouch()
{
if (Instigator != NULL)
{
CheckTouching();
}
}
void ANZDroppedPickup::CheckTouching()
{
TArray<AActor*> Overlaps;
GetOverlappingActors(Overlaps, APawn::StaticClass());
for (AActor* TestActor : Overlaps)
{
APawn* P = Cast<APawn>(TestActor);
if (P != NULL && P->GetMovementComponent() != NULL)
{
FHitResult UnusedHitResult;
OnOverlapBegin(Collision, P, Cast<UPrimitiveComponent>(P->GetMovementComponent()->UpdatedComponent), 0, false, UnusedHitResult);
}
}
}
void ANZDroppedPickup::Tick(float DeltaTime)
{
if (!bFullyInitialized)
{
bFullyInitialized = true;
CheckTouching();
}
Super::Tick(DeltaTime);
}
float ANZDroppedPickup::BotDesireability_Implementation(APawn* Asker, float PathDistance)
{
return 0.f;
}
float ANZDroppedPickup::DetourWeight_Implementation(APawn* Asker, float PathDistance)
{
return 0.f;
}
| [
"terryzhong@tencent.com"
] | terryzhong@tencent.com |
f1f03fd068acb396217f8c97e4a00a623b35e7cc | 79810323367c80f327e639eccbe420680cb9c4c0 | /VideoCutting/FfmpegMixer.cpp | c0916324b45526a7c2a04c1caa5b10ae37a7cad8 | [] | no_license | 4ortyk/Mix | 5ee1d88b60b42eb0f3ece17aeeb291cf45acbd85 | 4ef3cf0b6b5502603db5f0f3b97f7a352d46cdf2 | refs/heads/master | 2021-01-19T03:16:32.136829 | 2012-09-07T09:11:14 | 2012-09-07T09:11:14 | 5,672,022 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,425 | cpp | #include "stdafx.h"
#include "FfmpegMixer.h"
#ifdef __cplusplus
extern "C"
#endif
{
#include <libavformat\avformat.h>
#include <libavutil\avutil.h>
#include <libswscale\swscale.h>
}
CFfmpegMixer::CFfmpegMixer(const CLayout& layout) : CConsumer(layout)
{
}
CFfmpegMixer::CFfmpegMixer(const CFfmpegMixer& obj) : CConsumer(obj)
{
}
CFfmpegMixer::~CFfmpegMixer()
{
}
CFfmpegMixer& CFfmpegMixer::operator=(const CFfmpegMixer& obj)
{
if (this == &obj)
return *this;
CConsumer::operator=(obj);
return *this;
}
void CFfmpegMixer::ScaleFrame(Uint8 *srcBuff, size_t originalW, size_t originalH,
Uint8 *destBuff, size_t scaledW, size_t scaledH)
{
if (srcBuff == NULL || destBuff == NULL)
return;
AVFrame* originalFrame = avcodec_alloc_frame();
AVFrame* rescaledFrame = avcodec_alloc_frame();
avpicture_fill(reinterpret_cast<AVPicture*>(originalFrame), srcBuff, PIX_FMT_YUV420P, originalW, originalH);
avpicture_fill(reinterpret_cast<AVPicture*>(rescaledFrame), destBuff, PIX_FMT_YUV420P, scaledW, scaledH);
SwsContext* encoderSwsContext = sws_getContext(originalW, originalH,
PIX_FMT_YUV420P, scaledW, scaledH,
PIX_FMT_YUV420P, SWS_BICUBIC, NULL, NULL, NULL);
sws_scale(encoderSwsContext, originalFrame->data, originalFrame->linesize,
0, originalH, rescaledFrame->data, rescaledFrame->linesize);
sws_freeContext(encoderSwsContext);
av_free(originalFrame);
av_free(rescaledFrame);
} | [
"antonina_pelts@bigmir.net"
] | antonina_pelts@bigmir.net |
f6ecdf4d44213482d1085671421e1fff46e78d77 | abca9e32e4fb97c9433ce50720049e0a8f18d9d4 | /src/support/cleanse.cpp | bece96ae3d3c0de3119e6c388970ac67928636dc | [
"MIT"
] | permissive | nikolake/minerium | b0829475f24033b81b184781308dbaef1db182d1 | aa014119a70ba4997df1ab4ab05570a0b01f1590 | refs/heads/master | 2022-07-18T13:33:04.536700 | 2020-05-17T19:03:20 | 2020-05-17T19:03:20 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 424 | cpp | // Copyright (c) 2009-2010 Satoshi Nakamoto
// Copyright (c) 2009-2015 The Bitcoin Core developers
// Copyright (c) 2014-2020 The Minerium Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "cleanse.h"
#include <openssl/crypto.h>
void memory_cleanse(void *ptr, size_t len)
{
OPENSSL_cleanse(ptr, len);
}
| [
"46746362+bunbunbunbunbunny@users.noreply.github.com"
] | 46746362+bunbunbunbunbunny@users.noreply.github.com |
ee5f6605484155c42e0eb941a5b761a83beee623 | 217807dd255fa7a2df1535dc6844b39317573f60 | /src/Eclipse.cpp | a519eaaa8f128fad5211ba41bf29c064aaa771ea | [] | no_license | jkleiber/EclipseR | e287a98d49fc0e896960ba241062492761c1d5c9 | a2e7ff1cdf601dc008a4ceec9c6f387880496609 | refs/heads/master | 2021-08-24T02:47:00.523675 | 2017-12-07T18:25:07 | 2017-12-07T18:25:07 | 106,234,285 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,762 | cpp | /*
* Eclipse.cpp
*
* Created on: Sep 17, 2017
* Author: justin
*/
#include "Eclipse.h"
#include <iostream>
Eclipse::Eclipse()
{
this->catalogNum = "0";
this->eclipseType = " ";
this->numCells = 24;
this->numColumns = 0;
this->rawInput = "";
this->numErrors = 0;
this->row = 0;
for(int i = 0; i < 24; ++i)
{
this->columnErrors[i] = false;
}
}
Eclipse::Eclipse(Eclipse &eclipse)
{
this->catalogNum = eclipse.catalogNum;
this->eclipseType = eclipse.eclipseType;
this->numCells = eclipse.numCells;
this->numColumns = eclipse.numColumns;
this->rawInput = eclipse.rawInput;
this->numErrors = eclipse.numErrors;
this->row = eclipse.row;
for(int i = 0; i < 24; ++i)
{
this->cells[i] = eclipse.cells[i];
}
for(int i = 0; i < 24; ++i)
{
this->columnErrors[i] = eclipse.columnErrors[i];
}
}
void Eclipse::operator=(const Eclipse & eclipse)
{
this->catalogNum = eclipse.catalogNum;
this->eclipseType = eclipse.eclipseType;
this->numCells = eclipse.numCells;
this->numColumns = eclipse.numColumns;
this->rawInput = eclipse.rawInput;
this->numErrors = eclipse.numErrors;
this->row = eclipse.row;
for(int i = 0; i < 24; ++i)
{
this->cells[i] = eclipse.cells[i];
}
for(int i = 0; i < 24; ++i)
{
this->columnErrors[i] = eclipse.columnErrors[i];
}
}
Eclipse::~Eclipse()
{
}
bool Eclipse::equals(Eclipse Eclipse)
{
if(this->catalogNum == Eclipse.catalogNum && this->eclipseType == Eclipse.eclipseType
&& this->numCells == Eclipse.numCells && this->numColumns == Eclipse.numColumns) {
bool areCellsSame = true;
for(int i = 0; i < this->numColumns; ++i)
{
if(this->cells[i] != Eclipse.cells[i])
{
areCellsSame = false;
break;
}
}
if(areCellsSame)
{
return true;
}
}
return false;
}
std::string Eclipse::getCatalogNum() const {
return catalogNum;
}
void Eclipse::setCatalogNum(const std::string catalogNum) {
this->catalogNum = catalogNum;
}
Cell Eclipse::getCell(int index) const {
return cells[index];
}
void Eclipse::addCell(Cell cell, int index) {
this->cells[index] = cell;
numColumns++;
}
std::string Eclipse::getEclipseType() const {
return eclipseType;
}
void Eclipse::setEclipseType(std::string eclipseType) {
this->eclipseType = eclipseType;
}
int Eclipse::getNumColumns() const {
return this->numColumns;
}
void Eclipse::setNumColumns(int numColumns) {
this->numColumns = numColumns;
}
std::string Eclipse::getRawInput() const {
return rawInput;
}
void Eclipse::setRawInput(std::string rawInput)
{
this->rawInput = rawInput;
}
void Eclipse::addError(int col)
{
this->columnErrors[col] = true;
numErrors++;
}
void Eclipse::printAllErrors()
{
for(int i = 0; i < numColumns; ++i)
{
if(columnErrors[i] && (i == 10 || i == 11))
{
std::cerr << "Error in data row " << this->row << ": Column " << (i + 1) << " is not a decimal number.\n";
}
else if(columnErrors[i])
{
std::cerr << "Error in data row " << this->row << ": Column " << (i + 1) << " is not a whole number.\n";
}
}
}
int Eclipse::getNumErrors()
{
return this->numErrors;
}
void Eclipse::setRow(int row)
{
this->row = row;
}
int Eclipse::getRow()
{
return this->row;
}
bool Eclipse::operator<(const Eclipse& eclipse)
{
return this->cells[0] < eclipse.cells[0];
}
bool Eclipse::operator>(const Eclipse& eclipse)
{
return this->cells[0] > eclipse.cells[0];
}
bool Eclipse::operator==(const Eclipse& eclipse)
{
return this->cells[0] == eclipse.cells[0];
}
bool Eclipse::operator==(const int& catalogNum)
{
return this->cells[0] == catalogNum;
}
bool Eclipse::operator!=(const Eclipse& eclipse)
{
return this->cells[0] != eclipse.cells[0];
}
std::ostream& operator<<(std::ostream& os, Eclipse &eclipse)
{
os << eclipse.rawInput;
return os;
}
| [
"jkleiber8@gmail.com"
] | jkleiber8@gmail.com |
dfd0a650c29e821b4d2be6b11554789074d5adda | f81749de4aad3955433ef183dba9813cd54af57f | /instance/problem/continuous/large_scale/CEC2013/N7S1_SR_Ackley_F6.h | c46b168ae5d6137228eb9dec185658e8e752ae45 | [] | no_license | Strawberry9583/OFEC_Alpha | bc27208143647e91f5acd7cfc86b666c8a59aac4 | f251f02d8d63544f49d832efa8acb06da5cd028a | refs/heads/master | 2021-08-22T11:00:32.068132 | 2017-11-28T02:04:36 | 2017-11-28T02:04:36 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,179 | h | /*************************************************************************
* Project:Open Frameworks for Evolutionary Computation (OFEC)
*************************************************************************
* Author: Li Zhou
* Email: 441837060@qq.com
* Language: C++
*************************************************************************
* This file is part of OFEC. This library is free software;
* you can redistribute it and/or modify it under the terms of the
* GNU General Public License as published by the Free Software
* Foundation; either version 2, or (at your option) any later version.
*************************************************************************/
#ifndef N7S1_SR_ACKLEY_F6_H
#define N7S1_SR_ACKLEY_F6_H
#include "function_CEC2013.h"
namespace OFEC {
namespace CEC2013 {
class N7S1_SR_Ackley_F6 final:public function_CEC2013 {
public:
N7S1_SR_Ackley_F6(param_map &v);
N7S1_SR_Ackley_F6(const std::string &name, size_t size_var, size_t size_obj);
void evaluate__(real *x, std::vector<real>& obj);
~N7S1_SR_Ackley_F6();
protected:
void initialize();
};
}
using CEC2013_LSOP_F6 = CEC2013::N7S1_SR_Ackley_F6;
}
#endif
| [
"changhe.lw@gmail.com"
] | changhe.lw@gmail.com |
870dfda88ec680676877b445cd001002f333e8b7 | 0aa76b60b43fcef208c372fd72900936b39266ea | /mainwindow.cpp | 9b46a9afca7045ec0b1f8448de77d3fdc39404c8 | [] | no_license | jac132/custom-tcp-passthrough | 2351114e1d64e31ea9ffa236cf3020b1af07f576 | 71db08f86b8a7e53782ef397cebb41c7259943f8 | refs/heads/master | 2021-01-10T10:27:04.990783 | 2012-11-05T19:46:56 | 2012-11-05T19:46:56 | 51,627,377 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 11,669 | cpp | #include "mainwindow.h"
#include "ui_mainwindow.h"
MainWindow::MainWindow(QWidget *parent) :
QMainWindow(parent),
ui(new Ui::MainWindow)
{
ui->setupUi(this);
defHost = "109.234.78.19";
defPort = "10001";
reachedServer = false;
loopActEd = false;
connect(ui->textBr_1, SIGNAL(anchorClicked(QUrl)),
this, SLOT(processLink(QUrl)));
connect(ui->textBr_2, SIGNAL(anchorClicked(QUrl)),
this, SLOT(processLink(QUrl)));
connect(ui->textBr_3a, SIGNAL(anchorClicked(QUrl)),
this, SLOT(processLink(QUrl)));
connect(ui->textBr_3b, SIGNAL(anchorClicked(QUrl)),
this, SLOT(processLink(QUrl)));
ui->stackedWidget->setCurrentIndex(0);
//ui->lineEditHost->setText("109.234.74.22");109.234.78.19
ui->lineEditHost->setText(defHost);
ui->lineEditPort->setText(defPort);
LogFile = new QFile("ctp_log.txt");
LogFile->open(QIODevice::WriteOnly | QIODevice::Text);
log("", "started");
}
MainWindow::~MainWindow()
{
log("", "shutting down");
if (loopActEd) setupLoopback(false); //false != activate -> false == deactivate
LogFile->close();
delete ui;
}
void MainWindow::manageInQuery() {
log("textBr_3a", "<span>It seems to work.</span>");
Server->blockSignals(true);
//disconnect(Server,SIGNAL(newConnection()));
log("textBr_3b", "a client connected");
internalSocket = Server->nextPendingConnection();
internalSocket->blockSignals(false);
connect(internalSocket, SIGNAL(disconnected()), this, SLOT(manageDisco()));
connect(externalSocket, SIGNAL(connected()), this, SLOT(connectedToExt()));
externalSocket->connectToHost(ui->lineEditHost->text(), ui->lineEditPort->text().toInt());
if (internalSocket->isWritable()) internalSocket->write(externalSocket->readAll());
connect(internalSocket, SIGNAL(readyRead()), this, SLOT(readIntSocket()));
}
void MainWindow::connectedToExt() {
if (externalSocket->isWritable()) externalSocket->write(internalSocket->readAll());
connect(externalSocket, SIGNAL(readyRead()), this, SLOT(readExtSocket()));
}
void MainWindow::manageDisco() {
internalSocket->blockSignals(true);
//disconnect(internalSocket, SIGNAL(disconnected()));
internalSocket->abort();
//internalSocket = new QTcpSocket();
externalSocket->abort();
//externalSocket = new QTcpSocket();
log("textBr_3b", "a client disconnected");
log("textBr_3a", "<span><b>You can now close this application.</b></span>");
ui->pushB_exit->setText("Exit");
ui->pushB_exit->setEnabled(true);
if (Server->hasPendingConnections()) {
qDebug() << "jawohl";
manageInQuery();
} else {
Server->blockSignals(false);
}
}
void MainWindow::readIntSocket() {
if (!externalSocket->isWritable()) return;
qDebug() << "readIntSocket()";
externalSocket->write(internalSocket->readAll());
}
void MainWindow::readExtSocket() {
if (!internalSocket->isWritable()) return;
qDebug() << "readExtSocket()";
internalSocket->write(externalSocket->readAll());
}
void MainWindow::on_pushB_startNetAnal_clicked() // :)
{
ui->pushB_startNetAnal->setEnabled(false);
ui->pushB_startNetAnal->setText("Testing. Please wait ..");
ui->centralWidget->setCursor(Qt::BusyCursor);
log("textBr_0", "Testing connection to CAE version server .. ");
QTcpSocket* TestSocket = new QTcpSocket();
connect(TestSocket, SIGNAL(stateChanged(QAbstractSocket::SocketState)),
this, SLOT(processNasState(QAbstractSocket::SocketState)));
connect(TestSocket, SIGNAL(error(QAbstractSocket::SocketError)),
this, SLOT(processNasError(QAbstractSocket::SocketError)));
TestSocket->connectToHost(QHostAddress(defHost), 10001);
}
void MainWindow::processNasState(QAbstractSocket::SocketState state) {
QString msg = "";
QTcpSocket* socket = qobject_cast<QTcpSocket*>(QObject::sender());
switch(state)
{
case QAbstractSocket::UnconnectedState:
if (socket->error() == -1) {
msg = "Not connected.";
} else {
msg = ("\n\nCould not connect to the server! There propably is a maintenance.\n");
ui->centralWidget->setCursor(Qt::ArrowCursor);
ui->pushB_startNetAnal->setEnabled(true);
ui->pushB_startNetAnal->setText("Start network analysis");
ui->stackedWidget->setCurrentIndex(1);
}
break;
case QAbstractSocket::HostLookupState: msg = "Looking up host ..";
break;
case QAbstractSocket::ConnectingState: msg = "Connecting to server ..";
break;
case QAbstractSocket::ConnectedState: msg = "Successfully connected to server!";
reachedServer = true;
socket->disconnectFromHost();
socket->deleteLater();
ui->centralWidget->setCursor(Qt::ArrowCursor);
ui->stackedWidget->setCurrentIndex(2);
break;
case QAbstractSocket::BoundState: msg = "BoundState: if you see this, something went wrong";
break;
case QAbstractSocket::ClosingState: msg = "Closing connection ..";
break;
case QAbstractSocket::ListeningState: msg = "ListeningState. if you see this, something went wrong";
break;
default: msg = "Trying to connect ..";
}
msg.append(QString(reachedServer?" (1)":" (0)"));
if (socket->error() != -1) msg.append(" | error: " + QString::number(socket->error()) + " = " + socket->errorString() + "\n\n\n");
log("textBr_0", msg);
}
void MainWindow::processNasError(QAbstractSocket::SocketError error) {
QString msg = "";
switch(error) {
case QAbstractSocket::ConnectionRefusedError: msg= "ConnectionRefused" ;
break;
case QAbstractSocket::RemoteHostClosedError: msg= "RemoteHostClosed" ;
break;
case QAbstractSocket::HostNotFoundError: msg= "HostNotFound" ;
break;
case QAbstractSocket::SocketAccessError: msg= "SocketAccess" ;
break;
case QAbstractSocket::SocketResourceError: msg= "SocketResource" ;
break;
case QAbstractSocket::SocketTimeoutError: msg= "SocketTimeout" ;
break;
case QAbstractSocket::DatagramTooLargeError: msg= "DatagramTooLarge" ;
break;
case QAbstractSocket::NetworkError: msg= "Network" ;
break;
case QAbstractSocket::AddressInUseError: msg= "AddressInUse" ;
break;
case QAbstractSocket::SocketAddressNotAvailableError: msg= "SocketAddressNotAvailable" ;
break;
case QAbstractSocket::UnsupportedSocketOperationError: msg= "UnsupportedSocketOperation" ;
break;
case QAbstractSocket::ProxyAuthenticationRequiredError: msg= "ProxyAuthenticationRequired" ;
break;
case QAbstractSocket::SslHandshakeFailedError: msg= "SslHandshakeFailed" ;
break;
case QAbstractSocket::UnfinishedSocketOperationError: msg= "UnfinishedSocketOperation" ;
break;
case QAbstractSocket::ProxyConnectionRefusedError: msg= "ProxyConnectionRefused" ;
break;
case QAbstractSocket::ProxyConnectionClosedError: msg= "ProxyConnectionClosed" ;
break;
case QAbstractSocket::ProxyConnectionTimeoutError: msg= "ProxyConnectionTimeout" ;
break;
case QAbstractSocket::ProxyNotFoundError: msg= "ProxyNotFound" ;
break;
case QAbstractSocket::ProxyProtocolError: msg= "ProxyProtocol" ;
break;
case QAbstractSocket::UnknownSocketError: msg= "UnknownSocket" ;
break;
}
msg.prepend("Error encountered while connecting: ");
}
void MainWindow::processLink(QUrl url) {
if (url.toString().left(5) == "goto:") {
ui->stackedWidget->setCurrentIndex(url.toString().remove(0, 5).toInt());
} else {
QDesktopServices::openUrl(url);
}
}
void MainWindow::on_pushB_fixError_clicked()
{
ui->pushB_fixError->setEnabled(false);
runLocalServer();
}
void MainWindow::runLocalServer() {
Server = new QTcpServer(this);
if (Server->listen(QHostAddress::Any, 10001)) {
log("textBr_3b", "server now listening on port 10001");
internalSocket = new QTcpSocket();
externalSocket = new QTcpSocket();
connect(Server, SIGNAL(newConnection()), this, SLOT(manageInQuery()));
connect(internalSocket, SIGNAL(disconnected()), this, SLOT(manageDisco()));
setupLoopback(true);
} else {
log("textBr_3b", "Error: server can't listen on port 10001, probably another programme is already listening on that port.");
log("textBr_3b", "Try restarting this programme.");
log("textBr_3b", "If that doesn't help, perform a clean boot and start this programme again.");
}
}
void MainWindow::setupLoopback(bool install) {
if (install) {
// add addr "Loop" 109.234.74.22/32 store=active
// (/32 means MASK 255.255.255.255)
log("textBr_3a", "Adding 109.234.74.22 to loopback device.");
QProcess* SetupProcess = new QProcess(this);
SetupProcess->start("netsh", QStringList() << "int" << "ip" << "add" << "address" << "\"Loop\"" << "109.234.74.22/32" << "store=active");
log("textBr_3a", "Running netsh int ip add addr \"Loop\" 109.234.74.22/32 store=active");
connect(SetupProcess, SIGNAL(finished(int)), this, SLOT(finishLoopbackAct(int)));
} else {
// delete address "Loop" addr=109.234.74.22
log("textBr_3a", "Removing 109.234.74.22 from loopback device.");
QProcess* SetupProcess = new QProcess(0); // 0 as parent so process will continue running after this prog is closed
SetupProcess->start("netsh", QStringList() << "int" << "ip" << "delete" << "address" << "\"Loop\"" << "addr=109.234.74.22");
log("textBr_3a", "Running netsh int ip delete address \"Loop\" addr=109.234.74.22");
connect(SetupProcess, SIGNAL(finished(int)), this, SLOT(finishLoopbackDeAct(int)));
}
}
void MainWindow::finishLoopbackAct(int status) {
log("textBr_3a", "Act: " + QString::number(status));
loopActEd = true;
if (status == 0) {
log("textBr_3a", "<span><b>Try launching CAE now.</b></span>");
} else {
log("textBr_3a", "<span><b>Sorry. Could not fix error automatically. Consider reinstalling CAE: <a href=\"http://download.nexoneu.com/cba/fullversion/Combatarms_eu.exe\">download.nexoneu.com/cba/fullversion/Combatarms_eu.exe</a></b></span>");
}
}
void MainWindow::finishLoopbackDeAct(int status) {
log("textBr_3a", "DeAct: " + QString::number(status));
}
void MainWindow::on_pushB_exit_clicked()
{
this->close();
}
void MainWindow::log(QString loc, QString msg) {
if (loc == "textBr_0") {
ui->textBr_0->append(msg);
} else if (loc == "textBr_1") {
ui->textBr_1->append(msg);
} else if (loc == "textBr_2") {
ui->textBr_2->append(msg);
} else if (loc == "textBr_3a") {
ui->textBr_3a->append(msg);
} else if (loc == "textBr_3b") {
ui->textBr_3b->append(msg);
}
QDate date = QDate::currentDate();
QTime time = QTime::currentTime();
LogFile->write(QString(date.toString("yyyy-MM-dd") + " " + time.toString("hh-mm-ss") + " " + loc + ": " + msg + "\n").toUtf8());
qDebug() << QString(date.toString("yyyy-MM-dd") + " " + time.toString("hh-mm-ss") + " " + loc + ": " + msg);
}
| [
"asisit@hotmail.com"
] | asisit@hotmail.com |
630e33a2d541108ab08bb6b8a85b0c005ed8fa7d | d6cf7e3a1a58fd3185e2619419f6aa66e8e9a9da | /3.6.7 Cyclic process. Working with numbers in number/4/main.cpp | 0d09dcdca2ebf818a13208e9bae77ec1f2d9ddf9 | [] | no_license | Nkeyka/Qt-Creator-Cpp-Book | 6ba92cdb0eda0b844c83815266756c7e18d285e1 | dcbfaf86bd0ece7c0e5642e03ab5796e2a68c916 | refs/heads/main | 2023-02-23T08:52:16.902547 | 2021-02-02T05:21:36 | 2021-02-02T05:21:36 | 319,847,831 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 304 | cpp | #include <iostream>
using namespace std;
int main()
{
int N, even = 0, odd = 0;
cout << "N = ";
cin >> N;
do {
if (N % 10 % 2 == 0) even++;
else odd++;
N /= 10;
} while (N > 0);
cout << "even " << even << " odd " << odd;
return 0;
}
| [
"nkeyka@gmail.com"
] | nkeyka@gmail.com |
947c15559da3e7539dd1ac740521379275f5d172 | 73d648a072775d64db7a4c4711b9da32c69fbece | /poj/2100.cpp | 4a755b6c54dd3da32834fe7fbf948198afacf275 | [] | no_license | 12Dong/acm | e209605c57e8a2d0247ef5c86f50aec1d43e86b3 | 4f0c98fd4649f730db2ab8300ce45d04dd31e766 | refs/heads/master | 2020-12-30T17:51:18.751827 | 2017-10-21T07:30:56 | 2017-10-21T07:30:56 | 90,933,913 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 592 | cpp | #include<iostream>
#include<cmath>
typedef long long ll;
using namespace std;
ll Ans[10000005][2];
int main()
{
ll n;
while(cin >> n)
{
ll times;
ll l=1,r=1;
ll el,er;
ll ans=0;
ll sum=0;
while(1)
{
while(r<=sqrt(n)&& sum < n)
{
sum=sum+r*r;
r++;
}
if(sum < n) break;
if(sum==n)
{
Ans[ans][0]=l;
Ans[ans++][1]=r;
}
sum=sum-l*l;
l++;
}
cout << ans <<endl;
for(ll i=0;i<ans;i++)
{
cout << Ans[i][1]-Ans[i][0]<<" ";
for(ll j=Ans[i][0];j<Ans[i][1];j++)
{
j==Ans[i][1]-1?cout <<j<<endl:cout <<j<<" ";
}
}
}
}
| [
"289663639@qq.com"
] | 289663639@qq.com |
72d526ce13be34b75079281542f8adae940e7f53 | b2628ff5e11120549620d31d0f03b82452e6dacb | /Demo.cpp | 945226437f3d0fd46d120055e6f3324f23b6cd0f | [] | no_license | ZviMints/BullAndPgia | 999aa7a95878389f23b2ea146aa1136a1f3bba7d | 1189c97cfd929e028cf90bbd20ca0dd97d7b2501 | refs/heads/master | 2020-05-19T00:59:35.124068 | 2019-05-06T11:14:09 | 2019-05-06T11:14:09 | 184,747,250 | 1 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 1,551 | cpp | /**
* A demo program for bull-pgia.
*
* @author Erel Segal-Halevi
* @since 2019-04
*/
#include <iostream>
using namespace std;
#include "play.hpp"
#include "DummyChoosers.hpp"
#include "DummyGuessers.hpp"
#include "SmartGuesser.hpp"
#include <chrono>
#include <thread> // For Sleep
using namespace bullpgia;
int main() {
ConstantChooser c1234{"1234"}, c12345{"12345"}, c9999{"9999"};
ConstantGuesser g1234{"1234"}, g12345{"12345"}, g9999{"9999"};
RandomChooser randy;
RandomGuesser guessy;
// for (uint i=0; i<100; ++i) {
// cout << play(randy, guessy, 2, 100) << endl; // guesser should often win but sometimes lose.
// }
SmartGuesser smarty;
for (uint i=0; i<200; ++i) {
int len = rand()%12 + 1 ; // [1,12]
auto t_start = std::chrono::high_resolution_clock::now();
cout << "(" << len << ",";
uint number_of_guesses;
if( len < 7 ) {
number_of_guesses = play(randy, smarty, len , 100); // smarty should always win in at most 10 turns!
}
else {
//std::this_thread::sleep_for(std::chrono::milliseconds(2000)); // Sleep
number_of_guesses = play(randy, smarty, len , 100); // smarty should always win in at most 50 turns!
}
auto t_end = std::chrono::high_resolution_clock::now();
double elaspedTimeMs = std::chrono::duration<double, std::milli>(t_end-t_start).count();
cout << number_of_guesses << " ," << elaspedTimeMs << ") for (Len,# Guesses,Time (mills))" << endl;
//cout << "******************************* END ***********************" << endl;
}
return 0;
}
| [
"ZviMints@gmail.com"
] | ZviMints@gmail.com |
c5f45768652650881b3845208185c56412da3c17 | d20b517c520a441cd4c2dbbbbcd7c204dc654f61 | /Base Station/src/LilyGO-SIM7000-Cayenne.ino | c54b35f6ec43b45a666f45f46e37269bdc89119d | [] | no_license | izzet-kalinsazlioglu/Monitoring-System | f27f9741b51679c3c62b5de44cd3ec8e496fbb81 | 925ab7a248d04d66095f1eb9e0f745e293d64c5e | refs/heads/main | 2022-12-25T19:59:21.621800 | 2020-10-05T14:50:08 | 2020-10-05T14:50:08 | 301,428,757 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 7,426 | ino |
#define TINY_GSM_DEBUG Serial
#define CAYENNE_PRINT Serial
#define TINY_GSM_MODEM_SIM7000
#define USE_GSM //! Uncomment will use SIM7000 for GSM communication
#ifdef USE_GSM
#include <CayenneMQTTGSM.h>
#else
#include <CayenneMQTTESP32.h>
#endif
#include <Arduino.h>
#include <Wire.h>
#include <Adafruit_BMP085.h>
#define TEMPERATURE_VIRTUAL_CHANNEL 1
#define BAROMETER_VIRTUAL_CHANNEL 2
#define ALTITUDE_VIRTUAL_CHANNEL 3
#define BATTERY_VIRTUAL_CHANNEL 4
#define SOLAR_VIRTUAL_CHANNEL 5
#define LIGHTSENSOR_VIRTUAL_CHANNEL 6
#define PIN_TX 27
#define PIN_RX 26
#define UART_BAUD 115200
#define PWR_PIN 4
#define BAT_ADC 35
#define SOLAR_ADC 36
//for google script Things to change
//const char * ssid = "";
//const char * password = "";
//https://script.google.com/macros/s/AKfycbylrRpSX7SUPJzZfElazwG_BRp7yafTgLRy5vwXbtqaCNFSXGg/exec
String GOOGLE_SCRIPT_ID = "AKfycbylrRpSX7SUPJzZfElazwG_BRp7yafTgLRy5vwXbtqaCNFSXGg"; // Replace by your GAS service id
const int sendInterval = 996 *5; // in millis, 996 instead of 1000 is adjustment, with 1000 it jumps ahead a minute every 3-4 hours
//-------------
//updated 04.12.2019
const char * root_ca=\
"-----BEGIN CERTIFICATE-----\n" \
"MIIDujCCAqKgAwIBAgILBAAAAAABD4Ym5g0wDQYJKoZIhvcNAQEFBQAwTDEgMB4G\n" \
"A1UECxMXR2xvYmFsU2lnbiBSb290IENBIC0gUjIxEzARBgNVBAoTCkdsb2JhbFNp\n" \
"Z24xEzARBgNVBAMTCkdsb2JhbFNpZ24wHhcNMDYxMjE1MDgwMDAwWhcNMjExMjE1\n" \
"MDgwMDAwWjBMMSAwHgYDVQQLExdHbG9iYWxTaWduIFJvb3QgQ0EgLSBSMjETMBEG\n" \
"A1UEChMKR2xvYmFsU2lnbjETMBEGA1UEAxMKR2xvYmFsU2lnbjCCASIwDQYJKoZI\n" \
"hvcNAQEBBQADggEPADCCAQoCggEBAKbPJA6+Lm8omUVCxKs+IVSbC9N/hHD6ErPL\n" \
"v4dfxn+G07IwXNb9rfF73OX4YJYJkhD10FPe+3t+c4isUoh7SqbKSaZeqKeMWhG8\n" \
"eoLrvozps6yWJQeXSpkqBy+0Hne/ig+1AnwblrjFuTosvNYSuetZfeLQBoZfXklq\n" \
"tTleiDTsvHgMCJiEbKjNS7SgfQx5TfC4LcshytVsW33hoCmEofnTlEnLJGKRILzd\n" \
"C9XZzPnqJworc5HGnRusyMvo4KD0L5CLTfuwNhv2GXqF4G3yYROIXJ/gkwpRl4pa\n" \
"zq+r1feqCapgvdzZX99yqWATXgAByUr6P6TqBwMhAo6CygPCm48CAwEAAaOBnDCB\n" \
"mTAOBgNVHQ8BAf8EBAMCAQYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUm+IH\n" \
"V2ccHsBqBt5ZtJot39wZhi4wNgYDVR0fBC8wLTAroCmgJ4YlaHR0cDovL2NybC5n\n" \
"bG9iYWxzaWduLm5ldC9yb290LXIyLmNybDAfBgNVHSMEGDAWgBSb4gdXZxwewGoG\n" \
"3lm0mi3f3BmGLjANBgkqhkiG9w0BAQUFAAOCAQEAmYFThxxol4aR7OBKuEQLq4Gs\n" \
"J0/WwbgcQ3izDJr86iw8bmEbTUsp9Z8FHSbBuOmDAGJFtqkIk7mpM0sYmsL4h4hO\n" \
"291xNBrBVNpGP+DTKqttVCL1OmLNIG+6KYnX3ZHu01yiPqFbQfXf5WRDLenVOavS\n" \
"ot+3i9DAgBkcRcAtjOj4LaR0VknFBbVPFd5uRHg5h6h+u/N5GJG79G+dwfCMNYxd\n" \
"AfvDbbnvRG15RjF+Cv6pgsH/76tuIMRQyV+dTZsXjAzlAcmgQWpzU/qlULRuJQ/7\n" \
"TBj0/VLZjmmx6BEP3ojY+x1J96relc8geMJgEtslQIxq/H5COEBkEveegeGTLg==\n" \
"-----END CERTIFICATE-----\n";
Adafruit_BMP085 bmp;
HardwareSerial gsmSerial(1);
#ifdef USE_GSM
// GSM connection info.
char apn[] = ""; // Access point name. Leave empty if it is not needed.
char gprsLogin[] = ""; // GPRS username. Leave empty if it is not needed.
char gprsPassword[] = ""; // GPRS password. Leave empty if it is not needed.
char pin[] = ""; // SIM pin number. Leave empty if it is not needed.
#else
// WiFi network info.
char ssid[] = "your wifi ssid";
char wifiPassword[] = "your wifi password";
#endif
// Cayenne authentication info. This should be obtained from the Cayenne Dashboard.
char username[] = "dbd718c0-0afd-11e7-a044-09cb7c7beef1";
char password[] = "b311142229b601732d6cda7fdef1f2e9be49c185";
char clientID[] = "b313b040-fbf6-11ea-93bf-d33a96695544";
bool bmpSensorDetected = true;
void setup()
{
Serial.begin(UART_BAUD);
gsmSerial.begin(UART_BAUD, SERIAL_8N1, PIN_RX, PIN_TX);
pinMode(PWR_PIN, OUTPUT);
//Launch SIM7000
digitalWrite(PWR_PIN, HIGH);
delay(300);
digitalWrite(PWR_PIN, LOW);
// Launch BMP085
// if (!bmp.begin())
// {
// bmpSensorDetected = false;
// Serial.println("Could not find a valid BMP085 sensor, check wiring!");
// while (1)
// {
// }
// }
//Wait for the SIM7000 communication to be normal, and will quit when receiving any byte
int i = 6;
delay(200);
while (i)
{
Serial.println("Send AT");
gsmSerial.println("AT");
if (gsmSerial.available())
{
String r = gsmSerial.readString();
Serial.println(r);
break;
}
delay(1000);
i--;
}
#ifdef USE_GSM
Cayenne.begin(username, password, clientID, gsmSerial, apn, gprsLogin, gprsPassword, pin);
#else
Cayenne.begin(username, password, clientID, ssid, wifiPassword);
#endif
Serial.println("Ready to go");
}
float getFakeTemperature() {
return micros()%20;
}
String fakeFunc1()
{
return "somedata";
}
float fakeFunc2()
{
return millis()%100;
}
void loop()
{
Cayenne.loop();
}
// Default function for processing actuator commands from the Cayenne Dashboard.
// You can also use functions for specific channels, e.g CAYENNE_IN(1) for channel 1 commands.
CAYENNE_IN_DEFAULT()
{
CAYENNE_LOG("Channel %u, value %s", request.channel, getValue.asString());
//Process message here. If there is an error set an error message using getValue.setError(), e.g getValue.setError("Error message");
}
CAYENNE_IN(1)
{
CAYENNE_LOG("Channel %u, value %s", request.channel, getValue.asString());
}
// This function is called at intervals to send temperature sensor data to Cayenne.
CAYENNE_OUT(TEMPERATURE_VIRTUAL_CHANNEL)
{
if (bmpSensorDetected)
{
float temperature = random(100) ;// bmp.readTemperature();
Serial.print("Temperature = ");
Serial.print(temperature);
Serial.println(" *C");
Cayenne.celsiusWrite(TEMPERATURE_VIRTUAL_CHANNEL, temperature);
}
//delay(2000);
// sendData("info1=" + fakeFunc1()+"&info2="+String(fakeFunc2())+"&temp="+String(getFakeTemperature()));
}
// This function is called at intervals to send barometer sensor data to Cayenne.
CAYENNE_OUT(BAROMETER_VIRTUAL_CHANNEL)
{
if (bmpSensorDetected)
{
float pressure = random(100) ;// bmp.readPressure() / 1000;
Serial.print("Pressure = ");
Serial.print(pressure);
Serial.println(" hPa");
Cayenne.hectoPascalWrite(BAROMETER_VIRTUAL_CHANNEL, pressure);
}
}
CAYENNE_OUT(ALTITUDE_VIRTUAL_CHANNEL)
{
if (bmpSensorDetected)
{
float altitude = random(100) ;// bmp.readAltitude();
Serial.print("Altitude = ");
Serial.print(altitude);
Serial.println(" meters");
Cayenne.virtualWrite(ALTITUDE_VIRTUAL_CHANNEL, altitude, "meters", UNIT_METER);
}
}
float readBattery(uint8_t pin)
{
int vref = 1100;
uint16_t volt = analogRead(pin);
float battery_voltage = ((float)volt / 4095.0) * 2.0 * 3.3 * (vref);
return battery_voltage;
}
CAYENNE_OUT(BATTERY_VIRTUAL_CHANNEL)
{
float mv = readBattery(BAT_ADC);
Serial.printf("batter : %f\n", mv);
Cayenne.virtualWrite(BATTERY_VIRTUAL_CHANNEL, mv, TYPE_VOLTAGE, UNIT_MILLIVOLTS);
}
CAYENNE_OUT(SOLAR_VIRTUAL_CHANNEL)
{
float mv = readBattery(SOLAR_ADC);
Serial.printf("solar : %f\n", mv);
Cayenne.virtualWrite(SOLAR_VIRTUAL_CHANNEL, mv, TYPE_VOLTAGE, UNIT_MILLIVOLTS);
}
| [
"izzet@idealyazilim.net"
] | izzet@idealyazilim.net |
32e571fabfb8fb3e32576a977ae3538399daee17 | 349fe789ab1e4e46aae6812cf60ada9423c0b632 | /Program/FIBPlus/DBServ20/DocReal/UDMDocReal.h | 0177ef4c4e4ab4d7486f8d6e4fd7626338b50fe9 | [] | no_license | presscad/ERP | a6acdaeb97b3a53f776677c3a585ca860d4de980 | 18ecc6c8664ed7fc3f01397d587cce91fc3ac78b | refs/heads/master | 2020-08-22T05:24:15.449666 | 2019-07-12T12:59:13 | 2019-07-12T12:59:13 | 216,326,440 | 1 | 0 | null | 2019-10-20T07:52:26 | 2019-10-20T07:52:26 | null | WINDOWS-1251 | C++ | false | false | 5,074 | h | //---------------------------------------------------------------------------
#ifndef UDMDocRealH
#define UDMDocRealH
//---------------------------------------------------------------------------
#include <Classes.hpp>
#include <Controls.hpp>
#include <StdCtrls.hpp>
#include <Forms.hpp>
#include <DB.hpp>
#include <IBCustomDataSet.hpp>
#include <IBDatabase.hpp>
#include <IBQuery.hpp>
#include "FIBDatabase.hpp"
#include "FIBDataSet.hpp"
#include "pFIBDatabase.hpp"
#include "pFIBDataSet.hpp"
#include "FIBQuery.hpp"
#include "pFIBQuery.hpp"
//---------------------------------------------------------------------------
class TDMDocReal : public TDataModule
{
__published: // IDE-managed Components
TDataSource *DataSourceDoc;
TDataSource *DataSourceDocT;
TDataSource *DataSourceDocAll;
TpFIBTransaction *IBTr;
TpFIBTransaction *IBTrUpdate;
TpFIBDataSet *DocAll;
TpFIBDataSet *Doc;
TpFIBDataSet *DocT;
TFIBDateTimeField *DocAllPOSDOC;
TFIBSmallIntField *DocAllPRDOC;
TFIBStringField *DocAllTDOC;
TFIBIntegerField *DocAllNUMDOC;
TFIBBCDField *DocAllSUMDOC;
TFIBStringField *DocAllNAME_SINFBASE_OBMEN;
TFIBStringField *DocAllNAMEFIRM;
TFIBStringField *DocAllNAMESKLAD;
TFIBStringField *DocAllNAMEKLIENT;
TFIBStringField *DocAllFNAME_USER;
TFIBStringField *DocPRIMREA;
TFIBStringField *DocNAME_TPRICE;
TFIBStringField *DocNAMEKLIENT;
TFIBStringField *DocNAMEBSCHET;
TFIBBCDField *DocTKOLREAT;
TFIBBCDField *DocTKFREAT;
TFIBBCDField *DocTPRICEREAT;
TFIBBCDField *DocTSUMREAT;
TFIBStringField *DocTNAMENOM;
TFIBStringField *DocTNAMEED;
TFIBIntegerField *DocTTNOM;
TpFIBTransaction *IBTrDvReg;
TpFIBQuery *pFIBQ;
TIntegerField *DocTRECNO;
TpFIBQuery *QueryCancelDvReg;
TpFIBQuery *QueryDvReg;
TpFIBDataSet *NumDoc;
TFIBBCDField *DocAllIDDOC;
TFIBBCDField *DocAllIDFIRMDOC;
TFIBBCDField *DocAllIDSKLDOC;
TFIBBCDField *DocAllIDKLDOC;
TFIBBCDField *DocAllIDDOGDOC;
TFIBBCDField *DocAllIDUSERDOC;
TFIBBCDField *DocAllIDDOCOSNDOC;
TFIBIntegerField *DocAllTYPEEXTDOC;
TFIBBCDField *DocIDREA;
TFIBBCDField *DocIDDOCREA;
TFIBBCDField *DocIDTPRICEREA;
TFIBBCDField *DocIDGRPOLREA;
TFIBBCDField *DocIDBSCHETREA;
TFIBBCDField *DocTIDREAT;
TFIBBCDField *DocTIDDOCREAT;
TFIBBCDField *DocTIDNOMREAT;
TFIBBCDField *DocTIDEDREAT;
TFIBBCDField *DocAllIDEXTDOC;
TFIBStringField *DocAllGID_DOC;
TFIBStringField *DocGID_DREA;
TFIBStringField *DocTGID_DREAT;
TFIBBCDField *DocIDBASE_DREA;
TFIBBCDField *DocTIDBASE_DREAT;
TFIBBCDField *DocAllIDBASE_GALLDOC;
void __fastcall DataModuleDestroy(TObject *Sender);
void __fastcall DocTCalcFields(TDataSet *DataSet);
void __fastcall DataModuleCreate(TObject *Sender);
void __fastcall DocTBeforeDelete(TDataSet *DataSet);
void __fastcall DocTAfterDelete(TDataSet *DataSet);
void __fastcall DocTKOLREATChange(TField *Sender);
void __fastcall DocTPRICEREATChange(TField *Sender);
void __fastcall DocNewRecord(TDataSet *DataSet);
void __fastcall DocTNewRecord(TDataSet *DataSet);
void __fastcall DocAllPOSDOCChange(TField *Sender);
void __fastcall DocAllNAME_SINFBASE_OBMENGetText(TField *Sender,
AnsiString &Text, bool DisplayText);
void __fastcall DocAllIDBASE_GALLDOCChange(TField *Sender);
private: // User declarations
public: // User declarations
__fastcall TDMDocReal(TComponent* Owner);
void NewDoc(void);
void OpenDoc(__int64 IdDoc);
bool SaveDoc(void);
bool DvRegDoc(void);
bool CancelDvRegDoc(void);
void AddDocNewString(void);
void DeleteStringDoc(void);
void CloseDoc(void);
bool DeleteDoc(__int64 id);
double Summa(void);
__int64 GetIDDocPoNomeruDoc(int number_doc, TDate date_doc);
bool NewElement; // ะฝะพะฒัะน ัะปะตะผะตะฝั
bool Prosmotr; //ัะพะปัะบะพ ะฟัะพัะผะพัั
bool NoEdit;
bool Vibor; //ะดะปั ะฒัะฑะพัะฐ
__int64 IdDoc; //ะธะดะตะฝัะธัะธะบะฐัะพั ัะตะบััะตะน ะทะฐะฟะธัะธ
__int64 IdGrp; // ะธะดะตัะธัะธะบะฐัะพั ะณััะฟะฟั
__int64 IdElementaMaster; //ะธะดะตะฝัะธัะธะบะฐัะพั ะฒะฝะตัะตะฝะณะพ ัะฟัะฐะฒะพัะฝะธะบะฐ-ะฒะปะฐะดะตะปััะฐ
double SummaDoc;
double OldSummaStr;
double NewSummaStr;
bool Error;
AnsiString TextError;
int Operation; //1-ัะตะฐะปะธะทะฐัะธั, 2-ะฟะตัะตะผะตัะตะฝะธะต, 3-ะฝะฐ ะฒัะฟััะบ ะฟัะพะดัะบัะธะธ, 4-ัะฟะธัะฐะฝะธะต
int IdSklad;
double SebReal;
double SebProd;
double SebNom;
double KolOtrSpisNom;
double KolSpisNom;
double KolBasEdinic;
double KolBasEdinic2;
double KFEd;
bool AutoRaschet;
bool EnableDvReg;
__int64 GetIDDocSchetFact(void);
bool SkladRozn;
bool NoOtrOstatok;
};
//---------------------------------------------------------------------------
extern PACKAGE TDMDocReal *DMDocReal;
//---------------------------------------------------------------------------
#endif
| [
"sasha@kaserv.ru"
] | sasha@kaserv.ru |
7430f700bbc63dca6e6fb017bbdb3d19c040c296 | 61804cb6c5a947bd89a5d3bedb45fae7dd09480f | /vecteur.cpp | 86ba73ab5d9a01dfb690411fb9fffc5b2f803d1f | [] | no_license | Nageat/VecteurMatrice | 213eedfc9152c1ee229668c99f19dd51eff61c43 | 022263e583f9d06c0aac6aa9ebc345f978ad639c | refs/heads/master | 2020-12-07T23:06:00.147687 | 2020-01-09T14:14:31 | 2020-01-09T14:14:31 | 232,822,484 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 411 | cpp | #include "vecteur.h"
vecteur::vecteur()
{
for (int i = 0; i < 3; i++)
nTab[i] = 0;
}
void vecteur::display(int nTab[])
{
cout << "(" << nTab[0] << "," << nTab[1] << "," << nTab[2] << ")" << endl;
}
vecteur::~vecteur()
{
}
vecteur rodeMembre(Matrice, vecteur)
{
vecteur vect;
for (int i = 0; i < 3; i++)
{
vect.nTab[i] = 0;
for (int j = 0; j < 3; j++) {
vect.nTab[i] ++;
}
}
return vect;
}
| [
"skyfulle68@gmail.com"
] | skyfulle68@gmail.com |
476a45e1d395f41d9e2910c042a0b5694c452777 | 382efc4bb390811b3317652097f80b5def9a963d | /src/rpc/blockchain.cpp | d8d6783b484b5c933dd81c00e71f234cc0df7ec9 | [
"MIT"
] | permissive | maniacoin/maniacoin | dcfc3ea77afdcaa73bcf82e5eefc1b92f81f0de8 | cfc0ee57ddff4e05d363298725c91727c6d27ddf | refs/heads/master | 2023-02-28T11:16:05.730596 | 2021-02-04T20:20:51 | 2021-02-04T20:20:51 | 335,065,954 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 68,175 | cpp | // Copyright (c) 2010 Satoshi Nakamoto
// Copyright (c) 2009-2016 The Bitcoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#include "rpc/blockchain.h"
#include "amount.h"
#include "chain.h"
#include "chainparams.h"
#include "checkpoints.h"
#include "coins.h"
#include "consensus/validation.h"
#include "validation.h"
#include "core_io.h"
#include "policy/feerate.h"
#include "policy/policy.h"
#include "primitives/transaction.h"
#include "rpc/server.h"
#include "streams.h"
#include "sync.h"
#include "txdb.h"
#include "txmempool.h"
#include "util.h"
#include "utilstrencodings.h"
#include "hash.h"
#include <stdint.h>
#include <univalue.h>
#include <boost/thread/thread.hpp> // boost::thread::interrupt
#include <mutex>
#include <condition_variable>
struct CUpdatedBlock
{
uint256 hash;
int height;
};
static std::mutex cs_blockchange;
static std::condition_variable cond_blockchange;
static CUpdatedBlock latestblock;
extern void TxToJSON(const CTransaction& tx, const uint256 hashBlock, UniValue& entry);
double GetDifficulty(const CBlockIndex* blockindex)
{
if (blockindex == nullptr)
{
if (chainActive.Tip() == nullptr)
return 1.0;
else
blockindex = chainActive.Tip();
}
int nShift = (blockindex->nBits >> 24) & 0xff;
double dDiff =
(double)0x0000ffff / (double)(blockindex->nBits & 0x00ffffff);
while (nShift < 29)
{
dDiff *= 256.0;
nShift++;
}
while (nShift > 29)
{
dDiff /= 256.0;
nShift--;
}
return dDiff;
}
UniValue blockheaderToJSON(const CBlockIndex* blockindex)
{
UniValue result(UniValue::VOBJ);
result.push_back(Pair("hash", blockindex->GetBlockHash().GetHex()));
int confirmations = -1;
// Only report confirmations if the block is on the main chain
if (chainActive.Contains(blockindex))
confirmations = chainActive.Height() - blockindex->nHeight + 1;
result.push_back(Pair("confirmations", confirmations));
result.push_back(Pair("height", blockindex->nHeight));
result.push_back(Pair("version", blockindex->nVersion));
result.push_back(Pair("versionHex", strprintf("%08x", blockindex->nVersion)));
result.push_back(Pair("merkleroot", blockindex->hashMerkleRoot.GetHex()));
result.push_back(Pair("time", (int64_t)blockindex->nTime));
result.push_back(Pair("mediantime", (int64_t)blockindex->GetMedianTimePast()));
result.push_back(Pair("nonce", (uint64_t)blockindex->nNonce));
result.push_back(Pair("bits", strprintf("%08x", blockindex->nBits)));
result.push_back(Pair("difficulty", GetDifficulty(blockindex)));
result.push_back(Pair("chainwork", blockindex->nChainWork.GetHex()));
if (blockindex->pprev)
result.push_back(Pair("previousblockhash", blockindex->pprev->GetBlockHash().GetHex()));
CBlockIndex *pnext = chainActive.Next(blockindex);
if (pnext)
result.push_back(Pair("nextblockhash", pnext->GetBlockHash().GetHex()));
return result;
}
UniValue blockToJSON(const CBlock& block, const CBlockIndex* blockindex, bool txDetails)
{
UniValue result(UniValue::VOBJ);
result.push_back(Pair("hash", blockindex->GetBlockHash().GetHex()));
int confirmations = -1;
// Only report confirmations if the block is on the main chain
if (chainActive.Contains(blockindex))
confirmations = chainActive.Height() - blockindex->nHeight + 1;
result.push_back(Pair("confirmations", confirmations));
result.push_back(Pair("strippedsize", (int)::GetSerializeSize(block, SER_NETWORK, PROTOCOL_VERSION | SERIALIZE_TRANSACTION_NO_WITNESS)));
result.push_back(Pair("size", (int)::GetSerializeSize(block, SER_NETWORK, PROTOCOL_VERSION)));
result.push_back(Pair("weight", (int)::GetBlockWeight(block)));
result.push_back(Pair("height", blockindex->nHeight));
result.push_back(Pair("version", block.nVersion));
result.push_back(Pair("versionHex", strprintf("%08x", block.nVersion)));
result.push_back(Pair("merkleroot", block.hashMerkleRoot.GetHex()));
UniValue txs(UniValue::VARR);
for(const auto& tx : block.vtx)
{
if(txDetails)
{
UniValue objTx(UniValue::VOBJ);
TxToUniv(*tx, uint256(), objTx, true, RPCSerializationFlags());
txs.push_back(objTx);
}
else
txs.push_back(tx->GetHash().GetHex());
}
result.push_back(Pair("tx", txs));
result.push_back(Pair("time", block.GetBlockTime()));
result.push_back(Pair("mediantime", (int64_t)blockindex->GetMedianTimePast()));
result.push_back(Pair("nonce", (uint64_t)block.nNonce));
result.push_back(Pair("bits", strprintf("%08x", block.nBits)));
result.push_back(Pair("difficulty", GetDifficulty(blockindex)));
result.push_back(Pair("chainwork", blockindex->nChainWork.GetHex()));
if (blockindex->pprev)
result.push_back(Pair("previousblockhash", blockindex->pprev->GetBlockHash().GetHex()));
CBlockIndex *pnext = chainActive.Next(blockindex);
if (pnext)
result.push_back(Pair("nextblockhash", pnext->GetBlockHash().GetHex()));
return result;
}
UniValue getblockcount(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() != 0)
throw std::runtime_error(
"getblockcount\n"
"\nReturns the number of blocks in the longest blockchain.\n"
"\nResult:\n"
"n (numeric) The current block count\n"
"\nExamples:\n"
+ HelpExampleCli("getblockcount", "")
+ HelpExampleRpc("getblockcount", "")
);
LOCK(cs_main);
return chainActive.Height();
}
UniValue getbestblockhash(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() != 0)
throw std::runtime_error(
"getbestblockhash\n"
"\nReturns the hash of the best (tip) block in the longest blockchain.\n"
"\nResult:\n"
"\"hex\" (string) the block hash hex encoded\n"
"\nExamples:\n"
+ HelpExampleCli("getbestblockhash", "")
+ HelpExampleRpc("getbestblockhash", "")
);
LOCK(cs_main);
return chainActive.Tip()->GetBlockHash().GetHex();
}
void RPCNotifyBlockChange(bool ibd, const CBlockIndex * pindex)
{
if(pindex) {
std::lock_guard<std::mutex> lock(cs_blockchange);
latestblock.hash = pindex->GetBlockHash();
latestblock.height = pindex->nHeight;
}
cond_blockchange.notify_all();
}
UniValue waitfornewblock(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() > 1)
throw std::runtime_error(
"waitfornewblock (timeout)\n"
"\nWaits for a specific new block and returns useful info about it.\n"
"\nReturns the current block on timeout or exit.\n"
"\nArguments:\n"
"1. timeout (int, optional, default=0) Time in milliseconds to wait for a response. 0 indicates no timeout.\n"
"\nResult:\n"
"{ (json object)\n"
" \"hash\" : { (string) The blockhash\n"
" \"height\" : { (int) Block height\n"
"}\n"
"\nExamples:\n"
+ HelpExampleCli("waitfornewblock", "1000")
+ HelpExampleRpc("waitfornewblock", "1000")
);
int timeout = 0;
if (!request.params[0].isNull())
timeout = request.params[0].get_int();
CUpdatedBlock block;
{
std::unique_lock<std::mutex> lock(cs_blockchange);
block = latestblock;
if(timeout)
cond_blockchange.wait_for(lock, std::chrono::milliseconds(timeout), [&block]{return latestblock.height != block.height || latestblock.hash != block.hash || !IsRPCRunning(); });
else
cond_blockchange.wait(lock, [&block]{return latestblock.height != block.height || latestblock.hash != block.hash || !IsRPCRunning(); });
block = latestblock;
}
UniValue ret(UniValue::VOBJ);
ret.push_back(Pair("hash", block.hash.GetHex()));
ret.push_back(Pair("height", block.height));
return ret;
}
UniValue waitforblock(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() < 1 || request.params.size() > 2)
throw std::runtime_error(
"waitforblock <blockhash> (timeout)\n"
"\nWaits for a specific new block and returns useful info about it.\n"
"\nReturns the current block on timeout or exit.\n"
"\nArguments:\n"
"1. \"blockhash\" (required, string) Block hash to wait for.\n"
"2. timeout (int, optional, default=0) Time in milliseconds to wait for a response. 0 indicates no timeout.\n"
"\nResult:\n"
"{ (json object)\n"
" \"hash\" : { (string) The blockhash\n"
" \"height\" : { (int) Block height\n"
"}\n"
"\nExamples:\n"
+ HelpExampleCli("waitforblock", "\"0000000000079f8ef3d2c688c244eb7a4570b24c9ed7b4a8c619eb02596f8862\", 1000")
+ HelpExampleRpc("waitforblock", "\"0000000000079f8ef3d2c688c244eb7a4570b24c9ed7b4a8c619eb02596f8862\", 1000")
);
int timeout = 0;
uint256 hash = uint256S(request.params[0].get_str());
if (!request.params[1].isNull())
timeout = request.params[1].get_int();
CUpdatedBlock block;
{
std::unique_lock<std::mutex> lock(cs_blockchange);
if(timeout)
cond_blockchange.wait_for(lock, std::chrono::milliseconds(timeout), [&hash]{return latestblock.hash == hash || !IsRPCRunning();});
else
cond_blockchange.wait(lock, [&hash]{return latestblock.hash == hash || !IsRPCRunning(); });
block = latestblock;
}
UniValue ret(UniValue::VOBJ);
ret.push_back(Pair("hash", block.hash.GetHex()));
ret.push_back(Pair("height", block.height));
return ret;
}
UniValue waitforblockheight(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() < 1 || request.params.size() > 2)
throw std::runtime_error(
"waitforblockheight <height> (timeout)\n"
"\nWaits for (at least) block height and returns the height and hash\n"
"of the current tip.\n"
"\nReturns the current block on timeout or exit.\n"
"\nArguments:\n"
"1. height (required, int) Block height to wait for (int)\n"
"2. timeout (int, optional, default=0) Time in milliseconds to wait for a response. 0 indicates no timeout.\n"
"\nResult:\n"
"{ (json object)\n"
" \"hash\" : { (string) The blockhash\n"
" \"height\" : { (int) Block height\n"
"}\n"
"\nExamples:\n"
+ HelpExampleCli("waitforblockheight", "\"100\", 1000")
+ HelpExampleRpc("waitforblockheight", "\"100\", 1000")
);
int timeout = 0;
int height = request.params[0].get_int();
if (!request.params[1].isNull())
timeout = request.params[1].get_int();
CUpdatedBlock block;
{
std::unique_lock<std::mutex> lock(cs_blockchange);
if(timeout)
cond_blockchange.wait_for(lock, std::chrono::milliseconds(timeout), [&height]{return latestblock.height >= height || !IsRPCRunning();});
else
cond_blockchange.wait(lock, [&height]{return latestblock.height >= height || !IsRPCRunning(); });
block = latestblock;
}
UniValue ret(UniValue::VOBJ);
ret.push_back(Pair("hash", block.hash.GetHex()));
ret.push_back(Pair("height", block.height));
return ret;
}
UniValue getdifficulty(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() != 0)
throw std::runtime_error(
"getdifficulty\n"
"\nReturns the proof-of-work difficulty as a multiple of the minimum difficulty.\n"
"\nResult:\n"
"n.nnn (numeric) the proof-of-work difficulty as a multiple of the minimum difficulty.\n"
"\nExamples:\n"
+ HelpExampleCli("getdifficulty", "")
+ HelpExampleRpc("getdifficulty", "")
);
LOCK(cs_main);
return GetDifficulty();
}
std::string EntryDescriptionString()
{
return " \"size\" : n, (numeric) virtual transaction size as defined in BIP 141. This is different from actual serialized size for witness transactions as witness data is discounted.\n"
" \"fee\" : n, (numeric) transaction fee in " + CURRENCY_UNIT + "\n"
" \"modifiedfee\" : n, (numeric) transaction fee with fee deltas used for mining priority\n"
" \"time\" : n, (numeric) local time transaction entered pool in seconds since 1 Jan 1970 GMT\n"
" \"height\" : n, (numeric) block height when transaction entered pool\n"
" \"descendantcount\" : n, (numeric) number of in-mempool descendant transactions (including this one)\n"
" \"descendantsize\" : n, (numeric) virtual transaction size of in-mempool descendants (including this one)\n"
" \"descendantfees\" : n, (numeric) modified fees (see above) of in-mempool descendants (including this one)\n"
" \"ancestorcount\" : n, (numeric) number of in-mempool ancestor transactions (including this one)\n"
" \"ancestorsize\" : n, (numeric) virtual transaction size of in-mempool ancestors (including this one)\n"
" \"ancestorfees\" : n, (numeric) modified fees (see above) of in-mempool ancestors (including this one)\n"
" \"depends\" : [ (array) unconfirmed transactions used as inputs for this transaction\n"
" \"transactionid\", (string) parent transaction id\n"
" ... ]\n";
}
void entryToJSON(UniValue &info, const CTxMemPoolEntry &e)
{
AssertLockHeld(mempool.cs);
info.push_back(Pair("size", (int)e.GetTxSize()));
info.push_back(Pair("fee", ValueFromAmount(e.GetFee())));
info.push_back(Pair("modifiedfee", ValueFromAmount(e.GetModifiedFee())));
info.push_back(Pair("time", e.GetTime()));
info.push_back(Pair("height", (int)e.GetHeight()));
info.push_back(Pair("descendantcount", e.GetCountWithDescendants()));
info.push_back(Pair("descendantsize", e.GetSizeWithDescendants()));
info.push_back(Pair("descendantfees", e.GetModFeesWithDescendants()));
info.push_back(Pair("ancestorcount", e.GetCountWithAncestors()));
info.push_back(Pair("ancestorsize", e.GetSizeWithAncestors()));
info.push_back(Pair("ancestorfees", e.GetModFeesWithAncestors()));
const CTransaction& tx = e.GetTx();
std::set<std::string> setDepends;
for (const CTxIn& txin : tx.vin)
{
if (mempool.exists(txin.prevout.hash))
setDepends.insert(txin.prevout.hash.ToString());
}
UniValue depends(UniValue::VARR);
for (const std::string& dep : setDepends)
{
depends.push_back(dep);
}
info.push_back(Pair("depends", depends));
}
UniValue mempoolToJSON(bool fVerbose)
{
if (fVerbose)
{
LOCK(mempool.cs);
UniValue o(UniValue::VOBJ);
for (const CTxMemPoolEntry& e : mempool.mapTx)
{
const uint256& hash = e.GetTx().GetHash();
UniValue info(UniValue::VOBJ);
entryToJSON(info, e);
o.push_back(Pair(hash.ToString(), info));
}
return o;
}
else
{
std::vector<uint256> vtxid;
mempool.queryHashes(vtxid);
UniValue a(UniValue::VARR);
for (const uint256& hash : vtxid)
a.push_back(hash.ToString());
return a;
}
}
UniValue getrawmempool(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() > 1)
throw std::runtime_error(
"getrawmempool ( verbose )\n"
"\nReturns all transaction ids in memory pool as a json array of string transaction ids.\n"
"\nHint: use getmempoolentry to fetch a specific transaction from the mempool.\n"
"\nArguments:\n"
"1. verbose (boolean, optional, default=false) True for a json object, false for array of transaction ids\n"
"\nResult: (for verbose = false):\n"
"[ (json array of string)\n"
" \"transactionid\" (string) The transaction id\n"
" ,...\n"
"]\n"
"\nResult: (for verbose = true):\n"
"{ (json object)\n"
" \"transactionid\" : { (json object)\n"
+ EntryDescriptionString()
+ " }, ...\n"
"}\n"
"\nExamples:\n"
+ HelpExampleCli("getrawmempool", "true")
+ HelpExampleRpc("getrawmempool", "true")
);
bool fVerbose = false;
if (!request.params[0].isNull())
fVerbose = request.params[0].get_bool();
return mempoolToJSON(fVerbose);
}
UniValue getmempoolancestors(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() < 1 || request.params.size() > 2) {
throw std::runtime_error(
"getmempoolancestors txid (verbose)\n"
"\nIf txid is in the mempool, returns all in-mempool ancestors.\n"
"\nArguments:\n"
"1. \"txid\" (string, required) The transaction id (must be in mempool)\n"
"2. verbose (boolean, optional, default=false) True for a json object, false for array of transaction ids\n"
"\nResult (for verbose=false):\n"
"[ (json array of strings)\n"
" \"transactionid\" (string) The transaction id of an in-mempool ancestor transaction\n"
" ,...\n"
"]\n"
"\nResult (for verbose=true):\n"
"{ (json object)\n"
" \"transactionid\" : { (json object)\n"
+ EntryDescriptionString()
+ " }, ...\n"
"}\n"
"\nExamples:\n"
+ HelpExampleCli("getmempoolancestors", "\"mytxid\"")
+ HelpExampleRpc("getmempoolancestors", "\"mytxid\"")
);
}
bool fVerbose = false;
if (!request.params[1].isNull())
fVerbose = request.params[1].get_bool();
uint256 hash = ParseHashV(request.params[0], "parameter 1");
LOCK(mempool.cs);
CTxMemPool::txiter it = mempool.mapTx.find(hash);
if (it == mempool.mapTx.end()) {
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Transaction not in mempool");
}
CTxMemPool::setEntries setAncestors;
uint64_t noLimit = std::numeric_limits<uint64_t>::max();
std::string dummy;
mempool.CalculateMemPoolAncestors(*it, setAncestors, noLimit, noLimit, noLimit, noLimit, dummy, false);
if (!fVerbose) {
UniValue o(UniValue::VARR);
for (CTxMemPool::txiter ancestorIt : setAncestors) {
o.push_back(ancestorIt->GetTx().GetHash().ToString());
}
return o;
} else {
UniValue o(UniValue::VOBJ);
for (CTxMemPool::txiter ancestorIt : setAncestors) {
const CTxMemPoolEntry &e = *ancestorIt;
const uint256& _hash = e.GetTx().GetHash();
UniValue info(UniValue::VOBJ);
entryToJSON(info, e);
o.push_back(Pair(_hash.ToString(), info));
}
return o;
}
}
UniValue getmempooldescendants(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() < 1 || request.params.size() > 2) {
throw std::runtime_error(
"getmempooldescendants txid (verbose)\n"
"\nIf txid is in the mempool, returns all in-mempool descendants.\n"
"\nArguments:\n"
"1. \"txid\" (string, required) The transaction id (must be in mempool)\n"
"2. verbose (boolean, optional, default=false) True for a json object, false for array of transaction ids\n"
"\nResult (for verbose=false):\n"
"[ (json array of strings)\n"
" \"transactionid\" (string) The transaction id of an in-mempool descendant transaction\n"
" ,...\n"
"]\n"
"\nResult (for verbose=true):\n"
"{ (json object)\n"
" \"transactionid\" : { (json object)\n"
+ EntryDescriptionString()
+ " }, ...\n"
"}\n"
"\nExamples:\n"
+ HelpExampleCli("getmempooldescendants", "\"mytxid\"")
+ HelpExampleRpc("getmempooldescendants", "\"mytxid\"")
);
}
bool fVerbose = false;
if (!request.params[1].isNull())
fVerbose = request.params[1].get_bool();
uint256 hash = ParseHashV(request.params[0], "parameter 1");
LOCK(mempool.cs);
CTxMemPool::txiter it = mempool.mapTx.find(hash);
if (it == mempool.mapTx.end()) {
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Transaction not in mempool");
}
CTxMemPool::setEntries setDescendants;
mempool.CalculateDescendants(it, setDescendants);
// CTxMemPool::CalculateDescendants will include the given tx
setDescendants.erase(it);
if (!fVerbose) {
UniValue o(UniValue::VARR);
for (CTxMemPool::txiter descendantIt : setDescendants) {
o.push_back(descendantIt->GetTx().GetHash().ToString());
}
return o;
} else {
UniValue o(UniValue::VOBJ);
for (CTxMemPool::txiter descendantIt : setDescendants) {
const CTxMemPoolEntry &e = *descendantIt;
const uint256& _hash = e.GetTx().GetHash();
UniValue info(UniValue::VOBJ);
entryToJSON(info, e);
o.push_back(Pair(_hash.ToString(), info));
}
return o;
}
}
UniValue getmempoolentry(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() != 1) {
throw std::runtime_error(
"getmempoolentry txid\n"
"\nReturns mempool data for given transaction\n"
"\nArguments:\n"
"1. \"txid\" (string, required) The transaction id (must be in mempool)\n"
"\nResult:\n"
"{ (json object)\n"
+ EntryDescriptionString()
+ "}\n"
"\nExamples:\n"
+ HelpExampleCli("getmempoolentry", "\"mytxid\"")
+ HelpExampleRpc("getmempoolentry", "\"mytxid\"")
);
}
uint256 hash = ParseHashV(request.params[0], "parameter 1");
LOCK(mempool.cs);
CTxMemPool::txiter it = mempool.mapTx.find(hash);
if (it == mempool.mapTx.end()) {
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Transaction not in mempool");
}
const CTxMemPoolEntry &e = *it;
UniValue info(UniValue::VOBJ);
entryToJSON(info, e);
return info;
}
UniValue getblockhash(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() != 1)
throw std::runtime_error(
"getblockhash height\n"
"\nReturns hash of block in best-block-chain at height provided.\n"
"\nArguments:\n"
"1. height (numeric, required) The height index\n"
"\nResult:\n"
"\"hash\" (string) The block hash\n"
"\nExamples:\n"
+ HelpExampleCli("getblockhash", "1000")
+ HelpExampleRpc("getblockhash", "1000")
);
LOCK(cs_main);
int nHeight = request.params[0].get_int();
if (nHeight < 0 || nHeight > chainActive.Height())
throw JSONRPCError(RPC_INVALID_PARAMETER, "Block height out of range");
CBlockIndex* pblockindex = chainActive[nHeight];
return pblockindex->GetBlockHash().GetHex();
}
UniValue getblockheader(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() < 1 || request.params.size() > 2)
throw std::runtime_error(
"getblockheader \"hash\" ( verbose )\n"
"\nIf verbose is false, returns a string that is serialized, hex-encoded data for blockheader 'hash'.\n"
"If verbose is true, returns an Object with information about blockheader <hash>.\n"
"\nArguments:\n"
"1. \"hash\" (string, required) The block hash\n"
"2. verbose (boolean, optional, default=true) true for a json object, false for the hex encoded data\n"
"\nResult (for verbose = true):\n"
"{\n"
" \"hash\" : \"hash\", (string) the block hash (same as provided)\n"
" \"confirmations\" : n, (numeric) The number of confirmations, or -1 if the block is not on the main chain\n"
" \"height\" : n, (numeric) The block height or index\n"
" \"version\" : n, (numeric) The block version\n"
" \"versionHex\" : \"00000000\", (string) The block version formatted in hexadecimal\n"
" \"merkleroot\" : \"xxxx\", (string) The merkle root\n"
" \"time\" : ttt, (numeric) The block time in seconds since epoch (Jan 1 1970 GMT)\n"
" \"mediantime\" : ttt, (numeric) The median block time in seconds since epoch (Jan 1 1970 GMT)\n"
" \"nonce\" : n, (numeric) The nonce\n"
" \"bits\" : \"1d00ffff\", (string) The bits\n"
" \"difficulty\" : x.xxx, (numeric) The difficulty\n"
" \"chainwork\" : \"0000...1f3\" (string) Expected number of hashes required to produce the current chain (in hex)\n"
" \"previousblockhash\" : \"hash\", (string) The hash of the previous block\n"
" \"nextblockhash\" : \"hash\", (string) The hash of the next block\n"
"}\n"
"\nResult (for verbose=false):\n"
"\"data\" (string) A string that is serialized, hex-encoded data for block 'hash'.\n"
"\nExamples:\n"
+ HelpExampleCli("getblockheader", "\"e2acdf2dd19a702e5d12a925f1e984b01e47a933562ca893656d4afb38b44ee3\"")
+ HelpExampleRpc("getblockheader", "\"e2acdf2dd19a702e5d12a925f1e984b01e47a933562ca893656d4afb38b44ee3\"")
);
LOCK(cs_main);
std::string strHash = request.params[0].get_str();
uint256 hash(uint256S(strHash));
bool fVerbose = true;
if (!request.params[1].isNull())
fVerbose = request.params[1].get_bool();
if (mapBlockIndex.count(hash) == 0)
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Block not found");
CBlockIndex* pblockindex = mapBlockIndex[hash];
if (!fVerbose)
{
CDataStream ssBlock(SER_NETWORK, PROTOCOL_VERSION);
ssBlock << pblockindex->GetBlockHeader();
std::string strHex = HexStr(ssBlock.begin(), ssBlock.end());
return strHex;
}
return blockheaderToJSON(pblockindex);
}
UniValue getblock(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() < 1 || request.params.size() > 2)
throw std::runtime_error(
"getblock \"blockhash\" ( verbosity ) \n"
"\nIf verbosity is 0, returns a string that is serialized, hex-encoded data for block 'hash'.\n"
"If verbosity is 1, returns an Object with information about block <hash>.\n"
"If verbosity is 2, returns an Object with information about block <hash> and information about each transaction. \n"
"\nArguments:\n"
"1. \"blockhash\" (string, required) The block hash\n"
"2. verbosity (numeric, optional, default=1) 0 for hex encoded data, 1 for a json object, and 2 for json object with transaction data\n"
"\nResult (for verbosity = 0):\n"
"\"data\" (string) A string that is serialized, hex-encoded data for block 'hash'.\n"
"\nResult (for verbosity = 1):\n"
"{\n"
" \"hash\" : \"hash\", (string) the block hash (same as provided)\n"
" \"confirmations\" : n, (numeric) The number of confirmations, or -1 if the block is not on the main chain\n"
" \"size\" : n, (numeric) The block size\n"
" \"strippedsize\" : n, (numeric) The block size excluding witness data\n"
" \"weight\" : n (numeric) The block weight as defined in BIP 141\n"
" \"height\" : n, (numeric) The block height or index\n"
" \"version\" : n, (numeric) The block version\n"
" \"versionHex\" : \"00000000\", (string) The block version formatted in hexadecimal\n"
" \"merkleroot\" : \"xxxx\", (string) The merkle root\n"
" \"tx\" : [ (array of string) The transaction ids\n"
" \"transactionid\" (string) The transaction id\n"
" ,...\n"
" ],\n"
" \"time\" : ttt, (numeric) The block time in seconds since epoch (Jan 1 1970 GMT)\n"
" \"mediantime\" : ttt, (numeric) The median block time in seconds since epoch (Jan 1 1970 GMT)\n"
" \"nonce\" : n, (numeric) The nonce\n"
" \"bits\" : \"1d00ffff\", (string) The bits\n"
" \"difficulty\" : x.xxx, (numeric) The difficulty\n"
" \"chainwork\" : \"xxxx\", (string) Expected number of hashes required to produce the chain up to this block (in hex)\n"
" \"previousblockhash\" : \"hash\", (string) The hash of the previous block\n"
" \"nextblockhash\" : \"hash\" (string) The hash of the next block\n"
"}\n"
"\nResult (for verbosity = 2):\n"
"{\n"
" ..., Same output as verbosity = 1.\n"
" \"tx\" : [ (array of Objects) The transactions in the format of the getrawtransaction RPC. Different from verbosity = 1 \"tx\" result.\n"
" ,...\n"
" ],\n"
" ,... Same output as verbosity = 1.\n"
"}\n"
"\nExamples:\n"
+ HelpExampleCli("getblock", "\"e2acdf2dd19a702e5d12a925f1e984b01e47a933562ca893656d4afb38b44ee3\"")
+ HelpExampleRpc("getblock", "\"e2acdf2dd19a702e5d12a925f1e984b01e47a933562ca893656d4afb38b44ee3\"")
);
LOCK(cs_main);
std::string strHash = request.params[0].get_str();
uint256 hash(uint256S(strHash));
int verbosity = 1;
if (!request.params[1].isNull()) {
if(request.params[1].isNum())
verbosity = request.params[1].get_int();
else
verbosity = request.params[1].get_bool() ? 1 : 0;
}
if (mapBlockIndex.count(hash) == 0)
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Block not found");
CBlock block;
CBlockIndex* pblockindex = mapBlockIndex[hash];
if (fHavePruned && !(pblockindex->nStatus & BLOCK_HAVE_DATA) && pblockindex->nTx > 0)
throw JSONRPCError(RPC_MISC_ERROR, "Block not available (pruned data)");
if (!ReadBlockFromDisk(block, pblockindex, Params().GetConsensus()))
// Block not found on disk. This could be because we have the block
// header in our index but don't have the block (for example if a
// non-whitelisted node sends us an unrequested long chain of valid
// blocks, we add the headers to our index, but don't accept the
// block).
throw JSONRPCError(RPC_MISC_ERROR, "Block not found on disk");
if (verbosity <= 0)
{
CDataStream ssBlock(SER_NETWORK, PROTOCOL_VERSION | RPCSerializationFlags());
ssBlock << block;
std::string strHex = HexStr(ssBlock.begin(), ssBlock.end());
return strHex;
}
return blockToJSON(block, pblockindex, verbosity >= 2);
}
struct CCoinsStats
{
int nHeight;
uint256 hashBlock;
uint64_t nTransactions;
uint64_t nTransactionOutputs;
uint64_t nBogoSize;
uint256 hashSerialized;
uint64_t nDiskSize;
CAmount nTotalAmount;
CCoinsStats() : nHeight(0), nTransactions(0), nTransactionOutputs(0), nBogoSize(0), nDiskSize(0), nTotalAmount(0) {}
};
static void ApplyStats(CCoinsStats &stats, CHashWriter& ss, const uint256& hash, const std::map<uint32_t, Coin>& outputs)
{
assert(!outputs.empty());
ss << hash;
ss << VARINT(outputs.begin()->second.nHeight * 2 + outputs.begin()->second.fCoinBase);
stats.nTransactions++;
for (const auto output : outputs) {
ss << VARINT(output.first + 1);
ss << output.second.out.scriptPubKey;
ss << VARINT(output.second.out.nValue);
stats.nTransactionOutputs++;
stats.nTotalAmount += output.second.out.nValue;
stats.nBogoSize += 32 /* txid */ + 4 /* vout index */ + 4 /* height + coinbase */ + 8 /* amount */ +
2 /* scriptPubKey len */ + output.second.out.scriptPubKey.size() /* scriptPubKey */;
}
ss << VARINT(0);
}
//! Calculate statistics about the unspent transaction output set
static bool GetUTXOStats(CCoinsView *view, CCoinsStats &stats)
{
std::unique_ptr<CCoinsViewCursor> pcursor(view->Cursor());
CHashWriter ss(SER_GETHASH, PROTOCOL_VERSION);
stats.hashBlock = pcursor->GetBestBlock();
{
LOCK(cs_main);
stats.nHeight = mapBlockIndex.find(stats.hashBlock)->second->nHeight;
}
ss << stats.hashBlock;
uint256 prevkey;
std::map<uint32_t, Coin> outputs;
while (pcursor->Valid()) {
boost::this_thread::interruption_point();
COutPoint key;
Coin coin;
if (pcursor->GetKey(key) && pcursor->GetValue(coin)) {
if (!outputs.empty() && key.hash != prevkey) {
ApplyStats(stats, ss, prevkey, outputs);
outputs.clear();
}
prevkey = key.hash;
outputs[key.n] = std::move(coin);
} else {
return error("%s: unable to read value", __func__);
}
pcursor->Next();
}
if (!outputs.empty()) {
ApplyStats(stats, ss, prevkey, outputs);
}
stats.hashSerialized = ss.GetHash();
stats.nDiskSize = view->EstimateSize();
return true;
}
UniValue pruneblockchain(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() != 1)
throw std::runtime_error(
"pruneblockchain\n"
"\nArguments:\n"
"1. \"height\" (numeric, required) The block height to prune up to. May be set to a discrete height, or a unix timestamp\n"
" to prune blocks whose block time is at least 2 hours older than the provided timestamp.\n"
"\nResult:\n"
"n (numeric) Height of the last block pruned.\n"
"\nExamples:\n"
+ HelpExampleCli("pruneblockchain", "1000")
+ HelpExampleRpc("pruneblockchain", "1000"));
if (!fPruneMode)
throw JSONRPCError(RPC_MISC_ERROR, "Cannot prune blocks because node is not in prune mode.");
LOCK(cs_main);
int heightParam = request.params[0].get_int();
if (heightParam < 0)
throw JSONRPCError(RPC_INVALID_PARAMETER, "Negative block height.");
// Height value more than a billion is too high to be a block height, and
// too low to be a block time (corresponds to timestamp from Sep 2001).
if (heightParam > 1000000000) {
// Add a 2 hour buffer to include blocks which might have had old timestamps
CBlockIndex* pindex = chainActive.FindEarliestAtLeast(heightParam - TIMESTAMP_WINDOW);
if (!pindex) {
throw JSONRPCError(RPC_INVALID_PARAMETER, "Could not find block with at least the specified timestamp.");
}
heightParam = pindex->nHeight;
}
unsigned int height = (unsigned int) heightParam;
unsigned int chainHeight = (unsigned int) chainActive.Height();
if (chainHeight < Params().PruneAfterHeight())
throw JSONRPCError(RPC_MISC_ERROR, "Blockchain is too short for pruning.");
else if (height > chainHeight)
throw JSONRPCError(RPC_INVALID_PARAMETER, "Blockchain is shorter than the attempted prune height.");
else if (height > chainHeight - MIN_BLOCKS_TO_KEEP) {
LogPrint(BCLog::RPC, "Attempt to prune blocks close to the tip. Retaining the minimum number of blocks.");
height = chainHeight - MIN_BLOCKS_TO_KEEP;
}
PruneBlockFilesManual(height);
return uint64_t(height);
}
UniValue gettxoutsetinfo(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() != 0)
throw std::runtime_error(
"gettxoutsetinfo\n"
"\nReturns statistics about the unspent transaction output set.\n"
"Note this call may take some time.\n"
"\nResult:\n"
"{\n"
" \"height\":n, (numeric) The current block height (index)\n"
" \"bestblock\": \"hex\", (string) the best block hash hex\n"
" \"transactions\": n, (numeric) The number of transactions\n"
" \"txouts\": n, (numeric) The number of output transactions\n"
" \"bogosize\": n, (numeric) A meaningless metric for UTXO set size\n"
" \"hash_serialized_2\": \"hash\", (string) The serialized hash\n"
" \"disk_size\": n, (numeric) The estimated size of the chainstate on disk\n"
" \"total_amount\": x.xxx (numeric) The total amount\n"
"}\n"
"\nExamples:\n"
+ HelpExampleCli("gettxoutsetinfo", "")
+ HelpExampleRpc("gettxoutsetinfo", "")
);
UniValue ret(UniValue::VOBJ);
CCoinsStats stats;
FlushStateToDisk();
if (GetUTXOStats(pcoinsdbview, stats)) {
ret.push_back(Pair("height", (int64_t)stats.nHeight));
ret.push_back(Pair("bestblock", stats.hashBlock.GetHex()));
ret.push_back(Pair("transactions", (int64_t)stats.nTransactions));
ret.push_back(Pair("txouts", (int64_t)stats.nTransactionOutputs));
ret.push_back(Pair("bogosize", (int64_t)stats.nBogoSize));
ret.push_back(Pair("hash_serialized_2", stats.hashSerialized.GetHex()));
ret.push_back(Pair("disk_size", stats.nDiskSize));
ret.push_back(Pair("total_amount", ValueFromAmount(stats.nTotalAmount)));
} else {
throw JSONRPCError(RPC_INTERNAL_ERROR, "Unable to read UTXO set");
}
return ret;
}
UniValue gettxout(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() < 2 || request.params.size() > 3)
throw std::runtime_error(
"gettxout \"txid\" n ( include_mempool )\n"
"\nReturns details about an unspent transaction output.\n"
"\nArguments:\n"
"1. \"txid\" (string, required) The transaction id\n"
"2. \"n\" (numeric, required) vout number\n"
"3. \"include_mempool\" (boolean, optional) Whether to include the mempool. Default: true."
" Note that an unspent output that is spent in the mempool won't appear.\n"
"\nResult:\n"
"{\n"
" \"bestblock\" : \"hash\", (string) the block hash\n"
" \"confirmations\" : n, (numeric) The number of confirmations\n"
" \"value\" : x.xxx, (numeric) The transaction value in " + CURRENCY_UNIT + "\n"
" \"scriptPubKey\" : { (json object)\n"
" \"asm\" : \"code\", (string) \n"
" \"hex\" : \"hex\", (string) \n"
" \"reqSigs\" : n, (numeric) Number of required signatures\n"
" \"type\" : \"pubkeyhash\", (string) The type, eg pubkeyhash\n"
" \"addresses\" : [ (array of string) array of maniacoin addresses\n"
" \"address\" (string) maniacoin address\n"
" ,...\n"
" ]\n"
" },\n"
" \"coinbase\" : true|false (boolean) Coinbase or not\n"
"}\n"
"\nExamples:\n"
"\nGet unspent transactions\n"
+ HelpExampleCli("listunspent", "") +
"\nView the details\n"
+ HelpExampleCli("gettxout", "\"txid\" 1") +
"\nAs a json rpc call\n"
+ HelpExampleRpc("gettxout", "\"txid\", 1")
);
LOCK(cs_main);
UniValue ret(UniValue::VOBJ);
std::string strHash = request.params[0].get_str();
uint256 hash(uint256S(strHash));
int n = request.params[1].get_int();
COutPoint out(hash, n);
bool fMempool = true;
if (!request.params[2].isNull())
fMempool = request.params[2].get_bool();
Coin coin;
if (fMempool) {
LOCK(mempool.cs);
CCoinsViewMemPool view(pcoinsTip, mempool);
if (!view.GetCoin(out, coin) || mempool.isSpent(out)) {
return NullUniValue;
}
} else {
if (!pcoinsTip->GetCoin(out, coin)) {
return NullUniValue;
}
}
BlockMap::iterator it = mapBlockIndex.find(pcoinsTip->GetBestBlock());
CBlockIndex *pindex = it->second;
ret.push_back(Pair("bestblock", pindex->GetBlockHash().GetHex()));
if (coin.nHeight == MEMPOOL_HEIGHT) {
ret.push_back(Pair("confirmations", 0));
} else {
ret.push_back(Pair("confirmations", (int64_t)(pindex->nHeight - coin.nHeight + 1)));
}
ret.push_back(Pair("value", ValueFromAmount(coin.out.nValue)));
UniValue o(UniValue::VOBJ);
ScriptPubKeyToUniv(coin.out.scriptPubKey, o, true);
ret.push_back(Pair("scriptPubKey", o));
ret.push_back(Pair("coinbase", (bool)coin.fCoinBase));
return ret;
}
UniValue verifychain(const JSONRPCRequest& request)
{
int nCheckLevel = gArgs.GetArg("-checklevel", DEFAULT_CHECKLEVEL);
int nCheckDepth = gArgs.GetArg("-checkblocks", DEFAULT_CHECKBLOCKS);
if (request.fHelp || request.params.size() > 2)
throw std::runtime_error(
"verifychain ( checklevel nblocks )\n"
"\nVerifies blockchain database.\n"
"\nArguments:\n"
"1. checklevel (numeric, optional, 0-4, default=" + strprintf("%d", nCheckLevel) + ") How thorough the block verification is.\n"
"2. nblocks (numeric, optional, default=" + strprintf("%d", nCheckDepth) + ", 0=all) The number of blocks to check.\n"
"\nResult:\n"
"true|false (boolean) Verified or not\n"
"\nExamples:\n"
+ HelpExampleCli("verifychain", "")
+ HelpExampleRpc("verifychain", "")
);
LOCK(cs_main);
if (!request.params[0].isNull())
nCheckLevel = request.params[0].get_int();
if (!request.params[1].isNull())
nCheckDepth = request.params[1].get_int();
return CVerifyDB().VerifyDB(Params(), pcoinsTip, nCheckLevel, nCheckDepth);
}
/** Implementation of IsSuperMajority with better feedback */
static UniValue SoftForkMajorityDesc(int version, CBlockIndex* pindex, const Consensus::Params& consensusParams)
{
UniValue rv(UniValue::VOBJ);
bool activated = false;
switch(version)
{
case 2:
activated = pindex->nHeight >= consensusParams.BIP34Height;
break;
case 3:
activated = pindex->nHeight >= consensusParams.BIP66Height;
break;
case 4:
activated = pindex->nHeight >= consensusParams.BIP65Height;
break;
}
rv.push_back(Pair("status", activated));
return rv;
}
static UniValue SoftForkDesc(const std::string &name, int version, CBlockIndex* pindex, const Consensus::Params& consensusParams)
{
UniValue rv(UniValue::VOBJ);
rv.push_back(Pair("id", name));
rv.push_back(Pair("version", version));
rv.push_back(Pair("reject", SoftForkMajorityDesc(version, pindex, consensusParams)));
return rv;
}
static UniValue BIP9SoftForkDesc(const Consensus::Params& consensusParams, Consensus::DeploymentPos id)
{
UniValue rv(UniValue::VOBJ);
const ThresholdState thresholdState = VersionBitsTipState(consensusParams, id);
switch (thresholdState) {
case THRESHOLD_DEFINED: rv.push_back(Pair("status", "defined")); break;
case THRESHOLD_STARTED: rv.push_back(Pair("status", "started")); break;
case THRESHOLD_LOCKED_IN: rv.push_back(Pair("status", "locked_in")); break;
case THRESHOLD_ACTIVE: rv.push_back(Pair("status", "active")); break;
case THRESHOLD_FAILED: rv.push_back(Pair("status", "failed")); break;
}
if (THRESHOLD_STARTED == thresholdState)
{
rv.push_back(Pair("bit", consensusParams.vDeployments[id].bit));
}
rv.push_back(Pair("startTime", consensusParams.vDeployments[id].nStartTime));
rv.push_back(Pair("timeout", consensusParams.vDeployments[id].nTimeout));
rv.push_back(Pair("since", VersionBitsTipStateSinceHeight(consensusParams, id)));
if (THRESHOLD_STARTED == thresholdState)
{
UniValue statsUV(UniValue::VOBJ);
BIP9Stats statsStruct = VersionBitsTipStatistics(consensusParams, id);
statsUV.push_back(Pair("period", statsStruct.period));
statsUV.push_back(Pair("threshold", statsStruct.threshold));
statsUV.push_back(Pair("elapsed", statsStruct.elapsed));
statsUV.push_back(Pair("count", statsStruct.count));
statsUV.push_back(Pair("possible", statsStruct.possible));
rv.push_back(Pair("statistics", statsUV));
}
return rv;
}
void BIP9SoftForkDescPushBack(UniValue& bip9_softforks, const std::string &name, const Consensus::Params& consensusParams, Consensus::DeploymentPos id)
{
// Deployments with timeout value of 0 are hidden.
// A timeout value of 0 guarantees a softfork will never be activated.
// This is used when softfork codes are merged without specifying the deployment schedule.
if (consensusParams.vDeployments[id].nTimeout > 0)
bip9_softforks.push_back(Pair(name, BIP9SoftForkDesc(consensusParams, id)));
}
UniValue getblockchaininfo(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() != 0)
throw std::runtime_error(
"getblockchaininfo\n"
"Returns an object containing various state info regarding blockchain processing.\n"
"\nResult:\n"
"{\n"
" \"chain\": \"xxxx\", (string) current network name as defined in BIP70 (main, test, regtest)\n"
" \"blocks\": xxxxxx, (numeric) the current number of blocks processed in the server\n"
" \"headers\": xxxxxx, (numeric) the current number of headers we have validated\n"
" \"bestblockhash\": \"...\", (string) the hash of the currently best block\n"
" \"difficulty\": xxxxxx, (numeric) the current difficulty\n"
" \"mediantime\": xxxxxx, (numeric) median time for the current best block\n"
" \"verificationprogress\": xxxx, (numeric) estimate of verification progress [0..1]\n"
" \"chainwork\": \"xxxx\" (string) total amount of work in active chain, in hexadecimal\n"
" \"pruned\": xx, (boolean) if the blocks are subject to pruning\n"
" \"pruneheight\": xxxxxx, (numeric) lowest-height complete block stored\n"
" \"softforks\": [ (array) status of softforks in progress\n"
" {\n"
" \"id\": \"xxxx\", (string) name of softfork\n"
" \"version\": xx, (numeric) block version\n"
" \"reject\": { (object) progress toward rejecting pre-softfork blocks\n"
" \"status\": xx, (boolean) true if threshold reached\n"
" },\n"
" }, ...\n"
" ],\n"
" \"bip9_softforks\": { (object) status of BIP9 softforks in progress\n"
" \"xxxx\" : { (string) name of the softfork\n"
" \"status\": \"xxxx\", (string) one of \"defined\", \"started\", \"locked_in\", \"active\", \"failed\"\n"
" \"bit\": xx, (numeric) the bit (0-28) in the block version field used to signal this softfork (only for \"started\" status)\n"
" \"startTime\": xx, (numeric) the minimum median time past of a block at which the bit gains its meaning\n"
" \"timeout\": xx, (numeric) the median time past of a block at which the deployment is considered failed if not yet locked in\n"
" \"since\": xx, (numeric) height of the first block to which the status applies\n"
" \"statistics\": { (object) numeric statistics about BIP9 signalling for a softfork (only for \"started\" status)\n"
" \"period\": xx, (numeric) the length in blocks of the BIP9 signalling period \n"
" \"threshold\": xx, (numeric) the number of blocks with the version bit set required to activate the feature \n"
" \"elapsed\": xx, (numeric) the number of blocks elapsed since the beginning of the current period \n"
" \"count\": xx, (numeric) the number of blocks with the version bit set in the current period \n"
" \"possible\": xx (boolean) returns false if there are not enough blocks left in this period to pass activation threshold \n"
" }\n"
" }\n"
" }\n"
"}\n"
"\nExamples:\n"
+ HelpExampleCli("getblockchaininfo", "")
+ HelpExampleRpc("getblockchaininfo", "")
);
LOCK(cs_main);
UniValue obj(UniValue::VOBJ);
obj.push_back(Pair("chain", Params().NetworkIDString()));
obj.push_back(Pair("blocks", (int)chainActive.Height()));
obj.push_back(Pair("headers", pindexBestHeader ? pindexBestHeader->nHeight : -1));
obj.push_back(Pair("bestblockhash", chainActive.Tip()->GetBlockHash().GetHex()));
obj.push_back(Pair("difficulty", (double)GetDifficulty()));
obj.push_back(Pair("mediantime", (int64_t)chainActive.Tip()->GetMedianTimePast()));
obj.push_back(Pair("verificationprogress", GuessVerificationProgress(Params().TxData(), chainActive.Tip())));
obj.push_back(Pair("chainwork", chainActive.Tip()->nChainWork.GetHex()));
obj.push_back(Pair("pruned", fPruneMode));
const Consensus::Params& consensusParams = Params().GetConsensus();
CBlockIndex* tip = chainActive.Tip();
UniValue softforks(UniValue::VARR);
UniValue bip9_softforks(UniValue::VOBJ);
softforks.push_back(SoftForkDesc("bip34", 2, tip, consensusParams));
softforks.push_back(SoftForkDesc("bip66", 3, tip, consensusParams));
softforks.push_back(SoftForkDesc("bip65", 4, tip, consensusParams));
BIP9SoftForkDescPushBack(bip9_softforks, "csv", consensusParams, Consensus::DEPLOYMENT_CSV);
BIP9SoftForkDescPushBack(bip9_softforks, "segwit", consensusParams, Consensus::DEPLOYMENT_SEGWIT);
obj.push_back(Pair("softforks", softforks));
obj.push_back(Pair("bip9_softforks", bip9_softforks));
if (fPruneMode)
{
CBlockIndex *block = chainActive.Tip();
while (block && block->pprev && (block->pprev->nStatus & BLOCK_HAVE_DATA))
block = block->pprev;
obj.push_back(Pair("pruneheight", block->nHeight));
}
return obj;
}
/** Comparison function for sorting the getchaintips heads. */
struct CompareBlocksByHeight
{
bool operator()(const CBlockIndex* a, const CBlockIndex* b) const
{
/* Make sure that unequal blocks with the same height do not compare
equal. Use the pointers themselves to make a distinction. */
if (a->nHeight != b->nHeight)
return (a->nHeight > b->nHeight);
return a < b;
}
};
UniValue getchaintips(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() != 0)
throw std::runtime_error(
"getchaintips\n"
"Return information about all known tips in the block tree,"
" including the main chain as well as orphaned branches.\n"
"\nResult:\n"
"[\n"
" {\n"
" \"height\": xxxx, (numeric) height of the chain tip\n"
" \"hash\": \"xxxx\", (string) block hash of the tip\n"
" \"branchlen\": 0 (numeric) zero for main chain\n"
" \"status\": \"active\" (string) \"active\" for the main chain\n"
" },\n"
" {\n"
" \"height\": xxxx,\n"
" \"hash\": \"xxxx\",\n"
" \"branchlen\": 1 (numeric) length of branch connecting the tip to the main chain\n"
" \"status\": \"xxxx\" (string) status of the chain (active, valid-fork, valid-headers, headers-only, invalid)\n"
" }\n"
"]\n"
"Possible values for status:\n"
"1. \"invalid\" This branch contains at least one invalid block\n"
"2. \"headers-only\" Not all blocks for this branch are available, but the headers are valid\n"
"3. \"valid-headers\" All blocks are available for this branch, but they were never fully validated\n"
"4. \"valid-fork\" This branch is not part of the active chain, but is fully validated\n"
"5. \"active\" This is the tip of the active main chain, which is certainly valid\n"
"\nExamples:\n"
+ HelpExampleCli("getchaintips", "")
+ HelpExampleRpc("getchaintips", "")
);
LOCK(cs_main);
/*
* Idea: the set of chain tips is chainActive.tip, plus orphan blocks which do not have another orphan building off of them.
* Algorithm:
* - Make one pass through mapBlockIndex, picking out the orphan blocks, and also storing a set of the orphan block's pprev pointers.
* - Iterate through the orphan blocks. If the block isn't pointed to by another orphan, it is a chain tip.
* - add chainActive.Tip()
*/
std::set<const CBlockIndex*, CompareBlocksByHeight> setTips;
std::set<const CBlockIndex*> setOrphans;
std::set<const CBlockIndex*> setPrevs;
for (const std::pair<const uint256, CBlockIndex*>& item : mapBlockIndex)
{
if (!chainActive.Contains(item.second)) {
setOrphans.insert(item.second);
setPrevs.insert(item.second->pprev);
}
}
for (std::set<const CBlockIndex*>::iterator it = setOrphans.begin(); it != setOrphans.end(); ++it)
{
if (setPrevs.erase(*it) == 0) {
setTips.insert(*it);
}
}
// Always report the currently active tip.
setTips.insert(chainActive.Tip());
/* Construct the output array. */
UniValue res(UniValue::VARR);
for (const CBlockIndex* block : setTips)
{
UniValue obj(UniValue::VOBJ);
obj.push_back(Pair("height", block->nHeight));
obj.push_back(Pair("hash", block->phashBlock->GetHex()));
const int branchLen = block->nHeight - chainActive.FindFork(block)->nHeight;
obj.push_back(Pair("branchlen", branchLen));
std::string status;
if (chainActive.Contains(block)) {
// This block is part of the currently active chain.
status = "active";
} else if (block->nStatus & BLOCK_FAILED_MASK) {
// This block or one of its ancestors is invalid.
status = "invalid";
} else if (block->nChainTx == 0) {
// This block cannot be connected because full block data for it or one of its parents is missing.
status = "headers-only";
} else if (block->IsValid(BLOCK_VALID_SCRIPTS)) {
// This block is fully validated, but no longer part of the active chain. It was probably the active block once, but was reorganized.
status = "valid-fork";
} else if (block->IsValid(BLOCK_VALID_TREE)) {
// The headers for this block are valid, but it has not been validated. It was probably never part of the most-work chain.
status = "valid-headers";
} else {
// No clue.
status = "unknown";
}
obj.push_back(Pair("status", status));
res.push_back(obj);
}
return res;
}
UniValue mempoolInfoToJSON()
{
UniValue ret(UniValue::VOBJ);
ret.push_back(Pair("size", (int64_t) mempool.size()));
ret.push_back(Pair("bytes", (int64_t) mempool.GetTotalTxSize()));
ret.push_back(Pair("usage", (int64_t) mempool.DynamicMemoryUsage()));
size_t maxmempool = gArgs.GetArg("-maxmempool", DEFAULT_MAX_MEMPOOL_SIZE) * 1000000;
ret.push_back(Pair("maxmempool", (int64_t) maxmempool));
ret.push_back(Pair("mempoolminfee", ValueFromAmount(mempool.GetMinFee(maxmempool).GetFeePerK())));
return ret;
}
UniValue getmempoolinfo(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() != 0)
throw std::runtime_error(
"getmempoolinfo\n"
"\nReturns details on the active state of the TX memory pool.\n"
"\nResult:\n"
"{\n"
" \"size\": xxxxx, (numeric) Current tx count\n"
" \"bytes\": xxxxx, (numeric) Sum of all virtual transaction sizes as defined in BIP 141. Differs from actual serialized size because witness data is discounted\n"
" \"usage\": xxxxx, (numeric) Total memory usage for the mempool\n"
" \"maxmempool\": xxxxx, (numeric) Maximum memory usage for the mempool\n"
" \"mempoolminfee\": xxxxx (numeric) Minimum feerate (" + CURRENCY_UNIT + " per KB) for tx to be accepted\n"
"}\n"
"\nExamples:\n"
+ HelpExampleCli("getmempoolinfo", "")
+ HelpExampleRpc("getmempoolinfo", "")
);
return mempoolInfoToJSON();
}
UniValue preciousblock(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() != 1)
throw std::runtime_error(
"preciousblock \"blockhash\"\n"
"\nTreats a block as if it were received before others with the same work.\n"
"\nA later preciousblock call can override the effect of an earlier one.\n"
"\nThe effects of preciousblock are not retained across restarts.\n"
"\nArguments:\n"
"1. \"blockhash\" (string, required) the hash of the block to mark as precious\n"
"\nResult:\n"
"\nExamples:\n"
+ HelpExampleCli("preciousblock", "\"blockhash\"")
+ HelpExampleRpc("preciousblock", "\"blockhash\"")
);
std::string strHash = request.params[0].get_str();
uint256 hash(uint256S(strHash));
CBlockIndex* pblockindex;
{
LOCK(cs_main);
if (mapBlockIndex.count(hash) == 0)
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Block not found");
pblockindex = mapBlockIndex[hash];
}
CValidationState state;
PreciousBlock(state, Params(), pblockindex);
if (!state.IsValid()) {
throw JSONRPCError(RPC_DATABASE_ERROR, state.GetRejectReason());
}
return NullUniValue;
}
UniValue invalidateblock(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() != 1)
throw std::runtime_error(
"invalidateblock \"blockhash\"\n"
"\nPermanently marks a block as invalid, as if it violated a consensus rule.\n"
"\nArguments:\n"
"1. \"blockhash\" (string, required) the hash of the block to mark as invalid\n"
"\nResult:\n"
"\nExamples:\n"
+ HelpExampleCli("invalidateblock", "\"blockhash\"")
+ HelpExampleRpc("invalidateblock", "\"blockhash\"")
);
std::string strHash = request.params[0].get_str();
uint256 hash(uint256S(strHash));
CValidationState state;
{
LOCK(cs_main);
if (mapBlockIndex.count(hash) == 0)
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Block not found");
CBlockIndex* pblockindex = mapBlockIndex[hash];
InvalidateBlock(state, Params(), pblockindex);
}
if (state.IsValid()) {
ActivateBestChain(state, Params());
}
if (!state.IsValid()) {
throw JSONRPCError(RPC_DATABASE_ERROR, state.GetRejectReason());
}
return NullUniValue;
}
UniValue reconsiderblock(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() != 1)
throw std::runtime_error(
"reconsiderblock \"blockhash\"\n"
"\nRemoves invalidity status of a block and its descendants, reconsider them for activation.\n"
"This can be used to undo the effects of invalidateblock.\n"
"\nArguments:\n"
"1. \"blockhash\" (string, required) the hash of the block to reconsider\n"
"\nResult:\n"
"\nExamples:\n"
+ HelpExampleCli("reconsiderblock", "\"blockhash\"")
+ HelpExampleRpc("reconsiderblock", "\"blockhash\"")
);
std::string strHash = request.params[0].get_str();
uint256 hash(uint256S(strHash));
{
LOCK(cs_main);
if (mapBlockIndex.count(hash) == 0)
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Block not found");
CBlockIndex* pblockindex = mapBlockIndex[hash];
ResetBlockFailureFlags(pblockindex);
}
CValidationState state;
ActivateBestChain(state, Params());
if (!state.IsValid()) {
throw JSONRPCError(RPC_DATABASE_ERROR, state.GetRejectReason());
}
return NullUniValue;
}
UniValue getchaintxstats(const JSONRPCRequest& request)
{
if (request.fHelp || request.params.size() > 2)
throw std::runtime_error(
"getchaintxstats ( nblocks blockhash )\n"
"\nCompute statistics about the total number and rate of transactions in the chain.\n"
"\nArguments:\n"
"1. nblocks (numeric, optional) Size of the window in number of blocks (default: one month).\n"
"2. \"blockhash\" (string, optional) The hash of the block that ends the window.\n"
"\nResult:\n"
"{\n"
" \"time\": xxxxx, (numeric) The timestamp for the statistics in UNIX format.\n"
" \"txcount\": xxxxx, (numeric) The total number of transactions in the chain up to that point.\n"
" \"txrate\": x.xx, (numeric) The average rate of transactions per second in the window.\n"
"}\n"
"\nExamples:\n"
+ HelpExampleCli("getchaintxstats", "")
+ HelpExampleRpc("getchaintxstats", "2016")
);
const CBlockIndex* pindex;
int blockcount = 30 * 24 * 60 * 60 / Params().GetConsensus().nPowTargetSpacing; // By default: 1 month
if (request.params.size() > 0 && !request.params[0].isNull()) {
blockcount = request.params[0].get_int();
}
bool havehash = request.params.size() > 1 && !request.params[1].isNull();
uint256 hash;
if (havehash) {
hash = uint256S(request.params[1].get_str());
}
{
LOCK(cs_main);
if (havehash) {
auto it = mapBlockIndex.find(hash);
if (it == mapBlockIndex.end()) {
throw JSONRPCError(RPC_INVALID_ADDRESS_OR_KEY, "Block not found");
}
pindex = it->second;
if (!chainActive.Contains(pindex)) {
throw JSONRPCError(RPC_INVALID_PARAMETER, "Block is not in main chain");
}
} else {
pindex = chainActive.Tip();
}
}
if (blockcount < 1 || blockcount >= pindex->nHeight) {
throw JSONRPCError(RPC_INVALID_PARAMETER, "Invalid block count: should be between 1 and the block's height");
}
const CBlockIndex* pindexPast = pindex->GetAncestor(pindex->nHeight - blockcount);
int nTimeDiff = pindex->GetMedianTimePast() - pindexPast->GetMedianTimePast();
int nTxDiff = pindex->nChainTx - pindexPast->nChainTx;
UniValue ret(UniValue::VOBJ);
ret.push_back(Pair("time", (int64_t)pindex->nTime));
ret.push_back(Pair("txcount", (int64_t)pindex->nChainTx));
ret.push_back(Pair("txrate", ((double)nTxDiff) / nTimeDiff));
return ret;
}
static const CRPCCommand commands[] =
{ // category name actor (function) okSafe argNames
// --------------------- ------------------------ ----------------------- ------ ----------
{ "blockchain", "getblockchaininfo", &getblockchaininfo, true, {} },
{ "blockchain", "getchaintxstats", &getchaintxstats, true, {"nblocks", "blockhash"} },
{ "blockchain", "getbestblockhash", &getbestblockhash, true, {} },
{ "blockchain", "getblockcount", &getblockcount, true, {} },
{ "blockchain", "getblock", &getblock, true, {"blockhash","verbosity|verbose"} },
{ "blockchain", "getblockhash", &getblockhash, true, {"height"} },
{ "blockchain", "getblockheader", &getblockheader, true, {"blockhash","verbose"} },
{ "blockchain", "getchaintips", &getchaintips, true, {} },
{ "blockchain", "getdifficulty", &getdifficulty, true, {} },
{ "blockchain", "getmempoolancestors", &getmempoolancestors, true, {"txid","verbose"} },
{ "blockchain", "getmempooldescendants", &getmempooldescendants, true, {"txid","verbose"} },
{ "blockchain", "getmempoolentry", &getmempoolentry, true, {"txid"} },
{ "blockchain", "getmempoolinfo", &getmempoolinfo, true, {} },
{ "blockchain", "getrawmempool", &getrawmempool, true, {"verbose"} },
{ "blockchain", "gettxout", &gettxout, true, {"txid","n","include_mempool"} },
{ "blockchain", "gettxoutsetinfo", &gettxoutsetinfo, true, {} },
{ "blockchain", "pruneblockchain", &pruneblockchain, true, {"height"} },
{ "blockchain", "verifychain", &verifychain, true, {"checklevel","nblocks"} },
{ "blockchain", "preciousblock", &preciousblock, true, {"blockhash"} },
/* Not shown in help */
{ "hidden", "invalidateblock", &invalidateblock, true, {"blockhash"} },
{ "hidden", "reconsiderblock", &reconsiderblock, true, {"blockhash"} },
{ "hidden", "waitfornewblock", &waitfornewblock, true, {"timeout"} },
{ "hidden", "waitforblock", &waitforblock, true, {"blockhash","timeout"} },
{ "hidden", "waitforblockheight", &waitforblockheight, true, {"height","timeout"} },
};
void RegisterBlockchainRPCCommands(CRPCTable &t)
{
for (unsigned int vcidx = 0; vcidx < ARRAYLEN(commands); vcidx++)
t.appendCommand(commands[vcidx].name, &commands[vcidx]);
}
| [
"support@maniacraft.net"
] | support@maniacraft.net |
450892e7c366246b82e26c1a57515ef8c56c1b78 | aaa31215193aeae549a553c58f278891e9b67e1c | /source/CompilerGlsl/GlslExprConfigFiller.hpp | 3dcde36eec9b20ba29a9a2e7cd5c51cc9a1df5f2 | [
"MIT"
] | permissive | lethep/ShaderWriter | b14d5308bf9ab64e24afeceaf6a9d79b91223a5a | 4cbf830435e33a70bf8dc77386f00a3c910be274 | refs/heads/master | 2023-03-10T06:09:58.842691 | 2021-02-18T19:37:07 | 2021-02-18T19:37:07 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,653 | hpp | /*
See LICENSE file in root folder
*/
#ifndef ___SDW_GlslExprConfigFiller_H___
#define ___SDW_GlslExprConfigFiller_H___
#pragma once
#include "GlslHelpers.hpp"
#include <ShaderAST/Expr/ExprVisitor.hpp>
namespace glsl
{
class ExprConfigFiller
: public ast::expr::SimpleVisitor
{
public:
static void submit( ast::expr::Expr * expr
, IntrinsicsConfig & config );
static void submit( ast::expr::ExprPtr const & expr
, IntrinsicsConfig & config );
private:
ExprConfigFiller( IntrinsicsConfig & config );
void visitUnaryExpr( ast::expr::Unary * expr )override;
void visitBinaryExpr( ast::expr::Binary * expr )override;
void visitAggrInitExpr( ast::expr::AggrInit * expr )override;
void visitCompositeConstructExpr( ast::expr::CompositeConstruct * expr )override;
void visitMbrSelectExpr( ast::expr::MbrSelect * expr )override;
void visitFnCallExpr( ast::expr::FnCall * expr )override;
void visitIntrinsicCallExpr( ast::expr::IntrinsicCall * expr )override;
void visitTextureAccessCallExpr( ast::expr::TextureAccessCall * expr )override;
void visitImageAccessCallExpr( ast::expr::ImageAccessCall * expr )override;
void visitIdentifierExpr( ast::expr::Identifier * expr )override;
void visitInitExpr( ast::expr::Init * expr )override;
void visitLiteralExpr( ast::expr::Literal * expr )override;
void visitQuestionExpr( ast::expr::Question * expr )override;
void visitSwitchCaseExpr( ast::expr::SwitchCase * expr )override;
void visitSwitchTestExpr( ast::expr::SwitchTest * expr )override;
void visitSwizzleExpr( ast::expr::Swizzle * expr )override;
private:
IntrinsicsConfig & m_config;
};
}
#endif
| [
"dragonjoker59@hotmail.com"
] | dragonjoker59@hotmail.com |
6e4db4db9ed7a6d11a6a78c20538e226ca22af35 | 9b553bbfc8b0807d7f860964d6044d6ccf6d1342 | /rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2.cpp | e98217a9ef441491e249f7cef91f778e5df53fa6 | [] | no_license | DedoGamingONE/tp | 5e2e668f7120b154cf6ef6b002c2b4b51ae07ee5 | 5020395dfd34d4dc846e3ea228f6271bfca1c72a | refs/heads/master | 2023-09-03T06:55:25.773029 | 2021-10-24T21:35:00 | 2021-10-24T21:35:00 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 20,273 | cpp | //
// Generated By: dol2asm
// Translation Unit: d_a_obj_tornado2
//
#include "rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2.h"
#include "dol2asm.h"
#include "dolphin/types.h"
//
// Types:
//
struct csXyz {};
struct cXyz {
/* 80266EF4 */ void normalize();
/* 802670AC */ void isZero() const;
static f32 Zero[3];
};
struct mDoMtx_stack_c {
/* 8000CD64 */ void transS(cXyz const&);
/* 8000CF44 */ void ZXYrotM(csXyz const&);
static u8 now[48];
};
struct fopAc_ac_c {
/* 80018B64 */ fopAc_ac_c();
};
struct daObjTrnd2_c {
/* 80D1C4D8 */ void setPntWind();
/* 80D1C54C */ void cutPntWind();
/* 80D1C570 */ void movePntWind();
/* 80D1C780 */ void setCpsInfo();
/* 80D1C924 */ void initBaseMtx();
/* 80D1C944 */ void setBaseMtx();
/* 80D1C98C */ void Create();
/* 80D1CC80 */ void create();
/* 80D1CDC0 */ void execute();
/* 80D1D0AC */ void setParticle();
/* 80D1D214 */ void endParticle();
/* 80D1D278 */ void startParticle();
/* 80D1D2AC */ void stopParticle();
/* 80D1D2E0 */ bool draw();
/* 80D1D2E8 */ void _delete();
};
struct dSv_info_c {
/* 80035360 */ void isSwitch(int, int) const;
};
struct dPa_levelEcallBack {};
struct dKy_tevstr_c {};
struct _GXColor {};
struct dPa_control_c {
/* 8004CA90 */ void set(u8, u16, cXyz const*, dKy_tevstr_c const*, csXyz const*, cXyz const*,
u8, dPa_levelEcallBack*, s8, _GXColor const*, _GXColor const*,
cXyz const*, f32);
};
struct dCcD_Stts {
/* 80083860 */ void Init(int, int, fopAc_ac_c*);
};
struct dCcD_SrcCps {};
struct dCcD_GStts {
/* 80083760 */ dCcD_GStts();
};
struct dCcD_GObjInf {
/* 80083A28 */ dCcD_GObjInf();
};
struct dCcD_Cps {
/* 800847D0 */ void Set(dCcD_SrcCps const&);
};
struct cM3dGCpsS {};
struct cM3dGCps {
/* 8026EF88 */ cM3dGCps();
/* 8026F03C */ void Set(cM3dGCpsS const&);
};
struct cM3dGAab {
/* 80D1CD78 */ ~cM3dGAab();
};
struct cCcD_Obj {};
struct cCcS {
/* 80264BA8 */ void Set(cCcD_Obj*);
};
struct WIND_INFLUENCE {};
//
// Forward References:
//
extern "C" void setPntWind__12daObjTrnd2_cFv();
extern "C" void cutPntWind__12daObjTrnd2_cFv();
extern "C" void movePntWind__12daObjTrnd2_cFv();
extern "C" void setCpsInfo__12daObjTrnd2_cFv();
extern "C" void initBaseMtx__12daObjTrnd2_cFv();
extern "C" void setBaseMtx__12daObjTrnd2_cFv();
extern "C" void Create__12daObjTrnd2_cFv();
extern "C" void create__12daObjTrnd2_cFv();
extern "C" void __dt__8cM3dGAabFv();
extern "C" void execute__12daObjTrnd2_cFv();
extern "C" void setParticle__12daObjTrnd2_cFv();
extern "C" void endParticle__12daObjTrnd2_cFv();
extern "C" void startParticle__12daObjTrnd2_cFv();
extern "C" void stopParticle__12daObjTrnd2_cFv();
extern "C" bool draw__12daObjTrnd2_cFv();
extern "C" void _delete__12daObjTrnd2_cFv();
extern "C" static void daObjTrnd2_Draw__FP12daObjTrnd2_c();
extern "C" static void daObjTrnd2_Execute__FP12daObjTrnd2_c();
extern "C" static void daObjTrnd2_Delete__FP12daObjTrnd2_c();
extern "C" static void daObjTrnd2_Create__FP12daObjTrnd2_c();
extern "C" void func_80D1D3B0(void* _this, s32*);
//
// External References:
//
extern "C" void transS__14mDoMtx_stack_cFRC4cXyz();
extern "C" void ZXYrotM__14mDoMtx_stack_cFRC5csXyz();
extern "C" void __ct__10fopAc_ac_cFv();
extern "C" void fopAcM_setCullSizeBox__FP10fopAc_ac_cffffff();
extern "C" void isSwitch__10dSv_info_cCFii();
extern "C" void
set__13dPa_control_cFUcUsPC4cXyzPC12dKy_tevstr_cPC5csXyzPC4cXyzUcP18dPa_levelEcallBackScPC8_GXColorPC8_GXColorPC4cXyzf();
extern "C" void dKyw_pntwind_set__FP14WIND_INFLUENCE();
extern "C" void dKyw_pntwind_cut__FP14WIND_INFLUENCE();
extern "C" void dKyw_custom_windpower__Ff();
extern "C" void dKyw_evt_wind_set__Fss();
extern "C" void dKyr_get_vectle_calc__FP4cXyzP4cXyzP4cXyz();
extern "C" void __ct__10dCcD_GSttsFv();
extern "C" void Init__9dCcD_SttsFiiP10fopAc_ac_c();
extern "C" void __ct__12dCcD_GObjInfFv();
extern "C" void Set__8dCcD_CpsFRC11dCcD_SrcCps();
extern "C" void Set__4cCcSFP8cCcD_Obj();
extern "C" void normalize__4cXyzFv();
extern "C" void isZero__4cXyzCFv();
extern "C" void cM_rndF__Ff();
extern "C" void __ct__8cM3dGCpsFv();
extern "C" void Set__8cM3dGCpsFRC9cM3dGCpsS();
extern "C" void cLib_addCalc__FPfffff();
extern "C" void cLib_chaseF__FPfff();
extern "C" void __dl__FPv();
extern "C" void PSMTXCopy();
extern "C" void PSMTXMultVec();
extern "C" void PSVECScale();
extern "C" void PSVECSquareDistance();
extern "C" void _savegpr_26();
extern "C" void _savegpr_28();
extern "C" void _savegpr_29();
extern "C" void _restgpr_26();
extern "C" void _restgpr_28();
extern "C" void _restgpr_29();
extern "C" extern void* g_fopAc_Method[8];
extern "C" extern void* g_fpcLf_Method[5 + 1 /* padding */];
extern "C" extern void* __vt__8dCcD_Cps[36];
extern "C" extern void* __vt__9dCcD_Stts[11];
extern "C" extern void* __vt__12cCcD_CpsAttr[25];
extern "C" extern void* __vt__14cCcD_ShapeAttr[22];
extern "C" extern void* __vt__9cCcD_Stts[8];
extern "C" u8 now__14mDoMtx_stack_c[48];
extern "C" extern u8 g_dComIfG_gameInfo[122384];
extern "C" extern u8 g_env_light[4880];
extern "C" f32 Zero__4cXyz[3];
extern "C" extern u32 __float_nan;
//
// Declarations:
//
/* ############################################################################################## */
/* 80D1D3D4-80D1D3DC 000000 0006+02 6/6 0/0 0/0 .rodata l_R02_eff_id */
SECTION_RODATA static u8 const l_R02_eff_id[6 + 2 /* padding */] = {
0x8B,
0x5E,
0x8B,
0x5F,
0xFF,
0xFF,
/* padding */
0x00,
0x00,
};
COMPILER_STRIP_GATE(0x80D1D3D4, &l_R02_eff_id);
/* 80D1D3DC-80D1D3E4 000008 0006+02 0/1 0/0 0/0 .rodata l_R04_eff_id */
#pragma push
#pragma force_active on
SECTION_RODATA static u8 const l_R04_eff_id[6 + 2 /* padding */] = {
0x8B,
0x60,
0x8B,
0x61,
0xFF,
0xFF,
/* padding */
0x00,
0x00,
};
COMPILER_STRIP_GATE(0x80D1D3DC, &l_R04_eff_id);
#pragma pop
/* 80D1D3E4-80D1D3EC 000010 0006+02 0/1 0/0 0/0 .rodata l_R05_eff_id */
#pragma push
#pragma force_active on
SECTION_RODATA static u8 const l_R05_eff_id[6 + 2 /* padding */] = {
0x8B,
0x6B,
0x8B,
0x6C,
0xFF,
0xFF,
/* padding */
0x00,
0x00,
};
COMPILER_STRIP_GATE(0x80D1D3E4, &l_R05_eff_id);
#pragma pop
/* 80D1D3EC-80D1D3F4 000018 0006+02 0/1 0/0 0/0 .rodata l_R07_eff_id */
#pragma push
#pragma force_active on
SECTION_RODATA static u8 const l_R07_eff_id[6 + 2 /* padding */] = {
0x8B,
0x6D,
0x8B,
0x6E,
0xFF,
0xFF,
/* padding */
0x00,
0x00,
};
COMPILER_STRIP_GATE(0x80D1D3EC, &l_R07_eff_id);
#pragma pop
/* 80D1D3F4-80D1D3FC 000020 0006+02 0/1 0/0 0/0 .rodata l_R14_eff_id */
#pragma push
#pragma force_active on
SECTION_RODATA static u8 const l_R14_eff_id[6 + 2 /* padding */] = {
0x8B,
0x66,
0x8B,
0x67,
0x8B,
0x68,
/* padding */
0x00,
0x00,
};
COMPILER_STRIP_GATE(0x80D1D3F4, &l_R14_eff_id);
#pragma pop
/* 80D1D3FC-80D1D404 000028 0006+02 0/1 0/0 0/0 .rodata l_R51_eff_id */
#pragma push
#pragma force_active on
SECTION_RODATA static u8 const l_R51_eff_id[6 + 2 /* padding */] = {
0x8B,
0x69,
0x8B,
0x6A,
0xFF,
0xFF,
/* padding */
0x00,
0x00,
};
COMPILER_STRIP_GATE(0x80D1D3FC, &l_R51_eff_id);
#pragma pop
/* 80D1D404-80D1D408 000030 0004+00 0/5 0/0 0/0 .rodata @3631 */
#pragma push
#pragma force_active on
SECTION_RODATA static u8 const lit_3631[4] = {
0x00,
0x00,
0x00,
0x00,
};
COMPILER_STRIP_GATE(0x80D1D404, &lit_3631);
#pragma pop
/* 80D1D408-80D1D40C 000034 0004+00 0/3 0/0 0/0 .rodata @3632 */
#pragma push
#pragma force_active on
SECTION_RODATA static f32 const lit_3632 = 1.0f;
COMPILER_STRIP_GATE(0x80D1D408, &lit_3632);
#pragma pop
/* 80D1D40C-80D1D410 000038 0004+00 0/2 0/0 0/0 .rodata @3633 */
#pragma push
#pragma force_active on
SECTION_RODATA static f32 const lit_3633 = 1.0f / 5.0f;
COMPILER_STRIP_GATE(0x80D1D40C, &lit_3633);
#pragma pop
/* 80D1C4D8-80D1C54C 000078 0074+00 1/1 0/0 0/0 .text setPntWind__12daObjTrnd2_cFv */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm void daObjTrnd2_c::setPntWind() {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/setPntWind__12daObjTrnd2_cFv.s"
}
#pragma pop
/* 80D1C54C-80D1C570 0000EC 0024+00 1/1 0/0 0/0 .text cutPntWind__12daObjTrnd2_cFv */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm void daObjTrnd2_c::cutPntWind() {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/cutPntWind__12daObjTrnd2_cFv.s"
}
#pragma pop
/* ############################################################################################## */
/* 80D1D410-80D1D414 00003C 0004+00 0/1 0/0 0/0 .rodata @3681 */
#pragma push
#pragma force_active on
SECTION_RODATA static f32 const lit_3681 = 2.0f;
COMPILER_STRIP_GATE(0x80D1D410, &lit_3681);
#pragma pop
/* 80D1D414-80D1D418 000040 0004+00 0/2 0/0 0/0 .rodata @3682 */
#pragma push
#pragma force_active on
SECTION_RODATA static f32 const lit_3682 = 1.0f / 10.0f;
COMPILER_STRIP_GATE(0x80D1D414, &lit_3682);
#pragma pop
/* 80D1D418-80D1D41C 000044 0004+00 0/3 0/0 0/0 .rodata @3683 */
#pragma push
#pragma force_active on
SECTION_RODATA static f32 const lit_3683 = 0.5f;
COMPILER_STRIP_GATE(0x80D1D418, &lit_3683);
#pragma pop
/* 80D1D41C-80D1D424 000048 0008+00 0/1 0/0 0/0 .rodata @3684 */
#pragma push
#pragma force_active on
SECTION_RODATA static u8 const lit_3684[8] = {
0x3F, 0xE0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
};
COMPILER_STRIP_GATE(0x80D1D41C, &lit_3684);
#pragma pop
/* 80D1D424-80D1D42C 000050 0008+00 0/1 0/0 0/0 .rodata @3685 */
#pragma push
#pragma force_active on
SECTION_RODATA static u8 const lit_3685[8] = {
0x40, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
};
COMPILER_STRIP_GATE(0x80D1D424, &lit_3685);
#pragma pop
/* 80D1D42C-80D1D434 000058 0008+00 0/1 0/0 0/0 .rodata @3686 */
#pragma push
#pragma force_active on
SECTION_RODATA static u8 const lit_3686[8] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
};
COMPILER_STRIP_GATE(0x80D1D42C, &lit_3686);
#pragma pop
/* 80D1C570-80D1C780 000110 0210+00 1/1 0/0 0/0 .text movePntWind__12daObjTrnd2_cFv */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm void daObjTrnd2_c::movePntWind() {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/movePntWind__12daObjTrnd2_cFv.s"
}
#pragma pop
/* ############################################################################################## */
/* 80D1D434-80D1D438 000060 0004+00 0/1 0/0 0/0 .rodata @3730 */
#pragma push
#pragma force_active on
SECTION_RODATA static f32 const lit_3730 = 1.0f / 20.0f;
COMPILER_STRIP_GATE(0x80D1D434, &lit_3730);
#pragma pop
/* 80D1D438-80D1D43C 000064 0004+00 0/2 0/0 0/0 .rodata @3731 */
#pragma push
#pragma force_active on
SECTION_RODATA static f32 const lit_3731 = 10.0f;
COMPILER_STRIP_GATE(0x80D1D438, &lit_3731);
#pragma pop
/* 80D1D43C-80D1D444 000068 0008+00 0/1 0/0 0/0 .rodata @3733 */
#pragma push
#pragma force_active on
SECTION_RODATA static u8 const lit_3733[8] = {
0x43, 0x30, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
};
COMPILER_STRIP_GATE(0x80D1D43C, &lit_3733);
#pragma pop
/* 80D1C780-80D1C924 000320 01A4+00 1/1 0/0 0/0 .text setCpsInfo__12daObjTrnd2_cFv */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm void daObjTrnd2_c::setCpsInfo() {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/setCpsInfo__12daObjTrnd2_cFv.s"
}
#pragma pop
/* 80D1C924-80D1C944 0004C4 0020+00 1/1 0/0 0/0 .text initBaseMtx__12daObjTrnd2_cFv */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm void daObjTrnd2_c::initBaseMtx() {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/initBaseMtx__12daObjTrnd2_cFv.s"
}
#pragma pop
/* 80D1C944-80D1C98C 0004E4 0048+00 2/2 0/0 0/0 .text setBaseMtx__12daObjTrnd2_cFv */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm void daObjTrnd2_c::setBaseMtx() {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/setBaseMtx__12daObjTrnd2_cFv.s"
}
#pragma pop
/* ############################################################################################## */
/* 80D1D444-80D1D448 000070 0004+00 0/1 0/0 0/0 .rodata @3819 */
#pragma push
#pragma force_active on
SECTION_RODATA static f32 const lit_3819 = 150.0f;
COMPILER_STRIP_GATE(0x80D1D444, &lit_3819);
#pragma pop
/* 80D1D448-80D1D44C 000074 0004+00 0/1 0/0 0/0 .rodata @3820 */
#pragma push
#pragma force_active on
SECTION_RODATA static f32 const lit_3820 = 1000.0f;
COMPILER_STRIP_GATE(0x80D1D448, &lit_3820);
#pragma pop
/* 80D1D458-80D1D4A4 000000 004C+00 1/1 0/0 0/0 .data l_cps_src */
SECTION_DATA static u8 l_cps_src[76] = {
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1D,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03,
0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x45, 0x3B, 0x80, 0x00, 0x00, 0x00, 0x00, 0x00, 0x43, 0x16, 0x00, 0x00,
};
/* 80D1C98C-80D1CC80 00052C 02F4+00 1/1 0/0 0/0 .text Create__12daObjTrnd2_cFv */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm void daObjTrnd2_c::Create() {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/Create__12daObjTrnd2_cFv.s"
}
#pragma pop
/* ############################################################################################## */
/* 80D1D4A4-80D1D4C4 -00001 0020+00 1/0 0/0 0/0 .data l_daObjTrnd2_Method */
SECTION_DATA static void* l_daObjTrnd2_Method[8] = {
(void*)daObjTrnd2_Create__FP12daObjTrnd2_c,
(void*)daObjTrnd2_Delete__FP12daObjTrnd2_c,
(void*)daObjTrnd2_Execute__FP12daObjTrnd2_c,
(void*)NULL,
(void*)daObjTrnd2_Draw__FP12daObjTrnd2_c,
(void*)NULL,
(void*)NULL,
(void*)NULL,
};
/* 80D1D4C4-80D1D4F4 -00001 0030+00 0/0 0/0 1/0 .data g_profile_Obj_Tornado2 */
SECTION_DATA extern void* g_profile_Obj_Tornado2[12] = {
(void*)0xFFFFFFFD, (void*)0x0007FFFD,
(void*)0x015C0000, (void*)&g_fpcLf_Method,
(void*)0x00000788, (void*)NULL,
(void*)NULL, (void*)&g_fopAc_Method,
(void*)0x01BD0000, (void*)&l_daObjTrnd2_Method,
(void*)0x00040000, (void*)0x000E0000,
};
/* 80D1D4F4-80D1D500 00009C 000C+00 2/2 0/0 0/0 .data __vt__8cM3dGAab */
SECTION_DATA extern void* __vt__8cM3dGAab[3] = {
(void*)NULL /* RTTI */,
(void*)NULL,
(void*)__dt__8cM3dGAabFv,
};
/* 80D1CC80-80D1CD78 000820 00F8+00 1/1 0/0 0/0 .text create__12daObjTrnd2_cFv */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm void daObjTrnd2_c::create() {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/func_80D1CC80.s"
}
#pragma pop
/* 80D1CD78-80D1CDC0 000918 0048+00 1/0 0/0 0/0 .text __dt__8cM3dGAabFv */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm cM3dGAab::~cM3dGAab() {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/__dt__8cM3dGAabFv.s"
}
#pragma pop
/* ############################################################################################## */
/* 80D1D44C-80D1D450 000078 0004+00 0/1 0/0 0/0 .rodata @4012 */
#pragma push
#pragma force_active on
SECTION_RODATA static f32 const lit_4012 = 3.0f / 10.0f;
COMPILER_STRIP_GATE(0x80D1D44C, &lit_4012);
#pragma pop
/* 80D1D450-80D1D454 00007C 0004+00 0/1 0/0 0/0 .rodata @4013 */
#pragma push
#pragma force_active on
SECTION_RODATA static u32 const lit_4013 = 0x3A83126F;
COMPILER_STRIP_GATE(0x80D1D450, &lit_4013);
#pragma pop
/* 80D1D454-80D1D458 000080 0004+00 0/1 0/0 0/0 .rodata @4014 */
#pragma push
#pragma force_active on
SECTION_RODATA static f32 const lit_4014 = 9.0f / 10.0f;
COMPILER_STRIP_GATE(0x80D1D454, &lit_4014);
#pragma pop
/* 80D1CDC0-80D1D0AC 000960 02EC+00 1/1 0/0 0/0 .text execute__12daObjTrnd2_cFv */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm void daObjTrnd2_c::execute() {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/execute__12daObjTrnd2_cFv.s"
}
#pragma pop
/* 80D1D0AC-80D1D214 000C4C 0168+00 1/1 0/0 0/0 .text setParticle__12daObjTrnd2_cFv */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm void daObjTrnd2_c::setParticle() {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/setParticle__12daObjTrnd2_cFv.s"
}
#pragma pop
/* 80D1D214-80D1D278 000DB4 0064+00 1/1 0/0 0/0 .text endParticle__12daObjTrnd2_cFv */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm void daObjTrnd2_c::endParticle() {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/endParticle__12daObjTrnd2_cFv.s"
}
#pragma pop
/* 80D1D278-80D1D2AC 000E18 0034+00 2/2 0/0 0/0 .text startParticle__12daObjTrnd2_cFv */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm void daObjTrnd2_c::startParticle() {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/startParticle__12daObjTrnd2_cFv.s"
}
#pragma pop
/* 80D1D2AC-80D1D2E0 000E4C 0034+00 2/2 0/0 0/0 .text stopParticle__12daObjTrnd2_cFv */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm void daObjTrnd2_c::stopParticle() {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/stopParticle__12daObjTrnd2_cFv.s"
}
#pragma pop
/* 80D1D2E0-80D1D2E8 000E80 0008+00 1/1 0/0 0/0 .text draw__12daObjTrnd2_cFv */
bool daObjTrnd2_c::draw() {
return true;
}
/* 80D1D2E8-80D1D330 000E88 0048+00 1/1 0/0 0/0 .text _delete__12daObjTrnd2_cFv */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
asm void daObjTrnd2_c::_delete() {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/_delete__12daObjTrnd2_cFv.s"
}
#pragma pop
/* 80D1D330-80D1D350 000ED0 0020+00 1/0 0/0 0/0 .text daObjTrnd2_Draw__FP12daObjTrnd2_c
*/
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
static asm void daObjTrnd2_Draw(daObjTrnd2_c* param_0) {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/daObjTrnd2_Draw__FP12daObjTrnd2_c.s"
}
#pragma pop
/* 80D1D350-80D1D370 000EF0 0020+00 1/0 0/0 0/0 .text daObjTrnd2_Execute__FP12daObjTrnd2_c */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
static asm void daObjTrnd2_Execute(daObjTrnd2_c* param_0) {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/daObjTrnd2_Execute__FP12daObjTrnd2_c.s"
}
#pragma pop
/* 80D1D370-80D1D390 000F10 0020+00 1/0 0/0 0/0 .text daObjTrnd2_Delete__FP12daObjTrnd2_c
*/
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
static asm void daObjTrnd2_Delete(daObjTrnd2_c* param_0) {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/daObjTrnd2_Delete__FP12daObjTrnd2_c.s"
}
#pragma pop
/* 80D1D390-80D1D3B0 000F30 0020+00 1/0 0/0 0/0 .text daObjTrnd2_Create__FP12daObjTrnd2_c
*/
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
static asm void daObjTrnd2_Create(daObjTrnd2_c* param_0) {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/daObjTrnd2_Create__FP12daObjTrnd2_c.s"
}
#pragma pop
/* 80D1D3B0-80D1D3CC 000F50 001C+00 1/1 0/0 0/0 .text cLib_calcTimer<l>__FPl */
#pragma push
#pragma optimization_level 0
#pragma optimizewithasm off
extern "C" asm void func_80D1D3B0(void* _this, s32* param_0) {
nofralloc
#include "asm/rel/d/a/obj/d_a_obj_tornado2/d_a_obj_tornado2/func_80D1D3B0.s"
}
#pragma pop
| [
""
] | |
bd0bd8a4fc8576c6962e696f4a6d945aa928d04f | c03dc1a10fcb3875798308bc5937d4ba10e2386e | /Test_Proc/Procedural.h | f5e58a4de3d2febe45efb1dd1b0ef5efe022552f | [] | no_license | Le2o/TecProg_ProcVersion | ef472c49bdc6952bc06a11e4e874e7cb46a5bfbf | 6596139879bc719ccd1f08abcb3f0d145531e98f | refs/heads/master | 2020-04-21T18:33:00.862138 | 2019-03-26T12:08:26 | 2019-03-26T12:08:26 | 169,773,817 | 0 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 416 | h | #ifndef PROCEDURAL_H
#define PROCEDURAL_H
#include <fstream>
using namespace std;
namespace Filippov
{
struct Procedural
{
enum lang
{
PROCEDURAL,
OOP,
FUNCTIONAL
} key;
unsigned short int year_of_development;
int reference;
bool abstract_type;
};
void Procedural_Input(Procedural &obj, ifstream &fin);
void Procedural_Output(Procedural &obj, ofstream &fout);
}
#endif // !PROCEDURAL_H | [
"le2o1995@gmail.com"
] | le2o1995@gmail.com |
f23fe929ab9afd2445c5be61c572093dcc4cd6f2 | f1d0ea36f07c2ef126dec93208bd025aa78eceb7 | /Zen/plugins/ZPhysX/src/PhysicsJoint.cpp | 2ff3e009f79047de8ac25ff78fcc328352501291 | [] | no_license | SgtFlame/indiezen | b7d6f87143b2f33abf977095755b6af77e9e7dab | 5513d5a05dc1425591ab7b9ba1b16d11b6a74354 | refs/heads/master | 2020-05-17T23:57:21.063997 | 2016-09-05T15:28:28 | 2016-09-05T15:28:28 | 33,279,102 | 3 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,548 | cpp | //-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~
// IndieZen Game Engine Framework
//
// Copyright (C) 2001 - 2007 Tony Richards
// Copyright (C) 2008 Walt Collins
//
// This software is provided 'as-is', without any express or implied
// warranty. In no event will the authors be held liable for any damages
// arising from the use of this software.
//
// Permission is granted to anyone to use this software for any purpose,
// including commercial applications, and to alter it and redistribute it
// freely, subject to the following restrictions:
//
// 1. The origin of this software must not be misrepresented; you must not
// claim that you wrote the original software. If you use this software
// in a product, an acknowledgment in the product documentation would be
// appreciated but is not required.
// 2. Altered source versions must be plainly marked as such, and must not be
// misrepresented as being the original software.
// 3. This notice may not be removed or altered from any source distribution.
//
// Tony Richards trichards@indiezen.com
// Walt Collins (Arcanor) - wcollins@indiezen.com
//-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~
#include "PhysicsJoint.hpp"
#include <Zen/Engine/Physics/I_PhysicsWorld.hpp>
#include <Zen/Engine/Physics/I_PhysicsShape.hpp>
#include <Zen/Core/Math/Vector3.hpp>
//-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~
namespace Zen {
namespace ZPhysX {
//-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~
PhysicsJoint::PhysicsJoint(wpPhysicsZone_type _zone)
: m_pZone(_zone)
{
}
//-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~
PhysicsJoint::~PhysicsJoint()
{
}
//-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~
void
PhysicsJoint::attachShape(PhysicsJoint::pCollisionShape_type _shape)
{
m_pShape = _shape;
}
//-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~
void
PhysicsJoint::initUpVectorJoint(const Math::Vector3& _upVector)
{
NewtonConstraintCreateUpVector((NewtonWorld*)m_pZone->getZonePtr(), _upVector.m_array, (NewtonBody*)m_pShape->getBodyPtr());
}
//-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~
} // namespace ZNewton
} // namespace Zen
//-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~-~
| [
"mgray@wintermute"
] | mgray@wintermute |
25062c0e94da53e6a6bc8c79be5107afbf405006 | d4c720f93631097ee048940d669e0859e85eabcf | /chrome/browser/web_applications/web_app_logging.h | 2a4c6af6391e111cc9095f6a94ffc899c88cc2bf | [
"BSD-3-Clause"
] | permissive | otcshare/chromium-src | 26a7372773b53b236784c51677c566dc0ad839e4 | 3b920d87437d9293f654de1f22d3ea341e7a8b55 | refs/heads/webnn | 2023-03-21T03:20:15.377034 | 2023-01-25T21:19:44 | 2023-01-25T21:19:44 | 209,262,645 | 18 | 21 | BSD-3-Clause | 2023-03-23T06:20:07 | 2019-09-18T08:52:07 | null | UTF-8 | C++ | false | false | 2,385 | h | // Copyright 2022 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_LOGGING_H_
#define CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_LOGGING_H_
#include <memory>
#include <string>
#include "base/values.h"
#include "chrome/browser/web_applications/web_app_constants.h"
#include "chrome/browser/web_applications/web_app_id.h"
#include "chrome/browser/web_applications/web_app_install_info.h"
#include "chrome/browser/web_applications/web_app_url_loader.h"
#include "components/webapps/browser/installable/installable_metrics.h"
namespace web_app {
// This class is used to accumulate a single log entry
class InstallErrorLogEntry {
public:
explicit InstallErrorLogEntry(bool background_installation,
webapps::WebappInstallSource install_surface);
~InstallErrorLogEntry();
// The InstallWebAppTask determines this after construction, so a setter is
// required.
void set_background_installation(bool background_installation) {
background_installation_ = background_installation;
}
bool HasErrorDict() const { return !!error_dict_; }
// Collects install errors (unbounded) if the |kRecordWebAppDebugInfo|
// flag is enabled to be used by: chrome://web-app-internals
base::Value TakeErrorDict();
void LogUrlLoaderError(const char* stage,
const std::string& url,
WebAppUrlLoader::Result result);
void LogExpectedAppIdError(const char* stage,
const std::string& url,
const AppId& app_id,
const AppId& expected_app_id);
void LogDownloadedIconsErrors(
const WebAppInstallInfo& web_app_info,
IconsDownloadedResult icons_downloaded_result,
const IconsMap& icons_map,
const DownloadedIconsHttpResults& icons_http_results);
private:
void LogHeaderIfLogEmpty(const std::string& url);
void LogErrorObject(const char* stage,
const std::string& url,
base::Value::Dict object);
std::unique_ptr<base::Value::Dict> error_dict_;
bool background_installation_;
webapps::WebappInstallSource install_surface_;
};
} // namespace web_app
#endif // CHROME_BROWSER_WEB_APPLICATIONS_WEB_APP_LOGGING_H_
| [
"chromium-scoped@luci-project-accounts.iam.gserviceaccount.com"
] | chromium-scoped@luci-project-accounts.iam.gserviceaccount.com |
0e4eaf1e492c47d724cb6d4ba251036380a7ade8 | da1b99cb8f45186085339ea8043ffb335bcd733c | /UvaOnlineJudge/11661.cpp | 982cd4ac0831126111c73c7252e82d605fa88c6d | [] | no_license | Intiser/ProblemSolvingAndContest | 2dff8470fe109701d2e3e407d757f8859691dbd1 | de5431261ac675f323e1d8c19008b0523ba6455e | refs/heads/master | 2020-03-28T04:33:15.934870 | 2019-02-12T09:43:54 | 2019-02-12T09:43:54 | 147,721,990 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 655 | cpp | #include<iostream>
#include<stdio.h>
using namespace std;
int main(){
char c;
int n,fr,fd,r,d,mn,tmp;
while(cin>>n){
cin.ignore();
if(n==0) break;
mn=2000001; fr=0; fd=0;
for(int i=0;i<n;i++){
c=getchar();
if(c=='Z'){
mn=0;
}
else if(c=='R'){
r=i; fr=1;
}
else if(c=='D'){
d=i; fd=1;
}
if(fd==1&&fr==1){
if(r>d) tmp=r-d;
else tmp=d-r;
if(tmp<mn) mn=tmp;
}
}
cout<<mn<<endl;
}
}
| [
"Intiser@users.noreply.github.com"
] | Intiser@users.noreply.github.com |
7375005514b407d40d56dd71cef2d46c0fdb3bc9 | d4d9779e1f476921fbec4b43b115d24bf394f513 | /MyProject/Private/BTPatrolPointSelect.cpp | 00c172e224ba02e4bffee7da7431431cdcb11b05 | [] | no_license | RastBerryHI/UnrealEngineMed- | 2a1c604a9ba50f5ce595c0d02aef6247757d38e8 | 8e092d687606ef402bcd02583aae52f813045784 | refs/heads/main | 2023-03-03T07:20:09.234775 | 2021-02-16T19:27:11 | 2021-02-16T19:27:11 | 339,506,147 | 2 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,210 | cpp | // Fill out your copyright notice in the Description page of Project Settings.
#include "PatrolPoint.h"
#include "AIPatrolController.h"
#include "BehaviorTree/BlackboardComponent.h"
#include "BTPatrolPointSelect.h"
EBTNodeResult::Type UBTPatrolPointSelect::ExecuteTask(UBehaviorTreeComponent& OwnerComp, uint8* NodeMemory)
{
AAIPatrolController* AAICon = Cast<AAIPatrolController>(OwnerComp.GetAIOwner());
if (AAICon)
{
/* Get blackboard coponent */
UBlackboardComponent* BlackboardComp = AAICon->GetBlackboardComponent();
APatrolPoint* CurrentPoint = Cast<APatrolPoint>(BlackboardComp->GetValueAsObject("LocationToGo"));
TArray<AActor*> AvaliablePatrolPoints = AAICon->GetPatrolPoints();
APatrolPoint* NextPatrolPoint = nullptr;
if(AAICon->CurrentPatroPoint != AvaliablePatrolPoints.Num() - 1)
{
NextPatrolPoint = Cast<APatrolPoint>(AvaliablePatrolPoints[++AAICon->CurrentPatroPoint]);
}
else // if there no points to go to
{
NextPatrolPoint = Cast<APatrolPoint>(AvaliablePatrolPoints[0]);
AAICon->CurrentPatroPoint = 0;
}
BlackboardComp->SetValueAsObject("LocationToGo", NextPatrolPoint);
return EBTNodeResult::Succeeded;
}
return EBTNodeResult::Failed;
}
| [
"musaev.pasha@gmail.com"
] | musaev.pasha@gmail.com |
8518cf93aad2e98a2025578d31d87cbed6349673 | 5abed44fbdb0532980b2c850a8e7fad20ef96078 | /libredex/IRTypeChecker.cpp | 56926ba0825fbcc02bf6ea1d4a577ecab2aee174 | [
"MIT"
] | permissive | chmodawk/redex | 8b42f33c71cffb58db49aa9613e3060d88de2116 | c1d2fdd2fdb14c2c3e7adafe827c458c4a1a56ec | refs/heads/master | 2023-03-18T21:45:10.287719 | 2021-03-08T17:45:47 | 2021-03-08T17:48:04 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 41,922 | cpp | /*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
#include "IRTypeChecker.h"
#include <boost/optional/optional.hpp>
#include "DexUtil.h"
#include "Match.h"
#include "Resolver.h"
#include "Show.h"
#include "Trace.h"
using namespace sparta;
using namespace type_inference;
namespace {
using namespace ir_analyzer;
// We abort the type checking process at the first error encountered.
class TypeCheckingException final : public std::runtime_error {
public:
explicit TypeCheckingException(const std::string& what_arg)
: std::runtime_error(what_arg) {}
};
std::ostringstream& print_register(std::ostringstream& out, reg_t reg) {
if (reg == RESULT_REGISTER) {
out << "result";
} else {
out << "register v" << reg;
}
return out;
}
void check_type_match(reg_t reg, IRType actual, IRType expected) {
if (actual == BOTTOM) {
// There's nothing to do for unreachable code.
return;
}
if (actual == SCALAR && expected != REFERENCE) {
// If the type is SCALAR and we're checking compatibility with an integer
// or float type, we just bail out.
return;
}
if (!TypeDomain(actual).leq(TypeDomain(expected))) {
std::ostringstream out;
print_register(out, reg) << ": expected type " << expected << ", but found "
<< actual << " instead";
throw TypeCheckingException(out.str());
}
}
/*
* There are cases where we cannot precisely infer the exception type for
* MOVE_EXCEPTION. In these cases, we use Ljava/lang/Throwable; as a fallback
* type.
*/
bool is_inference_fallback_type(const DexType* type) {
return type == type::java_lang_Throwable();
}
/*
* We might not have the external DexClass to fully determine the hierarchy.
* Therefore, be more lenient when assigning from or to external DexType.
*/
bool check_cast_helper(const DexType* from, const DexType* to) {
// We can always cast to Object
if (to == type::java_lang_Object()) {
return true;
}
// We can never cast from Object to anything besides Object
if (from == type::java_lang_Object() && from != to) {
// TODO(T66567547) sanity check that type::check_cast would have agreed
always_assert(!type::check_cast(from, to));
return false;
}
// If we have any external types (aside from Object), allow it
if (!type_class_internal(from) || !type_class_internal(to)) {
return true;
}
return type::check_cast(from, to);
}
// Type assignment check between two reference types. We assume that both `from`
// and `to` are reference types.
// Took reference from:
// http://androidxref.com/6.0.1_r10/xref/art/runtime/verifier/reg_type-inl.h#88
//
// Note: the expectation is that `from` and `to` are reference types, otherwise
// the check fails.
bool check_is_assignable_from(const DexType* from,
const DexType* to,
bool strict) {
always_assert(from && to);
always_assert_log(!type::is_primitive(from), "%s", SHOW(from));
if (type::is_primitive(from) || type::is_primitive(to)) {
return false; // Expect types be a reference type.
}
if (from == to) {
return true; // Fast path if the two are equal.
}
if (to == type::java_lang_Object()) {
return true; // All reference types can be assigned to Object.
}
if (type::is_java_lang_object_array(to)) {
// All reference arrays may be assigned to Object[]
return type::is_reference_array(from);
}
if (type::is_array(from) && type::is_array(to)) {
if (type::get_array_level(from) != type::get_array_level(to)) {
return false;
}
auto efrom = type::get_array_element_type(from);
auto eto = type::get_array_element_type(to);
return check_cast_helper(efrom, eto);
}
if (!strict) {
// If `to` is an interface, allow any assignment when non-strict.
// This behavior is copied from AOSP.
auto to_cls = type_class(to);
if (to_cls != nullptr && is_interface(to_cls)) {
return true;
}
}
return check_cast_helper(from, to);
}
void check_wide_type_match(reg_t reg,
IRType actual1,
IRType actual2,
IRType expected1,
IRType expected2) {
if (actual1 == BOTTOM) {
// There's nothing to do for unreachable code.
return;
}
if (actual1 == SCALAR1 && actual2 == SCALAR2) {
// If type of the pair of registers is (SCALAR1, SCALAR2), we just bail
// out.
return;
}
if (!(TypeDomain(actual1).leq(TypeDomain(expected1)) &&
TypeDomain(actual2).leq(TypeDomain(expected2)))) {
std::ostringstream out;
print_register(out, reg)
<< ": expected type (" << expected1 << ", " << expected2
<< "), but found (" << actual1 << ", " << actual2 << ") instead";
throw TypeCheckingException(out.str());
}
}
void assume_type(TypeEnvironment* state,
reg_t reg,
IRType expected,
bool ignore_top = false) {
if (state->is_bottom()) {
// There's nothing to do for unreachable code.
return;
}
IRType actual = state->get_type(reg).element();
if (ignore_top && actual == TOP) {
return;
}
check_type_match(reg, actual, /* expected */ expected);
}
void assume_wide_type(TypeEnvironment* state,
reg_t reg,
IRType expected1,
IRType expected2) {
if (state->is_bottom()) {
// There's nothing to do for unreachable code.
return;
}
IRType actual1 = state->get_type(reg).element();
IRType actual2 = state->get_type(reg + 1).element();
check_wide_type_match(reg,
actual1,
actual2,
/* expected1 */ expected1,
/* expected2 */ expected2);
}
// This is used for the operand of a comparison operation with zero. The
// complexity here is that this operation may be performed on either an
// integer or a reference.
void assume_comparable_with_zero(TypeEnvironment* state, reg_t reg) {
if (state->is_bottom()) {
// There's nothing to do for unreachable code.
return;
}
IRType t = state->get_type(reg).element();
if (t == SCALAR) {
// We can't say anything conclusive about a register that has SCALAR type,
// so we just bail out.
return;
}
if (!(TypeDomain(t).leq(TypeDomain(REFERENCE)) ||
TypeDomain(t).leq(TypeDomain(INT)))) {
std::ostringstream out;
print_register(out, reg)
<< ": expected integer or reference type, but found " << t
<< " instead";
throw TypeCheckingException(out.str());
}
}
// This is used for the operands of a comparison operation between two
// registers. The complexity here is that this operation may be performed on
// either two integers or two references.
void assume_comparable(TypeEnvironment* state, reg_t reg1, reg_t reg2) {
if (state->is_bottom()) {
// There's nothing to do for unreachable code.
return;
}
IRType t1 = state->get_type(reg1).element();
IRType t2 = state->get_type(reg2).element();
if (!((TypeDomain(t1).leq(TypeDomain(REFERENCE)) &&
TypeDomain(t2).leq(TypeDomain(REFERENCE))) ||
(TypeDomain(t1).leq(TypeDomain(SCALAR)) &&
TypeDomain(t2).leq(TypeDomain(SCALAR)) && (t1 != FLOAT) &&
(t2 != FLOAT)))) {
// Two values can be used in a comparison operation if they either both
// have the REFERENCE type or have non-float scalar types. Note that in
// the case where one or both types have the SCALAR type, we can't
// definitely rule out the absence of a type error.
std::ostringstream out;
print_register(out, reg1) << " and ";
print_register(out, reg2)
<< ": incompatible types in comparison " << t1 << " and " << t2;
throw TypeCheckingException(out.str());
}
}
void assume_integer(TypeEnvironment* state, reg_t reg) {
assume_type(state, reg, /* expected */ INT);
}
void assume_float(TypeEnvironment* state, reg_t reg) {
assume_type(state, reg, /* expected */ FLOAT);
}
void assume_long(TypeEnvironment* state, reg_t reg) {
assume_wide_type(state, reg, /* expected1 */ LONG1, /* expected2 */ LONG2);
}
void assume_double(TypeEnvironment* state, reg_t reg) {
assume_wide_type(
state, reg, /* expected1 */ DOUBLE1, /* expected2 */ DOUBLE2);
}
void assume_wide_scalar(TypeEnvironment* state, reg_t reg) {
assume_wide_type(
state, reg, /* expected1 */ SCALAR1, /* expected2 */ SCALAR2);
}
class Result final {
public:
static Result Ok() { return Result(); }
static Result make_error(const std::string& s) { return Result(s); }
const std::string& error_message() const {
always_assert(!is_ok);
return m_error_message;
}
bool operator==(const Result& that) const {
return is_ok == that.is_ok && m_error_message == that.m_error_message;
}
bool operator!=(const Result& that) const { return !(*this == that); }
private:
bool is_ok{true};
std::string m_error_message;
explicit Result(const std::string& s) : is_ok(false), m_error_message(s) {}
Result() = default;
};
static bool has_move_result_pseudo(const MethodItemEntry& mie) {
return mie.type == MFLOW_OPCODE && mie.insn->has_move_result_pseudo();
}
static bool is_move_result_pseudo(const MethodItemEntry& mie) {
return mie.type == MFLOW_OPCODE &&
opcode::is_a_move_result_pseudo(mie.insn->opcode());
}
Result check_load_params(const DexMethod* method) {
bool is_static_method = is_static(method);
const auto& signature = method->get_proto()->get_args()->get_type_list();
auto sig_it = signature.begin();
size_t load_insns_cnt = 0;
auto handle_instance =
[&](IRInstruction* insn) -> boost::optional<std::string> {
// Must be a param-object.
if (insn->opcode() != IOPCODE_LOAD_PARAM_OBJECT) {
return std::string(
"First parameter must be loaded with load-param-object: ") +
show(insn);
}
return boost::none;
};
auto handle_other = [&](IRInstruction* insn) -> boost::optional<std::string> {
if (sig_it == signature.end()) {
return std::string("Not enough argument types for ") + show(insn);
}
bool ok = false;
switch (insn->opcode()) {
case IOPCODE_LOAD_PARAM_OBJECT:
ok = type::is_object(*sig_it);
break;
case IOPCODE_LOAD_PARAM:
ok = type::is_primitive(*sig_it) && !type::is_wide_type(*sig_it);
break;
case IOPCODE_LOAD_PARAM_WIDE:
ok = type::is_primitive(*sig_it) && type::is_wide_type(*sig_it);
break;
default:
not_reached();
}
if (!ok) {
return std::string("Incompatible load-param ") + show(insn) + " for " +
type::type_shorty(*sig_it);
}
++sig_it;
return boost::none;
};
bool non_load_param_seen = false;
using handler_t = std::function<boost::optional<std::string>(IRInstruction*)>;
handler_t handler =
is_static_method ? handler_t(handle_other) : handler_t(handle_instance);
for (const auto& mie :
InstructionIterable(method->get_code()->cfg().entry_block())) {
IRInstruction* insn = mie.insn;
if (!opcode::is_a_load_param(insn->opcode())) {
non_load_param_seen = true;
continue;
}
++load_insns_cnt;
if (non_load_param_seen) {
return Result::make_error("Saw non-load-param instruction before " +
show(insn));
}
auto res = handler(insn);
if (res) {
return Result::make_error(res.get());
}
// Instance methods have an extra 'load-param' at the beginning for the
// instance object.
// Once we've checked that, though, the rest is the same so move on to
// using 'handle_other' in all cases.
handler = handler_t(handle_other);
}
size_t expected_load_params_cnt =
method->get_proto()->get_args()->size() + !is_static_method;
if (load_insns_cnt != expected_load_params_cnt) {
return Result::make_error(
"Number of existing load-param instructions (" + show(load_insns_cnt) +
") is lower than expected (" + show(expected_load_params_cnt) + ")");
}
return Result::Ok();
}
// Every variable created by a new-instance call should be initialized by a
// proper invoke-direct <init>. Here, we perform simple check to find some
// missing calls resulting in use of uninitialized variables. We correctly track
// variables in a basic block, the most common form of allocation+init.
Result check_uninitialized(const DexMethod* method) {
auto* code = method->get_code();
std::map<uint16_t, IRInstruction*> uninitialized_regs;
std::map<IRInstruction*, std::set<uint16_t>> uninitialized_regs_rev;
auto remove_from_uninitialized_list = [&](uint16_t reg) {
auto it = uninitialized_regs.find(reg);
if (it != uninitialized_regs.end()) {
uninitialized_regs_rev[it->second].erase(reg);
uninitialized_regs.erase(reg);
}
};
for (auto it = code->begin(); it != code->end(); ++it) {
if (it->type != MFLOW_OPCODE) {
continue;
}
auto* insn = it->insn;
auto op = insn->opcode();
if (op == OPCODE_NEW_INSTANCE) {
++it;
while (it != code->end() && it->type != MFLOW_OPCODE)
++it;
if (it == code->end() ||
it->insn->opcode() != IOPCODE_MOVE_RESULT_PSEUDO_OBJECT) {
auto prev = it;
prev--;
return Result::make_error("No opcode-move-result after new-instance " +
show(*prev) + " in \n" + show(code->cfg()));
}
auto reg_dest = it->insn->dest();
remove_from_uninitialized_list(reg_dest);
uninitialized_regs[reg_dest] = insn;
uninitialized_regs_rev[insn].insert(reg_dest);
continue;
}
if (opcode::is_a_move(op) && !opcode::is_move_result_any(op)) {
assert(insn->srcs().size() > 0);
auto src = insn->srcs()[0];
auto dest = insn->dest();
if (src == dest) continue;
auto it_src = uninitialized_regs.find(src);
// We no longer care about the old dest
remove_from_uninitialized_list(dest);
// But if src was uninitialized, dest is now too
if (it_src != uninitialized_regs.end()) {
uninitialized_regs[dest] = it_src->second;
uninitialized_regs_rev[it_src->second].insert(dest);
}
continue;
}
auto create_error = [&](const IRInstruction* instruction,
const IRCode* code) {
return Result::make_error("Use of uninitialized variable " +
show(instruction) + " detected at " +
show(*it) + " in \n" + show(code->cfg()));
};
if (op == OPCODE_INVOKE_DIRECT) {
auto const& sources = insn->srcs();
auto object = sources[0];
auto object_it = uninitialized_regs.find(object);
if (object_it != uninitialized_regs.end()) {
auto* object_ir = object_it->second;
if (insn->get_method()->get_name()->str() != "<init>") {
return create_error(object_ir, code);
}
if (insn->get_method()->get_class()->str() !=
object_ir->get_type()->str()) {
return Result::make_error("Variable " + show(object_ir) +
"initialized with the wrong type at " +
show(*it) + " in \n" + show(code->cfg()));
}
for (auto reg : uninitialized_regs_rev[object_ir]) {
uninitialized_regs.erase(reg);
}
uninitialized_regs_rev.erase(object_ir);
}
for (unsigned int i = 1; i < sources.size(); i++) {
auto u_it = uninitialized_regs.find(sources[i]);
if (u_it != uninitialized_regs.end())
return create_error(u_it->second, code);
}
continue;
}
auto const& sources = insn->srcs();
for (auto reg : sources) {
auto u_it = uninitialized_regs.find(reg);
if (u_it != uninitialized_regs.end())
return create_error(u_it->second, code);
}
if (insn->has_dest()) remove_from_uninitialized_list(insn->dest());
// We clear the structures after any branch, this doesn't cover all the
// possible issues, but is simple
auto branchingness = opcode::branchingness(op);
if (op == OPCODE_THROW ||
(branchingness != opcode::Branchingness::BRANCH_NONE &&
branchingness != opcode::Branchingness::BRANCH_THROW)) {
uninitialized_regs.clear();
uninitialized_regs_rev.clear();
}
}
return Result::Ok();
}
/*
* Do a linear pass to sanity-check the structure of the bytecode.
*/
Result check_structure(const DexMethod* method, bool check_no_overwrite_this) {
check_no_overwrite_this &= !is_static(method);
auto* code = method->get_code();
IRInstruction* this_insn = nullptr;
bool has_seen_non_load_param_opcode{false};
for (auto it = code->begin(); it != code->end(); ++it) {
// XXX we are using IRList::iterator instead of InstructionIterator here
// because the latter does not support reverse iteration
if (it->type != MFLOW_OPCODE) {
continue;
}
auto* insn = it->insn;
auto op = insn->opcode();
if (has_seen_non_load_param_opcode && opcode::is_a_load_param(op)) {
return Result::make_error("Encountered " + show(*it) +
" not at the start of the method");
}
has_seen_non_load_param_opcode = !opcode::is_a_load_param(op);
if (check_no_overwrite_this) {
if (op == IOPCODE_LOAD_PARAM_OBJECT && this_insn == nullptr) {
this_insn = insn;
} else if (insn->has_dest() && insn->dest() == this_insn->dest()) {
return Result::make_error(
"Encountered overwrite of `this` register by " + show(insn));
}
}
// The instruction immediately before a move-result instruction must be
// either an invoke-* or a filled-new-array instruction.
if (opcode::is_a_move_result(op)) {
auto prev = it;
while (prev != code->begin()) {
--prev;
if (prev->type == MFLOW_OPCODE) {
break;
}
}
if (it == code->begin() || prev->type != MFLOW_OPCODE) {
return Result::make_error("Encountered " + show(*it) +
" at start of the method");
}
auto prev_op = prev->insn->opcode();
if (!(opcode::is_an_invoke(prev_op) ||
opcode::is_filled_new_array(prev_op))) {
return Result::make_error(
"Encountered " + show(*it) +
" without appropriate prefix "
"instruction. Expected invoke or filled-new-array, got " +
show(prev->insn));
}
} else if (opcode::is_a_move_result_pseudo(insn->opcode()) &&
(it == code->begin() ||
!has_move_result_pseudo(*std::prev(it)))) {
return Result::make_error("Encountered " + show(*it) +
" without appropriate prefix "
"instruction");
} else if (insn->has_move_result_pseudo() &&
(it == code->end() || std::next(it) == code->end() ||
!is_move_result_pseudo(*std::next(it)))) {
return Result::make_error("Did not find move-result-pseudo after " +
show(*it) + " in \n" + show(code));
}
}
return check_uninitialized(method);
}
/**
* Validate if the caller has the permit to call a method or access a field.
*
* +-------------------------+--------+----------+-----------+-------+
* | Access Levels Modifier | Class | Package | Subclass | World |
* +-------------------------+--------+----------+-----------+-------+
* | public | Y | Y | Y | Y |
* | protected | Y | Y | Y | N |
* | no modifier | Y | Y | N | N |
* | private | Y | N | N | N |
* +-------------------------+--------+----------+-----------+-------+
*/
template <typename DexMember>
void validate_access(const DexMethod* accessor, const DexMember* accessee) {
auto accessor_class = accessor->get_class();
if (accessee == nullptr || is_public(accessee) ||
accessor_class == accessee->get_class()) {
return;
}
if (!is_private(accessee)) {
auto accessee_class = accessee->get_class();
auto from_same_package = type::same_package(accessor_class, accessee_class);
if (is_package_private(accessee) && from_same_package) {
return;
} else if (is_protected(accessee) &&
(from_same_package ||
type::check_cast(accessor_class, accessee_class))) {
return;
}
}
std::ostringstream out;
out << "\nillegal access to "
<< (is_private(accessee)
? "private "
: (is_package_private(accessee) ? "package-private "
: "protected "))
<< show_deobfuscated(accessee) << "\n from "
<< show_deobfuscated(accessor);
// If the accessee is external, we don't report the error, just log it.
// TODO(fengliu): We should enforce the correctness when visiting external dex
// members.
if (accessee->is_external()) {
TRACE(TYPE, 2, out.str().c_str());
return;
}
throw TypeCheckingException(out.str());
}
} // namespace
IRTypeChecker::~IRTypeChecker() {}
IRTypeChecker::IRTypeChecker(DexMethod* dex_method, bool validate_access)
: m_dex_method(dex_method),
m_validate_access(validate_access),
m_complete(false),
m_verify_moves(false),
m_check_no_overwrite_this(false),
m_good(true),
m_what("OK") {}
void IRTypeChecker::run() {
IRCode* code = m_dex_method->get_code();
if (m_complete) {
// The type checker can only be run once on any given method.
return;
}
if (code == nullptr) {
// If the method has no associated code, the type checking trivially
// succeeds.
m_complete = true;
return;
}
code->build_cfg(/* editable */ false);
auto result = check_structure(m_dex_method, m_check_no_overwrite_this);
if (result != Result::Ok()) {
m_complete = true;
m_good = false;
m_what = result.error_message();
return;
}
// We then infer types for all the registers used in the method.
const cfg::ControlFlowGraph& cfg = code->cfg();
// Check that the load-params match the signature.
auto params_result = check_load_params(m_dex_method);
if (params_result != Result::Ok()) {
m_complete = true;
m_good = false;
m_what = params_result.error_message();
return;
}
m_type_inference = std::make_unique<TypeInference>(cfg);
m_type_inference->run(m_dex_method);
// Finally, we use the inferred types to type-check each instruction in the
// method. We stop at the first type error encountered.
auto& type_envs = m_type_inference->get_type_environments();
for (const MethodItemEntry& mie : InstructionIterable(code)) {
IRInstruction* insn = mie.insn;
try {
auto it = type_envs.find(insn);
always_assert_log(
it != type_envs.end(), "%s in:\n%s", SHOW(mie), SHOW(code));
check_instruction(insn, &it->second);
} catch (const TypeCheckingException& e) {
m_good = false;
std::ostringstream out;
out << "Type error in method " << m_dex_method->get_deobfuscated_name()
<< " at instruction '" << SHOW(insn) << "' @ " << std::hex
<< static_cast<const void*>(&mie) << " for " << e.what();
m_what = out.str();
m_complete = true;
return;
}
}
m_complete = true;
if (traceEnabled(TYPE, 9)) {
std::ostringstream out;
m_type_inference->print(out);
TRACE(TYPE, 9, "%s", out.str().c_str());
}
}
void IRTypeChecker::assume_scalar(TypeEnvironment* state,
reg_t reg,
bool in_move) const {
assume_type(state,
reg,
/* expected */ SCALAR,
/* ignore_top */ in_move && !m_verify_moves);
}
void IRTypeChecker::assume_reference(TypeEnvironment* state,
reg_t reg,
bool in_move) const {
assume_type(state,
reg,
/* expected */ REFERENCE,
/* ignore_top */ in_move && !m_verify_moves);
}
void IRTypeChecker::assume_assignable(boost::optional<const DexType*> from,
DexType* to) const {
// There are some cases in type inference where we have to give up
// and claim we don't know anything about a dex type. See
// IRTypeCheckerTest.joinCommonBaseWithConflictingInterface, for
// example - the last invoke of 'base.foo()' after the blocks join -
// we no longer know anything about the type of the reference. It's
// in such a case as that that we have to bail out here when the from
// optional is empty.
if (from && !check_is_assignable_from(*from, to, false)) {
std::ostringstream out;
out << ": " << *from << " is not assignable to " << to << std::endl;
throw TypeCheckingException(out.str());
}
}
// This method performs type checking only: the type environment is not updated
// and the source registers of the instruction are checked against their
// expected types.
//
// Similarly, the various assume_* functions used throughout the code to check
// that the inferred type of a register matches with its expected type, as
// derived from the context.
void IRTypeChecker::check_instruction(IRInstruction* insn,
TypeEnvironment* current_state) const {
switch (insn->opcode()) {
case IOPCODE_LOAD_PARAM:
case IOPCODE_LOAD_PARAM_OBJECT:
case IOPCODE_LOAD_PARAM_WIDE: {
// IOPCODE_LOAD_PARAM_* instructions have been processed before the
// analysis.
break;
}
case OPCODE_NOP: {
break;
}
case OPCODE_MOVE: {
assume_scalar(current_state, insn->src(0), /* in_move */ true);
break;
}
case OPCODE_MOVE_OBJECT: {
assume_reference(current_state, insn->src(0), /* in_move */ true);
break;
}
case OPCODE_MOVE_WIDE: {
assume_wide_scalar(current_state, insn->src(0));
break;
}
case IOPCODE_MOVE_RESULT_PSEUDO:
case OPCODE_MOVE_RESULT: {
assume_scalar(current_state, RESULT_REGISTER);
break;
}
case IOPCODE_MOVE_RESULT_PSEUDO_OBJECT:
case OPCODE_MOVE_RESULT_OBJECT: {
assume_reference(current_state, RESULT_REGISTER);
break;
}
case IOPCODE_MOVE_RESULT_PSEUDO_WIDE:
case OPCODE_MOVE_RESULT_WIDE: {
assume_wide_scalar(current_state, RESULT_REGISTER);
break;
}
case OPCODE_MOVE_EXCEPTION: {
// We don't know where to grab the type of the just-caught exception.
// Simply set to j.l.Throwable here.
break;
}
case OPCODE_RETURN_VOID: {
break;
}
case OPCODE_RETURN: {
assume_scalar(current_state, insn->src(0));
break;
}
case OPCODE_RETURN_WIDE: {
assume_wide_scalar(current_state, insn->src(0));
break;
}
case OPCODE_RETURN_OBJECT: {
assume_reference(current_state, insn->src(0));
auto dtype = current_state->get_dex_type(insn->src(0));
auto rtype = m_dex_method->get_proto()->get_rtype();
// If the inferred type is a fallback, there's no point performing the
// accurate type assignment checking.
if (dtype && !is_inference_fallback_type(*dtype)) {
// Return type checking is non-strict: it is allowed to return any
// reference type when `rtype` is an interface.
if (!check_is_assignable_from(*dtype, rtype, /*strict=*/false)) {
std::ostringstream out;
out << "Returning " << dtype << ", but expected from declaration "
<< rtype << std::endl;
throw TypeCheckingException(out.str());
}
}
break;
}
case OPCODE_CONST: {
break;
}
case OPCODE_CONST_WIDE: {
break;
}
case OPCODE_CONST_STRING: {
break;
}
case OPCODE_CONST_CLASS: {
break;
}
case OPCODE_MONITOR_ENTER:
case OPCODE_MONITOR_EXIT: {
assume_reference(current_state, insn->src(0));
break;
}
case OPCODE_CHECK_CAST: {
assume_reference(current_state, insn->src(0));
break;
}
case OPCODE_INSTANCE_OF:
case OPCODE_ARRAY_LENGTH: {
assume_reference(current_state, insn->src(0));
break;
}
case OPCODE_NEW_INSTANCE: {
break;
}
case OPCODE_NEW_ARRAY: {
assume_integer(current_state, insn->src(0));
break;
}
case OPCODE_FILLED_NEW_ARRAY: {
const DexType* element_type =
type::get_array_component_type(insn->get_type());
// We assume that structural constraints on the bytecode are satisfied,
// i.e., the type is indeed an array type.
always_assert(element_type != nullptr);
bool is_array_of_references = type::is_object(element_type);
for (size_t i = 0; i < insn->srcs_size(); ++i) {
if (is_array_of_references) {
assume_reference(current_state, insn->src(i));
} else {
assume_scalar(current_state, insn->src(i));
}
}
break;
}
case OPCODE_FILL_ARRAY_DATA: {
break;
}
case OPCODE_THROW: {
assume_reference(current_state, insn->src(0));
break;
}
case OPCODE_GOTO: {
break;
}
case OPCODE_SWITCH: {
assume_integer(current_state, insn->src(0));
break;
}
case OPCODE_CMPL_FLOAT:
case OPCODE_CMPG_FLOAT: {
assume_float(current_state, insn->src(0));
assume_float(current_state, insn->src(1));
break;
}
case OPCODE_CMPL_DOUBLE:
case OPCODE_CMPG_DOUBLE: {
assume_double(current_state, insn->src(0));
assume_double(current_state, insn->src(1));
break;
}
case OPCODE_CMP_LONG: {
assume_long(current_state, insn->src(0));
assume_long(current_state, insn->src(1));
break;
}
case OPCODE_IF_EQ:
case OPCODE_IF_NE: {
assume_comparable(current_state, insn->src(0), insn->src(1));
break;
}
case OPCODE_IF_LT:
case OPCODE_IF_GE:
case OPCODE_IF_GT:
case OPCODE_IF_LE: {
assume_integer(current_state, insn->src(0));
assume_integer(current_state, insn->src(1));
break;
}
case OPCODE_IF_EQZ:
case OPCODE_IF_NEZ: {
assume_comparable_with_zero(current_state, insn->src(0));
break;
}
case OPCODE_IF_LTZ:
case OPCODE_IF_GEZ:
case OPCODE_IF_GTZ:
case OPCODE_IF_LEZ: {
assume_integer(current_state, insn->src(0));
break;
}
case OPCODE_AGET: {
assume_reference(current_state, insn->src(0));
assume_integer(current_state, insn->src(1));
break;
}
case OPCODE_AGET_BOOLEAN:
case OPCODE_AGET_BYTE:
case OPCODE_AGET_CHAR:
case OPCODE_AGET_SHORT: {
assume_reference(current_state, insn->src(0));
assume_integer(current_state, insn->src(1));
break;
}
case OPCODE_AGET_WIDE: {
assume_reference(current_state, insn->src(0));
assume_integer(current_state, insn->src(1));
break;
}
case OPCODE_AGET_OBJECT: {
assume_reference(current_state, insn->src(0));
assume_integer(current_state, insn->src(1));
break;
}
case OPCODE_APUT: {
assume_scalar(current_state, insn->src(0));
assume_reference(current_state, insn->src(1));
assume_integer(current_state, insn->src(2));
break;
}
case OPCODE_APUT_BOOLEAN:
case OPCODE_APUT_BYTE:
case OPCODE_APUT_CHAR:
case OPCODE_APUT_SHORT: {
assume_integer(current_state, insn->src(0));
assume_reference(current_state, insn->src(1));
assume_integer(current_state, insn->src(2));
break;
}
case OPCODE_APUT_WIDE: {
assume_wide_scalar(current_state, insn->src(0));
assume_reference(current_state, insn->src(1));
assume_integer(current_state, insn->src(2));
break;
}
case OPCODE_APUT_OBJECT: {
assume_reference(current_state, insn->src(0));
assume_reference(current_state, insn->src(1));
assume_integer(current_state, insn->src(2));
break;
}
case OPCODE_IGET: {
assume_reference(current_state, insn->src(0));
break;
}
case OPCODE_IGET_BOOLEAN:
case OPCODE_IGET_BYTE:
case OPCODE_IGET_CHAR:
case OPCODE_IGET_SHORT: {
assume_reference(current_state, insn->src(0));
break;
}
case OPCODE_IGET_WIDE: {
assume_reference(current_state, insn->src(0));
break;
}
case OPCODE_IGET_OBJECT: {
assume_reference(current_state, insn->src(0));
always_assert(insn->has_field());
const auto f_cls = insn->get_field()->get_class();
assume_assignable(current_state->get_dex_type(insn->src(0)), f_cls);
break;
}
case OPCODE_IPUT: {
const DexType* type = insn->get_field()->get_type();
if (type::is_float(type)) {
assume_float(current_state, insn->src(0));
} else {
assume_integer(current_state, insn->src(0));
}
assume_reference(current_state, insn->src(1));
break;
}
case OPCODE_IPUT_BOOLEAN:
case OPCODE_IPUT_BYTE:
case OPCODE_IPUT_CHAR:
case OPCODE_IPUT_SHORT: {
assume_integer(current_state, insn->src(0));
assume_reference(current_state, insn->src(1));
break;
}
case OPCODE_IPUT_WIDE: {
assume_wide_scalar(current_state, insn->src(0));
assume_reference(current_state, insn->src(1));
break;
}
case OPCODE_IPUT_OBJECT: {
assume_reference(current_state, insn->src(0));
assume_reference(current_state, insn->src(1));
always_assert(insn->has_field());
const auto f_type = insn->get_field()->get_type();
assume_assignable(current_state->get_dex_type(insn->src(0)), f_type);
const auto f_cls = insn->get_field()->get_class();
assume_assignable(current_state->get_dex_type(insn->src(1)), f_cls);
break;
}
case OPCODE_SGET: {
break;
}
case OPCODE_SGET_BOOLEAN:
case OPCODE_SGET_BYTE:
case OPCODE_SGET_CHAR:
case OPCODE_SGET_SHORT: {
break;
}
case OPCODE_SGET_WIDE: {
break;
}
case OPCODE_SGET_OBJECT: {
break;
}
case OPCODE_SPUT: {
const DexType* type = insn->get_field()->get_type();
if (type::is_float(type)) {
assume_float(current_state, insn->src(0));
} else {
assume_integer(current_state, insn->src(0));
}
break;
}
case OPCODE_SPUT_BOOLEAN:
case OPCODE_SPUT_BYTE:
case OPCODE_SPUT_CHAR:
case OPCODE_SPUT_SHORT: {
assume_integer(current_state, insn->src(0));
break;
}
case OPCODE_SPUT_WIDE: {
assume_wide_scalar(current_state, insn->src(0));
break;
}
case OPCODE_SPUT_OBJECT: {
assume_reference(current_state, insn->src(0));
break;
}
case OPCODE_INVOKE_CUSTOM:
case OPCODE_INVOKE_POLYMORPHIC:
case OPCODE_INVOKE_VIRTUAL:
case OPCODE_INVOKE_SUPER:
case OPCODE_INVOKE_DIRECT:
case OPCODE_INVOKE_STATIC:
case OPCODE_INVOKE_INTERFACE: {
DexMethodRef* dex_method = insn->get_method();
const auto& arg_types =
dex_method->get_proto()->get_args()->get_type_list();
size_t expected_args =
(insn->opcode() != OPCODE_INVOKE_STATIC ? 1 : 0) + arg_types.size();
if (insn->srcs_size() != expected_args) {
std::ostringstream out;
out << SHOW(insn) << ": argument count mismatch; "
<< "expected " << expected_args << ", "
<< "but found " << insn->srcs_size() << " instead";
throw TypeCheckingException(out.str());
}
size_t src_idx{0};
if (insn->opcode() != OPCODE_INVOKE_STATIC) {
// The first argument is a reference to the object instance on which the
// method is invoked.
auto src = insn->src(src_idx++);
assume_reference(current_state, src);
assume_assignable(current_state->get_dex_type(src),
dex_method->get_class());
}
for (DexType* arg_type : arg_types) {
if (type::is_object(arg_type)) {
auto src = insn->src(src_idx++);
assume_reference(current_state, src);
assume_assignable(current_state->get_dex_type(src), arg_type);
continue;
}
if (type::is_integer(arg_type)) {
assume_integer(current_state, insn->src(src_idx++));
continue;
}
if (type::is_long(arg_type)) {
assume_long(current_state, insn->src(src_idx++));
continue;
}
if (type::is_float(arg_type)) {
assume_float(current_state, insn->src(src_idx++));
continue;
}
always_assert(type::is_double(arg_type));
assume_double(current_state, insn->src(src_idx++));
}
if (m_validate_access) {
auto resolved =
resolve_method(dex_method, opcode_to_search(insn), m_dex_method);
validate_access(m_dex_method, resolved);
}
break;
}
case OPCODE_NEG_INT:
case OPCODE_NOT_INT: {
assume_integer(current_state, insn->src(0));
break;
}
case OPCODE_NEG_LONG:
case OPCODE_NOT_LONG: {
assume_long(current_state, insn->src(0));
break;
}
case OPCODE_NEG_FLOAT: {
assume_float(current_state, insn->src(0));
break;
}
case OPCODE_NEG_DOUBLE: {
assume_double(current_state, insn->src(0));
break;
}
case OPCODE_INT_TO_BYTE:
case OPCODE_INT_TO_CHAR:
case OPCODE_INT_TO_SHORT: {
assume_integer(current_state, insn->src(0));
break;
}
case OPCODE_LONG_TO_INT: {
assume_long(current_state, insn->src(0));
break;
}
case OPCODE_FLOAT_TO_INT: {
assume_float(current_state, insn->src(0));
break;
}
case OPCODE_DOUBLE_TO_INT: {
assume_double(current_state, insn->src(0));
break;
}
case OPCODE_INT_TO_LONG: {
assume_integer(current_state, insn->src(0));
break;
}
case OPCODE_FLOAT_TO_LONG: {
assume_float(current_state, insn->src(0));
break;
}
case OPCODE_DOUBLE_TO_LONG: {
assume_double(current_state, insn->src(0));
break;
}
case OPCODE_INT_TO_FLOAT: {
assume_integer(current_state, insn->src(0));
break;
}
case OPCODE_LONG_TO_FLOAT: {
assume_long(current_state, insn->src(0));
break;
}
case OPCODE_DOUBLE_TO_FLOAT: {
assume_double(current_state, insn->src(0));
break;
}
case OPCODE_INT_TO_DOUBLE: {
assume_integer(current_state, insn->src(0));
break;
}
case OPCODE_LONG_TO_DOUBLE: {
assume_long(current_state, insn->src(0));
break;
}
case OPCODE_FLOAT_TO_DOUBLE: {
assume_float(current_state, insn->src(0));
break;
}
case OPCODE_ADD_INT:
case OPCODE_SUB_INT:
case OPCODE_MUL_INT:
case OPCODE_AND_INT:
case OPCODE_OR_INT:
case OPCODE_XOR_INT:
case OPCODE_SHL_INT:
case OPCODE_SHR_INT:
case OPCODE_USHR_INT: {
assume_integer(current_state, insn->src(0));
assume_integer(current_state, insn->src(1));
break;
}
case OPCODE_DIV_INT:
case OPCODE_REM_INT: {
assume_integer(current_state, insn->src(0));
assume_integer(current_state, insn->src(1));
break;
}
case OPCODE_ADD_LONG:
case OPCODE_SUB_LONG:
case OPCODE_MUL_LONG:
case OPCODE_AND_LONG:
case OPCODE_OR_LONG:
case OPCODE_XOR_LONG: {
assume_long(current_state, insn->src(0));
assume_long(current_state, insn->src(1));
break;
}
case OPCODE_DIV_LONG:
case OPCODE_REM_LONG: {
assume_long(current_state, insn->src(0));
assume_long(current_state, insn->src(1));
break;
}
case OPCODE_SHL_LONG:
case OPCODE_SHR_LONG:
case OPCODE_USHR_LONG: {
assume_long(current_state, insn->src(0));
assume_integer(current_state, insn->src(1));
break;
}
case OPCODE_ADD_FLOAT:
case OPCODE_SUB_FLOAT:
case OPCODE_MUL_FLOAT:
case OPCODE_DIV_FLOAT:
case OPCODE_REM_FLOAT: {
assume_float(current_state, insn->src(0));
assume_float(current_state, insn->src(1));
break;
}
case OPCODE_ADD_DOUBLE:
case OPCODE_SUB_DOUBLE:
case OPCODE_MUL_DOUBLE:
case OPCODE_DIV_DOUBLE:
case OPCODE_REM_DOUBLE: {
assume_double(current_state, insn->src(0));
assume_double(current_state, insn->src(1));
break;
}
case OPCODE_ADD_INT_LIT16:
case OPCODE_RSUB_INT:
case OPCODE_MUL_INT_LIT16:
case OPCODE_AND_INT_LIT16:
case OPCODE_OR_INT_LIT16:
case OPCODE_XOR_INT_LIT16:
case OPCODE_ADD_INT_LIT8:
case OPCODE_RSUB_INT_LIT8:
case OPCODE_MUL_INT_LIT8:
case OPCODE_AND_INT_LIT8:
case OPCODE_OR_INT_LIT8:
case OPCODE_XOR_INT_LIT8:
case OPCODE_SHL_INT_LIT8:
case OPCODE_SHR_INT_LIT8:
case OPCODE_USHR_INT_LIT8: {
assume_integer(current_state, insn->src(0));
break;
}
case OPCODE_DIV_INT_LIT16:
case OPCODE_REM_INT_LIT16:
case OPCODE_DIV_INT_LIT8:
case OPCODE_REM_INT_LIT8: {
assume_integer(current_state, insn->src(0));
break;
}
}
if (insn->has_field() && m_validate_access) {
auto search = opcode::is_an_sfield_op(insn->opcode())
? FieldSearch::Static
: FieldSearch::Instance;
auto resolved = resolve_field(insn->get_field(), search);
validate_access(m_dex_method, resolved);
}
}
IRType IRTypeChecker::get_type(IRInstruction* insn, reg_t reg) const {
check_completion();
auto& type_envs = m_type_inference->get_type_environments();
auto it = type_envs.find(insn);
if (it == type_envs.end()) {
// The instruction doesn't belong to this method. We treat this as
// unreachable code and return BOTTOM.
return BOTTOM;
}
return it->second.get_type(reg).element();
}
boost::optional<const DexType*> IRTypeChecker::get_dex_type(IRInstruction* insn,
reg_t reg) const {
check_completion();
auto& type_envs = m_type_inference->get_type_environments();
auto it = type_envs.find(insn);
if (it == type_envs.end()) {
// The instruction doesn't belong to this method. We treat this as
// unreachable code and return BOTTOM.
return nullptr;
}
return it->second.get_dex_type(reg);
}
std::ostream& operator<<(std::ostream& output, const IRTypeChecker& checker) {
checker.m_type_inference->print(output);
return output;
}
| [
"facebook-github-bot@users.noreply.github.com"
] | facebook-github-bot@users.noreply.github.com |
b2e1cbcebd1d92f848008e00f66085c11a7f2d3e | ff64500dbd41735f267ab5d1f0124425edc8f2ce | /ESP32-drone/src/Drone.h | 06f03698b025b6e3d4f31c8210cd9bbfe85c097b | [] | no_license | MarziehJ/IDS_ESP32_Drone_1 | 0ee9c2e9037fa10c03e79b9e0dfcad4944d60315 | 5a1a6ee1585dbeb3421e001cf0d51b5c3ad94284 | refs/heads/main | 2022-12-29T23:34:30.879103 | 2020-10-14T11:31:17 | 2020-10-14T11:31:17 | 303,991,929 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,185 | h | #ifndef Drone_h
#define Drone_h
#include "Arduino.h"
#include "Joystick.h"
#include "Button.h"
#include "Lcd.h"
#include "led.h"
#include "AsyncUDP.h"
class Drone
{
public:
Drone(int xJoyPin, int yJoyPin, int buttonPin, int ledPin, uint8_t lcd_addr)
{
this->joystick = new Joystick(xJoyPin, xJoyPin);
this->button = new Button(buttonPin);
this->lcd = new Lcd(lcd_addr);
this->led = new Led(ledPin);
}
bool droneIsOn() { return this->led->state; }
void sendCommand(String msg)
{
////PixelEmulator
udp.writeTo((const uint8_t *)msg.c_str(),
msg.length(),
IPAddress(192, 168, 1, 39),
7000);
//Real Drone
// udp.writeTo((const uint8_t *)msg.c_str(),
// msg.length(),
// IPAddress(192, 168, 10, 1),
// 7000);
this->lcd->WriteMessage(msg);
Serial.println(msg);
}
void ChangeStatus()
{
if (droneIsOn())
{
StopDrone();
}
else
{
InitDrone();
}
}
void Move(std::pair<int, int> xy)
{
bool isMoving = this->joystick->isInDeadzone() == false;
if (isMoving)
{
Serial.println("Joystick Moving");
MoveDrone(xy);
}
}
Joystick *joystick;
Button *button;
private:
Lcd *lcd;
Led *led;
AsyncUDP udp;
void StopDrone()
{
//PixelEmulator
sendCommand("stop");
//Real Drone
//sendCommand("land");
this->led->off();
Serial.println(led->status());
}
void InitDrone()
{
//PixelEmulator
sendCommand("init 100 100");
//Real Drone
//sendCommand("command");
//sendCommand("takeoff");
this->led->on();
Serial.println(led->status());
}
void MoveDrone(std::pair<int, int> xy)
{
//PixelEmulator
Serial.print("X: ");
Serial.println(xy.first);
Serial.print("Y: ");
Serial.println(xy.second);
if (xy.first + xy.second <= 3500)
{
//PixelEmulator
sendCommand("moveleft");
//Real Drone
//sendCommand("left 1");
}
else
{
//PixelEmulator
sendCommand("moveright");
//Real Drone
//sendCommand("right 1");
}
}
};
#endif | [
"MarziJoukar@gmail.com"
] | MarziJoukar@gmail.com |
b18a4505f447fb39f38d64dda1c8059d8673ec04 | 06c0b8471fd49970752e9e77f58e454194ec5b10 | /DirectX_3D_v9_Framework_JCS/DirectX SDK/utilities/Source/Sas/Effect10.h | 5a5b45999540ae0f2c02f74b174c60752901ac53 | [
"MIT"
] | permissive | jcs090218/JCSCC_Engine | fd93b630b70c9fb8ead719bb474eef0b69a915d1 | eac6c55203bd804acb439305ff977cfca9365e1e | refs/heads/master | 2021-06-04T01:01:46.893887 | 2020-06-14T05:37:38 | 2020-06-14T05:37:38 | 102,942,649 | 4 | 2 | null | null | null | null | UTF-8 | C++ | false | false | 1,633 | h | #pragma once
#include "stdafx.h"
#include "D3D10_1.h"
#include "d3d10.h"
#include "d3dx10.h"
#include "Parameter.h"
#include "Effect.h"
namespace Sas
{
class Effect10 : public Effect
{
public:
virtual ~Effect10();
static HRESULT FromD3DEffect( ID3D10Effect* pD3DEffect, const SourceInfo& sf, Effect10** ppEffectOut );
static HRESULT FromSource( ID3D10Device* pDevice, const SourceInfo& sf, const D3D10_SHADER_MACRO* pDefines, ID3D10Include* pInclude, DWORD HlslFlags, DWORD FxFlags, Effect10** ppEffectOut );
virtual HRESULT LoadTexture( const WCHAR* file, IUnknown** texture);
ID3D10Effect* GetD3DEffect(){ return m_pD3DEffect; }
protected:
// Private constructor
Effect10() : Effect()
{
m_pD3DEffect = NULL;
}
ID3D10Effect* m_pD3DEffect;
};
class Variable10 : public Variable
{
public:
Variable10( ID3D10EffectVariable* pD3DEffectVariable, Effect* effect, Variable* parent = NULL, UINT index = 0);
protected:
virtual HRESULT GetScalar_Internal( Scalar* pScalar ) const;
virtual HRESULT GetVector_Internal( Vector* pVector ) const;
virtual HRESULT GetMatrix_Internal( Matrix* pMatrix ) const;
virtual HRESULT GetObject_Internal( Object* pObject ) const;
virtual HRESULT SetScalar_Internal( Scalar* pScalar );
virtual HRESULT SetVector_Internal( Vector* pVector );
virtual HRESULT SetMatrix_Internal( Matrix* pMatrix );
virtual HRESULT SetObject_Internal( Object* pObject );
virtual HRESULT SpecializedCasts( Value* pCached, const Value& value );
ID3D10EffectVariable* m_pD3DEffectVariable;
};
} | [
"lkk440456@gmail.com"
] | lkk440456@gmail.com |
b073baf3aa5bec369f14baca71eee0d81cd279fe | 934996b31ada702a7f2d327de1e0c14d9cef9e7a | /ChoudhryBilal00326_Assignment3/main.cpp | bd48a312f2159ab1f401f8233940133a19426f4f | [] | no_license | choudhrybilal/OOP-CS224 | 0a537951f5a1ddca1cc8d649e7b2a691cdc1c116 | 48d5f5d6dd66f52f4be10bf3a71218bc83acf02f | refs/heads/master | 2020-03-19T09:45:59.852195 | 2018-07-23T07:56:57 | 2018-07-23T07:56:57 | 136,315,855 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 8,602 | cpp | /*
Habib University, Summer Semester 2018,
Object Oriented Programming & Design Methodologies(CS224),
Assignment # 03; Package Delivery System.
Instructor: Dr. Umair Azfar Khan
TA: Ahmed Ali(aa02190)
Choudhry Bilal Mazhar (cm00326)
*/
#include <iostream>
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
#include <string.h>
using namespace std;
class Box
{
int length;
int width;
int height;
int volume;
public: //public functions
Box() //Constructor
{
length = 5 + (rand() % 26); //length between 5 and 30 inches
width = 5 + (rand() % 26); //width between 5 and 30 inches
height = 5 + (rand() % 26); //height between 5 and 30 inches
}
void Volume() //calculates the volume of each box
{
volume = length * width * height;
}
int get_volume() //returns the volume of the box
{
return volume;
}
};
class Truck
{
char driver[32];
int petrol;
int money;
int loaded_mileage;
int empty_mileage;
float total_journey;
float cost_per_litre;
float max_petrol;
Box *array_box; //initializing boxes array
public: //public functions
Truck() //Constructor
{
total_journey = 60; //distance of the journey
cost_per_litre = 2.73; //cost for one liter of petrol
max_petrol = 50; //tank limit
}
void set_driver(char d[32]) //acceses the name of the driver from main and sets it here
{
strcpy(driver, d); //character array d is copied to driver
}
string get_driver() //returns the name of the driver
{
return driver;
}
void set_petrol(int p) //acceses the value of petrol from main and sets it
{
petrol = p;
}
int get_petrol()
{
return petrol;
}
void set_money(int m)
{
money = m;
}
int get_money()
{
return money;
}
void set_e_mileage(int e_mileage)
{
empty_mileage = e_mileage;
}
int get_e_mileage()
{
return empty_mileage;
}
void set_l_mileage(int l_mileage)
{
loaded_mileage = l_mileage;
}
int get_l_mileage()
{
return loaded_mileage;
}
int checker() //checks whether the truck has enough money to go and deliver packages
{
int up;
float money_needed;
if (petrol < 50) //checks if the driver has less than 50 liters of petrol
{
up = max_petrol - petrol; //amount of liters needed
money_needed = up * cost_per_litre; //the amount of money needed to fill the tank
if(money_needed > money) //if the amount of money needed is greater than the money the driver has then this truck can't go
{
cout << "The money needed to fill the tank is $" << money_needed << " and the driver initially has $ " << money << endl;
return 0;
}
else //if the driver has enough cash to fill the tank then he can go
{
petrol = petrol + up; //fills the tank to 50 litres
cout << "\nThe money needed to fill the tank is $ " << money_needed << " and the driver initially has $ " << money << endl;
money = money - money_needed; //the cash needed to fill the tank is subtracted from the initial money
return 1;
}
}
return 0;
}
void print() //function prints out the updated details of the truck's driver
{
cout << "\n----->>> Driver is good to go!" << endl;
cout << "-----> Updated Details: " <<endl;
cout << "\n*******************************************" <<endl;
cout << "Truck driver name: " << driver <<endl;
cout << "Truck's petrol: " << petrol<<" liters"<<endl;
cout << "Truck driver's money: $ " << money <<endl;
cout << "Truck's mileage when loaded: " << loaded_mileage<<" km"<<endl;
cout << "Truck's mileage when empty: " << empty_mileage<<" km\n"<<endl;
}
void Load(int numBox) //loads boxes into the truck
{
array_box = new Box[numBox];
for (int i = 0; i < numBox; i++)
{
Box b;
b.Volume(); //stores the volume
array_box[i] = b;
cout << "Volume of box " << i + 1 << ": " << array_box[i].get_volume() << " cubic inches" << endl;
}
}
void Unload() //unloads boxes from the truck
{
delete[] array_box; //deallocates the array
}
float Cost() //calculates the total cost for the complete journey
{
float lit, total, lit1;
lit = (total_journey/loaded_mileage) * cost_per_litre; //money needed for going
lit1 = (total_journey/empty_mileage) * cost_per_litre; //money needed for coming back
total = lit + lit1; //total cost for the journey
cout << "\nThe total cost of the journey is $ " << total << endl;
return total;
}
};
int line_counter(const char* fileName) //tells the number of lines needed
{
FILE* file_pointer; //Declaring a file pointer
char buff[32]; //Declaring a character array to store a line
file_pointer = fopen(fileName, "r"); //Opening file as read only
if (file_pointer == NULL) //If file is not found
{
perror ("Error opening file"); //Show Error
return 0;
}
int counter = 0; //Counts the lines in file
while(fgets(buff, 32, (FILE*)file_pointer) !=NULL) //If line read is not NULL
{
counter++; //increase line count
}
fclose(file_pointer); //close file when done
return counter; //return line count
}
int main()
{
srand(time(0));
FILE* file_pointer; //Declaring a file pointer
file_pointer = fopen("Drivers.txt", "r"); //Opening file as read only
int count = line_counter("Drivers.txt");
int count1 = count/5; //since each driver has 5 lines of info
Truck *array_truck;
if (file_pointer == NULL)
{
perror ("Error opening file");
return 0;
}
array_truck = new Truck[count1];
cout <<" PACKAGE DELIVERY SYSTEM\n"<<endl;
for (int i = 0; i < count1; i++)
{
cout <<"----------------------------------------("<<i+1<<")----------------------------------------"<<endl;
Truck t; //creating an object
char buff[32]; //Declaring a character array to store a line
fgets(buff, 32, (FILE*)file_pointer); //Reading the name of the driver directly
t.set_driver(buff);
fgets(buff, 32, (FILE*)file_pointer); //Reading the next line as string
t.set_petrol(atoi(buff)); //Converting the string to integer
fgets(buff, 32, (FILE*)file_pointer);
t.set_money(atoi(buff));
fgets(buff, 32, (FILE*)file_pointer);
t.set_e_mileage(atoi(buff));
fgets(buff, 32, (FILE*)file_pointer);
t.set_l_mileage(atoi(buff));
cout << "Truck driver name: " << t.get_driver() <<endl;
cout << "Truck's petrol: " << t.get_petrol() <<" liters"<<endl;
cout << "Truck driver's money: $ " << t.get_money() <<endl;
cout << "Truck's mileage when loaded: " << t.get_l_mileage() <<" km"<<endl;
cout << "Truck's mileage when empty: " << t.get_e_mileage() <<" km"<<endl;
int random_boxes = 12 + (rand() % 9); //random packages between 12 to 20
if (t.checker() == 1) //checks if the driver has enough money to go
{
t.print();
cout << random_boxes << " Packages have been loaded on the truck:\n" << endl;
t.Load(random_boxes);
t.Unload();
cout << "\nThe truck has been unloaded!" << endl;
t.Cost();
cout << endl;
}
else //if the checker function returns 0 then that truck can't go
{
cout << "\n----->>> This truck can't go!\n" << endl;
}
array_truck[i] = t;
}
delete [] array_truck; // deallocating array of truck
fclose(file_pointer); //Closing file
return 0;
}
| [
"39990031+choudhrybilal@users.noreply.github.com"
] | 39990031+choudhrybilal@users.noreply.github.com |
0c2100c10f4494c9a931f302981aeb94a72e6e70 | 977f76a33d3d7391373178ebdde59a5e4452e523 | /Framework/PVRCore/IndexedArray.h | 254641f5c5ce1d2d1754b268c305dc1b0de438bf | [
"MIT"
] | permissive | rcdailey/Native_SDK | 7562f44d3254f5099c8e466759bae91fe531d50f | dfb214db150f67c59ae24123e46a0f5e5149eaea | refs/heads/master | 2020-04-14T21:19:01.847213 | 2019-05-24T13:55:37 | 2019-05-24T13:55:37 | 164,124,382 | 0 | 0 | null | 2019-01-04T15:34:46 | 2019-01-04T15:34:46 | null | UTF-8 | C++ | false | false | 25,896 | h | /*!*********************************************************************************************************************
\file PVRCore\IndexedArray.h
\author PowerVR by Imagination, Developer Technology Team.
\copyright Copyright (c) Imagination Technologies Limited.
\brief Implementation of a special kind of map that stores the data in a linear, contiguous store (std::vector interface),
but additionally contains an Index to them (std::map interface). Supports custom association of names with
values, and retrieval of indexes by name or values by index.
***********************************************************************************************************************/
#pragma once
#include <vector>
#include <map>
#include <list>
#include <algorithm>
namespace pvr {
/*!*********************************************************************************************************************
\brief A combination of array (std::vector) with associative container (std::map). Supports association of names
with values, and retrieval by index.
\description An std::vector style array class with the additional feature of associating "names" (IndexType_, std::string
by default) with the values stored. Keys are of type IndexType_, correspond to vector position 1:1, so that each vector position
("index") is associated with a "key", and only one key.
Use: Add pairs of values with insert(key, value).
Retrieve indices by key, using getIndex(key) -- O(logn)
Retrieve values by index, using indexing operator [] -- O(1)
The remove() function destroys the items on which it was called, but a default-constructed object will still exist. Performing
insert() after removing an item will use the place of a previously deleted item, if it exists.
CAUTION: If remove() has been called, the vector no longer guarantees contiguousness until compact() is called.
CAUTION: To manually reclaim all memory and guarantee contiguous allocation, call compact(). Calling compact invalidates all
indexes, which must then be retrieved anew by "getInxdex".
Calling getIndex on an unknown key returns (size_t)(-1)
Accessing an unknown item by index is undefined.
Accessing an index not retrieved by getIndex since the last compact() operation is undefined.
***********************************************************************************************************************/
template<typename ValueType_, typename IndexType_ = std::string>
class IndexedArray
{
private:
struct DictionaryEntry
{
ValueType_ value;
IndexType_ key;
DictionaryEntry() {}
DictionaryEntry(const IndexType_& key, const ValueType_& value) : key(key), value(value) { }
};
struct StorageItem_ : DictionaryEntry
{
bool isUnused;
StorageItem_() {}
StorageItem_(const IndexType_& key, const ValueType_& value) : DictionaryEntry(key, value), isUnused(false) { }
};
typedef std::vector<StorageItem_> vectortype_;
typedef typename std::map<IndexType_, size_t> maptype_;
typedef std::list<size_t> deleteditemlisttype_;
vectortype_ mystorage;
maptype_ myindex;
deleteditemlisttype_ myDeletedItems;
public:
/*!*********************************************************************************************************************
\brief An (modifiable) Linear iterator of the IndexedArray class. Will linearly iterate the backing store skipping empy
spots. Unordered.
***********************************************************************************************************************/
class iterator
{
friend class IndexedArray<ValueType_, IndexType_>;
class const_iterator;
StorageItem_* start;
size_t current;
size_t size; // required for out-of-bounds checks when skipping empty...
iterator(StorageItem_* start, size_t size, size_t current = 0) : start(start), current(current), size(size){ }
public:
iterator(const const_iterator& rhs) : start(rhs.start), size(rhs.size), current(rhs.current){ }
/*!
\brief operator *
\return Return this
*/
DictionaryEntry& operator*() { return *(start + current); }
/*!
\brief operator ->
\return Return this
*/
DictionaryEntry* operator->(){ return (start + current); }
/*!
\brief Get current index
*/
size_t getItemIndex() { return current; }
/*!
\brief operator ++
\return
*/
iterator& operator++()
{
while ((start + (++current))->isUnused && current != size) {} //skip empty values
return *this;
}
/*!
\brief operator ++
\return
*/
iterator operator++(int)
{
iterator ret = *this;
while ((start + (++current))->isUnused && current != size) {} //skip empty values
++(*this);
return ret;
}
/*!
\brief operator --
\return
*/
iterator& operator--()
{
while ((start + (--current))->isUnused
&& current != static_cast<size_t>(-1)) {} //CAREFUL! this is a size_t, which means it WILL eventually overflow.
return *this;
}
/*!
\brief operator --
\return
*/
iterator operator--(int)
{
iterator ret = *this;
--(*this);
return ret;
}
/*!
\brief operator !=
\param rhs
\return
*/
bool operator!=(const iterator& rhs)
{
return this->current != rhs.current;
}
/*!
\brief operator ==
\param rhs
\return
*/
bool operator==(const iterator& rhs)
{
return !((*this) != rhs);
}
};
/*!*********************************************************************************************************************
\brief An (constant) Linear iterator of the IndexedArray class. Will linearly iterate the backing store skipping empy
spots. Unordered.
***********************************************************************************************************************/
class const_iterator
{
friend class IndexedArray<ValueType_, IndexType_>;
const StorageItem_* start;
size_t current;
size_t size; // required for out-of-bounds checks when skipping empty...
const_iterator(const StorageItem_* start, size_t size, size_t current = 0) : start(start), size(size), current(current) { }
public:
const DictionaryEntry& operator*()
{
return *(start + current);
}
const DictionaryEntry* operator->()
{
return (start + current);
}
size_t getItemIndex()
{
return current;
}
const_iterator& operator++()
{
while (++current < size && (start + current)->isUnused) {} //skip empty values
return *this;
}
const_iterator operator++(int)
{
const_iterator ret = *this;
++(*this);
return ret;
}
const_iterator& operator--()
{
while (--current != static_cast<size_t>(-1) && (start + current)->isUnused) {} //CAREFUL! this is a size_t, which means it WILL eventually overflow.
return *this;
}
const_iterator operator--(int)
{
iterator ret = *this;
--(*this);
return ret;
}
bool operator!=(const const_iterator& rhs)
{
return this->current != rhs.current;
}
bool operator==(const const_iterator& rhs)
{
return !((*this) != rhs);
}
};
/*!*********************************************************************************************************************
\brief An Indexed iterator of the IndexedArray class. Will follow the indexing map of the IndexedArray iterating items
in their Indexing order.
***********************************************************************************************************************/
typedef typename maptype_::iterator index_iterator;
/*!*********************************************************************************************************************
\brief An Indexed (Constant) iterator of the IndexedArray class. Will follow the indexing map of the IndexedArray
iterating items in their Indexing order.
***********************************************************************************************************************/
typedef typename maptype_::const_iterator const_index_iterator;
/*!*********************************************************************************************************************
\brief Return a Linear iterator to the first non-deleted item in the backing store.
***********************************************************************************************************************/
iterator begin()
{
if (!mystorage.empty())
{
iterator ret(&mystorage.front(), mystorage.size());
while ((ret.start + ret.current)->isUnused && (ret.current != ret.size))
{
++ret.current;
} //skip empty values
return ret;
}
else
{
return iterator(NULL, 0);
}
}
/*!*********************************************************************************************************************
\brief Return a Linear const_iterator to the first non-deleted item in the backing store.
***********************************************************************************************************************/
const_iterator begin() const
{
if (!mystorage.empty())
{
const_iterator ret(&mystorage.front(), mystorage.size());
while ((ret.start + ret.current)->isUnused && ret.current != ret.size) { ++ret.current; } //skip empty values
return ret;
}
else
{
return const_iterator(NULL, 0);
}
}
/*!*********************************************************************************************************************
\brief Return an indexed_iterator by finding the provided key Indexing map.
***********************************************************************************************************************/
typename maptype_::iterator indexed_find(const IndexType_& key)
{
return myindex.find(key);
}
/*!*********************************************************************************************************************
\brief Return an indexed_iterator by finding the provided key Indexing map.
***********************************************************************************************************************/
typename maptype_::const_iterator indexed_find(const IndexType_& key)const
{
return myindex.find(key);
}
/*!*********************************************************************************************************************
\brief Return an indexed_const_iterator to the first item in the map.
***********************************************************************************************************************/
typename maptype_::iterator indexed_begin()
{
return myindex.begin();
}
/*!*********************************************************************************************************************
\brief Return a indexed_const_iterator to the first item in the map.
***********************************************************************************************************************/
typename maptype_::const_iterator indexed_begin() const
{
return myindex.begin();
}
/*!*********************************************************************************************************************
\brief Return an indexed_iterator pointing one item past the last item in the map.
***********************************************************************************************************************/
typename maptype_::iterator indexed_end()
{
return myindex.begin();
}
/*!*********************************************************************************************************************
\brief Return an indexed_const_iterator pointing one item past the last item in the map.
***********************************************************************************************************************/
typename maptype_::const_iterator indexed_end() const
{
return myindex.end();
}
/*!*********************************************************************************************************************
\brief Return an iterator pointing one item past the last item in the backing array.
***********************************************************************************************************************/
iterator end()
{
return mystorage.empty() ? iterator(NULL, 0) : iterator(&mystorage.front(), mystorage.size(), mystorage.size());
}
/*!*********************************************************************************************************************
\brief Return a const_iterator pointing one item past the last item in the backing array.
***********************************************************************************************************************/
const_iterator end() const
{
return mystorage.empty() ? const_iterator(NULL, 0) : const_iterator(&mystorage.front(), mystorage.size(), mystorage.size());
}
/*!*********************************************************************************************************************
\brief Insert an item at a specific point in the backing array.
\param where The index where to insert the new item
\param key The Key of the new item
\param val The Value of the new item
***********************************************************************************************************************/
void insertAt(size_t where, const IndexType_& key, const ValueType_ & val)
{
if (insert(key, val) != where)
{
relocate(key, where);
}
}
/*!*********************************************************************************************************************
\brief Insert an item at the first possible spot in the backing array.
\param key The Key of the new item
\param val The Value of the new item
***********************************************************************************************************************/
size_t insert(const IndexType_& key, const ValueType_ & val)
{
std::pair<typename maptype_::iterator, bool> found = myindex.insert(std::make_pair(key, 0));
if (!found.second) // Element already existed!
{
mystorage[found.first->second].value = val;
}
else
{
found.first->second = insertinvector(key, val);
}
return found.first->second;
}
/*!*********************************************************************************************************************
\brief Get the index of a specific key in the backing array. Valid until a reshuffling of the array is done via insert,
compact or similar operation.
***********************************************************************************************************************/
size_t getIndex(const IndexType_& key) const
{
typename maptype_::const_iterator found = myindex.find(key);
if (found != myindex.end()) // Element already existed!
{
return found->second;
}
return static_cast<size_t>(-1);// == static_cast<size_t>(-1)
}
/*!*********************************************************************************************************************
\brief Removes the item with the specified key from the IndexedArray.
\description This method will find the entry with specified key and remove it. It will not invalidata existing indices, but
it will voids the contiguousness guarantee the backing array normally has. Call compact() afterwards to make
the vector contiguous again (but invalidate existing indices).
***********************************************************************************************************************/
void erase(const IndexType_& key)
{
typename maptype_::iterator where = myindex.find(key);
if (where != myindex.end())
{
removefromvector(where->second);
myindex.erase(where);
//SPECIAL CASE: If no more items are left, there is absolutely no point in NOT compacting, as no iterators or indices exist to be invalidated, so we can clean up
//even though "deferred" was asked. Additionally, this is essentially free, except maybe for the list...
if (myindex.empty())
{
mystorage.clear();
myDeletedItems.clear();
}
}
}
/*!*********************************************************************************************************************
\brief Array indexing operator. Use getIndex to get the indexes of specific items. If idx points to a deleted item or
past the last item, the behaviour is undefined.
***********************************************************************************************************************/
ValueType_& operator[](size_t idx)
{
return mystorage[idx].value;
}
/*!*********************************************************************************************************************
\brief Const array indexing operator. Use getIndex to get the indexes of specific items. If idx points to a deleted item or
past the last item, the behaviour is undefined.
***********************************************************************************************************************/
const ValueType_& operator[](size_t idx)const
{
return mystorage[idx].value;
}
/*!*********************************************************************************************************************
\brief Indexed indexing operator. Uses std::map binary search to find and retrieve the specified value. If the key does not
exist, behaviour is undefined.
***********************************************************************************************************************/
ValueType_& operator[](const IndexType_& key)
{
return mystorage[myindex.find(key)->second].value;
}
/*!*********************************************************************************************************************
\brief Const Indexed indexing operator. Uses std::map binary search to find and retrieve the specified value. If the key
does not exist, behaviour is undefined.
***********************************************************************************************************************/
const ValueType_& operator[](const IndexType_& key)const
{
return mystorage[myindex.find(key)->second].value;
}
/*!*********************************************************************************************************************
\brief Compacts the backing array by removing existing items from the end of the vector and putting them in the place of
deleted items, and then updating their index, until no more positions marked as deleted are left. Will ensure the
contiguousness of the backing vector, but will invalidate previously gotten item indexes.
***********************************************************************************************************************/
void compact()
{
//We can do that because the last remove() tears down all datastructures used.
if (!myindex.size())
{
return;
}
//First, make sure there is something to compact...
deleteditemlisttype_::iterator unused_spot = myDeletedItems.begin();
while (myDeletedItems.size() && unused_spot != myDeletedItems.end())
{
//Last item in the storage vector.
size_t last = mystorage.size();
//1) Trim the end of the vector...
while (last-- && mystorage[last].isUnused)
{
mystorage.pop_back();
//Rinse, repeat. If size is zero, there is nothing to do.
}
//Either the storage is empty
if (mystorage.empty())
{
myDeletedItems.clear();
//the rest should already be cleared...
//the loop will exit naturally
}
else //Or we can have find its last item!
{
//2)Trim any items from the end of the unused spots list that may have been trimmed off by the vector...
while (unused_spot != myDeletedItems.end() && *unused_spot >= last)
{
myDeletedItems.erase(unused_spot++);
}
//Any spots left?
if (unused_spot != myDeletedItems.end())
{
//Do the actual data movement. After all we've been through, we know that
//i. The last item of the vector is a valid item (guaranteed by 1)
//ii. The unused spot is not out of bounds of the vector
//iii.
//Copy by hand(as we have not defined a move assignment operator for compatibility reasons.
//Also, since the string does not throw, this makes easier to reason about exceptions.
#ifdef PVR_SUPPORT_MOVE_SEMANTICS
mystorage[*unused_spot].value = std::move(mystorage[last].value);
mystorage[*unused_spot].key = std::move(mystorage[last].key);
#else
mystorage[*unused_spot].value = mystorage[last].value;
mystorage[last].value.ValueType_::~ValueType_();
new(&mystorage[last].value) ValueType_();
mystorage[*unused_spot].key = mystorage[last].key;
mystorage[last].key.clear();
#endif
mystorage[*unused_spot].isUnused = false;
myindex[mystorage[*unused_spot].key] = *unused_spot;
mystorage.pop_back();
myDeletedItems.erase(unused_spot++);
}//else : No action needed - unused spots has been trimmed off completely, so no movement is possible, or necessary...
}
}
}
/*!*********************************************************************************************************************
\brief Empties the IndexedArray.
***********************************************************************************************************************/
void clear()
{
myindex.clear();
mystorage.clear();
myDeletedItems.clear();
}
/*!*********************************************************************************************************************
\brief Gets the number of items in the IndexedArray.
\return The number of items in the IndexedArray.
***********************************************************************************************************************/
size_t size() const
{
return myindex.size();
}
/*!*********************************************************************************************************************
\brief Gets the number of items in the IndexedArray, including items that have been deleted.
\return The number of items in the IndexedArray, including items that have been deleted.
***********************************************************************************************************************/
size_t sizeWithDeleted() const
{
return mystorage.size();
}
/*!*********************************************************************************************************************
\brief Gets the current capacity of the backing array of the IndexedArray.
\return The current capacity of the backing array of the IndexedArray.
***********************************************************************************************************************/
size_t capacity() const
{
return mystorage.size();
}
/*!*********************************************************************************************************************
\brief Gets the number of deleted items.
\return The number of deleted items.
***********************************************************************************************************************/
size_t deletedItemsCount() const
{
return myDeletedItems.size();
}
/*!*********************************************************************************************************************
\brief Move a specific item (identified by a key) to a specific index in the list. If an item is already in this spot in the
list, their positions are swapped.
\return False if the specified key was not found in the index.
***********************************************************************************************************************/
bool relocate(const IndexType_& key, size_t index)
{
typename maptype_::iterator found = myindex.find(key);
if (found == myindex.end()) { return false; }
size_t old_index = myindex[key];
if (index == old_index) { return true; } //No-op
if (index + 1 > mystorage.size()) // Storage not big enough.
{
//Grow, and mark unused all required items. Need to add all spots (But the last) to unusedspots.
size_t oldsize = mystorage.size();
mystorage.resize(index + 1);
for (size_t i = oldsize; i < index; ++i)
{
myDeletedItems.push_front(i);
mystorage[i].isUnused = 1;
}
mystorage.back() = mystorage[old_index];
removefromvector(old_index);
}
else if (mystorage[index].isUnused) // Lucky! Storage is big enough, and the item is not used!
{
deleteditemlisttype_::iterator place = std::find(myDeletedItems.begin(), myDeletedItems.end(), index);
assert(place != myDeletedItems.end()); // Shouldn't happen! Ever!
myDeletedItems.erase(place);
mystorage[index] = mystorage[old_index];
removefromvector(old_index);
}
else // Whoops! Space is already occupied. Swap with the old item!
{
myindex[mystorage[index].key] = old_index;
std::swap(mystorage[index], mystorage[old_index]);
}
myindex[key] = index;
return true;
}
private:
size_t insertinvector(const IndexType_& key, const ValueType_ & val)
{
size_t retval;
if (myDeletedItems.empty())
{
retval = mystorage.size();
mystorage.push_back(StorageItem_());
mystorage.back().isUnused = false;
mystorage.back().key = key;
mystorage.back().value = val;
}
else
{
retval = myDeletedItems.back();
myDeletedItems.pop_back();
mystorage[retval].value = val;
mystorage[retval].key = key;
mystorage[retval].isUnused = false;
}
return retval;
}
void removefromvector(size_t index)
{
if (index == (mystorage.size() - 1))
{
//Removing the last item from the vector -- just pop it.
mystorage.pop_back();
}
else
{
//NOT the last item, so we just destruct it (to free any potential expensive resources),
//and then default-construct it (to have the spot destructible). We keep the reference to
//the key as we will need it.
myDeletedItems.push_front(index);
mystorage[index].isUnused = true;
mystorage[index].value.ValueType_::~ValueType_();
new(&mystorage[index].value) ValueType_;
}
}
};
}
| [
"rcdailey@gmail.com"
] | rcdailey@gmail.com |
74ab5b6078f772974de3f4da851af9d7ff12066c | b84e96b6645bd444b27d727af396a46ec387cff3 | /LearnOpenGLPart3/LearnOpenGLPart3/test2.cpp | 92d4d81141a43aa40dbf261dc6a9ca4a2eb537aa | [] | no_license | AverJing/LearnOpenGL | 485f4fa7efb3d4c94d890e4b5d5f3ffdc09c02d9 | 54211ebaf5f04919d7b87231fb3dac0aadb61798 | refs/heads/master | 2020-03-09T10:09:44.739149 | 2019-07-14T15:12:13 | 2019-07-14T15:12:13 | 128,730,277 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 6,472 | cpp | #include <glad/glad.h>
#include <GLFW/glfw3.h>
#include <stb_image.h>
#include <glm/glm.hpp>
#include <glm/gtc/matrix_transform.hpp>
#include <glm/gtc/type_ptr.hpp>
#include <Shader.h>
#include <iostream>
void framebuffer_size_callback(GLFWwindow* window, int width, int height);
void processInput(GLFWwindow *window);
// settings
const unsigned int SCR_WIDTH = 800;
const unsigned int SCR_HEIGHT = 600;
int main()
{
// glfw: initialize and configure
// ------------------------------
glfwInit();
glfwWindowHint(GLFW_CONTEXT_VERSION_MAJOR, 3);
glfwWindowHint(GLFW_CONTEXT_VERSION_MINOR, 3);
glfwWindowHint(GLFW_OPENGL_PROFILE, GLFW_OPENGL_CORE_PROFILE);
#ifdef __APPLE__
glfwWindowHint(GLFW_OPENGL_FORWARD_COMPAT, GL_TRUE); // uncomment this statement to fix compilation on OS X
#endif
// glfw window creation
// --------------------
GLFWwindow* window = glfwCreateWindow(SCR_WIDTH, SCR_HEIGHT, "LearnOpenGL", NULL, NULL);
if (window == NULL)
{
std::cout << "Failed to create GLFW window" << std::endl;
glfwTerminate();
return -1;
}
glfwMakeContextCurrent(window);
glfwSetFramebufferSizeCallback(window, framebuffer_size_callback);
// glad: load all OpenGL function pointers
// ---------------------------------------
if (!gladLoadGLLoader((GLADloadproc)glfwGetProcAddress))
{
std::cout << "Failed to initialize GLAD" << std::endl;
return -1;
}
// configure global opengl state
// -----------------------------
glEnable(GL_DEPTH_TEST);
// build and compile our shader zprogram
// ------------------------------------
Shader ourShader("lightColor.vs", "lightColor.fs");
// set up vertex data (and buffer(s)) and configure vertex attributes
// ------------------------------------------------------------------
float vertices[] = {
-0.5f, -0.5f, -0.5f, 0.0f, 0.0f,
0.5f, -0.5f, -0.5f, 1.0f, 0.0f,
0.5f, 0.5f, -0.5f, 1.0f, 1.0f,
0.5f, 0.5f, -0.5f, 1.0f, 1.0f,
-0.5f, 0.5f, -0.5f, 0.0f, 1.0f,
-0.5f, -0.5f, -0.5f, 0.0f, 0.0f,
-0.5f, -0.5f, 0.5f, 0.0f, 0.0f,
0.5f, -0.5f, 0.5f, 1.0f, 0.0f,
0.5f, 0.5f, 0.5f, 1.0f, 1.0f,
0.5f, 0.5f, 0.5f, 1.0f, 1.0f,
-0.5f, 0.5f, 0.5f, 0.0f, 1.0f,
-0.5f, -0.5f, 0.5f, 0.0f, 0.0f,
-0.5f, 0.5f, 0.5f, 1.0f, 0.0f,
-0.5f, 0.5f, -0.5f, 1.0f, 1.0f,
-0.5f, -0.5f, -0.5f, 0.0f, 1.0f,
-0.5f, -0.5f, -0.5f, 0.0f, 1.0f,
-0.5f, -0.5f, 0.5f, 0.0f, 0.0f,
-0.5f, 0.5f, 0.5f, 1.0f, 0.0f,
0.5f, 0.5f, 0.5f, 1.0f, 0.0f,
0.5f, 0.5f, -0.5f, 1.0f, 1.0f,
0.5f, -0.5f, -0.5f, 0.0f, 1.0f,
0.5f, -0.5f, -0.5f, 0.0f, 1.0f,
0.5f, -0.5f, 0.5f, 0.0f, 0.0f,
0.5f, 0.5f, 0.5f, 1.0f, 0.0f,
-0.5f, -0.5f, -0.5f, 0.0f, 1.0f,
0.5f, -0.5f, -0.5f, 1.0f, 1.0f,
0.5f, -0.5f, 0.5f, 1.0f, 0.0f,
0.5f, -0.5f, 0.5f, 1.0f, 0.0f,
-0.5f, -0.5f, 0.5f, 0.0f, 0.0f,
-0.5f, -0.5f, -0.5f, 0.0f, 1.0f,
-0.5f, 0.5f, -0.5f, 0.0f, 1.0f,
0.5f, 0.5f, -0.5f, 1.0f, 1.0f,
0.5f, 0.5f, 0.5f, 1.0f, 0.0f,
0.5f, 0.5f, 0.5f, 1.0f, 0.0f,
-0.5f, 0.5f, 0.5f, 0.0f, 0.0f,
-0.5f, 0.5f, -0.5f, 0.0f, 1.0f
};
unsigned int VBO, VAO;
glGenVertexArrays(1, &VAO);
glGenBuffers(1, &VBO);
glBindVertexArray(VAO);
glBindBuffer(GL_ARRAY_BUFFER, VBO);
glBufferData(GL_ARRAY_BUFFER, sizeof(vertices), vertices, GL_STATIC_DRAW);
// position attribute
glVertexAttribPointer(0, 3, GL_FLOAT, GL_FALSE, 5 * sizeof(float), (void*)0);
glEnableVertexAttribArray(0);
// tell opengl for each sampler to which texture unit it belongs to (only has to be done once)
// -------------------------------------------------------------------------------------------
ourShader.use();
// render loop
// -----------
while (!glfwWindowShouldClose(window))
{
// input
// -----
processInput(window);
// render
// ------
glClearColor(0.2f, 0.3f, 0.3f, 1.0f);
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); // also clear the depth buffer now!
// bind textures on corresponding texture units
// activate shader
ourShader.use();
// create transformations
glm::mat4 model;
glm::mat4 view;
glm::mat4 projection;
model = glm::rotate(model, (float)glfwGetTime(), glm::vec3(0.5f, 1.0f, 0.0f));
view = glm::translate(view, glm::vec3(0.0f, 0.0f, -3.0f));
projection = glm::perspective(glm::radians(45.0f), (float)SCR_WIDTH / (float)SCR_HEIGHT, 0.1f, 100.0f);
// retrieve the matrix uniform locations
unsigned int modelLoc = glGetUniformLocation(ourShader.ID, "model");
unsigned int viewLoc = glGetUniformLocation(ourShader.ID, "view");
// pass them to the shaders (3 different ways)
glUniformMatrix4fv(modelLoc, 1, GL_FALSE, glm::value_ptr(model));
glUniformMatrix4fv(viewLoc, 1, GL_FALSE, &view[0][0]);
// note: currently we set the projection matrix each frame, but since the projection matrix rarely changes it's often best practice to set it outside the main loop only once.
ourShader.setMat4("projection", projection);
// render box
glBindVertexArray(VAO);
glDrawArrays(GL_TRIANGLES, 0, 36);
// glfw: swap buffers and poll IO events (keys pressed/released, mouse moved etc.)
// -------------------------------------------------------------------------------
glfwSwapBuffers(window);
glfwPollEvents();
}
// optional: de-allocate all resources once they've outlived their purpose:
// ------------------------------------------------------------------------
glDeleteVertexArrays(1, &VAO);
glDeleteBuffers(1, &VBO);
// glfw: terminate, clearing all previously allocated GLFW resources.
// ------------------------------------------------------------------
glfwTerminate();
return 0;
}
// process all input: query GLFW whether relevant keys are pressed/released this frame and react accordingly
// ---------------------------------------------------------------------------------------------------------
void processInput(GLFWwindow *window)
{
if (glfwGetKey(window, GLFW_KEY_ESCAPE) == GLFW_PRESS)
glfwSetWindowShouldClose(window, true);
}
// glfw: whenever the window size changed (by OS or user resize) this callback function executes
// ---------------------------------------------------------------------------------------------
void framebuffer_size_callback(GLFWwindow* window, int width, int height)
{
// make sure the viewport matches the new window dimensions; note that width and
// height will be significantly larger than specified on retina displays.
glViewport(0, 0, width, height);
} | [
"panda12396@163.com"
] | panda12396@163.com |
b1512380633b74483aa424968642285136ba34d1 | 05f7573db159e870fb26c847991c4cb8c407ed4c | /VBF/Source/VBF_CORE4.0/VBF_Interface/VBF_Plot/Massive/IVBF_MarkModelPointSprite.h | fa98e6ce14682014c280c962880c6c3805ccf346 | [] | no_license | riyue625/OneGIS.ModelingTool | e126ef43429ce58d22c65832d96dbd113eacbf85 | daf3dc91584df7ecfed6a51130ecdf6671614ac4 | refs/heads/master | 2020-05-28T12:12:43.543730 | 2018-09-06T07:42:00 | 2018-09-06T07:42:00 | null | 0 | 0 | null | null | null | null | GB18030 | C++ | false | false | 3,306 | h | //************************************************************************
// FileName๏ผIVBF_MarkModelPointSprite.h
// Function๏ผๅๆ ๅฎไฝๆจกๅๆฅๅฃ๏ผ็น็ฒพ็ต๏ผ้็จไบ็ปๅถๅคง้็ธๅ็็น๏ผ
// ่ฏฅ้ๅไธญๆๆ็น็็บน็็ธๅ๏ผๅฐบๅฏธ็ธๅ๏ผไธๅง็ปๆๅ่ง็น
// Author: ๆ่น
// Date: 2015-11-23
//************************************************************************
#ifndef __IVBF_MARK_MODEL_POINTSPRITE_H__
#define __IVBF_MARK_MODEL_POINTSPRITE_H__
#include <VBF_Plot/IVBF_MarkModel.h>
#include <VBF_Plot/Massive/VBF_3DPlotDataTypes_Massive.h>
#include <Types/VBF_3DStyles.h>
#include <VBF_Engine/VBF_SceneGraph/Image>
typedef std::map<std::string, std::string> CVBF_UserValueMap;
//--------------------------------------------------------------------
// ๅฎไนๆฅๅฃ๏ผIVBF_MarkModelPointSprite
// ๆฅๅฃๆ่ฟฐ๏ผ็น็ฒพ็ต
//--------------------------------------------------------------------
class IVBF_MarkModelPointSprite : public IVBF_MarkModel
{
public:
virtual ~IVBF_MarkModelPointSprite() {}
// ๅๅงๅ้ๅไธญๆๆ็น็ๅฐบๅฏธไฟกๆฏ๏ผๅช่ฝ่ฐ็จไธๆฌก๏ผ่ไธๅฟ
้กปๅจๆทปๅ ๅไธชๆจกๅไนๅ่ฐ็จ
// fSizeInPixels -- ๅไธช็น็ๅฐบๅฏธ๏ผๅไฝ๏ผๅ็ด ๏ผ
virtual void InitSize(float fSizeInPixels)=0;
// ๅๅงๅ้ๅ็็บน็ไฟกๆฏ๏ผๅช่ฝ่ฐ็จไธๆฌก๏ผ่ไธๅฟ
้กปๅจๆทปๅ ๅไธชๆจกๅไนๅ่ฐ็จ
// ๅๆฐ๏ผpTexImage -- ้ๅไธญๆๆๆจกๅๅ
ฌ็จ็็บน็ๅพๅๆ้
// fTexAlpha -- ้ๅไธญๆๆๆจกๅ็็บน็้ๆๅบฆ๏ผ้ป่ฎคๅผไธบ1.0๏ผ
virtual void InitTexture(osg::Image* pTexImage, float fTexAlpha=1.0f)=0;
// ๅๅงๅ็ฉบ้ดๅๅฒๅๆฏไธชๅๅ
ๆ ผไธญๅญๅจ็ๆๅคง็นๆฐ๏ผ้ป่ฎคๅผไธบ100๏ผ
// ๅฆๆๅๅฒๆฐ<=5๏ผ่กจ็คบ็นๆปๆฐ่พๅฐ๏ผ็ฒพ็กฎ่ฃๅชไผๅ
๏ผ็ปๅถๆ็ๆฌกไน๏ผๅฆๅ๏ผ็ปๅถๆ็ไผๅ
๏ผ็ฒพ็กฎ่ฃๅชๆฌกไน
virtual void InitNumMaxPointsPerCell(unsigned int num)=0;
// ๆทปๅ ไธไธช็น๏ผๅนถ่ฟๅ่ฏฅ็นๅจ้ๅไธญ็ๅบๅท๏ผๅๆฐvGeo่กจ็คบ็น็ๅฐ็ๅๆ
virtual int AddPoint(const osg::Vec3d& vGeo)=0;
// ่ทๅ้ๅไธญ็น็ไธชๆฐ
virtual int GetNumPoints()=0;
// ๆทปๅ /็งป้ค/่ทๅ็จๆท่ชๅฎไน็็ฎ็ฅๅๆฐๅฏน๏ผ็จไบๆพ็คบ่ขซ้ๆจกๅ็็ฎ็ฅไฟกๆฏ๏ผๅๆๆฏ่ฏฅๆจกๅๅทฒ็ปๆทปๅ
virtual void AddUserValue(int nIndex, const std::string& strName, const std::string& strValue, bool bOverwrite=true)=0;
virtual void RemoveUseValue(int nIndex, const std::string& strName)=0;
virtual bool GetUserValue(int nIndex, const std::string& strName, std::string& strValue)=0;
virtual void SetUserValues(int nIndex, const CVBF_UserValueMap& values)=0;
virtual bool GetUserValues(int nIndex, CVBF_UserValueMap& values)=0;
// ๆทปๅ /็งป้ค/่ทๅ็จๆท่ชๅฎไน็่ฏฆ็ปๅๆฐๅฏน๏ผ็จไบๆพ็คบ่ขซ้ๆจกๅ็่ฏฆ็ปไฟกๆฏ๏ผๅๆๆฏ่ฏฅๆจกๅๅทฒ็ปๆทปๅ
virtual void AddUserValueDetail(int nIndex, const std::string& strName, const std::string& strValue, bool bOverwrite=true)=0;
virtual void RemoveUseValueDetail(int nIndex, const std::string& strName)=0;
virtual bool GetUserValueDetail(int nIndex, const std::string& strName, std::string& strValue)=0;
virtual void SetUserValuesDetail(int nIndex, const CVBF_UserValueMap& values)=0;
virtual bool GetUserValuesDetail(int nIndex, CVBF_UserValueMap& values)=0;
};
#endif
| [
"robertsam@126.com"
] | robertsam@126.com |
bb031d21dc9208ae30b921b636039a30ff3937fe | 88c0e520e2389e676fea559f944109e1ee7e157b | /include/Windows.Graphics.Display.1_4bc8ceb3.h | d904161cf29b02455127dc360dba71b8437cdbd2 | [] | no_license | jchoi2022/NtFuzz-HeaderData | fb4ecbd5399f4fac6a4982a0fb516dd7f9368118 | 6adc3d339e6cac072cde6cfef07eccafbc6b204c | refs/heads/main | 2023-08-03T02:26:10.666986 | 2021-09-17T13:35:26 | 2021-09-17T13:35:26 | 407,547,359 | 4 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,022 | h |
#include "winrt/impl/Windows.Storage.Streams.0.h"
#include "winrt/impl/Windows.Graphics.Display.0.h"
WINRT_EXPORT namespace winrt::Windows::Graphics::Display {
struct WINRT_EBO IAdvancedColorInfo :
Windows::Foundation::IInspectable,
impl::consume_t<IAdvancedColorInfo>
{
IAdvancedColorInfo(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IBrightnessOverride :
Windows::Foundation::IInspectable,
impl::consume_t<IBrightnessOverride>
{
IBrightnessOverride(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IBrightnessOverrideSettings :
Windows::Foundation::IInspectable,
impl::consume_t<IBrightnessOverrideSettings>
{
IBrightnessOverrideSettings(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IBrightnessOverrideSettingsStatics :
Windows::Foundation::IInspectable,
impl::consume_t<IBrightnessOverrideSettingsStatics>
{
IBrightnessOverrideSettingsStatics(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IBrightnessOverrideStatics :
Windows::Foundation::IInspectable,
impl::consume_t<IBrightnessOverrideStatics>
{
IBrightnessOverrideStatics(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IColorOverrideSettings :
Windows::Foundation::IInspectable,
impl::consume_t<IColorOverrideSettings>
{
IColorOverrideSettings(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IColorOverrideSettingsStatics :
Windows::Foundation::IInspectable,
impl::consume_t<IColorOverrideSettingsStatics>
{
IColorOverrideSettingsStatics(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IDisplayEnhancementOverride :
Windows::Foundation::IInspectable,
impl::consume_t<IDisplayEnhancementOverride>
{
IDisplayEnhancementOverride(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IDisplayEnhancementOverrideCapabilities :
Windows::Foundation::IInspectable,
impl::consume_t<IDisplayEnhancementOverrideCapabilities>
{
IDisplayEnhancementOverrideCapabilities(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IDisplayEnhancementOverrideCapabilitiesChangedEventArgs :
Windows::Foundation::IInspectable,
impl::consume_t<IDisplayEnhancementOverrideCapabilitiesChangedEventArgs>
{
IDisplayEnhancementOverrideCapabilitiesChangedEventArgs(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IDisplayEnhancementOverrideStatics :
Windows::Foundation::IInspectable,
impl::consume_t<IDisplayEnhancementOverrideStatics>
{
IDisplayEnhancementOverrideStatics(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IDisplayInformation :
Windows::Foundation::IInspectable,
impl::consume_t<IDisplayInformation>
{
IDisplayInformation(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IDisplayInformation2 :
Windows::Foundation::IInspectable,
impl::consume_t<IDisplayInformation2>,
impl::require<IDisplayInformation2, Windows::Graphics::Display::IDisplayInformation>
{
IDisplayInformation2(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IDisplayInformation3 :
Windows::Foundation::IInspectable,
impl::consume_t<IDisplayInformation3>
{
IDisplayInformation3(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IDisplayInformation4 :
Windows::Foundation::IInspectable,
impl::consume_t<IDisplayInformation4>
{
IDisplayInformation4(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IDisplayInformation5 :
Windows::Foundation::IInspectable,
impl::consume_t<IDisplayInformation5>
{
IDisplayInformation5(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IDisplayInformationStatics :
Windows::Foundation::IInspectable,
impl::consume_t<IDisplayInformationStatics>
{
IDisplayInformationStatics(std::nullptr_t = nullptr) noexcept {}
};
struct WINRT_EBO IDisplayPropertiesStatics :
Windows::Foundation::IInspectable,
impl::consume_t<IDisplayPropertiesStatics>
{
IDisplayPropertiesStatics(std::nullptr_t = nullptr) noexcept {}
};
}
| [
"jschoi.2022@gmail.com"
] | jschoi.2022@gmail.com |
abf17135bd73832ddf1d3235e491b5a5e67c360e | 3fca51025651363b205171c963d0c21e3a8450bf | /int2Str_test/main.cpp | 7b92c466e065e518e7cf88a8291a58744285beff | [] | no_license | yujianjun1025/cplusplus_exercise | 65191673eeb746d7a986fc8ac2ad4c42d10bb192 | d2e1c74b0b0de6c59097d0127c7138a0836c022e | refs/heads/master | 2021-01-21T12:11:06.897566 | 2016-03-30T03:21:26 | 2016-03-30T03:21:26 | 39,677,597 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 356 | cpp | #include<stdio.h>
#include <iostream>
#include <map>
using namespace std;
int main()
{
int n = 65535;
char t[256];
std::string s;
sprintf(t, "%d", n);
s = t;
cout <<"sprintf ่ฝฌๅ็ปๆ:" << s << endl;
map<string, string> map;
map["a"] = n;
cout<< "็ดๆฅ่ตๅผ่ฝฌๅ็ปๆ:" << map["a"] << endl;
return 0;
}
| [
"yujianjun@hbdata-search-test01.lf.sankuai.com"
] | yujianjun@hbdata-search-test01.lf.sankuai.com |
089451c97cf15878d531947872c49bbfb8c096f0 | 0368436dc981ab44975d4b28935ae89a37065030 | /src/core_memusage.h | d06eadfd6cbdb24b8153d045e0dce785c2d619a2 | [
"MIT"
] | permissive | mirzaei-ce/core-koobit | b1d350c28f87764a14ed7e92e9918c7af90a93a0 | 7d24e9c554fec6f3631691f456e9873bc4536fbd | refs/heads/master | 2021-08-14T19:04:05.775343 | 2017-11-16T14:35:05 | 2017-11-16T14:35:05 | 110,982,099 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,219 | h | // Copyright (c) 2015 The Bitcoin Core developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#ifndef KOOBIT_CORE_MEMUSAGE_H
#define KOOBIT_CORE_MEMUSAGE_H
#include "primitives/transaction.h"
#include "primitives/block.h"
#include "memusage.h"
static inline size_t RecursiveDynamicUsage(const CScript& script) {
return memusage::DynamicUsage(*static_cast<const CScriptBase*>(&script));
}
static inline size_t RecursiveDynamicUsage(const COutPoint& out) {
return 0;
}
static inline size_t RecursiveDynamicUsage(const CTxIn& in) {
return RecursiveDynamicUsage(in.scriptSig) + RecursiveDynamicUsage(in.prevout);
}
static inline size_t RecursiveDynamicUsage(const CTxOut& out) {
return RecursiveDynamicUsage(out.scriptPubKey);
}
static inline size_t RecursiveDynamicUsage(const CTransaction& tx) {
size_t mem = memusage::DynamicUsage(tx.vin) + memusage::DynamicUsage(tx.vout);
for (std::vector<CTxIn>::const_iterator it = tx.vin.begin(); it != tx.vin.end(); it++) {
mem += RecursiveDynamicUsage(*it);
}
for (std::vector<CTxOut>::const_iterator it = tx.vout.begin(); it != tx.vout.end(); it++) {
mem += RecursiveDynamicUsage(*it);
}
return mem;
}
static inline size_t RecursiveDynamicUsage(const CMutableTransaction& tx) {
size_t mem = memusage::DynamicUsage(tx.vin) + memusage::DynamicUsage(tx.vout);
for (std::vector<CTxIn>::const_iterator it = tx.vin.begin(); it != tx.vin.end(); it++) {
mem += RecursiveDynamicUsage(*it);
}
for (std::vector<CTxOut>::const_iterator it = tx.vout.begin(); it != tx.vout.end(); it++) {
mem += RecursiveDynamicUsage(*it);
}
return mem;
}
static inline size_t RecursiveDynamicUsage(const CBlock& block) {
size_t mem = memusage::DynamicUsage(block.vtx);
for (std::vector<CTransaction>::const_iterator it = block.vtx.begin(); it != block.vtx.end(); it++) {
mem += RecursiveDynamicUsage(*it);
}
return mem;
}
static inline size_t RecursiveDynamicUsage(const CBlockLocator& locator) {
return memusage::DynamicUsage(locator.vHave);
}
#endif // KOOBIT_CORE_MEMUSAGE_H
| [
"mirzaei@ce.sharif.edu"
] | mirzaei@ce.sharif.edu |
77d6548ca557650e1dcf394ae917e97e44fca1fe | f34dd88f36ad1a05d49a48920d4fea2dd4cd6462 | /hackerrank/Project-Euler/pe037.cpp | 00ed7b962b24fd5b0a1e6bab59e3720d01b68acf | [] | no_license | ccd97/cp_solutions | e1a9f66eb9ae15c5aa80679f3695f32de0f55ded | 702fd1c6a8c3bdc8e255a51abf66c5d71a31ff9e | refs/heads/master | 2021-07-20T06:58:42.496450 | 2018-11-27T14:38:39 | 2018-11-27T14:41:36 | 130,831,095 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 895 | cpp | #include <bits/stdc++.h>
using namespace std;
#define MAX 1000006
bool prime[1000007];
void SieveOfEratosthenes() {
memset(prime, true, sizeof(prime));
for (int p=2; p*p<=MAX; p++){
if (prime[p] == true){
for (int i=p*2; i<=MAX; i += p)
prime[i] = false;
}
}
prime[0] = false;
prime[1] = false;
}
int calcTruPri(int num){
int div = 1, n= num;
while (n/div >= 10) div *= 10;
while(n > 0){
if(!prime[n]) return 0;
n %= div;
div /= 10;
}
n = num;
while(n > 0){
if(!prime[n]) return 0;
n /= 10;
}
return num;
}
int main(int argc, char const *argv[]) {
SieveOfEratosthenes();
int n; cin>>n;
unsigned long long tripsum = 0;
for(int i=11; i<n; i++){
if(prime[i]) tripsum += calcTruPri(i);
}
cout<<tripsum<<endl;
return 0;
}
| [
"dcunha.cyprien@gmail.com"
] | dcunha.cyprien@gmail.com |
09bd8d81b20cdafb518ae4d207a018936fa51a46 | 28c83c7cf21ae5363a0de614d13fac32bca764e2 | /Engine/include/openface/FaceWorker.h | 112d1058f03b93f2b7b95d29b8f58d33969c23f4 | [] | no_license | sumit33k/Emotinal-behaviour-analytics | 477eea2cf39ab460aab9e021cda694190d690191 | f53562e8b46fd1fc4b219ca37c2fc656a189b82c | refs/heads/master | 2021-08-30T16:31:50.783313 | 2017-12-18T16:44:11 | 2017-12-18T16:44:11 | 114,663,050 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,255 | h | #pragma once
#ifndef __FACE_WORKER_H
#define __FACE_WORKER_H
#include <thread>
#include <atomic>
#include <chrono>
#include <FaceQueue.h>
#define WORKER_DEFAULT_QUEUESIZE 2
namespace OpenFace
{
/// <summary>
/// Base class wrapping an async worker-thread.
/// </summary>
template <typename T, typename U, typename W>
class Worker
{
protected:
::std::thread mThread;
::std::atomic<bool> mIsRunning;
::std::atomic<float> mFPS;
::std::chrono::time_point<::std::chrono::high_resolution_clock> mTick;
::std::chrono::time_point<::std::chrono::high_resolution_clock> mTickLast;
::std::chrono::time_point<::std::chrono::high_resolution_clock> mTickLastMeasure;
::std::chrono::duration<long long, ::std::nano> mTickDelta;
Queue<T> mQueueIn;
Queue<U> mQueueOut;
Queue<W> mCommands;
long long mProcessedCount;
virtual void init() { }
virtual void shutdown() { }
virtual void process(T item) { }
virtual void execute(W command) { }
/// <summary>
/// This code is executed by the internal worker-thread
/// </summary>
void threadProc()
{
// get init ticks
mTickLast = ::std::chrono::high_resolution_clock::now();
mTick = ::std::chrono::high_resolution_clock::now();
// mini sleep
::std::this_thread::sleep_for(::std::chrono::milliseconds(1));
// init of subclasses
init();
///////////////////////////////////////////////////////////////////////////
// threadloop
while (mIsRunning.load())
{
// update current tick and delta to last tick
mTick = ::std::chrono::high_resolution_clock::now();
mTickDelta = mTick - mTickLast;
///////////////////////////////////////////////////////////////////////
// get span since last tps measuring
const ::std::chrono::duration<long long, ::std::nano> NANOS_SINCE_MEASURE =
mTick - mTickLastMeasure;
// possibly calculate new TPS value for last span (every ~1000ms)
if (NANOS_SINCE_MEASURE >= ::std::chrono::milliseconds(1000))
{
const float RATIO = (float)mProcessedCount / (float)NANOS_SINCE_MEASURE.count();
mFPS.store(1000000000.0f * RATIO);
// reset counter and store last TPS update tick
mProcessedCount = 0;
mTickLastMeasure = mTick;
}
///////////////////////////////////////////////////////////////////////
// try get command
W command = mCommands.dequeue();
if (command)
{
execute(command);
}
///////////////////////////////////////////////////////////////////////
// try get work item
T item = mQueueIn.dequeue();
// if there is an item, process it and immediately loop again
if (item)
{
process(item);
mProcessedCount++;
}
// otherwise sleep a bit
else
::std::this_thread::sleep_for(::std::chrono::milliseconds(1));
///////////////////////////////////////////////////////////////////////
// save this tick as last tick
mTickLast = mTick;
}
// shutdown of subclasses
shutdown();
}
public:
/// <summary>
/// Constructor
/// </summary>
Worker() :
mIsRunning(false),
mQueueIn(WORKER_DEFAULT_QUEUESIZE),
mQueueOut(WORKER_DEFAULT_QUEUESIZE)
{ }
/// <summary>
/// Destructor
/// </summary>
~Worker()
{
// free remaining queue items
while (T item = mQueueIn.dequeue())
delete item;
}
/// <summary>
/// Starts or stops the worker
/// </summary>
void setIsRunning(bool isRunning)
{
if (!mIsRunning.load())
{
mIsRunning.store(true);
mThread = ::std::thread(&Worker::threadProc, this);
mThread.detach();
}
else
mIsRunning.store(false);
}
/// <summary>
/// Returns current FPS rate.
/// </summary>
__forceinline float getFPS() { return mFPS.load(); }
/// <summary>
/// Adds a new task for the worker.
/// </summary>
__forceinline bool enqueueWork(T item) { return mQueueIn.enqueue(item); }
/// <summary>
/// Returns the next task result from the worker.
/// </summary>
__forceinline U dequeueResult() { return mQueueOut.dequeue(); }
};
}
#endif
| [
"sumit3.k@gmail.com"
] | sumit3.k@gmail.com |
63e9ba6894cc10a02ba9c66869db761018d20e1d | 5c2c7f71ae8adb724f1dc99935fd4fd37ee6523e | /art.cpp | b06fae2b7b4569481c82fbfb2445da688c14eae5 | [] | no_license | Twisol/mushclient | d1b9de077b6fcc0c854e9ff459b3491b0fe16eb7 | 430896bb7abdd025e7a09ddbae40ebfef7e735f0 | refs/heads/master | 2021-01-18T19:14:24.835242 | 2010-09-19T07:53:50 | 2010-09-19T07:53:50 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 19,692 | cpp | /*
ASCII-art generator.
Based on figlet.
FIGlet Copyright 1991, 1993, 1994 Glenn Chappell and Ian Chai
FIGlet Copyright 1996, 1997 John Cowan
Portions written by Paul Burton
Internet: <ianchai@usa.net>
FIGlet, along with the various FIGlet fonts and documentation, is
copyrighted under the provisions of the Artistic License (as listed
in the file "artistic.license" which is included in this package.
*/
#include "stdafx.h"
#include "MUSHclient.h"
#include "TextDocument.h"
#include "TextView.h"
#include "doc.h"
#include "dialogs\AsciiArtDlg.h"
#ifdef _DEBUG
//#define new DEBUG_NEW
#undef THIS_FILE
static char BASED_CODE THIS_FILE[] = __FILE__;
#endif
#define MYSTRLEN(x) ((int)strlen(x)) /* Eliminate ANSI problem */
#define FONTFILESUFFIX ".flf"
#define FONTFILEMAGICNUMBER "flf2"
#define FSUFFIXLEN MYSTRLEN(FONTFILESUFFIX)
#define CONTROLFILESUFFIX ".flc"
#define CONTROLFILEMAGICNUMBER "flc2" /* no longer used in 2.2 */
#define CSUFFIXLEN MYSTRLEN(CONTROLFILESUFFIX)
#define DEFAULTCOLUMNS 500
#ifndef DEFAULTFONTDIR
#define DEFAULTFONTDIR "fonts"
#endif
#ifndef DEFAULTFONTFILE
#define DEFAULTFONTFILE "standard.flf"
#endif
/****************************************************************************
Globals dealing with chars that are read
****************************************************************************/
typedef long inchr; /* "char" read from stdin */
static inchr *inchrline = NULL; /* Alloc'd inchr inchrline[inchrlinelenlimit+1]; */
/* Note: not null-terminated. */
static int inchrlinelen,inchrlinelenlimit;
static inchr deutsch[7] = {196, 214, 220, 228, 246, 252, 223};
/* Latin-1 codes for German letters, respectively:
LATIN CAPITAL LETTER A WITH DIAERESIS = A-umlaut
LATIN CAPITAL LETTER O WITH DIAERESIS = O-umlaut
LATIN CAPITAL LETTER U WITH DIAERESIS = U-umlaut
LATIN SMALL LETTER A WITH DIAERESIS = a-umlaut
LATIN SMALL LETTER O WITH DIAERESIS = o-umlaut
LATIN SMALL LETTER U WITH DIAERESIS = u-umlaut
LATIN SMALL LETTER SHARP S = ess-zed
*/
/****************************************************************************
Globals affected by command line options
****************************************************************************/
static int deutschflag,justification,paragraphflag,right2left,multibyte;
static int cmdinput;
#define SM_SMUSH 128
#define SM_KERN 64
#define SM_EQUAL 1
#define SM_LOWLINE 2
#define SM_HIERARCHY 4
#define SM_PAIR 8
#define SM_BIGX 16
#define SM_HARDBLANK 32
static int smushmode;
#define SMO_NO 0 /* no command-line smushmode */
#define SMO_YES 1 /* use command-line smushmode, ignore font smushmode */
#define SMO_FORCE 2 /* logically OR command-line and font smushmodes */
static int smushoverride;
static int outputwidth;
static int outlinelenlimit;
static char *fontdirname,*fontname;
/****************************************************************************
Globals dealing with chars that are written
****************************************************************************/
typedef struct fc {
inchr ord;
char **thechar; /* Alloc'd char thechar[charheight][]; */
struct fc *next;
} fcharnode;
static fcharnode *fcharlist = NULL;
static char **currchar;
static int currcharwidth;
static int previouscharwidth;
static char **outputline = NULL; /* Alloc'd char outputline[charheight][outlinelenlimit+1]; */
static int outlinelen;
/****************************************************************************
Globals read from font file
****************************************************************************/
static char hardblank;
static int charheight;
/****************************************************************************
myalloc
Calls malloc. If malloc returns error, prints error message and
quits.
****************************************************************************/
/*
char *myalloc(size_t size)
{
char *ptr;
ptr = new char [size];
if (ptr == NULL)
ThrowErrorException ("Out of memory");
return ptr;
}
*/
#define myalloc(arg) new char [arg]
#define myfree(arg) delete [] arg
/****************************************************************************
getparams
Handles all command-line parameters. Puts all parameters within
bounds.
****************************************************************************/
static void getparams()
{
extern char *optarg;
extern int optind;
int firstfont,infoprint;
fontdirname = DEFAULTFONTDIR;
firstfont = 1;
deutschflag = 0;
justification = -1;
right2left = -1;
paragraphflag = 0;
infoprint = -1;
cmdinput = 0;
outputwidth = DEFAULTCOLUMNS;
outlinelenlimit = outputwidth-1;
}
/****************************************************************************
readmagic
Reads a four-character magic string from a stream.
****************************************************************************/
static void readmagic(CStdioFile & file, char * magic)
{
file.Read (magic, 4);
magic[4] = 0;
}
/****************************************************************************
skiptoeol
Skips to the end of a line, given a stream.
****************************************************************************/
static void skiptoeol(CStdioFile & fp)
{
char dummy [2];
while (fp.Read (dummy, 1))
if (dummy [0] == '\n') return;
}
/****************************************************************************
readfontchar
Reads a font character from the font file, and places it in a
newly-allocated entry in the list.
****************************************************************************/
static void readfontchar(CStdioFile & file, inchr theord, char * line, int maxlen)
{
int row,k;
char endchar;
fcharnode *fclsave;
fclsave = fcharlist;
fcharlist = (fcharnode*)myalloc(sizeof(fcharnode));
fcharlist->ord = theord;
fcharlist->thechar = (char**)myalloc(sizeof(char*)*charheight);
fcharlist->next = fclsave;
for (row=0;row<charheight;row++) {
if (file.ReadString(line,maxlen+1)==NULL) {
line[0] = '\0';
}
k = MYSTRLEN(line)-1;
while (k>=0 && isspace(line[k])) {
k--;
}
if (k>=0) {
endchar = line[k];
while (k>=0 ? line[k]==endchar : 0) {
k--;
}
}
line[k+1] = '\0';
fcharlist->thechar[row] = (char*)myalloc(sizeof(char)*(k+2));
strcpy(fcharlist->thechar[row],line);
}
}
/****************************************************************************
readfont
Allocates memory, initializes variables, and reads in the font.
****************************************************************************/
static void readfont(CString strName)
{
#define MAXFIRSTLINELEN 1000
int i,row,numsread;
inchr theord;
int maxlen,cmtlines,ffright2left;
int smush,smush2;
char *fileline,magicnum[5];
CStdioFile fontfile (strName,
CFile::modeRead|CFile::shareDenyNone|CFile::typeText);
readmagic(fontfile,magicnum);
fileline = (char*)myalloc(sizeof(char)*(MAXFIRSTLINELEN+1));
if (fontfile.ReadString(fileline,MAXFIRSTLINELEN+1)==NULL) {
fileline[0] = '\0';
}
if (MYSTRLEN(fileline)>0 ? fileline[MYSTRLEN(fileline)-1]!='\n' : 0) {
skiptoeol(fontfile);
}
numsread = sscanf(fileline,"%*c%c %d %*d %d %d %d %d %d",
&hardblank,&charheight,&maxlen,&smush,&cmtlines,
&ffright2left,&smush2);
myfree(fileline);
if (strcmp(magicnum,FONTFILEMAGICNUMBER) || numsread<5)
ThrowErrorException ("Not a FIGlet 2 font file");
for (i=1;i<=cmtlines;i++) {
skiptoeol(fontfile);
}
if (numsread<6) {
ffright2left = 0;
}
if (numsread<7) { /* if no smush2, decode smush into smush2 */
if (smush == 0) smush2 = SM_KERN;
else if (smush < 0) smush2 = 0;
else smush2 = (smush & 31) | SM_SMUSH;
}
if (charheight<1) {
charheight = 1;
}
if (maxlen<1) {
maxlen = 1;
}
maxlen += 100; /* Give ourselves some extra room */
if (smushoverride == SMO_NO)
smushmode = smush2;
else if (smushoverride == SMO_FORCE)
smushmode |= smush2;
if (right2left<0) {
right2left = ffright2left;
}
if (justification<0) {
justification = 2*right2left;
}
fileline = (char*)myalloc(sizeof(char)*(maxlen+1));
/* Allocate "missing" character */
fcharlist = (fcharnode*)myalloc(sizeof(fcharnode));
fcharlist->ord = 0;
fcharlist->thechar = (char**)myalloc(sizeof(char*)*charheight);
fcharlist->next = NULL;
for (row=0;row<charheight;row++) {
fcharlist->thechar[row] = (char*)myalloc(sizeof(char));
fcharlist->thechar[row][0] = '\0';
}
for (theord=' ';theord<='~';theord++) {
readfontchar(fontfile,theord,fileline,maxlen);
}
for (theord=0;theord<=6;theord++) {
readfontchar(fontfile,deutsch[theord],fileline,maxlen);
}
while (fontfile.ReadString(fileline,maxlen+1)==NULL?0:
sscanf(fileline,"%li",&theord)==1) {
readfontchar(fontfile,theord,fileline,maxlen);
}
myfree(fileline);
}
/****************************************************************************
clearline
Clears both the input (inchrline) and output (outputline) storage.
****************************************************************************/
static void clearline()
{
int i;
for (i=0;i<charheight;i++) {
outputline[i][0] = '\0';
}
outlinelen = 0;
inchrlinelen = 0;
}
/****************************************************************************
linealloc
Allocates & clears outputline, inchrline. Sets inchrlinelenlimit.
Called near beginning of main().
****************************************************************************/
static void linealloc()
{
int row;
outputline = (char**)myalloc(sizeof(char*)*charheight);
for (row=0;row<charheight;row++) {
outputline[row] = (char*)myalloc(sizeof(char)*(outlinelenlimit+1));
}
inchrlinelenlimit = outputwidth*4+100;
inchrline = (inchr*)myalloc(sizeof(inchr)*(inchrlinelenlimit+1));
clearline();
}
/****************************************************************************
linefree
Frees outputline, inchrline.
****************************************************************************/
static void linefree()
{
int row;
if (outputline)
{
for (row=0;row<charheight;row++) {
if (outputline[row])
myfree (outputline[row]);
outputline[row] = NULL;
}
myfree (outputline);
outputline = NULL;
}
if (inchrline)
myfree (inchrline);
inchrline = NULL;
}
static void fontfree()
{
int row;
fcharnode *charptr, *nextptr;
for (charptr=fcharlist; charptr; charptr=nextptr)
{
nextptr = charptr->next; // next node
if (charptr->thechar)
{
for (row=0;row<charheight;row++) {
if (charptr->thechar[row])
myfree (charptr->thechar[row]);
charptr->thechar[row] = NULL;
}
myfree (charptr->thechar);
charptr->thechar = NULL;
}
myfree (charptr);
charptr = NULL;
} // end of traversing list
fcharlist = NULL; // list is empty now
}
/****************************************************************************
getletter
Sets currchar to point to the font entry for the given character.
Sets currcharwidth to the width of this character.
****************************************************************************/
static void getletter(inchr c)
{
fcharnode *charptr;
for (charptr=fcharlist;charptr==NULL?0:charptr->ord!=c;
charptr=charptr->next) ;
if (charptr!=NULL) {
currchar = charptr->thechar;
}
else {
for (charptr=fcharlist;charptr==NULL?0:charptr->ord!=0;
charptr=charptr->next) ;
currchar = charptr->thechar;
}
previouscharwidth = currcharwidth;
currcharwidth = MYSTRLEN(currchar[0]);
}
/****************************************************************************
smushem
Given 2 characters, attempts to smush them into 1, according to
smushmode. Returns smushed character or '\0' if no smushing can be
done.
smushmode values are sum of following (all values smush blanks):
1: Smush equal chars (not hardblanks)
2: Smush '_' with any char in hierarchy below
4: hierarchy: "|", "/\", "[]", "{}", "()", "<>"
Each class in hier. can be replaced by later class.
8: [ + ] -> |, { + } -> |, ( + ) -> |
16: / + \ -> X, > + < -> X (only in that order)
32: hardblank + hardblank -> hardblank
****************************************************************************/
static char smushem(char lch,char rch)
{
if (lch==' ') return rch;
if (rch==' ') return lch;
if (previouscharwidth<2 || currcharwidth<2) return '\0';
/* Disallows overlapping if the previous character */
/* or the current character has a width of 1 or zero. */
if ((smushmode & SM_SMUSH) == 0) return '\0'; /* kerning */
if ((smushmode & 63) == 0) {
/* This is smushing by universal overlapping. */
if (lch==' ') return rch;
if (rch==' ') return lch;
if (lch==hardblank) return rch;
if (rch==hardblank) return lch;
/* Above four lines ensure overlapping preference to */
/* visible characters. */
if (right2left==1) return lch;
/* Above line ensures that the dominant (foreground) */
/* fig-character for overlapping is the latter in the */
/* user's text, not necessarily the rightmost character. */
return rch;
/* Occurs in the absence of above exceptions. */
}
if (smushmode & SM_HARDBLANK) {
if (lch==hardblank && rch==hardblank) return lch;
}
if (lch==hardblank || rch==hardblank) return '\0';
if (smushmode & SM_EQUAL) {
if (lch==rch) return lch;
}
if (smushmode & SM_LOWLINE) {
if (lch=='_' && strchr("|/\\[]{}()<>",rch)) return rch;
if (rch=='_' && strchr("|/\\[]{}()<>",lch)) return lch;
}
if (smushmode & SM_HIERARCHY) {
if (lch=='|' && strchr("/\\[]{}()<>",rch)) return rch;
if (rch=='|' && strchr("/\\[]{}()<>",lch)) return lch;
if (strchr("/\\",lch) && strchr("[]{}()<>",rch)) return rch;
if (strchr("/\\",rch) && strchr("[]{}()<>",lch)) return lch;
if (strchr("[]",lch) && strchr("{}()<>",rch)) return rch;
if (strchr("[]",rch) && strchr("{}()<>",lch)) return lch;
if (strchr("{}",lch) && strchr("()<>",rch)) return rch;
if (strchr("{}",rch) && strchr("()<>",lch)) return lch;
if (strchr("()",lch) && strchr("<>",rch)) return rch;
if (strchr("()",rch) && strchr("<>",lch)) return lch;
}
if (smushmode & SM_PAIR) {
if (lch=='[' && rch==']') return '|';
if (rch=='[' && lch==']') return '|';
if (lch=='{' && rch=='}') return '|';
if (rch=='{' && lch=='}') return '|';
if (lch=='(' && rch==')') return '|';
if (rch=='(' && lch==')') return '|';
}
if (smushmode & SM_BIGX) {
if (lch=='/' && rch=='\\') return '|';
if (rch=='/' && lch=='\\') return 'Y';
if (lch=='>' && rch=='<') return 'X';
/* Don't want the reverse of above to give 'X'. */
}
return '\0';
}
/****************************************************************************
smushamt
Returns the maximum amount that the current character can be smushed
into the current line.
****************************************************************************/
static int smushamt()
{
int maxsmush,amt;
int row,linebd,charbd;
char ch1,ch2;
if ((smushmode & (SM_SMUSH | SM_KERN)) == 0) {
return 0;
}
maxsmush = currcharwidth;
for (row=0;row<charheight;row++) {
if (right2left) {
for (charbd=MYSTRLEN(currchar[row]);
ch1=currchar[row][charbd],(charbd>0&&(!ch1||ch1==' '));charbd--) ;
for (linebd=0;ch2=outputline[row][linebd],ch2==' ';linebd++) ;
amt = linebd+currcharwidth-1-charbd;
}
else {
for (linebd=MYSTRLEN(outputline[row]);
ch1 = outputline[row][linebd],(linebd>0&&(!ch1||ch1==' '));linebd--) ;
for (charbd=0;ch2=currchar[row][charbd],ch2==' ';charbd++) ;
amt = charbd+outlinelen-1-linebd;
}
if (!ch1||ch1==' ') {
amt++;
}
else if (ch2) {
if (smushem(ch1,ch2)!='\0') {
amt++;
}
}
if (amt<maxsmush) {
maxsmush = amt;
}
}
return maxsmush;
}
/****************************************************************************
addchar
Attempts to add the given character onto the end of the current line.
Returns 1 if this can be done, 0 otherwise.
****************************************************************************/
static int addchar(inchr c)
{
int smushamount,row,k;
char *templine;
getletter(c);
smushamount = smushamt();
if (outlinelen+currcharwidth-smushamount>outlinelenlimit
||inchrlinelen+1>inchrlinelenlimit) {
return 0;
}
templine = (char*)myalloc(sizeof(char)*(outlinelenlimit+1));
for (row=0;row<charheight;row++) {
if (right2left) {
strcpy(templine,currchar[row]);
for (k=0;k<smushamount;k++) {
templine[currcharwidth-smushamount+k] =
smushem(templine[currcharwidth-smushamount+k],outputline[row][k]);
}
strcat(templine,outputline[row]+smushamount);
strcpy(outputline[row],templine);
}
else {
for (k=0;k<smushamount;k++) {
outputline[row][outlinelen-smushamount+k] =
smushem(outputline[row][outlinelen-smushamount+k],currchar[row][k]);
}
strcat(outputline[row],currchar[row]+smushamount);
}
}
myfree(templine);
outlinelen = MYSTRLEN(outputline[0]);
inchrline[inchrlinelen++] = c;
return 1;
}
void CTextView::OnEditAsciiart()
{
CAsciiArtDlg dlg;
dlg.m_strText = App.m_strAsciiArtText;
dlg.m_iLayout = App.m_iAsciiArtLayout;
dlg.m_strFont = App.m_strAsciiArtFont;
if (dlg.DoModal () != IDOK)
return;
// remember text but don't save in registry
App.m_strAsciiArtText = dlg.m_strText;
// remember layout in registry
if (dlg.m_iLayout != (int) App.m_iAsciiArtLayout)
App.db_write_int ("prefs", "AsciiArtLayout", dlg.m_iLayout);
App.m_iAsciiArtLayout = dlg.m_iLayout;
// remember font in registry
if (dlg.m_strFont != App.m_strAsciiArtFont)
App.db_write_string ("prefs", "AsciiArtFont", dlg.m_strFont);
App.m_strAsciiArtFont = dlg.m_strFont;
CString str = dlg.m_strText;
switch (dlg.m_iLayout)
{
case 1: // full smush
smushmode = SM_SMUSH;
smushoverride = SMO_FORCE;
break;
case 2: // kern
smushmode = SM_KERN;
smushoverride = SMO_YES;
break;
case 3: // full width
smushmode = 0;
smushoverride = SMO_YES;
break;
case 4: // overlap
smushmode = SM_SMUSH;
smushoverride = SMO_YES;
break;
default: // default is normal smush
smushoverride = SMO_NO;
break;
} // end of switch
inchr c;
int i;
try
{
getparams ();
readfont (dlg.m_strFont);
linealloc();
for (i = 0; i < str.GetLength (); i++) {
c = str [i];
if (isascii(c)&&isspace(c)) {
c = (c=='\t'||c==' ') ? ' ' : '\n';
}
if ((c>'\0' && c<' ' && c!='\n') || c==127) continue;
addchar (c);
} // end of processing each character
for (i=0;i<charheight;i++) {
CString strLine = Replace (outputline[i], hardblank, " ");
GetEditCtrl ().ReplaceSel (CFormat ("%s%s", (LPCTSTR) strLine, ENDLINE), true);
}
linefree ();
fontfree ();
}
catch (CException* e)
{
e->ReportError();
e->Delete();
linefree (); // free memory used
fontfree ();
}
}
| [
"nick@gammon.com.au"
] | nick@gammon.com.au |
17438b24412681977b21f6760fcc7ea8fc763745 | 8c2051a172d86f232d97455a43b387973277f4fc | /src/xmpp/biboumi_component.hpp | d5b87e91ccb706b4834148494e2de71eabeeaf36 | [
"Zlib"
] | permissive | lep/biboumi | 5fefdc3891cb38de5fad3d0285e7a36ed6dd387b | ba4fcbb68efdf34d173b0bc475d30e6dcbdb9553 | refs/heads/master | 2021-01-12T11:12:39.284514 | 2016-11-04T17:10:38 | 2016-11-04T17:10:38 | 72,871,259 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,307 | hpp | #pragma once
#include <xmpp/xmpp_component.hpp>
#include <bridge/bridge.hpp>
#include <memory>
#include <string>
#include <map>
namespace db
{
class MucLogLine;
}
struct ListElement;
/**
* A callback called when the waited iq result is received (it is matched
* against the iq id)
*/
using iq_responder_callback_t = std::function<void(Bridge* bridge, const Stanza& stanza)>;
/**
* Interact with the Biboumi Bridge
*/
class BiboumiComponent: public XmppComponent
{
public:
explicit BiboumiComponent(std::shared_ptr<Poller> poller, const std::string& hostname, const std::string& secret);
~BiboumiComponent() = default;
BiboumiComponent(const BiboumiComponent&) = delete;
BiboumiComponent(BiboumiComponent&&) = delete;
BiboumiComponent& operator=(const BiboumiComponent&) = delete;
BiboumiComponent& operator=(BiboumiComponent&&) = delete;
/**
* Returns the bridge for the given user. If it does not exist, return
* nullptr.
*/
Bridge* find_user_bridge(const std::string& full_jid);
/**
* Return a list of all the managed bridges.
*/
std::vector<Bridge*> get_bridges() const;
/**
* Send a "close" message to all our connected peers. That message
* depends on the protocol used (this may be a QUIT irc message, or a
* <stream/>, etc). We may also directly close the connection, or we may
* wait for the remote peer to acknowledge it before closing.
*/
void shutdown();
/**
* Run a check on all bridges, to remove all disconnected (socket is
* closed, or no channel is joined) IrcClients. Some kind of garbage collector.
*/
void clean();
/**
* Send a result IQ with the gateway disco informations.
*/
void send_self_disco_info(const std::string& id, const std::string& jid_to);
/**
* Send a result IQ with the disco informations regarding IRC server JIDs.
*/
void send_irc_server_disco_info(const std::string& id, const std::string& jid_to, const std::string& jid_from);
/**
* Sends the allowed namespaces in MUC message, according to
* http://xmpp.org/extensions/xep-0045.html#impl-service-traffic
*/
void send_irc_channel_muc_traffic_info(const std::string id, const std::string& jid_from, const std::string& jid_to);
/**
* Send an iq version request
*/
void send_iq_version_request(const std::string& from,
const std::string& jid_to);
/**
* Send a ping request
*/
void send_ping_request(const std::string& from,
const std::string& jid_to,
const std::string& id);
/**
* Send the channels list in one big stanza
*/
void send_iq_room_list_result(const std::string& id, const std::string& to_jid, const std::string& from,
const ChannelList& channel_list, std::vector<ListElement>::const_iterator begin,
std::vector<ListElement>::const_iterator end, const ResultSetInfo& rs_info);
void send_invitation(const std::string& room_target, const std::string& jid_to, const std::string& author_nick);
/**
* Handle the various stanza types
*/
void handle_presence(const Stanza& stanza);
void handle_message(const Stanza& stanza);
void handle_iq(const Stanza& stanza);
#ifdef USE_DATABASE
bool handle_mam_request(const Stanza& stanza);
void send_archived_message(const db::MucLogLine& log_line, const std::string& from, const std::string& to,
const std::string& queryid);
#endif
private:
/**
* Return the bridge associated with the bare JID. Create a new one
* if none already exist.
*/
Bridge* get_user_bridge(const std::string& user_jid);
/**
* A map of id -> callback. When we want to wait for an iq result, we add
* the callback to this map, with the iq id as the key. When an iq result
* is received, we look for a corresponding callback in this map. If
* found, we call it and remove it.
*/
std::map<std::string, iq_responder_callback_t> waiting_iq;
/**
* One bridge for each user of the component. Indexed by the user's bare
* jid
*/
std::unordered_map<std::string, std::unique_ptr<Bridge>> bridges;
AdhocCommandsHandler irc_server_adhoc_commands_handler;
AdhocCommandsHandler irc_channel_adhoc_commands_handler;
};
| [
"louiz@louiz.org"
] | louiz@louiz.org |
454f360ae9b84e006acb8d94c6fad62e0dca0c2b | 4fdac6b6c7034fe087847497847727fb7bee5f9f | /Adapter.h | 76526d9d4af85d17f849ed6f6890a3459165867f | [] | no_license | DennisAL54/Design-patterns | 2b08825c2836c9ea2a3dbc78e17a135fd15064ee | f5aa87634f1f968dfffcb941ca87c4e7748fc6ee | refs/heads/master | 2022-12-09T14:36:39.045352 | 2020-09-24T03:01:49 | 2020-09-24T03:01:49 | 298,143,214 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 167 | h | //
// Created by dennis on 9/23/20.
//
#ifndef DESIGN_PATTERNS_ADAPTER_H
#define DESIGN_PATTERNS_ADAPTER_H
class Adapter {
};
#endif //DESIGN_PATTERNS_ADAPTER_H
| [
"alejimenezc@hotmail.com"
] | alejimenezc@hotmail.com |
8bc8c0dcfbf0978ba15f9b6de9ac1f5fb138f682 | 0800620ddb9aacb0eb5fe1550ce2fd20825029d3 | /Dรญa 4/E/E_no.cpp | 182b35db7ac05880eba614e931e0d989bfb381eb | [] | no_license | IgnacioYanjari/Campamento | c95435f754c87045a85fd7dca6798dc6decbc84c | 27ffd2a08093a4eab30c6d54d6e41628c855128e | refs/heads/master | 2021-06-20T17:32:54.315661 | 2017-07-25T04:38:29 | 2017-07-25T04:38:29 | 97,542,924 | 0 | 0 | null | 2020-04-30T19:58:29 | 2017-07-18T02:24:13 | C++ | UTF-8 | C++ | false | false | 2,650 | cpp | // Utilities library
#include <cstdlib>
#include <bitset>
#include <functional>
#include <utility>
#include <tuple>
#include <limits>
#include <cinttypes>
#include <cassert>
// Strings library
#include <cctype>
#include <cstring>
#include <string>
//Containers library
#include <array>
#include <vector>
#include <deque>
#include <list>
#include <forward_list>
#include <set>
#include <map>
#include <unordered_set>
#include <unordered_map>
#include <stack>
#include <queue>
// Algorithms library
#include <algorithm>
// Iterators library
#include <iterator>
// Numerics library
#include <cmath>
#include <complex>
#include <valarray>
#include <numeric>
// Input/Ouput library
#include <iostream>
#include <sstream>
#include <iomanip>
#include <cstdio>
// Localization library
#include <locale>
// Regular expressions library
#include <regex>
// Support code
using std::cout;
using std::cin;
using std::size_t;
template <class Function>
void repeat(std::size_t n, Function f) {
while(n--) f();
}
template <class T>
T input_value(std::istream& input = std::cin) {
T value;
input >> value;
return value;
}
int dp_bottom(std::vector< std::vector<int> > graph, std::vector<int> &memoized, int m, std::map<int, bool> map){
memoized.at(m) = 1;
for(int j = m-1 ; j >=0 ;j--){
int suma=0;
for(int i = m; i >= 0 ;i--){
if( graph.at(i).at(j) == 1 ){
suma+=memoized.at(i);
}
}
memoized.at(j) = suma;
}
return memoized.at(0);
}
int dp_top_down(std::vector< std::vector<int> > graph, std::vector<int> &memoized, int m, std::map<int, bool> map){
// if(memoized)
// memoized.at(m) = 1;
// for(int j = m-1 ; j >=0 ;j--){
// int suma=0;
// for(int i = m; i >= 0 ;i--){
// if( graph.at(i).at(j) == 1 ){
// suma+=memoized.at(i);
// }
// }
// memoized.at(j) = suma;
// }
// return memoized.at(0);
}
int main() {
std::ios_base::sync_with_stdio(false);
std::cin.tie(nullptr);
int N;
bool first = true;
while(cin>>N){
if(!first)
cout<<"\n";
else
first = false;
std::map<int,bool> map;
std::vector< std::vector<int> > graph( N+1 , std::vector<int>(N+1) );
std::vector<int > memoized( N+1 );
for (int i = 0; i < N; i++) {
auto K = input_value<int>();
if( K == 0){
map[i] = true;
}
for (int j = 0; j < K; j++) {
auto node = input_value<int>();
graph.at(node).at(i)=1;
}
}
for (auto &elem : map) {
graph.at(N).at(elem.first)=1;
}
std::cout<< dp_bottom(graph,memoized,N,map)<<"\n";
}
}
| [
"nach116@hotmail.com"
] | nach116@hotmail.com |
7c401d629b761ed66bd633b2c5f6348fd19e4191 | 7e48d392300fbc123396c6a517dfe8ed1ea7179f | /RodentVR/Intermediate/Build/Win64/RodentVR/Inc/AnimationCore/NodeChain.generated.h | 04475bb3592a3d097f440dc3dd816a1e46b40724 | [] | no_license | WestRyanK/Rodent-VR | f4920071b716df6a006b15c132bc72d3b0cba002 | 2033946f197a07b8c851b9a5075f0cb276033af6 | refs/heads/master | 2021-06-14T18:33:22.141793 | 2020-10-27T03:25:33 | 2020-10-27T03:25:33 | 154,956,842 | 1 | 1 | null | 2018-11-29T09:56:21 | 2018-10-27T11:23:11 | C++ | UTF-8 | C++ | false | false | 1,026 | h | // Copyright Epic Games, Inc. All Rights Reserved.
/*===========================================================================
Generated code exported from UnrealHeaderTool.
DO NOT modify this manually! Edit the corresponding .h files instead!
===========================================================================*/
#include "UObject/ObjectMacros.h"
#include "UObject/ScriptMacros.h"
PRAGMA_DISABLE_DEPRECATION_WARNINGS
#ifdef ANIMATIONCORE_NodeChain_generated_h
#error "NodeChain.generated.h already included, missing '#pragma once' in NodeChain.h"
#endif
#define ANIMATIONCORE_NodeChain_generated_h
#define Engine_Source_Runtime_AnimationCore_Public_NodeChain_h_12_GENERATED_BODY \
friend struct Z_Construct_UScriptStruct_FNodeChain_Statics; \
static class UScriptStruct* StaticStruct();
template<> ANIMATIONCORE_API UScriptStruct* StaticStruct<struct FNodeChain>();
#undef CURRENT_FILE_ID
#define CURRENT_FILE_ID Engine_Source_Runtime_AnimationCore_Public_NodeChain_h
PRAGMA_ENABLE_DEPRECATION_WARNINGS
| [
"west.ryan.k@gmail.com"
] | west.ryan.k@gmail.com |
0b4237d4663fce11ccfb7b82522b4d7b34287cf4 | ed590edd688d0ece038a14fba91dfd718a6f002b | /Group 14 QuickSort/QuickSort.cpp | a495f98bdb3d31167b5cbf8afde1cd227714c541 | [] | no_license | humayoonrafei/structureWork | 5f9bae8fbf6e816460ac624776544b1cbba15bed | 1af56b9477b9dc52ae47b82abbed0799baeb7e4d | refs/heads/master | 2022-12-16T02:25:58.521373 | 2020-09-06T03:34:43 | 2020-09-06T03:34:43 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 2,734 | cpp | #include <iostream>
#include <fstream>
#include <string>
using namespace std;
void quickSort(int arr[], int low, int high);
int getPartition(int arr[], int low, int high);
void addDigit(int arr[], int counter);
void countSort(int arr[], int n, int exp);
void radixSort(int arr[], int n);
int getMax(int arr[], int n);
void printArray(int arr[], int n);
void displayData();
int main()
{
displayData();
return 0;
}
int getPartition(int arr[], int low, int high)
{
int pivot = arr[high], i = (low - 1);
for (int j = low; j <= high- 1; j++)
{
if(arr[j] >= pivot)
{
swap(arr[++i], arr[j]);
}
}
swap(arr[i + 1], arr[high]);
return (i + 1);
}
void quickSort(int arr[], int low, int high)
{
if (low < high)
{
int pi = getPartition(arr, low, high);
quickSort(arr, low, pi - 1);
quickSort(arr, pi, high);
}
}
void addDigit(int arr[], int counter)
{
for(int i = 0; i < counter; i++)
{
for(int j = (to_string(arr[0]).length()); (to_string(arr[i]).length()) < j;)
{
arr[i] = stoi(to_string(arr[i])+'5');
}
}
}
void countSort(int arr[], int n, int exp)
{
int temp[n], count[10] = {0};
for (int i = 0; i < n; i++)
{
count[9-arr[i]/exp%10]++;
}
for (int i = 1; i < 10; i++)
{
count[i] += count[i - 1];
}
for (int i = n - 1; i >= 0; i--)
{
temp[--count[(9-(arr[i]/exp%10))]] = arr[i];
}
for (int i = 0; i < n; i++)
{
arr[i] = temp[i];
}
}
void radixSort(int arr[], int n)
{
for (int m = getMax(arr, n), exp = 1; m/exp>0; exp *= 10)
{
countSort(arr, n, exp);
}
}
int getMax(int arr[], int n)
{
int m = arr[0];
for (int i = 1; i < n; i++)
{
if (arr[i] > m)
{
m = arr[i];
}
}
return m;
}
void printArray(int arr[], int n)
{
for(int i = 0; i < n; i++)
{
cout << arr[i] << " ";
}
cout << endl;
}
void displayData()
{
int numA[10];
ifstream infile("input.txt");
int n = 0;
while(infile.good())
{
infile>>numA[n];
n++;
}
cout << "Original array:" << endl;
printArray(numA, n);
cout << endl;
quickSort(numA, 0, n - 1);
cout << "Decending(QuickSort): " << endl;
for (int i = 0; i < n; i++){cout << numA[i] << " ";}
cout << '\n' << endl;
addDigit(numA, n);
cout << "After adding the five's: " << endl;
for (int i = 0; i < n; i++){cout << numA[i] << " ";}
cout << '\n' << endl;
radixSort(numA, n);
cout << "Decending(RadixSort): " << endl;
for (int i = 0; i < n; i++){cout << numA[i] << " ";}
cout << endl;
}
| [
"hormoz_halimi@yahoo.com"
] | hormoz_halimi@yahoo.com |
3c605b30d053912315674f94980c4c5ed214b647 | c40c60471d9d6ceeb55cabe1845418f8056c98f3 | /Sorting Algos/quick_sort.cpp | 0df28a4f7e40987c6c282f2bc0b8fa5d99cdefbe | [] | no_license | bansalmohitwss/Contributed-code-in-Hackoctober | 290ab3bab3f8971d850bc07a2ecec7b77eb4cf23 | e53f5d8abc08bcfcf8cb7842f7c00478a8102f48 | refs/heads/main | 2022-12-21T08:03:23.009756 | 2020-10-03T16:01:46 | 2020-10-03T16:01:46 | 300,914,386 | 0 | 0 | null | 2020-10-03T15:35:59 | 2020-10-03T15:35:58 | null | UTF-8 | C++ | false | false | 720 | cpp | #include<stdio.h>
int partition(int arr[],int l,int u)
{
int i=l,j=u+1,temp;
do{
do{
i++;
}while(i<=u && arr[i]<arr[l]);
do{
j--;
}while(arr[j]>arr[l]);
if(j>i)
{
temp = arr[i];
arr[i] = arr[j];
arr[j] = temp;
}
}while(j>i);
temp = arr[l];
arr[l] = arr[j];
arr[j] = temp;
return j;
}
void quick_sort(int arr[],int l,int u)
{
if(l>=u)
return;
int k = partition(arr,l,u);
quick_sort(arr,l,k-1);
quick_sort(arr,k+1,u);
}
int main()
{
int n;
printf("Enter size of array : ");
scanf("%d",&n);
int i,arr[n];
for(i=0;i<n;i++)
scanf("%d",&arr[i]);
quick_sort(arr,0,n-1);
for(i=0;i<n;i++)
printf("%d ",arr[i]);
return 0;
}
| [
"bansalmohit9414@gmail.com"
] | bansalmohit9414@gmail.com |
baddc9a7467858657209e743d474621fc5efc051 | 1d2247650a919b96c8ca82bf03f71ce7bacbfb94 | /client/client.h | 577960f9c45e23e32b746fdfc309ca9c3b789774 | [
"BSD-3-Clause"
] | permissive | alisheikh/Replicant | e6d217bee9615478af3625c58c046591279630fe | 2091e4f1c55d8bd9c710739bc48ac8eb74004cf4 | refs/heads/master | 2020-12-11T05:53:42.202763 | 2015-05-28T17:41:07 | 2015-05-28T17:41:07 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 7,312 | h | // Copyright (c) 2015, Robert Escriva
// 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 conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above copyright
// notice, this list of conditions and the following disclaimer in the
// documentation and/or other materials provided with the distribution.
// * Neither the name of Replicant nor the names of its contributors may be
// used to endorse or promote products derived from this software without
// specific prior written permission.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
// AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
// IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
// ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
// LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
// CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
// SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
// INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
// CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
// POSSIBILITY OF SUCH DAMAGE.
#ifndef replicant_daemon_client_h_
#define replicant_daemon_client_h_
// C
#include <stdint.h>
// STL
#include <list>
#include <map>
#include <memory>
#include <set>
// e
#include <e/error.h>
#include <e/flagfd.h>
#include <e/intrusive_ptr.h>
// Replicant
#include <replicant.h>
#include "namespace.h"
#include "common/bootstrap.h"
#include "common/ids.h"
#include "client/mapper.h"
BEGIN_REPLICANT_NAMESPACE
class pending;
class pending_robust;
class client
{
public:
client(const char* coordinator, uint16_t port);
client(const char* conn_str);
~client() throw ();
public:
int64_t poke(replicant_returncode* status);
int64_t generate_unique_number(replicant_returncode* status,
uint64_t* number);
int64_t new_object(const char* object,
const char* path,
replicant_returncode* status);
int64_t del_object(const char* object,
replicant_returncode* status);
int64_t kill_object(const char* object,
replicant_returncode* status);
int64_t backup_object(const char* object,
replicant_returncode* status,
char** state, size_t* state_sz);
int64_t restore_object(const char* object,
const char* backup, size_t backup_sz,
replicant_returncode* status);
int64_t list_objects(replicant_returncode* status, char** objects);
int64_t call(const char* object,
const char* func,
const char* input, size_t input_sz,
unsigned flags,
replicant_returncode* status,
char** output, size_t* output_sz);
int64_t cond_wait(const char* object,
const char* cond,
uint64_t state,
replicant_returncode* status,
char** data, size_t* data_sz);
int64_t cond_follow(const char* object,
const char* cond,
enum replicant_returncode* status,
uint64_t* state,
char** data, size_t* data_sz);
int64_t defended_call(const char* object,
const char* enter_func,
const char* enter_input, size_t enter_input_sz,
const char* exit_func,
const char* exit_input, size_t exit_input_sz,
replicant_returncode* status);
int conn_str(replicant_returncode* status, char** servers);
int64_t kill_server(uint64_t token, replicant_returncode* status);
// looping/polling
int64_t loop(int timeout, replicant_returncode* status);
int64_t wait(int64_t id, int timeout, replicant_returncode* status);
void kill(int64_t id);
// Return the fildescriptor that replicant uses for networking
int poll_fd();
// Block unitl there is incoming data or the timeout is reached
int block(int timeout);
// error handling
const char* error_message();
const char* error_location();
void set_error_message(const char* msg);
public:
void reset_busybee();
int64_t inner_loop(replicant_returncode* status);
bool maintain_connection(replicant_returncode* status);
void possibly_clear_flagfd();
void handle_disruption(server_id si);
int64_t send(pending* p);
int64_t send_robust(pending_robust* p);
bool send(server_id si, std::auto_ptr<e::buffer> msg, replicant_returncode* status);
void callback_config();
void callback_tick();
void add_defense(uint64_t nonce) { m_defended.insert(nonce); }
private:
typedef std::map<std::pair<server_id, uint64_t>, e::intrusive_ptr<pending> > pending_map_t;
typedef std::map<std::pair<server_id, uint64_t>, e::intrusive_ptr<pending_robust> > pending_robust_map_t;
typedef std::list<e::intrusive_ptr<pending> > pending_list_t;
typedef std::list<e::intrusive_ptr<pending_robust> > pending_robust_list_t;
// communication
bootstrap m_bootstrap;
mapper m_busybee_mapper;
std::auto_ptr<class busybee_st> m_busybee;
// server selection
uint64_t m_random_token;
// configuration
uint64_t m_config_state;
char* m_config_data;
size_t m_config_data_sz;
replicant_returncode m_config_status;
configuration m_config;
// ticks
uint64_t m_ticks;
replicant_returncode m_tick_status;
// defended nonces
std::set<uint64_t> m_defended;
// operations
int64_t m_next_client_id;
uint64_t m_next_nonce;
pending_map_t m_pending;
pending_robust_map_t m_pending_robust;
pending_list_t m_pending_retry;
pending_robust_list_t m_pending_robust_retry;
pending_list_t m_complete;
// persistent background operations
pending_list_t m_persistent;
// errror
e::error m_last_error;
// push events and problems up to higher layers
e::flagfd m_flagfd;
bool m_backoff;
// used for internal calls, so they have a status ptr
replicant_returncode m_dummy_status;
private:
client(const client&);
client& operator = (const client&);
};
END_REPLICANT_NAMESPACE
#endif // replicant_daemon_client_h_
| [
"robert@rescrv.net"
] | robert@rescrv.net |
6653fbfbe95ce2cfb182301540389c894c4a6862 | 0c55a1486d32b05165400bfe3b724a0c02c3b338 | /src/gui/app/Widgets/Button.h | b7eba7031c629ecf76a59869b3e5c4e6b82b984c | [] | no_license | hubert-kniola/szt-OS | 4ad39a6fc9180779e9a78ea4c5d2b3c82bce5ff9 | 28fe68f10b76e201762cc50f4d14b2b347edb6bc | refs/heads/master | 2022-04-04T13:47:57.049904 | 2020-01-15T20:55:23 | 2020-01-15T20:55:23 | 256,813,954 | 1 | 0 | null | 2020-04-18T17:33:39 | 2020-04-18T17:33:38 | null | UTF-8 | C++ | false | false | 802 | h | #pragma once
#include <SFML/Graphics.hpp>
#include "../CommandButton.h"
class Button
{
public:
Button(float x, float y, const sf::Vector2f& size, const sf::String& title);
virtual ~Button() = default;
bool draw{ false };
bool clicked{ false };
bool areCommandsDrawn{ false };
virtual sf::FloatRect getGlobalBounds() const;
virtual void markAsClicked();
virtual void markAsReleased();
void drawCommands();
void hideCommands();
virtual void setTemporaryColor(const sf::Color& color);
virtual void drawTo(sf::RenderWindow& window) const;
virtual void setPosition(const sf::Vector2f& position);
virtual void setLabelFont(const sf::Font& font);
std::vector<CommandButton> commands;
private:
sf::RectangleShape shape_;
sf::Text label_;
virtual void setRelativeLabelPosition_();
};
| [
"bartoshmen@gmail.com"
] | bartoshmen@gmail.com |
b3e3ade9a327ac8b311807f8d41e05b6d116fc1d | cf7e0b065f3edbb38b4d8bdf4d63d51fc3b0106f | /src/alembic/lib/Alembic/AbcGeom/XformOp.cpp | fb03753b49e407b9176b8216a38941e53c236504 | [] | no_license | appleseedhq/windows-deps | 06478bc8ec8f4a9ec40399b763a038e5a76dfbf7 | 7955c4fa1c9e39080862deb84f5e4ddf0cf71f62 | refs/heads/master | 2022-11-21T07:16:35.646878 | 2019-12-11T19:46:46 | 2020-07-19T08:57:23 | 16,730,675 | 5 | 8 | null | 2020-07-19T08:57:25 | 2014-02-11T12:54:46 | C++ | UTF-8 | C++ | false | false | 15,454 | cpp | //-*****************************************************************************
//
// Copyright (c) 2009-2011,
// Sony Pictures Imageworks, Inc. and
// Industrial Light & Magic, a division of Lucasfilm Entertainment Company Ltd.
//
// 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 conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above
// copyright notice, this list of conditions and the following disclaimer
// in the documentation and/or other materials provided with the
// distribution.
// * Neither the name of Sony Pictures Imageworks, nor
// Industrial Light & Magic nor the names of their contributors may be used
// to endorse or promote products derived from this software without specific
// prior written permission.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
//
//-*****************************************************************************
#include <Alembic/AbcGeom/XformOp.h>
#include <boost/format.hpp>
namespace Alembic {
namespace AbcGeom {
namespace ALEMBIC_VERSION_NS {
//-*****************************************************************************
XformOp::XformOp()
: m_type( kTranslateOperation )
, m_hint( 0 )
{
m_channels.clear();
m_channels.resize( 3 );
}
//-*****************************************************************************
XformOp::XformOp( const XformOperationType iType,
const Alembic::Util::uint8_t iHint )
: m_type( iType )
{
m_channels.clear();
switch ( m_type )
{
case kRotateXOperation:
case kRotateYOperation:
case kRotateZOperation:
m_channels.resize( 1 );
break;
case kScaleOperation:
case kTranslateOperation:
m_channels.resize( 3 );
break;
case kRotateOperation:
m_channels.resize( 4 );
break;
case kMatrixOperation:
m_channels.resize( 16 );
break;
}
setHint( iHint );
}
//-*****************************************************************************
XformOp::XformOp( const Alembic::Util::uint8_t iEncodedOp )
{
m_type = (XformOperationType)(iEncodedOp >> 4);
setHint( iEncodedOp & 0xF );
switch ( m_type )
{
case kRotateXOperation:
case kRotateYOperation:
case kRotateZOperation:
m_channels.resize( 1 );
break;
case kScaleOperation:
case kTranslateOperation:
m_channels.resize( 3 );
break;
case kRotateOperation:
m_channels.resize( 4 );
break;
case kMatrixOperation:
m_channels.resize( 16 );
break;
}
}
//-*****************************************************************************
XformOperationType XformOp::getType() const
{
return m_type;
}
//-*****************************************************************************
void XformOp::setType( const XformOperationType iType )
{
m_type = iType;
m_hint = 0;
switch ( m_type )
{
case kRotateXOperation:
case kRotateYOperation:
case kRotateZOperation:
m_channels.resize( 1 );
break;
case kScaleOperation:
case kTranslateOperation:
m_channels.resize( 3 );
break;
case kRotateOperation:
m_channels.resize( 4 );
break;
case kMatrixOperation:
m_channels.resize( 16 );
break;
}
}
//-*****************************************************************************
uint8_t XformOp::getHint() const
{
return m_hint;
}
//-*****************************************************************************
void XformOp::setHint( const Alembic::Util::uint8_t iHint )
{
// if a non-existant hint value is set, default it to 0
if ( m_type == kScaleOperation && iHint > kScaleHint )
{
m_hint = 0;
}
else if ( m_type == kTranslateOperation && iHint >
kRotatePivotTranslationHint )
{
m_hint = 0;
}
else if ( ( m_type == kRotateOperation || m_type == kRotateXOperation ||
m_type == kRotateYOperation || m_type == kRotateZOperation )
&& iHint > kRotateOrientationHint )
{
m_hint = 0;
}
else if ( m_type == kMatrixOperation && iHint > kMayaShearHint )
{
m_hint = 0;
}
else
{
m_hint = iHint;
}
}
//-*****************************************************************************
bool XformOp::isXAnimated() const
{
if ( m_type == kRotateXOperation || m_type == kRotateYOperation ||
m_type == kRotateZOperation )
{
return false;
}
return m_animChannels.count( 0 ) > 0;
}
//-*****************************************************************************
bool XformOp::isYAnimated() const
{
if ( m_type == kRotateXOperation || m_type == kRotateYOperation ||
m_type == kRotateZOperation )
{
return false;
}
return m_animChannels.count( 1 ) > 0;
}
//-*****************************************************************************
bool XformOp::isZAnimated() const
{
if ( m_type == kRotateXOperation || m_type == kRotateYOperation ||
m_type == kRotateZOperation )
{
return false;
}
return m_animChannels.count( 2 ) > 0;
}
//-*****************************************************************************
bool XformOp::isAngleAnimated() const
{
if ( m_type == kRotateXOperation || m_type == kRotateYOperation ||
m_type == kRotateZOperation )
{
return m_animChannels.count( 0 ) > 0;
}
return m_animChannels.count( 3 ) > 0;
}
//-*****************************************************************************
bool XformOp::isChannelAnimated( std::size_t iIndex ) const
{
return m_animChannels.count( iIndex ) > 0;
}
//-*****************************************************************************
std::size_t XformOp::getNumChannels() const
{
return m_channels.size();
}
//-*****************************************************************************
double XformOp::getDefaultChannelValue( std::size_t iIndex ) const
{
switch ( m_type )
{
case kTranslateOperation:
case kRotateOperation:
case kRotateXOperation:
case kRotateYOperation:
case kRotateZOperation:
return 0.0;
case kScaleOperation:
return 1.0;
case kMatrixOperation:
switch ( iIndex )
{
case 0:
case 5:
case 10:
case 15:
return 1.0;
default:
return 0.0;
}
default:
return 0.0;
}
}
//-*****************************************************************************
double XformOp::getChannelValue( std::size_t iIndex ) const
{
return m_channels[iIndex];
}
//-*****************************************************************************
void XformOp::setChannelValue( std::size_t iIndex, double iVal )
{
m_channels[iIndex] = iVal;
}
//-*****************************************************************************
Alembic::Util::uint8_t XformOp::getOpEncoding() const
{
return ( m_type << 4 ) | ( m_hint & 0xF );
}
//-*****************************************************************************
bool XformOp::isTranslateOp() const
{
return m_type == kTranslateOperation;
}
//-*****************************************************************************
bool XformOp::isScaleOp() const
{
return m_type == kScaleOperation;
}
//-*****************************************************************************
bool XformOp::isRotateOp() const
{
return m_type == kRotateOperation;
}
//-*****************************************************************************
bool XformOp::isMatrixOp() const
{
return m_type == kMatrixOperation;
}
//-*****************************************************************************
bool XformOp::isRotateXOp() const
{
return m_type == kRotateXOperation;
}
//-*****************************************************************************
bool XformOp::isRotateYOp() const
{
return m_type == kRotateYOperation;
}
//-*****************************************************************************
bool XformOp::isRotateZOp() const
{
return m_type == kRotateZOperation;
}
//-*****************************************************************************
void XformOp::setVector( const Abc::V3d &iVec )
{
ABCA_ASSERT( m_type != kMatrixOperation,
"Meaningless to set Abc::V3d on matrix op" );
m_channels[0] = iVec.x;
m_channels[1] = iVec.y;
m_channels[2] = iVec.z;
}
//-*****************************************************************************
void XformOp::setTranslate( const Abc::V3d &iTrans )
{
ABCA_ASSERT( m_type == kTranslateOperation,
"Meaningless to set translate on non-translate op." );
this->setVector( iTrans );
}
//-*****************************************************************************
void XformOp::setScale( const Abc::V3d &iScale )
{
ABCA_ASSERT( m_type == kScaleOperation,
"Meaningless to set scale on non-scale op." );
this->setVector( iScale );
}
//-*****************************************************************************
void XformOp::setAxis( const Abc::V3d &iAxis )
{
ABCA_ASSERT( m_type == kRotateOperation,
"Meaningless to set rotation axis on non-rotation or fixed "
"angle rotation op." );
this->setVector( iAxis );
}
//-*****************************************************************************
void XformOp::setAngle( const double iAngle )
{
switch ( m_type )
{
case kRotateOperation:
m_channels[3] = iAngle;
break;
case kRotateXOperation:
case kRotateYOperation:
case kRotateZOperation:
m_channels[0] = iAngle;
break;
default:
ABCA_THROW( "Meaningless to set rotation angle on non-rotation op." );
}
}
//-*****************************************************************************
void XformOp::setMatrix( const Abc::M44d &iMatrix )
{
ABCA_ASSERT( m_type == kMatrixOperation,
"Cannot set non-matrix op from Abc::M44d" );
for ( size_t i = 0 ; i < 4 ; ++i )
{
for ( size_t j = 0 ; j < 4 ; ++j )
{
m_channels[( i * 4 ) + j] = iMatrix.x[i][j];
}
}
}
//-*****************************************************************************
Abc::V3d XformOp::getVector() const
{
ABCA_ASSERT( m_type != kMatrixOperation,
"Meaningless to get Abc::V3d from matrix op" );
return Abc::V3d( m_channels[0], m_channels[1], m_channels[2] );
}
//-*****************************************************************************
Abc::V3d XformOp::getTranslate() const
{
ABCA_ASSERT( m_type == kTranslateOperation,
"Meaningless to get translate vector from non-translate op." );
return this->getVector();
}
//-*****************************************************************************
Abc::V3d XformOp::getScale() const
{
ABCA_ASSERT( m_type == kScaleOperation,
"Meaningless to get scaling vector from non-scale op." );
return this->getVector();
}
//-*****************************************************************************
Abc::V3d XformOp::getAxis() const
{
switch ( m_type )
{
case kRotateOperation:
return this->getVector();
case kRotateXOperation:
return Abc::V3d(1.0, 0.0, 0.0);
case kRotateYOperation:
return Abc::V3d(0.0, 1.0, 0.0);
case kRotateZOperation:
return Abc::V3d(0.0, 0.0, 1.0);
default:
ABCA_THROW( "Meaningless to get rotation axis from non-rotation op." );
}
return Abc::V3d(0.0, 0.0, 0.0);
}
//-*****************************************************************************
double XformOp::getAngle() const
{
switch ( m_type )
{
case kRotateOperation:
return m_channels[3];
case kRotateXOperation:
case kRotateYOperation:
case kRotateZOperation:
return m_channels[0];
default:
ABCA_THROW( "Meaningless to get rotation angle from non-rotation op." );
}
return 0.0;
}
//-*****************************************************************************
double XformOp::getXRotation() const
{
ABCA_ASSERT( m_type == kRotateOperation || m_type == kRotateXOperation,
"Meaningless to get rotation angle from non-rotation op." );
if ( m_type == kRotateXOperation )
{
return m_channels[0];
}
else
{
Abc::M44d m;
Abc::V3d rot;
m.makeIdentity();
m.setAxisAngle( this->getVector(), DegreesToRadians( m_channels[3] ) );
Imath::extractEulerXYZ( m, rot );
return RadiansToDegrees( rot[0] );
}
}
//-*****************************************************************************
double XformOp::getYRotation() const
{
ABCA_ASSERT( m_type == kRotateOperation || m_type == kRotateYOperation,
"Meaningless to get rotation angle from non-rotation op." );
if ( m_type == kRotateYOperation )
{
return m_channels[0];
}
else
{
Abc::M44d m;
Abc::V3d rot;
m.makeIdentity();
m.setAxisAngle( this->getVector(), DegreesToRadians( m_channels[3] ) );
Imath::extractEulerXYZ( m, rot );
return RadiansToDegrees( rot[1] );
}
}
//-*****************************************************************************
double XformOp::getZRotation() const
{
ABCA_ASSERT( m_type == kRotateOperation || m_type == kRotateZOperation,
"Meaningless to get rotation angle from non-rotation op." );
if ( m_type == kRotateZOperation )
{
return m_channels[0];
}
else
{
Abc::M44d m;
Abc::V3d rot;
m.makeIdentity();
m.setAxisAngle( this->getVector(), DegreesToRadians( m_channels[3] ) );
Imath::extractEulerXYZ( m, rot );
return RadiansToDegrees( rot[2] );
}
}
//-*****************************************************************************
Abc::M44d XformOp::getMatrix() const
{
ABCA_ASSERT( m_type == kMatrixOperation,
"Can't get matrix from non-matrix op." );
Abc::M44d ret;
for ( size_t i = 0 ; i < 4 ; ++i )
{
for ( size_t j = 0 ; j < 4 ; ++j )
{
ret.x[i][j] = m_channels[( i * 4 ) + j];
}
}
return ret;
}
} // End namespace ALEMBIC_VERSION_NS
} // End namespace AbcGeom
} // End namespace Alembic
| [
"beaune@aist.enst.fr"
] | beaune@aist.enst.fr |
e81d60a6fd658dbda3df44adda6c1001824ea391 | d988f3302c7c4f49583fec21c07658ddb09b81e0 | /src/Cpl/TShell/Context_.h | ce28b9bce0f2a94c1b1a7e328de85c0d5aebb6b6 | [] | no_license | johnttaylor/colony.apps | 2b10141d8cb30067a5e387e6c53af9955549b17b | 839f3d62b660111ab122a96f550c8ae9de63faa0 | refs/heads/develop | 2023-05-10T17:24:58.286447 | 2021-12-05T20:54:43 | 2021-12-05T20:54:43 | 41,272,799 | 0 | 0 | null | 2021-12-05T20:54:45 | 2015-08-24T00:10:30 | C | UTF-8 | C++ | false | false | 2,319 | h | #ifndef Cpl_TShell_ContextApi_x_h_
#define Cpl_TShell_ContextApi_x_h_
/*-----------------------------------------------------------------------------
* This file is part of the Colony.Core Project. The Colony.Core Project is an
* open source project with a BSD type of licensing agreement. See the license
* agreement (license.txt) in the top/ directory or on the Internet at
* http://integerfox.com/colony.core/license.txt
*
* Copyright (c) 2014-2020 John T. Taylor
*
* Redistributions of the source code must retain the above copyright notice.
*----------------------------------------------------------------------------*/
/** @file */
#include "Cpl/TShell/ProcessorApi.h"
#include "Cpl/TShell/Command.h"
#include "Cpl/Container/Map.h"
///
namespace Cpl {
///
namespace TShell {
/** This Private Namespace class defines a "Context" for a TShell command. The
Context provide common infrastructure, information, buffers, etc. that
facilitates interaction between the Command Processor and individual
commands. The application SHOULD NEVER directly access this interface.
*/
class Context_ : public ProcessorApi
{
public:
/// This method returns the list of implemented commands
virtual Cpl::Container::Map<Command>& getCommands() noexcept = 0;
public:
/// This method encodes and outputs the specified message/text. The method returns false if there was Output Stream error
virtual bool writeFrame( const char* text ) noexcept = 0;
/// Same as writeFrame(), but only outputs (at most) 'N' bytes as the content of the frame
virtual bool writeFrame( const char* text, size_t maxBytes ) noexcept = 0;
public:
/** This method returns a working buffer for a command to format its
output prior to 'writing the frame'.
*/
virtual Cpl::Text::String& getOutputBuffer() noexcept = 0;
/** A shared/common working buffer. The buffer is guaranteed to be large
enough hold any valid token from an input frame. The contents of
buffer is guaranteed to be empty/cleared.
*/
virtual Cpl::Text::String& getTokenBuffer() noexcept = 0;
/** Same as getTokenBuffer(), except provides a second/separate token buffer
*/
virtual Cpl::Text::String& getTokenBuffer2() noexcept = 0;
public:
/// Virtual destructor
virtual ~Context_() {}
};
}; // end namespaces
};
#endif // end header latch
| [
"john.t.taylor@gmail.com"
] | john.t.taylor@gmail.com |
a938bbd39c9e759f5a70f9583b0b1826d3328a60 | 8ad7a692130161bac7b07135326dd7cad63144fb | /Prรกctica 7/Main.cpp | 9fbbf44eca0905a465465298e7546deddc518426 | [] | no_license | Javi96/EDA | c5bb31e14a6d62dd1c71e31bae0becb82ba30582 | 2ebc755d0a3be7db14287d0849f20951f045c76d | refs/heads/master | 2021-01-13T14:45:19.159531 | 2017-06-28T15:22:47 | 2017-06-28T15:22:47 | 76,579,268 | 1 | 1 | null | 2017-03-06T21:27:01 | 2016-12-15T17:02:18 | C++ | UTF-8 | C++ | false | false | 1,380 | cpp | #include "Arbin.h"
#include <iostream>
#include <fstream>
#include <string>
using namespace std;
void busquedaEnProfundidad(const Arbin<char>& falda, int & cuenta, int & cuentaParcial) {
Arbin<char> der = falda.hijoDer();
Arbin<char> izq = falda.hijoIz();
if (falda.raiz() == 'X') {
cuenta = cuenta + cuentaParcial * 2;
}
if (der.esVacio() && izq.esVacio()) {
cuentaParcial--;
}
else {
if (!izq.esVacio()) {
cuentaParcial++;
busquedaEnProfundidad(izq, cuenta, cuentaParcial);
}
if (!der.esVacio()) {
cuentaParcial++;
busquedaEnProfundidad(der, cuenta, cuentaParcial);
}
cuentaParcial--;
}
}
int tiempoAyuda(const Arbin<char>& falda) {
// A IMPLEMENTAR
int cuenta = 0, cuentaParcial = 0;
busquedaEnProfundidad(falda, cuenta, cuentaParcial);
return cuenta;
}
Arbin<char> leeArbol(istream& in) {
char c;
in >> c;
switch (c) {
case '#': return Arbin<char>();
case '[': {
char raiz;
in >> raiz;
in >> c;
return Arbin<char>(raiz);
}
case '(': {
Arbin<char> iz = leeArbol(in);
char raiz;
in >> raiz;
Arbin<char> dr = leeArbol(in);
in >> c;
return Arbin<char>(iz, raiz, dr);
}
default: return Arbin<char>();
}
}
int main() {
Arbin<char> falda;
while (cin.peek() != EOF) {
cout << tiempoAyuda(leeArbol(cin));
string restoLinea;
getline(cin, restoLinea);
if (cin.peek() != EOF) cout << endl;
}
return 0;
} | [
"josejaco@ucm.es"
] | josejaco@ucm.es |
104040b3d3b7b542b7eb4a58a645168b0ffe7a16 | d2fcf9142c2a35065271848d0bf0b2ef38c7643b | /cf/dp_problems/580A.cpp | 3b65b89e58945470a5b3206e0dcfbe59192dfe5e | [] | no_license | yashrsharma44/cp-archive | ede0e3cb67a388f760ef18907ad64b46e6223b9a | 1baea4d1614fa637d9e4acf9dbaa261aec9f906e | refs/heads/master | 2020-11-24T04:53:07.055089 | 2019-12-14T05:53:22 | 2019-12-14T05:53:22 | 227,973,288 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 366 | cpp | #include <bits/stdc++.h>
using namespace std;
int main(){
int n;
cin>>n;
vector<int> res;
for(int i=0;i<n;i++){
int a;
cin>>a;
res.push_back(a);
}
int len_max=1;
int mx = -1;
for(int i=1;i<res.size();i++){
if(res[i-1] <= res[i]){
len_max+=1;
} else {
mx = max(mx, len_max);
len_max = 1;
}
}
cout << max(len_max, mx)<<endl;
} | [
"yashrsharma44@gmail.com"
] | yashrsharma44@gmail.com |
4de421a27789e0f9b566285cd2eccc22b36f64a8 | 474ca3fbc2b3513d92ed9531a9a99a2248ec7f63 | /ThirdParty/boost_1_63_0/libs/hana/test/tuple/auto/remove_range.cpp | 3f3982dc7e711b96704a45ca4abca26c9358d52d | [
"BSL-1.0",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | LazyPlanet/MX-Architecture | 17b7b2e6c730409b22b7f38633e7b1f16359d250 | 732a867a5db3ba0c716752bffaeb675ebdc13a60 | refs/heads/master | 2020-12-30T15:41:18.664826 | 2018-03-02T00:59:12 | 2018-03-02T00:59:12 | 91,156,170 | 4 | 0 | null | 2018-02-04T03:29:46 | 2017-05-13T07:05:52 | C++ | UTF-8 | C++ | false | false | 260 | cpp | // Copyright Louis Dionne 2013-2016
// Distributed under the Boost Software License, Version 1.0.
// (See accompanying file LICENSE.md or copy at http://boost.org/LICENSE_1_0.txt)
#include "_specs.hpp"
#include <auto/remove_range.hpp>
int main() { }
| [
"1211618464@qq.com"
] | 1211618464@qq.com |
d921bfc61639abbf0ea5ef515f5a472657a8150c | a3bbea953d7b999f31e15a05e5c60fdfaf6f59c5 | /C/0311/helloo.cpp | 18afc37bd3202dd7c8fdf84a7333a78e6d16ea82 | [] | no_license | YaolinGe/KTH_MSc_Matlab_Scripts_for_Beacon_Transmitter | c08d279c6b50821cd3ef1825b1267accdfcfc2ee | a2bfba9479c5e845fc5c04c17cacaf676ef85a66 | refs/heads/master | 2022-09-02T15:43:41.001247 | 2020-05-24T20:28:45 | 2020-05-24T20:28:45 | 266,617,530 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 128 | cpp | // #include<stdio.h>
#include<iostream>
using namespace std;
int main()
{
int a = 3.9;
cout<<"the out is "<< a<<endl;
} | [
"YL@users.noreply.github.com"
] | YL@users.noreply.github.com |
b2c60c32c917cf469e211e93410aadf0e12b7809 | 8c0c4f9f3ecb00a671b595b9e3ac0b4498ef93ac | /CellToy/Source/Genome.cpp | bcfc8cd3c49ca3befb83266eea9995b6974a6fdf | [] | no_license | nstearns96/CellToy | b1ae3967fb90362f0759298a41177af71fc458b3 | 4d0fdfdae5e7b7d919a4db11193962c72385f013 | refs/heads/master | 2020-09-16T03:42:00.748112 | 2019-12-15T19:26:21 | 2019-12-15T19:26:21 | 223,640,631 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 66 | cpp | #include "Genome.h"
Genome::Genome()
{
}
Genome::~Genome()
{
}
| [
"nstearns96@gmail.com"
] | nstearns96@gmail.com |
43b7e87795844a6262b4426d132049c6518cda6c | 5add8458e6ea2af3c5ec1b87718b9e9e9f733974 | /GraphicsProject/shapes.h | f362b4a6aab2c49bddc852bd39b652544346af02 | [] | no_license | sean-h/graphics-project | cc436619e7acee87f88fecd178b59ede09d07312 | a0ca0107411bb57b1078218d8fbc179ce6c899ad | refs/heads/master | 2021-01-19T10:03:25.023018 | 2014-01-26T19:34:02 | 2014-01-26T19:34:02 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,091 | h | /***********
* shapes.h
***********/
#ifndef __SHAPES_H__
#define __SHAPES_H__
#include "Angel.h"
#include <vector>
class Shape {
protected:
vec2 position;
int vertexCount;
vec2 *vertices;
vec2 *transformedVertices;
vec3 *colors;
GLuint buffer;
void draw(GLenum, GLuint);
public:
Shape();
void draw(GLuint);
void move(float, float);
void move(vec2);
void rotate(float);
void setPosition(float, float);
void setPosition(vec2);
vec2 getPosition();
void setColor(vec3);
void setVertexColor(int, vec3);
void updateTransformedVertices();
};
class Circle : public Shape {
private:
float radius;
public:
Circle();
Circle(float, int, vec2, vec3);
void draw(GLuint);
float getRadius();
void changeRadius(float);
void makeJagged();
};
class Rect : public Shape {
private:
vec2 topLeft;
vec2 bottomRight;
void updateRect();
public:
Rect(vec2, float, float, vec3);
Rect(vec2, vec2, vec3);
vec2 getCenter();
vec2 getTopLeft();
vec2 getBottomRight();
float getHeight();
float getWidth();
void draw(GLuint);
void setWidth(float);
void setHeight(float);
};
#endif | [
"seanhumeniuk@gmail.com"
] | seanhumeniuk@gmail.com |
79dadd42d0e8f6354ba013a9d114b61c0b9be1be | 12d83468a3544af4e9d4f26711db1755d53838d6 | /cplusplus_basic/Qt/boost/icl/type_traits/is_element_container.hpp | 698fd95e1aaaf4fe940a3a09bfedb5936e1f5834 | [] | no_license | ngzHappy/cxx17 | 5e06a31d127b873355cab3a8fe0524f1223715da | 22d3f55bfe2a9ba300bbb65cfcbdd2dc58150ca4 | refs/heads/master | 2021-01-11T20:48:19.107618 | 2017-01-17T17:29:16 | 2017-01-17T17:29:16 | 79,188,658 | 1 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,801 | hpp | ๏ปฟ/*-----------------------------------------------------------------------------+
Copyright (c) 2008-2009: Joachim Faulhaber
+------------------------------------------------------------------------------+
Distributed under the Boost Software License, Version 1.0.
(See accompanying file LICENCE.txt or copy at
http://www.boost.org/LICENSE_1_0.txt)
+-----------------------------------------------------------------------------*/
#ifndef BOOST_ICL_TYPE_TRAITS_IS_ELEMENT_CONTAINER_HPP_JOFA_090830
#define BOOST_ICL_TYPE_TRAITS_IS_ELEMENT_CONTAINER_HPP_JOFA_090830
#include <Qt/boost/mpl/and.hpp>
#include <Qt/boost/mpl/or.hpp>
#include <Qt/boost/mpl/not.hpp>
#include <Qt/boost/icl/type_traits/is_container.hpp>
#include <Qt/boost/icl/type_traits/is_interval_container.hpp>
#include <Qt/boost/icl/type_traits/is_set.hpp>
namespace boost{ namespace icl
{
template<class Type>
struct is_element_map
{
typedef is_element_map<Type> type;
BOOST_STATIC_CONSTANT(bool, value =
(mpl::and_<is_map<Type>, mpl::not_<is_interval_container<Type> > >::value)
);
};
template<class Type>
struct is_element_set
{
typedef is_element_set<Type> type;
BOOST_STATIC_CONSTANT(bool, value =
(mpl::or_< mpl::and_< is_set<Type>
, mpl::not_<is_interval_container<Type> > >
, is_std_set<Type>
>::value)
);
};
template <class Type>
struct is_element_container
{
typedef is_element_container<Type> type;
BOOST_STATIC_CONSTANT(bool, value =
(mpl::or_<is_element_set<Type>, is_element_map<Type> >::value)
);
};
}} // namespace boost icl
#endif
| [
"819869472@qq.com"
] | 819869472@qq.com |
0401b0ca7e1e016f8afecb761b08ebad586cc868 | 12b377946d78de96d4096e55874933fe9bb38619 | /ash/wm/common/wm_globals.h | 28823ef7a353b1fa32000dd0ab02e00a2b0a3bb0 | [
"BSD-3-Clause"
] | permissive | neuyang/chromium | 57c0c6ef86e933bc5de11a9754e5ef6f9752badb | afb8f54b782055923cadd711452c2448f3f7b5b4 | refs/heads/master | 2023-02-20T21:47:59.999916 | 2016-04-20T21:38:20 | 2016-04-20T21:41:24 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,670 | h | // Copyright 2016 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef ASH_WM_COMMON_WM_GLOBALS_H_
#define ASH_WM_COMMON_WM_GLOBALS_H_
#include <stdint.h>
#include <vector>
#include "ash/ash_export.h"
namespace gfx {
class Rect;
}
namespace ash {
namespace wm {
class WmWindow;
// Used for accessing global state.
class ASH_EXPORT WmGlobals {
public:
virtual ~WmGlobals() {}
// This is necessary for a handful of places that is difficult to plumb
// through context.
static WmGlobals* Get();
virtual WmWindow* GetActiveWindow() = 0;
// Returns the root window for the specified display.
virtual WmWindow* GetRootWindowForDisplayId(int64_t display_id) = 0;
// Returns the root window that newly created windows should be added to.
// NOTE: this returns the root, newly created window should be added to the
// appropriate container in the returned window.
virtual WmWindow* GetRootWindowForNewWindows() = 0;
// returns the list of more recently used windows excluding modals.
virtual std::vector<WmWindow*> GetMruWindowListIgnoreModals() = 0;
// Returns true if the first window shown on first run should be
// unconditionally maximized, overriding the heuristic that normally chooses
// the window size.
virtual bool IsForceMaximizeOnFirstRun() = 0;
// See aura::client::CursorClient for details on these.
virtual void LockCursor() = 0;
virtual void UnlockCursor() = 0;
virtual std::vector<WmWindow*> GetAllRootWindows() = 0;
};
} // namespace wm
} // namespace ash
#endif // ASH_WM_COMMON_WM_GLOBALS_H_
| [
"commit-bot@chromium.org"
] | commit-bot@chromium.org |
e219e2f2618a14e11cc7156a0aa4a05d004bbc58 | 6c4f73b08cd78cd45245ae8f32cf05ecd45a4f08 | /src/align.cc | 9a48e338c963ce6979aa72518f5621b19e09af35 | [
"MIT"
] | permissive | alexeden/realsense-node | 14b69feae201afd427d07e1a162ea54806a91efc | a4060c8fdcc091d933fb4c895f04e72f44328e63 | refs/heads/develop | 2023-01-08T23:08:26.214863 | 2020-08-04T04:01:16 | 2020-08-04T04:01:16 | 200,130,817 | 0 | 0 | MIT | 2023-01-06T00:50:27 | 2019-08-01T23:18:33 | C++ | UTF-8 | C++ | false | false | 3,100 | cc | #ifndef ALIGN_H
#define ALIGN_H
#include "frame_callbacks.cc"
#include "frameset.cc"
#include <librealsense2/hpp/rs_types.hpp>
#include <napi.h>
using namespace Napi;
class RSAlign : public ObjectWrap<RSAlign> {
public:
static Object Init(Napi::Env env, Object exports) {
Napi::Function func = DefineClass(
env,
"RSAlign",
{
InstanceMethod("destroy", &RSAlign::Destroy),
InstanceMethod("process", &RSAlign::Process),
InstanceMethod("waitForFrames", &RSAlign::WaitForFrames),
});
constructor = Napi::Persistent(func);
constructor.SuppressDestruct();
exports.Set("RSAlign", func);
return exports;
}
RSAlign(const CallbackInfo& info)
: ObjectWrap<RSAlign>(info)
, align_(nullptr)
, frame_queue_(nullptr)
, error_(nullptr) {
auto stream = static_cast<rs2_stream>(info[0].ToNumber().Int32Value());
this->align_ = GetNativeResult<rs2_processing_block*>(rs2_create_align, &this->error_, stream, &this->error_);
this->frame_queue_ = GetNativeResult<rs2_frame_queue*>(rs2_create_frame_queue, &this->error_, 1, &this->error_);
if (!this->frame_queue_) return;
auto callback = new FrameCallbackForFrameQueue(this->frame_queue_);
CallNativeFunc(rs2_start_processing, &this->error_, this->align_, callback, &this->error_);
}
~RSAlign() {
DestroyMe();
}
private:
friend class RSPipeline;
static FunctionReference constructor;
rs2_processing_block* align_;
rs2_frame_queue* frame_queue_;
rs2_error* error_;
void DestroyMe() {
if (error_) rs2_free_error(error_);
error_ = nullptr;
if (align_) rs2_delete_processing_block(align_);
align_ = nullptr;
if (frame_queue_) rs2_delete_frame_queue(frame_queue_);
frame_queue_ = nullptr;
}
Napi::Value Destroy(const CallbackInfo& info) {
this->DestroyMe();
return info.This();
}
Napi::Value Process(const CallbackInfo& info) {
auto frameset = ObjectWrap<RSFrameSet>::Unwrap(info[0].ToObject());
auto target_fs = ObjectWrap<RSFrameSet>::Unwrap(info[1].ToObject());
if (!frameset || !target_fs) return Boolean::New(info.Env(), false);
// rs2_process_frame will release the input frame, so we need to addref
CallNativeFunc(rs2_frame_add_ref, &this->error_, frameset->GetFrames(), &this->error_);
if (this->error_) return Boolean::New(info.Env(), false);
CallNativeFunc(rs2_process_frame, &this->error_, this->align_, frameset->GetFrames(), &this->error_);
if (this->error_) return Boolean::New(info.Env(), false);
rs2_frame* frame = nullptr;
auto ret_code
= GetNativeResult<int>(rs2_poll_for_frame, &this->error_, this->frame_queue_, &frame, &this->error_);
if (!ret_code) return Boolean::New(info.Env(), false);
target_fs->Replace(frame);
return Boolean::New(info.Env(), true);
}
Napi::Value WaitForFrames(const CallbackInfo& info) {
rs2_frame* result
= GetNativeResult<rs2_frame*>(rs2_wait_for_frame, &this->error_, this->frame_queue_, 5000, &this->error_);
if (!result) return info.Env().Undefined();
return RSFrameSet::NewInstance(info.Env(), result);
}
};
Napi::FunctionReference RSAlign::constructor;
#endif
| [
"alexandereden91@gmail.com"
] | alexandereden91@gmail.com |
b11c3aadd34f395a0e6b9c23f14133a1cd392159 | a5aaa2cf1a4f31662a9f25bdb065882189ce1b4e | /Cylcops/Cylcops.ino | 0c04ce275d8537af072bb7e1a46859daed495c53 | [] | no_license | snersnasskve/Arduino | ee56836d142a9d83ac56c127618298c958d53f1f | 21c46ef2381e99e611b5be2eed78ee39c1e4d854 | refs/heads/master | 2021-01-17T11:32:21.136164 | 2018-02-25T06:29:10 | 2018-02-25T06:29:10 | 84,039,170 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 5,613 | ino | #include <Adafruit_NeoPixel.h>
#include <Ultrasonic.h>
// This example drives the stepper motors directly
// It makes the robot perform the "HullPixelBot Dance"
// See if you can change the moves.
// www.robmiles.com/hullpixelbot
////////////////////////////////////////////////
//declare variables for the motor pins
int rmotorPin1 = 17; // Blue - 28BYJ48 pin 1
int rmotorPin2 = 16; // Pink - 28BYJ48 pin 2
int rmotorPin3 = 15; // Yellow - 28BYJ48 pin 3
int rmotorPin4 = 14; // Orange - 28BYJ48 pin 4
// Red - 28BYJ48 pin 5 (VCC)
int lmotorPin1 = 4; // Blue - 28BYJ48 pin 1
int lmotorPin2 = 5; // Pink - 28BYJ48 pin 2
int lmotorPin3 = 6; // Yellow - 28BYJ48 pin 3
int lmotorPin4 = 7; // Orange - 28BYJ48 pin 4
// Red - 28BYJ48 pin 5 (VCC)
// Proximity sensor
int proximityTrig = 12;
int proximityEcho = 13;
Ultrasonic ultrasonic(proximityTrig,proximityEcho); // (Trig PIN,Echo PIN)
#define PIN 3
Adafruit_NeoPixel strip = Adafruit_NeoPixel(2, PIN, NEO_GRB + NEO_KHZ800);
int motorSpeed = 1200; //variable to set stepper speed
int count = 0; // count of steps made
int countsperrev = 512; // number of steps per full revolution
int lookup[8] = {B01000, B01100, B00100, B00110, B00010, B00011, B00001, B01001};
int photocellLeft = 4;
int photocellRight = 5;
float lengthOfRotation = 180.0f;
//////////////////////////////////////////////////////////////////////////////
void setup() {
//declare the motor pins as outputs
pinMode(lmotorPin1, OUTPUT);
pinMode(lmotorPin2, OUTPUT);
pinMode(lmotorPin3, OUTPUT);
pinMode(lmotorPin4, OUTPUT);
pinMode(rmotorPin1, OUTPUT);
pinMode(rmotorPin2, OUTPUT);
pinMode(rmotorPin3, OUTPUT);
pinMode(rmotorPin4, OUTPUT);
pinMode(proximityTrig, OUTPUT);
pinMode(proximityEcho, INPUT);
Serial.begin(9600);
strip.begin();
strip.setPixelColor(0, 00,20,20);
strip.show();
}
const int STOP = 0;
const int FORWARD = 1;
const int BACK = 2;
const int LEFT = 3;
const int RIGHT = 4;
const int SHARPLEFT = 5;
const int SHARPRIGHT = 6;
int moveState = FORWARD;
int storDistance = 0;
int storLight = 0;
void loop(){
if(count < (countsperrev / 10) ) {
moveStep();
}
else
{
Serial.print("Right = ");
int brightnessRight = analogRead(photocellRight);
Serial.println(brightnessRight); // the raw analog reading
Serial.print("Distance = ");
int distance = ultrasonic.Ranging(CM);
Serial.println(distance); // the raw analog reading
if (moveState == RIGHT || moveState == SHARPRIGHT)
{
if (distance < 10)
{
Serial.println("--- Keep on turning right");
}
else if (brightnessRight >= storLight)
{
// good decision, go straight
Serial.println("--- Good decision, go straight");
moveState = FORWARD;
}
else
{
// bad decision, go back
Serial.println("--- Bad decision, go back left");
moveState = LEFT;
}
}
else if (moveState == LEFT || moveState == SHARPLEFT)
{
if (distance < 10)
{
Serial.println("--- Keep on turning left");
}
else if (brightnessRight >= storLight)
{
// good decision, go straight
Serial.println("--- Good decision, go straight");
moveState = FORWARD;
}
else
{
// bad decision, go back
Serial.println("--- bad decision, go right now");
moveState = RIGHT;
}
}
else if (moveState == FORWARD)
{
if (distance < 10)
{
Serial.println("--- Keep on straight");
moveState = SHARPRIGHT;
}
else if (brightnessRight >= storLight)
{
// good decision, go straight
moveState = FORWARD;
Serial.println("--- Keep on straight");
}
else
{
// bad decision, go back
moveState = RIGHT;
Serial.println("--- bad decision try right");
}
}
storDistance = distance;
storLight = brightnessRight;
// We need to measure, decide, measure, decide
count=0;
}
count++;
}
void moveStep()
{
for(int i = 0; i < 8; i++)
{
switch(moveState)
{
case STOP:
return;
case FORWARD:
setOutputDir(i,7-i);
// delay(500);
// digitalWrite(pixel, LOW);
break;
case BACK:
setOutputDir(7-i,i);
break;
case LEFT:
setOutputDir(i,0);
break;
case RIGHT:
setOutputDir(0,7-i);
break;
case SHARPLEFT:
setOutputDir(7-i,7-i);
break;
case SHARPRIGHT:
setOutputDir(i,i);
break;
}
delayMicroseconds(motorSpeed);
}
}
void setOutputDir(int leftOut, int rightOut)
{
digitalWrite(lmotorPin1, bitRead(lookup[leftOut], 0));
digitalWrite(lmotorPin2, bitRead(lookup[leftOut], 1));
digitalWrite(lmotorPin3, bitRead(lookup[leftOut], 2));
digitalWrite(lmotorPin4, bitRead(lookup[leftOut], 3));
digitalWrite(rmotorPin1, bitRead(lookup[rightOut], 0));
digitalWrite(rmotorPin2, bitRead(lookup[rightOut], 1));
digitalWrite(rmotorPin3, bitRead(lookup[rightOut], 2));
digitalWrite(rmotorPin4, bitRead(lookup[rightOut], 3));
}
| [
"sners_nass@yahoo.co.uk"
] | sners_nass@yahoo.co.uk |
d07558ab14323f534eae17ace7df7c19ec74c425 | bc079fad03beef5bfbeaadcf82ac772172c27246 | /ArikaraSkinEditor/Editor/SkinDataWidget.cpp | 0ca526a91ffaae7fcad0bbd06bdd2c46c6f42f8e | [] | no_license | JonasOuellet/Arikara | 7b9dc9dd982162169bd8e77bb9101dee4a1ce961 | d2937b045c85cc7f5c9a212196acbee71857da4d | refs/heads/master | 2020-03-28T18:01:57.880720 | 2020-03-12T20:00:22 | 2020-03-12T20:00:22 | 148,846,154 | 0 | 2 | null | null | null | null | UTF-8 | C++ | false | false | 9,411 | cpp | #include "../ArikaraMaya/command/ArikaraSkinDataCmd.h"
#include "SkinDataWidget.h"
#include "qtwidgets/qhboxlayout"
#include "qtwidgets/qVboxlayout"
#include "qtwidgets/QLabel"
#include "qtwidgets/qpushbutton"
#include <qtcore/qfileinfo>
#include <maya/MString.h>
#include <maya/MGlobal.h>
#include <maya/MStringArray.h>
#include <maya/MSelectionList.h>
SkinDataWidget::SkinDataWidget(QWidget *parent /*= 0*/) : QWidget(parent)
{
QVBoxLayout *mainLayout = new QVBoxLayout;
QLabel *lbl_file = new QLabel("File:");
le_path = new QLineEdit(ArikaraSkinDataCmd::defaultPath.asChar());
QPushButton* pb_browse = new QPushButton("...");
connect(pb_browse, SIGNAL(clicked()), this, SLOT(browseFile()));
QHBoxLayout *layout1 = new QHBoxLayout;
layout1->addWidget(lbl_file, 0);
layout1->addWidget(le_path, 1);
layout1->addWidget(pb_browse, 0);
cb_loadBindMat = new QCheckBox("Load Bind Matrix");
cb_clean = new QCheckBox("Clean Skin");
QVBoxLayout *layoutcb1 = new QVBoxLayout;
layoutcb1->addWidget(cb_loadBindMat);
layoutcb1->addWidget(cb_clean);
cb_pos = new QGroupBox("Matching Position");
cb_pos->setCheckable(true);
cb_pos->setChecked(false);
cb_worldSpace = new QCheckBox("World Space");
QHBoxLayout *layouttmp = new QHBoxLayout;
QLabel *lbl_bias = new QLabel("bias: ");
dsb_bias = new QDoubleSpinBox();
dsb_bias->setSingleStep(0.005);
dsb_bias->setDecimals(5);
dsb_bias->setValue(ArikaraSkinDataCmd::defaultBias);
layouttmp->addWidget(lbl_bias, 0);
layouttmp->addWidget(dsb_bias, 0);
QVBoxLayout *layoutcb2 = new QVBoxLayout;
layoutcb2->addWidget(cb_worldSpace);
layoutcb2->addLayout(layouttmp);
cb_pos->setLayout(layoutcb2);
QHBoxLayout *layout2 = new QHBoxLayout;
layout2->addLayout(layoutcb1);
layout2->addWidget(cb_pos);
QPushButton* pb_save = new QPushButton("Save");
connect(pb_save, SIGNAL(clicked()), this, SLOT(saveSkin()));
QPushButton* pb_load = new QPushButton("Load");
connect(pb_load, SIGNAL(clicked()), this, SLOT(loadSkin()));
QHBoxLayout *layout3 = new QHBoxLayout;
layout3->addWidget(pb_save);
layout3->addWidget(pb_load);
QSpacerItem * spacer = new QSpacerItem(100, 20, QSizePolicy::Expanding, QSizePolicy::Expanding);
mainLayout->addLayout(layout1);
mainLayout->addLayout(layout2);
mainLayout->addLayout(layout3);
mainLayout->addSpacerItem(spacer);
setLayout(mainLayout);
}
SkinDataWidget::~SkinDataWidget()
{
}
void SkinDataWidget::browseFile()
{
//MString cmd = "fileDialog2 -fileFilter \"*.ars\" -dialogStyle 2 -fm 0 -okc \"Ok\" -cap \"Chose a skin data file.\" -dir \"";
MString cmd = "fileDialog2 -dialogStyle 2 -fm 3 -okc \"Ok\" -cap \"Pick arikara skin data folder.\" -dir \"";
#ifdef WIN32
MStringArray splittedPath;
ArikaraSkinDataCmd::defaultPath.split('\\', splittedPath);
MString newPath;
for (unsigned int x = 0; x < splittedPath.length(); x++)
{
newPath += splittedPath[x];
if (x < splittedPath.length() - 1)
newPath += "\\\\";
}
cmd += newPath;
#else
cmd += ArikaraSkinDataCmd::defaultPath.asChar();
#endif // WIN32
cmd += "\"";
MStringArray result;
MStatus status = MGlobal::executeCommand(cmd, result);
if (status == MS::kSuccess)
{
if (result.length() > 0)
{
std::string tmp = result[0].asChar();
#ifdef WIN32
std::replace(tmp.begin(), tmp.end(), '/', '\\');
#endif
le_path->setText(tmp.c_str());
}
}
}
void SkinDataWidget::saveSkin()
{
MSelectionList sel;
MGlobal::getActiveSelectionList(sel);
unsigned int selLen = sel.length();
if (selLen > 0)
{
MString cmd = "arikaraSkinData -save ";
MString path;
if (isValidPath(path))
{
#ifdef WIN32
MStringArray splittedPath;
path.split('\\', splittedPath);
path = "";
for (unsigned int x = 0; x < splittedPath.length(); x++)
{
path += splittedPath[x];
if (x < splittedPath.length() - 1)
path += "\\\\";
}
#endif // WIN32
cmd += "-path ";
cmd += path;
cmd += " ";
}
for (unsigned int x = 0; x < selLen; x++)
{
MDagPath dag;
sel.getDagPath(x, dag);
MString curCmd(cmd);
curCmd += dag.partialPathName();
MGlobal::executeCommand(curCmd, true);
}
}
else
{
MGlobal::displayError("You must select at least one skinned object");
}
}
void SkinDataWidget::loadSkin()
{
MSelectionList sel;
MGlobal::getActiveSelectionList(sel);
unsigned int selLen = sel.length();
if (selLen > 0)
{
MString cmd = "arikaraSkinData -load ";
if (cb_clean->isChecked())
{
cmd += "-clean ";
}
if (cb_loadBindMat->isChecked())
{
cmd += "-loadBindMatrix ";
}
if (cb_pos->isChecked())
{
cmd += "-position ";
double bias = dsb_bias->value();
if (bias != ArikaraSkinDataCmd::defaultBias)
{
cmd += "-bias ";
cmd += bias;
cmd += " ";
}
if (cb_worldSpace->isChecked())
{
cmd += "-worldSpace ";
}
}
MString path;
MString commandPath;
bool useCmdPath = false;
if (isValidPath(path))
{
bool useCmdPath = true;
}
else
{
path = ArikaraSkinDataCmd::defaultPath;
}
#ifdef WIN32
MStringArray splittedPath;
path.split('\\', splittedPath);
for (unsigned int x = 0; x < splittedPath.length(); x++)
{
commandPath += splittedPath[x];
if (x < splittedPath.length() - 1)
commandPath += "\\\\";
}
#else
commandPath = path;
#endif // WIN32
MString bigCommand;
for (unsigned int x = 0; x < selLen; x++)
{
MDagPath dag;
sel.getDagPath(x, dag);
MString curCmd(cmd);
//Check if we can find a file for the selected object.
MString filePath = path.asChar();
#ifdef WIN32
filePath += "\\";
#else
filePath += "/";
#endif // WIN32
filePath += dag.partialPathName();
filePath += ".ars";
QFileInfo file(filePath.asChar());
if (file.exists())
{
if (useCmdPath)
{
curCmd += "-path \"";
curCmd += commandPath;
curCmd += "\" ";
}
}
else
{
MString info = "Couldn't find file: ";
info += filePath;
info += "\nPlease specify a file.";
MGlobal::displayInfo(info);
MString browseCmd = "fileDialog2 -fileFilter \"*.ars\" -dialogStyle 2 -fm 1 -cap \"Chose a skin data file for object: ";
browseCmd += dag.partialPathName();
browseCmd += "\" -dir \"";
browseCmd += commandPath;
browseCmd += "\"";
MStringArray result;
MStatus status = MGlobal::executeCommand(browseCmd, result);
if (status == MS::kSuccess)
{
if (result.length() > 0)
{
MStringArray path;
result[0].split('/', path);
MString file = path[path.length() - 1];
MString folder;
for (unsigned int x = 0; x < path.length() - 1; x++)
{
folder += path[x];
if (x < path.length() - 2)
{
#ifdef WIN32
folder += "\\\\";
#else
folder += "/";
#endif //WIN32
}
}
curCmd += "-path \"";
curCmd += folder;
curCmd += "\" -file \"";
curCmd += file;
curCmd += "\" ";
}
else
{
continue;
}
}
else
{
continue;
}
}
bigCommand += curCmd;
bigCommand += dag.partialPathName();
bigCommand += ";\n";
}
MGlobal::executeCommand(bigCommand, true, true);
}
else
{
MGlobal::displayError("You must select at least one skinned object");
}
}
bool SkinDataWidget::isValidPath(MString& path)
{
std::string tmp = le_path->text().toStdString();
if (tmp.length() > 0)
{
int comp = tmp.compare(ArikaraSkinDataCmd::defaultPath.asChar());
if (comp != 0)
{
path = tmp.c_str();
return true;
}
}
return false;
}
| [
"ouelletjonathan@hotmail.com"
] | ouelletjonathan@hotmail.com |
e22024e90544695e52c4c9ee9c3d9a5f5e6ed563 | 1bf7bfc7a7f4653fe0e956459b23d0ffd9d8e479 | /tmplanner_continuous/include/tmplanner_continuous/stats/rand/rlogis.ipp | 5e44ad82ba027e9ffed179dc4235842ee0c3a724 | [] | no_license | ajitham123/IPP-SaR | e063d9bf1bc0d4e065d8d6c1992f9e87f128cd61 | f434bfaeff7ca5e9b0e7bb34b6d5d1c63566ea53 | refs/heads/master | 2021-07-16T04:30:55.263886 | 2021-07-09T12:39:54 | 2021-07-09T12:39:54 | 121,274,735 | 2 | 2 | null | null | null | null | UTF-8 | C++ | false | false | 2,291 | ipp | /*################################################################################
##
## Copyright (C) 2011-2018 Keith O'Hara
##
## This file is part of the StatsLib C++ library.
##
## 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 to in writing, software
## distributed under the License is distributed on an "AS IS" BASIS,
## WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
## See the License for the specific language governing permissions and
## limitations under the License.
##
################################################################################*/
/*
* Sample from a logistic distribution
*/
template<typename T>
statslib_inline
T
rlogis(const T mu_par, const T sigma_par, rand_engine_t& engine)
{
return qlogis(runif<T>(T(0.0),T(1.0),engine),mu_par,sigma_par);
}
template<typename T>
statslib_inline
T
rlogis(const T mu_par, const T sigma_par, uint_t seed_val)
{
return qlogis(runif<T>(T(0.0),T(1.0),seed_val),mu_par,sigma_par);
}
template<typename T>
statslib_inline
void
rlogis_int(const T mu_par, const T sigma_par, T* vals_out, const uint_t num_elem)
{
#ifdef STATS_USE_OPENMP
uint_t n_threads = omp_get_max_threads();
std::vector<rand_engine_t> engines;
for (uint_t k=0; k < n_threads; k++)
{
engines.push_back(rand_engine_t(std::random_device{}()));
}
#pragma omp parallel for
for (uint_t j=0U; j < num_elem; j++)
{
uint_t thread_id = omp_get_thread_num();
vals_out[j] = rlogis(mu_par,sigma_par,engines[thread_id]);
}
#else
rand_engine_t engine(std::random_device{}());
for (uint_t j=0U; j < num_elem; j++)
{
vals_out[j] = rlogis(mu_par,sigma_par,engine);
}
#endif
}
#ifdef STATS_WITH_MATRIX_LIB
template<typename mT, typename eT>
statslib_inline
mT
rlogis(const uint_t n, const uint_t k, const eT mu_par, const eT sigma_par)
{
mT mat_out(n,k);
rlogis_int(mu_par,sigma_par,mat_ops::get_mem_ptr(mat_out),n*k);
return mat_out;
}
#endif
| [
"ajitham1994@gmail.com"
] | ajitham1994@gmail.com |
eea9422c602d78b76b7f74034eeff2b3448e2925 | 11c5c16b77857f163fbb8bd6e6ba4fa79886d696 | /NameEntry.h | c96b3d668ed37c250ffc4094ad7a1c41808d7dd8 | [] | no_license | LucasLu2000/NamesDemo | 075106a18e84e3e78f3cf498b63798e23ec0ad48 | a1407c5a6eef6555eba5d49fddda4d02a8bd97da | refs/heads/master | 2022-12-09T07:13:45.226856 | 2020-09-15T03:59:38 | 2020-09-15T03:59:38 | 295,569,956 | 0 | 0 | null | 2020-09-15T00:19:55 | 2020-09-15T00:19:55 | null | UTF-8 | C++ | false | false | 888 | h | /***************************************************************************
* NameEntry.h - Object to store name data for a single name
*
* copyright : (C) 2018 by Jim Skon, Kenyon College
*
* This is part of a program create an index US Census name
* Data on the frequency of names in response to requestes.
* It then allows you to look up any name, giving the 10 closest matches
*
*
*
***************************************************************************/
#ifndef NAMEENTRY_H
#define NAMEENTRY_H
#include <string>
using namespace std;
class NameEntry {
public:
NameEntry();
string name; // Last name
string percent; // Frequency of occurrence of a given name
string cumulative; // cumulative frequency of all name up to and including this name
string rank; // Rank of this Name in terms of frequency
private:
};
#endif /* NAMEENTRY_H */
| [
"skonjp@kenyon.edu"
] | skonjp@kenyon.edu |
527a6ee8adc2580846f7a796d5fa5993ca442ce9 | 64058e1019497fbaf0f9cbfab9de4979d130416b | /c++/include/serial/objectiter.hpp | f799755e7e47dcb07d48be5193db428cbaf2a490 | [
"MIT"
] | permissive | OpenHero/gblastn | 31e52f3a49e4d898719e9229434fe42cc3daf475 | 1f931d5910150f44e8ceab81599428027703c879 | refs/heads/master | 2022-10-26T04:21:35.123871 | 2022-10-20T02:41:06 | 2022-10-20T02:41:06 | 12,407,707 | 38 | 21 | null | 2020-12-08T07:14:32 | 2013-08-27T14:06:00 | C++ | UTF-8 | C++ | false | false | 18,648 | hpp | #ifndef OBJECTITER__HPP
#define OBJECTITER__HPP
/* $Id: objectiter.hpp 358154 2012-03-29 15:05:12Z gouriano $
* ===========================================================================
*
* PUBLIC DOMAIN NOTICE
* National Center for Biotechnology Information
*
* This software/database is a "United States Government Work" under the
* terms of the United States Copyright Act. It was written as part of
* the author's official duties as a United States Government employee and
* thus cannot be copyrighted. This software/database is freely available
* to the public for use. The National Library of Medicine and the U.S.
* Government have not placed any restriction on its use or reproduction.
*
* Although all reasonable efforts have been taken to ensure the accuracy
* and reliability of the software and data, the NLM and the U.S.
* Government do not and cannot warrant the performance or results that
* may be obtained by using this software or data. The NLM and the U.S.
* Government disclaim all warranties, express or implied, including
* warranties of performance, merchantability or fitness for any particular
* purpose.
*
* Please cite the author in any work or product based on this material.
*
* ===========================================================================
*
* Author: Eugene Vasilchenko
*
* File Description:
* Iterators, which work on object information data
*/
#include <corelib/ncbistd.hpp>
#include <serial/objectinfo.hpp>
/** @addtogroup ObjStreamSupport
*
* @{
*/
BEGIN_NCBI_SCOPE
/////////////////////////////////////////////////////////////////////////////
///
/// CConstObjectInfoEI --
///
/// Container iterator
/// Provides read access to elements of container
/// @sa CConstObjectInfo::BeginElements
class NCBI_XSERIAL_EXPORT CConstObjectInfoEI
{
public:
CConstObjectInfoEI(void);
CConstObjectInfoEI(const CConstObjectInfo& object);
CConstObjectInfoEI& operator=(const CConstObjectInfo& object);
/// Is iterator valid
bool Valid(void) const;
/// Is iterator valid
DECLARE_OPERATOR_BOOL(Valid());
bool operator==(const CConstObjectInfoEI& obj) const
{
return GetElement() == obj.GetElement();
}
bool operator!=(const CConstObjectInfoEI& obj) const
{
return GetElement() != obj.GetElement();
}
/// Get index of the element in the container
TMemberIndex GetIndex(void) const
{
return m_Iterator.GetIndex();
}
/// Advance to next element
void Next(void);
/// Advance to next element
CConstObjectInfoEI& operator++(void);
/// Get element data and type information
CConstObjectInfo GetElement(void) const;
/// Get element data and type information
CConstObjectInfo operator*(void) const;
bool CanGet(void) const
{
return true;
}
const CItemInfo* GetItemInfo(void) const
{
return 0;
}
protected:
bool CheckValid(void) const;
private:
CConstContainerElementIterator m_Iterator;
};
/////////////////////////////////////////////////////////////////////////////
///
/// CObjectInfoEI --
///
/// Container iterator
/// Provides read/write access to elements of container
/// @sa CObjectInfo::BeginElements
class NCBI_XSERIAL_EXPORT CObjectInfoEI
{
public:
CObjectInfoEI(void);
CObjectInfoEI(const CObjectInfo& object);
CObjectInfoEI& operator=(const CObjectInfo& object);
/// Is iterator valid
bool Valid(void) const;
/// Is iterator valid
DECLARE_OPERATOR_BOOL(Valid());
bool operator==(const CObjectInfoEI& obj) const
{
return GetElement() == obj.GetElement();
}
bool operator!=(const CObjectInfoEI& obj) const
{
return GetElement() != obj.GetElement();
}
/// Get index of the element in the container
TMemberIndex GetIndex(void) const
{
return m_Iterator.GetIndex();
}
/// Advance to next element
void Next(void);
/// Advance to next element
CObjectInfoEI& operator++(void);
/// Get element data and type information
CObjectInfo GetElement(void) const;
/// Get element data and type information
CObjectInfo operator*(void) const;
void Erase(void);
bool CanGet(void) const
{
return true;
}
const CItemInfo* GetItemInfo(void) const
{
return 0;
}
protected:
bool CheckValid(void) const;
private:
CContainerElementIterator m_Iterator;
};
/////////////////////////////////////////////////////////////////////////////
///
/// CObjectTypeInfoII --
///
/// Item iterator (either class member or choice variant)
/// provides access to the data type information.
class NCBI_XSERIAL_EXPORT CObjectTypeInfoII
{
public:
const string& GetAlias(void) const;
/// Is iterator valid
bool Valid(void) const;
/// Is iterator valid
DECLARE_OPERATOR_BOOL(Valid());
bool operator==(const CObjectTypeInfoII& iter) const;
bool operator!=(const CObjectTypeInfoII& iter) const;
/// Advance to next element
void Next(void);
const CItemInfo* GetItemInfo(void) const;
/// Get index of the element in the container (class or choice)
TMemberIndex GetIndex(void) const
{
return GetItemIndex();
}
protected:
CObjectTypeInfoII(void);
CObjectTypeInfoII(const CClassTypeInfoBase* typeInfo);
CObjectTypeInfoII(const CClassTypeInfoBase* typeInfo, TMemberIndex index);
const CObjectTypeInfo& GetOwnerType(void) const;
const CClassTypeInfoBase* GetClassTypeInfoBase(void) const;
TMemberIndex GetItemIndex(void) const;
void Init(const CClassTypeInfoBase* typeInfo);
void Init(const CClassTypeInfoBase* typeInfo, TMemberIndex index);
bool CanGet(void) const
{
return true;
}
bool CheckValid(void) const;
private:
CObjectTypeInfo m_OwnerType;
TMemberIndex m_ItemIndex;
TMemberIndex m_LastItemIndex;
};
/////////////////////////////////////////////////////////////////////////////
///
/// CObjectTypeInfoMI --
///
/// Class member iterator
/// provides access to the data type information.
class NCBI_XSERIAL_EXPORT CObjectTypeInfoMI : public CObjectTypeInfoII
{
typedef CObjectTypeInfoII CParent;
public:
CObjectTypeInfoMI(void);
CObjectTypeInfoMI(const CObjectTypeInfo& info);
CObjectTypeInfoMI(const CObjectTypeInfo& info, TMemberIndex index);
/// Get index of the member in the class
TMemberIndex GetMemberIndex(void) const;
/// Advance to next element
CObjectTypeInfoMI& operator++(void);
CObjectTypeInfoMI& operator=(const CObjectTypeInfo& info);
/// Get containing class type
CObjectTypeInfo GetClassType(void) const;
/// Get data type information
operator CObjectTypeInfo(void) const;
/// Get data type information
CObjectTypeInfo GetMemberType(void) const;
/// Get data type information
CObjectTypeInfo operator*(void) const;
void SetLocalReadHook(CObjectIStream& stream,
CReadClassMemberHook* hook) const;
void SetGlobalReadHook(CReadClassMemberHook* hook) const;
void ResetLocalReadHook(CObjectIStream& stream) const;
void ResetGlobalReadHook(void) const;
void SetPathReadHook(CObjectIStream* in, const string& path,
CReadClassMemberHook* hook) const;
void SetLocalWriteHook(CObjectOStream& stream,
CWriteClassMemberHook* hook) const;
void SetGlobalWriteHook(CWriteClassMemberHook* hook) const;
void ResetLocalWriteHook(CObjectOStream& stream) const;
void ResetGlobalWriteHook(void) const;
void SetPathWriteHook(CObjectOStream* stream, const string& path,
CWriteClassMemberHook* hook) const;
void SetLocalSkipHook(CObjectIStream& stream,
CSkipClassMemberHook* hook) const;
void ResetLocalSkipHook(CObjectIStream& stream) const;
void SetPathSkipHook(CObjectIStream* stream, const string& path,
CSkipClassMemberHook* hook) const;
void SetLocalCopyHook(CObjectStreamCopier& stream,
CCopyClassMemberHook* hook) const;
void SetGlobalCopyHook(CCopyClassMemberHook* hook) const;
void ResetLocalCopyHook(CObjectStreamCopier& stream) const;
void ResetGlobalCopyHook(void) const;
void SetPathCopyHook(CObjectStreamCopier* stream, const string& path,
CCopyClassMemberHook* hook) const;
public: // mostly for internal use
const CMemberInfo* GetMemberInfo(void) const;
protected:
void Init(const CObjectTypeInfo& info);
void Init(const CObjectTypeInfo& info, TMemberIndex index);
const CClassTypeInfo* GetClassTypeInfo(void) const;
bool IsSet(const CConstObjectInfo& object) const;
private:
CMemberInfo* GetNCMemberInfo(void) const;
};
/////////////////////////////////////////////////////////////////////////////
///
/// CObjectTypeInfoVI --
///
/// Choice variant iterator
/// provides access to the data type information.
class NCBI_XSERIAL_EXPORT CObjectTypeInfoVI : public CObjectTypeInfoII
{
typedef CObjectTypeInfoII CParent;
public:
CObjectTypeInfoVI(const CObjectTypeInfo& info);
CObjectTypeInfoVI(const CObjectTypeInfo& info, TMemberIndex index);
/// Get index of the variant in the choice
TMemberIndex GetVariantIndex(void) const;
/// Advance to next element
CObjectTypeInfoVI& operator++(void);
CObjectTypeInfoVI& operator=(const CObjectTypeInfo& info);
/// Get containing choice type
CObjectTypeInfo GetChoiceType(void) const;
/// Get data type information
CObjectTypeInfo GetVariantType(void) const;
/// Get data type information
CObjectTypeInfo operator*(void) const;
void SetLocalReadHook(CObjectIStream& stream,
CReadChoiceVariantHook* hook) const;
void SetGlobalReadHook(CReadChoiceVariantHook* hook) const;
void ResetLocalReadHook(CObjectIStream& stream) const;
void ResetGlobalReadHook(void) const;
void SetPathReadHook(CObjectIStream* stream, const string& path,
CReadChoiceVariantHook* hook) const;
void SetLocalWriteHook(CObjectOStream& stream,
CWriteChoiceVariantHook* hook) const;
void SetGlobalWriteHook(CWriteChoiceVariantHook* hook) const;
void ResetLocalWriteHook(CObjectOStream& stream) const;
void ResetGlobalWriteHook(void) const;
void SetPathWriteHook(CObjectOStream* stream, const string& path,
CWriteChoiceVariantHook* hook) const;
void SetLocalSkipHook(CObjectIStream& stream,
CSkipChoiceVariantHook* hook) const;
void ResetLocalSkipHook(CObjectIStream& stream) const;
void SetPathSkipHook(CObjectIStream* stream, const string& path,
CSkipChoiceVariantHook* hook) const;
void SetLocalCopyHook(CObjectStreamCopier& stream,
CCopyChoiceVariantHook* hook) const;
void SetGlobalCopyHook(CCopyChoiceVariantHook* hook) const;
void ResetLocalCopyHook(CObjectStreamCopier& stream) const;
void ResetGlobalCopyHook(void) const;
void SetPathCopyHook(CObjectStreamCopier* stream, const string& path,
CCopyChoiceVariantHook* hook) const;
public: // mostly for internal use
const CVariantInfo* GetVariantInfo(void) const;
protected:
void Init(const CObjectTypeInfo& info);
void Init(const CObjectTypeInfo& info, TMemberIndex index);
const CChoiceTypeInfo* GetChoiceTypeInfo(void) const;
private:
CVariantInfo* GetNCVariantInfo(void) const;
};
/////////////////////////////////////////////////////////////////////////////
///
/// CConstObjectInfoMI --
///
/// Class member iterator
/// provides read access to class member data.
class NCBI_XSERIAL_EXPORT CConstObjectInfoMI : public CObjectTypeInfoMI
{
typedef CObjectTypeInfoMI CParent;
public:
CConstObjectInfoMI(void);
CConstObjectInfoMI(const CConstObjectInfo& object);
CConstObjectInfoMI(const CConstObjectInfo& object, TMemberIndex index);
/// Get containing class data
const CConstObjectInfo& GetClassObject(void) const;
CConstObjectInfoMI& operator=(const CConstObjectInfo& object);
/// Is member assigned a value
bool IsSet(void) const;
/// Get class member data
CConstObjectInfo GetMember(void) const;
/// Get class member data
CConstObjectInfo operator*(void) const;
bool CanGet(void) const;
private:
pair<TConstObjectPtr, TTypeInfo> GetMemberPair(void) const;
CConstObjectInfo m_Object;
};
/////////////////////////////////////////////////////////////////////////////
///
/// CObjectInfoMI --
///
/// Class member iterator
/// provides read/write access to class member data.
class NCBI_XSERIAL_EXPORT CObjectInfoMI : public CObjectTypeInfoMI
{
typedef CObjectTypeInfoMI CParent;
public:
CObjectInfoMI(void);
CObjectInfoMI(const CObjectInfo& object);
CObjectInfoMI(const CObjectInfo& object, TMemberIndex index);
/// Get containing class data
const CObjectInfo& GetClassObject(void) const;
CObjectInfoMI& operator=(const CObjectInfo& object);
/// Is member assigned a value
bool IsSet(void) const;
/// Get class member data
CObjectInfo GetMember(void) const;
/// Get class member data
CObjectInfo operator*(void) const;
/// Erase types
enum EEraseFlag {
eErase_Optional, ///< default - erase optional member only
eErase_Mandatory ///< allow erasing mandatory members, may be dangerous!
};
/// Erase member value
void Erase(EEraseFlag flag = eErase_Optional);
/// Reset value of member to default state
void Reset(void);
bool CanGet(void) const;
private:
pair<TObjectPtr, TTypeInfo> GetMemberPair(void) const;
CObjectInfo m_Object;
};
/////////////////////////////////////////////////////////////////////////////
///
/// CObjectTypeInfoCV --
///
/// Choice variant
/// provides access to the data type information.
class NCBI_XSERIAL_EXPORT CObjectTypeInfoCV
{
public:
CObjectTypeInfoCV(void);
CObjectTypeInfoCV(const CObjectTypeInfo& info);
CObjectTypeInfoCV(const CObjectTypeInfo& info, TMemberIndex index);
CObjectTypeInfoCV(const CConstObjectInfo& object);
/// Get index of the variant in the choice
TMemberIndex GetVariantIndex(void) const;
const string& GetAlias(void) const;
bool Valid(void) const;
DECLARE_OPERATOR_BOOL(Valid());
bool operator==(const CObjectTypeInfoCV& iter) const;
bool operator!=(const CObjectTypeInfoCV& iter) const;
CObjectTypeInfoCV& operator=(const CObjectTypeInfo& info);
CObjectTypeInfoCV& operator=(const CConstObjectInfo& object);
/// Get containing choice
CObjectTypeInfo GetChoiceType(void) const;
/// Get variant data type
CObjectTypeInfo GetVariantType(void) const;
/// Get variant data type
CObjectTypeInfo operator*(void) const;
void SetLocalReadHook(CObjectIStream& stream,
CReadChoiceVariantHook* hook) const;
void SetGlobalReadHook(CReadChoiceVariantHook* hook) const;
void ResetLocalReadHook(CObjectIStream& stream) const;
void ResetGlobalReadHook(void) const;
void SetPathReadHook(CObjectIStream* stream, const string& path,
CReadChoiceVariantHook* hook) const;
void SetLocalWriteHook(CObjectOStream& stream,
CWriteChoiceVariantHook* hook) const;
void SetGlobalWriteHook(CWriteChoiceVariantHook* hook) const;
void ResetLocalWriteHook(CObjectOStream& stream) const;
void ResetGlobalWriteHook(void) const;
void SetPathWriteHook(CObjectOStream* stream, const string& path,
CWriteChoiceVariantHook* hook) const;
void SetLocalCopyHook(CObjectStreamCopier& stream,
CCopyChoiceVariantHook* hook) const;
void SetGlobalCopyHook(CCopyChoiceVariantHook* hook) const;
void ResetLocalCopyHook(CObjectStreamCopier& stream) const;
void ResetGlobalCopyHook(void) const;
void SetPathCopyHook(CObjectStreamCopier* stream, const string& path,
CCopyChoiceVariantHook* hook) const;
public: // mostly for internal use
const CVariantInfo* GetVariantInfo(void) const;
protected:
const CChoiceTypeInfo* GetChoiceTypeInfo(void) const;
void Init(const CObjectTypeInfo& info);
void Init(const CObjectTypeInfo& info, TMemberIndex index);
void Init(const CConstObjectInfo& object);
private:
const CChoiceTypeInfo* m_ChoiceTypeInfo;
TMemberIndex m_VariantIndex;
private:
CVariantInfo* GetNCVariantInfo(void) const;
};
/////////////////////////////////////////////////////////////////////////////
///
/// CConstObjectInfoCV --
///
/// Choice variant
/// provides read access to the variant data.
class NCBI_XSERIAL_EXPORT CConstObjectInfoCV : public CObjectTypeInfoCV
{
typedef CObjectTypeInfoCV CParent;
public:
CConstObjectInfoCV(void);
CConstObjectInfoCV(const CConstObjectInfo& object);
CConstObjectInfoCV(const CConstObjectInfo& object, TMemberIndex index);
/// Get containing choice
const CConstObjectInfo& GetChoiceObject(void) const;
CConstObjectInfoCV& operator=(const CConstObjectInfo& object);
/// Get variant data
CConstObjectInfo GetVariant(void) const;
/// Get variant data
CConstObjectInfo operator*(void) const;
private:
pair<TConstObjectPtr, TTypeInfo> GetVariantPair(void) const;
CConstObjectInfo m_Object;
TMemberIndex m_VariantIndex;
};
/////////////////////////////////////////////////////////////////////////////
///
/// CObjectInfoCV --
///
/// Choice variant
/// provides read/write access to the variant data.
class NCBI_XSERIAL_EXPORT CObjectInfoCV : public CObjectTypeInfoCV
{
typedef CObjectTypeInfoCV CParent;
public:
CObjectInfoCV(void);
CObjectInfoCV(const CObjectInfo& object);
CObjectInfoCV(const CObjectInfo& object, TMemberIndex index);
/// Get containing choice
const CObjectInfo& GetChoiceObject(void) const;
CObjectInfoCV& operator=(const CObjectInfo& object);
/// Get variant data
CObjectInfo GetVariant(void) const;
/// Get variant data
CObjectInfo operator*(void) const;
private:
pair<TObjectPtr, TTypeInfo> GetVariantPair(void) const;
CObjectInfo m_Object;
};
/* @} */
#include <serial/impl/objectiter.inl>
END_NCBI_SCOPE
#endif /* OBJECTITER__HPP */
| [
"zhao.kaiyong@gmail.com"
] | zhao.kaiyong@gmail.com |
7ba71d7740cf727cbcf08eacd2933f8381589ef7 | d829d426e100e5f204bab15661db4e1da15515f9 | /src/EnergyPlus/ChillerExhaustAbsorption.cc | 8b60e724e57e2eb958734d912682f6b098c74bb6 | [
"BSD-2-Clause"
] | permissive | VB6Hobbyst7/EnergyPlus2 | a49409343e6c19a469b93c8289545274a9855888 | 622089b57515a7b8fbb20c8e9109267a4bb37eb3 | refs/heads/main | 2023-06-08T06:47:31.276257 | 2021-06-29T04:40:23 | 2021-06-29T04:40:23 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 124,684 | cc | // EnergyPlus, Copyright (c) 1996-2020, The Board of Trustees of the University of Illinois,
// The Regents of the University of California, through Lawrence Berkeley National Laboratory
// (subject to receipt of any required approvals from the U.S. Dept. of Energy), Oak Ridge
// National Laboratory, managed by UT-Battelle, Alliance for Sustainable Energy, LLC, and other
// contributors. All rights reserved.
//
// NOTICE: This Software was developed under funding from the U.S. Department of Energy and the
// U.S. Government consequently retains certain rights. As such, the U.S. Government has been
// granted for itself and others acting on its behalf a paid-up, nonexclusive, irrevocable,
// worldwide license in the Software to reproduce, distribute copies to the public, prepare
// derivative works, and perform publicly and display publicly, and to permit others to do so.
//
// Redistribution and use in source and binary forms, with or without modification, are permitted
// provided that the following conditions are met:
//
// (1) Redistributions of source code must retain the above copyright notice, this list of
// conditions and the following disclaimer.
//
// (2) Redistributions in binary form must reproduce the above copyright notice, this list of
// conditions and the following disclaimer in the documentation and/or other materials
// provided with the distribution.
//
// (3) Neither the name of the University of California, Lawrence Berkeley National Laboratory,
// the University of Illinois, U.S. Dept. of Energy nor the names of its contributors may be
// used to endorse or promote products derived from this software without specific prior
// written permission.
//
// (4) Use of EnergyPlus(TM) Name. If Licensee (i) distributes the software in stand-alone form
// without changes from the version obtained under this License, or (ii) Licensee makes a
// reference solely to the software portion of its product, Licensee must refer to the
// software as "EnergyPlus version X" software, where "X" is the version number Licensee
// obtained under this License and may not use a different name for the software. Except as
// specifically required in this Section (4), Licensee shall not use in a company name, a
// product name, in advertising, publicity, or other promotional activities any name, trade
// name, trademark, logo, or other designation of "EnergyPlus", "E+", "e+" or confusingly
// similar designation, without the U.S. Department of Energy's prior written consent.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
// IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
// AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
// CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
// CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
// SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
// OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
// POSSIBILITY OF SUCH DAMAGE.
// C++ Headers
#include <cassert>
#include <cmath>
// ObjexxFCL Headers
#include <ObjexxFCL/Array.functions.hh>
#include <ObjexxFCL/Fmath.hh>
// EnergyPlus Headers
#include <EnergyPlus/BranchNodeConnections.hh>
#include <EnergyPlus/ChillerExhaustAbsorption.hh>
#include <EnergyPlus/CurveManager.hh>
#include <EnergyPlus/DataBranchAirLoopPlant.hh>
#include <EnergyPlus/DataGlobalConstants.hh>
#include <EnergyPlus/DataHVACGlobals.hh>
#include <EnergyPlus/DataIPShortCuts.hh>
#include <EnergyPlus/DataLoopNode.hh>
#include <EnergyPlus/Plant/DataPlant.hh>
#include <EnergyPlus/DataSizing.hh>
#include <EnergyPlus/EMSManager.hh>
#include <EnergyPlus/FluidProperties.hh>
#include <EnergyPlus/General.hh>
#include <EnergyPlus/GlobalNames.hh>
#include <EnergyPlus/InputProcessing/InputProcessor.hh>
#include <EnergyPlus/MicroturbineElectricGenerator.hh>
#include <EnergyPlus/NodeInputManager.hh>
#include <EnergyPlus/OutAirNodeManager.hh>
#include <EnergyPlus/OutputProcessor.hh>
#include <EnergyPlus/OutputReportPredefined.hh>
#include <EnergyPlus/PlantUtilities.hh>
#include <EnergyPlus/Psychrometrics.hh>
#include <EnergyPlus/ReportSizingManager.hh>
#include <EnergyPlus/UtilityRoutines.hh>
namespace EnergyPlus {
namespace ChillerExhaustAbsorption {
// MODULE INFORMATION:
// AUTHOR Jason Glazer of GARD Analytics, Inc.
// for Gas Research Institute (Original module GasAbsoptionChiller)
// DATE WRITTEN March 2001
// MODIFIED Brent Griffith, Nov 2010 plant upgrades, generalize fluid properties
// Mahabir Bhandari, ORNL, Aug 2011, modified to accomodate Exhaust Fired Absorption Chiller
// RE-ENGINEERED na
// PURPOSE OF THIS MODULE:
// This module simulates the performance of the Exhaust fired double effect
// absorption chiller.
// METHODOLOGY EMPLOYED:
// Once the PlantLoopManager determines that the exhasut fired absorber chiller
// is available to meet a loop cooling demand, it calls SimExhaustAbsorption
// which in turn calls the appropriate Exhaut Fired Absorption Chiller model.
// REFERENCES:
// DOE-2.1e Supplement
// PG&E CoolToolsGas Mod
// Performnace curves obtained from manufcaturer
// OTHER NOTES:
// The curves on this model follow the DOE-2 approach of using
// electric and heat input ratios. In addition, the temperature
// correction curve has two independent variables for the
// chilled water temperature and either the entering or leaving
// condenser water temperature.
// The code was originally adopted from the ChillerAbsorption
// routine but has been extensively modified.
// Development of the original(GasAbsoptionChiller) module was funded by the Gas Research Institute.
// (Please see copyright and disclaimer information at end of module)
// Object Data
Array1D<ExhaustAbsorberSpecs> ExhaustAbsorber; // dimension to number of machines
bool Sim_GetInput(true); // then TRUE, calls subroutine to read input file.
PlantComponent *ExhaustAbsorberSpecs::factory(std::string const &objectName)
{
// Process the input data if it hasn't been done already
if (Sim_GetInput) {
GetExhaustAbsorberInput();
Sim_GetInput = false;
}
// Now look for this particular pipe in the list
for (auto &comp : ExhaustAbsorber) {
if (comp.Name == objectName) {
return ∁
}
}
// If we didn't find it, fatal
ShowFatalError("LocalExhaustAbsorberFactory: Error getting inputs for comp named: " + objectName); // LCOV_EXCL_LINE
// Shut up the compiler
return nullptr; // LCOV_EXCL_LINE
}
void ExhaustAbsorberSpecs::simulate(const PlantLocation &calledFromLocation, bool FirstHVACIteration, Real64 &CurLoad, bool RunFlag)
{
// kind of a hacky way to find the location of this, but it's what plantloopequip was doing
int BranchInletNodeNum =
DataPlant::PlantLoop(calledFromLocation.loopNum).LoopSide(calledFromLocation.loopSideNum).Branch(calledFromLocation.branchNum).NodeNumIn;
// Match inlet node name of calling branch to determine if this call is for heating or cooling
if (BranchInletNodeNum == this->ChillReturnNodeNum) { // Operate as chiller
this->InCoolingMode = RunFlag != 0;
this->initialize();
this->calcChiller(CurLoad);
this->updateCoolRecords(CurLoad, RunFlag);
} else if (BranchInletNodeNum == this->HeatReturnNodeNum) { // Operate as heater
this->InHeatingMode = RunFlag != 0;
this->initialize();
this->calcHeater(CurLoad, RunFlag);
this->updateHeatRecords(CurLoad, RunFlag);
} else if (BranchInletNodeNum == this->CondReturnNodeNum) { // called from condenser loop
if (this->CDLoopNum > 0) {
PlantUtilities::UpdateChillerComponentCondenserSide(this->CDLoopNum,
this->CDLoopSideNum,
DataPlant::TypeOf_Chiller_ExhFiredAbsorption,
this->CondReturnNodeNum,
this->CondSupplyNodeNum,
this->TowerLoad,
this->CondReturnTemp,
this->CondSupplyTemp,
this->CondWaterFlowRate,
FirstHVACIteration);
}
} else { // Error, nodes do not match
ShowSevereError("Invalid call to Exhaust Absorber Chiller " + this->Name);
ShowContinueError("Node connections in branch are not consistent with object nodes.");
ShowFatalError("Preceding conditions cause termination.");
}
}
void ExhaustAbsorberSpecs::getDesignCapacities(const PlantLocation &calledFromLocation, Real64 &MaxLoad, Real64 &MinLoad, Real64 &OptLoad)
{
// kind of a hacky way to find the location of this, but it's what plantloopequip was doing
int BranchInletNodeNum =
DataPlant::PlantLoop(calledFromLocation.loopNum).LoopSide(calledFromLocation.loopSideNum).Branch(calledFromLocation.branchNum).NodeNumIn;
// Match inlet node name of calling branch to determine if this call is for heating or cooling
if (BranchInletNodeNum == this->ChillReturnNodeNum) { // Operate as chiller
MinLoad = this->NomCoolingCap * this->MinPartLoadRat;
MaxLoad = this->NomCoolingCap * this->MaxPartLoadRat;
OptLoad = this->NomCoolingCap * this->OptPartLoadRat;
} else if (BranchInletNodeNum == this->HeatReturnNodeNum) { // Operate as heater
Real64 Sim_HeatCap = this->NomCoolingCap * this->NomHeatCoolRatio; // W - nominal heating capacity
MinLoad = Sim_HeatCap * this->MinPartLoadRat;
MaxLoad = Sim_HeatCap * this->MaxPartLoadRat;
OptLoad = Sim_HeatCap * this->OptPartLoadRat;
} else if (BranchInletNodeNum == this->CondReturnNodeNum) { // called from condenser loop
MinLoad = 0.0;
MaxLoad = 0.0;
OptLoad = 0.0;
} else { // Error, nodes do not match
ShowSevereError("SimExhaustAbsorber: Invalid call to Exhaust Absorbtion Chiller-Heater " + this->Name);
ShowContinueError("Node connections in branch are not consistent with object nodes.");
ShowFatalError("Preceding conditions cause termination.");
} // Operate as Chiller or Heater
}
void ExhaustAbsorberSpecs::getSizingFactor(Real64 &_SizFac)
{
_SizFac = this->SizFac;
}
void ExhaustAbsorberSpecs::onInitLoopEquip(const PlantLocation &calledFromLocation)
{
this->initialize();
// kind of a hacky way to find the location of this, but it's what plantloopequip was doing
int BranchInletNodeNum =
DataPlant::PlantLoop(calledFromLocation.loopNum).LoopSide(calledFromLocation.loopSideNum).Branch(calledFromLocation.branchNum).NodeNumIn;
if (BranchInletNodeNum == this->ChillReturnNodeNum) { // Operate as chiller
this->size(); // only call from chilled water loop
} else {
// don't do anything here
}
}
void ExhaustAbsorberSpecs::getDesignTemperatures(Real64 &TempDesCondIn, Real64 &TempDesEvapOut)
{
TempDesEvapOut = this->TempDesCHWSupply;
TempDesCondIn = this->TempDesCondReturn;
}
void GetExhaustAbsorberInput()
{
// SUBROUTINE INFORMATION:
// AUTHOR: Jason Glazer
// DATE WRITTEN: March 2001
// MODIFIED Mahabir Bhandari, ORNL, Aug 2011, modified to accomodate Exhaust Fired Double Effect Absorption Chiller
// RE-ENGINEERED na
// PURPOSE OF THIS SUBROUTINE:
// This routine will get the input
// required by the Exhaust Fired Absorption chiller model in the object ChillerHeater:Absorption:DoubleEffect
// METHODOLOGY EMPLOYED:
// EnergyPlus input processor
// Using/Aliasing
using namespace DataIPShortCuts; // Data for field names, blank numerics
using BranchNodeConnections::TestCompSet;
using CurveManager::GetCurveCheck;
using DataSizing::AutoSize;
using GlobalNames::VerifyUniqueChillerName;
using NodeInputManager::GetOnlySingleNode;
using OutAirNodeManager::CheckAndAddAirNodeNumber;
// LOCAL VARIABLES
int AbsorberNum; // Absorber counter
int NumAlphas; // Number of elements in the alpha array
int NumNums; // Number of elements in the numeric array
int IOStat; // IO Status when calling get input subroutine
std::string ChillerName;
bool Okay;
bool Get_ErrorsFound(false);
// FLOW
cCurrentModuleObject = "ChillerHeater:Absorption:DoubleEffect";
int NumExhaustAbsorbers = inputProcessor->getNumObjectsFound(cCurrentModuleObject);
if (NumExhaustAbsorbers <= 0) {
ShowSevereError("No " + cCurrentModuleObject + " equipment found in input file");
Get_ErrorsFound = true;
}
if (allocated(ExhaustAbsorber)) return;
// ALLOCATE ARRAYS
ExhaustAbsorber.allocate(NumExhaustAbsorbers);
// LOAD ARRAYS
for (AbsorberNum = 1; AbsorberNum <= NumExhaustAbsorbers; ++AbsorberNum) {
inputProcessor->getObjectItem(cCurrentModuleObject,
AbsorberNum,
cAlphaArgs,
NumAlphas,
rNumericArgs,
NumNums,
IOStat,
_,
lAlphaFieldBlanks,
cAlphaFieldNames,
cNumericFieldNames);
UtilityRoutines::IsNameEmpty(cAlphaArgs(1), cCurrentModuleObject, Get_ErrorsFound);
// Get_ErrorsFound will be set to True if problem was found, left untouched otherwise
VerifyUniqueChillerName(cCurrentModuleObject, cAlphaArgs(1), Get_ErrorsFound, cCurrentModuleObject + " Name");
ExhaustAbsorber(AbsorberNum).Name = cAlphaArgs(1);
ChillerName = cCurrentModuleObject + " Named " + ExhaustAbsorber(AbsorberNum).Name;
// Assign capacities
ExhaustAbsorber(AbsorberNum).NomCoolingCap = rNumericArgs(1);
if (ExhaustAbsorber(AbsorberNum).NomCoolingCap == AutoSize) {
ExhaustAbsorber(AbsorberNum).NomCoolingCapWasAutoSized = true;
}
ExhaustAbsorber(AbsorberNum).NomHeatCoolRatio = rNumericArgs(2);
// Assign efficiencies
ExhaustAbsorber(AbsorberNum).ThermalEnergyCoolRatio = rNumericArgs(3);
ExhaustAbsorber(AbsorberNum).ThermalEnergyHeatRatio = rNumericArgs(4);
ExhaustAbsorber(AbsorberNum).ElecCoolRatio = rNumericArgs(5);
ExhaustAbsorber(AbsorberNum).ElecHeatRatio = rNumericArgs(6);
// Assign Node Numbers to specified nodes
ExhaustAbsorber(AbsorberNum).ChillReturnNodeNum = GetOnlySingleNode(cAlphaArgs(2),
Get_ErrorsFound,
cCurrentModuleObject,
cAlphaArgs(1),
DataLoopNode::NodeType_Water,
DataLoopNode::NodeConnectionType_Inlet,
1,
DataLoopNode::ObjectIsNotParent);
ExhaustAbsorber(AbsorberNum).ChillSupplyNodeNum = GetOnlySingleNode(cAlphaArgs(3),
Get_ErrorsFound,
cCurrentModuleObject,
cAlphaArgs(1),
DataLoopNode::NodeType_Water,
DataLoopNode::NodeConnectionType_Outlet,
1,
DataLoopNode::ObjectIsNotParent);
TestCompSet(cCurrentModuleObject, cAlphaArgs(1), cAlphaArgs(2), cAlphaArgs(3), "Chilled Water Nodes");
// Condenser node processing depends on condenser type, see below
ExhaustAbsorber(AbsorberNum).HeatReturnNodeNum = GetOnlySingleNode(cAlphaArgs(6),
Get_ErrorsFound,
cCurrentModuleObject,
cAlphaArgs(1),
DataLoopNode::NodeType_Water,
DataLoopNode::NodeConnectionType_Inlet,
3,
DataLoopNode::ObjectIsNotParent);
ExhaustAbsorber(AbsorberNum).HeatSupplyNodeNum = GetOnlySingleNode(cAlphaArgs(7),
Get_ErrorsFound,
cCurrentModuleObject,
cAlphaArgs(1),
DataLoopNode::NodeType_Water,
DataLoopNode::NodeConnectionType_Outlet,
3,
DataLoopNode::ObjectIsNotParent);
TestCompSet(cCurrentModuleObject, cAlphaArgs(1), cAlphaArgs(6), cAlphaArgs(7), "Hot Water Nodes");
if (Get_ErrorsFound) {
ShowFatalError("Errors found in processing node input for " + cCurrentModuleObject + '=' + cAlphaArgs(1));
Get_ErrorsFound = false;
}
// Assign Part Load Ratios
ExhaustAbsorber(AbsorberNum).MinPartLoadRat = rNumericArgs(7);
ExhaustAbsorber(AbsorberNum).MaxPartLoadRat = rNumericArgs(8);
ExhaustAbsorber(AbsorberNum).OptPartLoadRat = rNumericArgs(9);
// Assign Design Conditions
ExhaustAbsorber(AbsorberNum).TempDesCondReturn = rNumericArgs(10);
ExhaustAbsorber(AbsorberNum).TempDesCHWSupply = rNumericArgs(11);
ExhaustAbsorber(AbsorberNum).EvapVolFlowRate = rNumericArgs(12);
if (ExhaustAbsorber(AbsorberNum).EvapVolFlowRate == AutoSize) {
ExhaustAbsorber(AbsorberNum).EvapVolFlowRateWasAutoSized = true;
}
if (UtilityRoutines::SameString(cAlphaArgs(16), "AirCooled")) {
ExhaustAbsorber(AbsorberNum).CondVolFlowRate = 0.0011; // Condenser flow rate not used for this cond type
} else {
ExhaustAbsorber(AbsorberNum).CondVolFlowRate = rNumericArgs(13);
if (ExhaustAbsorber(AbsorberNum).CondVolFlowRate == AutoSize) {
ExhaustAbsorber(AbsorberNum).CondVolFlowRateWasAutoSized = true;
}
}
ExhaustAbsorber(AbsorberNum).HeatVolFlowRate = rNumericArgs(14);
if (ExhaustAbsorber(AbsorberNum).HeatVolFlowRate == AutoSize) {
ExhaustAbsorber(AbsorberNum).HeatVolFlowRateWasAutoSized = true;
}
// Assign Curve Numbers
ExhaustAbsorber(AbsorberNum).CoolCapFTCurve = GetCurveCheck(cAlphaArgs(8), Get_ErrorsFound, ChillerName);
ExhaustAbsorber(AbsorberNum).ThermalEnergyCoolFTCurve = GetCurveCheck(cAlphaArgs(9), Get_ErrorsFound, ChillerName);
ExhaustAbsorber(AbsorberNum).ThermalEnergyCoolFPLRCurve = GetCurveCheck(cAlphaArgs(10), Get_ErrorsFound, ChillerName);
ExhaustAbsorber(AbsorberNum).ElecCoolFTCurve = GetCurveCheck(cAlphaArgs(11), Get_ErrorsFound, ChillerName);
ExhaustAbsorber(AbsorberNum).ElecCoolFPLRCurve = GetCurveCheck(cAlphaArgs(12), Get_ErrorsFound, ChillerName);
ExhaustAbsorber(AbsorberNum).HeatCapFCoolCurve = GetCurveCheck(cAlphaArgs(13), Get_ErrorsFound, ChillerName);
ExhaustAbsorber(AbsorberNum).ThermalEnergyHeatFHPLRCurve = GetCurveCheck(cAlphaArgs(14), Get_ErrorsFound, ChillerName);
if (Get_ErrorsFound) {
ShowFatalError("Errors found in processing curve input for " + cCurrentModuleObject + '=' + cAlphaArgs(1));
Get_ErrorsFound = false;
}
if (UtilityRoutines::SameString(cAlphaArgs(15), "LeavingCondenser")) {
ExhaustAbsorber(AbsorberNum).isEnterCondensTemp = false;
} else if (UtilityRoutines::SameString(cAlphaArgs(15), "EnteringCondenser")) {
ExhaustAbsorber(AbsorberNum).isEnterCondensTemp = true;
} else {
ExhaustAbsorber(AbsorberNum).isEnterCondensTemp = true;
ShowWarningError("Invalid " + cAlphaFieldNames(15) + '=' + cAlphaArgs(15));
ShowContinueError("Entered in " + cCurrentModuleObject + '=' + cAlphaArgs(1));
ShowContinueError("resetting to ENTERING-CONDENSER, simulation continues");
}
// Assign Other Paramters
if (UtilityRoutines::SameString(cAlphaArgs(16), "AirCooled")) {
ExhaustAbsorber(AbsorberNum).isWaterCooled = false;
} else if (UtilityRoutines::SameString(cAlphaArgs(16), "WaterCooled")) {
ExhaustAbsorber(AbsorberNum).isWaterCooled = true;
} else {
ExhaustAbsorber(AbsorberNum).isWaterCooled = true;
ShowWarningError("Invalid " + cAlphaFieldNames(16) + '=' + cAlphaArgs(16));
ShowContinueError("Entered in " + cCurrentModuleObject + '=' + cAlphaArgs(1));
ShowContinueError("resetting to WATER-COOLED, simulation continues");
}
if (!ExhaustAbsorber(AbsorberNum).isEnterCondensTemp && !ExhaustAbsorber(AbsorberNum).isWaterCooled) {
ExhaustAbsorber(AbsorberNum).isEnterCondensTemp = true;
ShowWarningError(cCurrentModuleObject + "=\"" + cAlphaArgs(1) + "\", invalid value");
ShowContinueError("Invalid to have both LeavingCondenser and AirCooled.");
ShowContinueError("resetting to EnteringCondenser, simulation continues");
}
if (ExhaustAbsorber(AbsorberNum).isWaterCooled) {
if (lAlphaFieldBlanks(5)) {
ShowSevereError(cCurrentModuleObject + "=\"" + cAlphaArgs(1) + "\", invalid value");
ShowContinueError("For WaterCooled chiller the condenser outlet node is required.");
Get_ErrorsFound = true;
}
ExhaustAbsorber(AbsorberNum).CondReturnNodeNum = GetOnlySingleNode(cAlphaArgs(4),
Get_ErrorsFound,
cCurrentModuleObject,
cAlphaArgs(1),
DataLoopNode::NodeType_Water,
DataLoopNode::NodeConnectionType_Inlet,
2,
DataLoopNode::ObjectIsNotParent);
ExhaustAbsorber(AbsorberNum).CondSupplyNodeNum = GetOnlySingleNode(cAlphaArgs(5),
Get_ErrorsFound,
cCurrentModuleObject,
cAlphaArgs(1),
DataLoopNode::NodeType_Water,
DataLoopNode::NodeConnectionType_Outlet,
2,
DataLoopNode::ObjectIsNotParent);
TestCompSet(cCurrentModuleObject, cAlphaArgs(1), cAlphaArgs(4), cAlphaArgs(5), "Condenser Water Nodes");
} else {
ExhaustAbsorber(AbsorberNum).CondReturnNodeNum = GetOnlySingleNode(cAlphaArgs(4),
Get_ErrorsFound,
cCurrentModuleObject,
cAlphaArgs(1),
DataLoopNode::NodeType_Air,
DataLoopNode::NodeConnectionType_OutsideAirReference,
2,
DataLoopNode::ObjectIsNotParent);
// Condenser outlet node not used for air or evap cooled condenser so ingore cAlphaArgs( 5 )
// Connection not required for air or evap cooled condenser so no call to TestCompSet here
CheckAndAddAirNodeNumber(ExhaustAbsorber(AbsorberNum).CondReturnNodeNum, Okay);
if (!Okay) {
ShowWarningError(cCurrentModuleObject + ", Adding OutdoorAir:Node=" + cAlphaArgs(4));
}
}
ExhaustAbsorber(AbsorberNum).CHWLowLimitTemp = rNumericArgs(15);
ExhaustAbsorber(AbsorberNum).SizFac = rNumericArgs(16);
ExhaustAbsorber(AbsorberNum).TypeOf = cAlphaArgs(17);
if (UtilityRoutines::SameString(cAlphaArgs(17), "Generator:MicroTurbine")) {
ExhaustAbsorber(AbsorberNum).CompType_Num = DataGlobalConstants::iGeneratorMicroturbine;
ExhaustAbsorber(AbsorberNum).ExhuastSourceName = cAlphaArgs(18);
auto thisMTG = MicroturbineElectricGenerator::MTGeneratorSpecs::factory(ExhaustAbsorber(AbsorberNum).ExhuastSourceName);
ExhaustAbsorber(AbsorberNum).ExhaustAirInletNodeNum =
dynamic_cast<MicroturbineElectricGenerator::MTGeneratorSpecs *>(thisMTG)->CombustionAirOutletNodeNum;
}
}
if (Get_ErrorsFound) {
ShowFatalError("Errors found in processing input for " + cCurrentModuleObject);
}
}
void ExhaustAbsorberSpecs::setupOutputVariables()
{
std::string const ChillerName = this->Name;
SetupOutputVariable("Chiller Heater Evaporator Cooling Rate", OutputProcessor::Unit::W, this->CoolingLoad, "System", "Average", ChillerName);
SetupOutputVariable("Chiller Heater Evaporator Cooling Energy",
OutputProcessor::Unit::J,
this->CoolingEnergy,
"System",
"Sum",
ChillerName,
_,
"ENERGYTRANSFER",
"CHILLERS",
_,
"Plant");
SetupOutputVariable("Chiller Heater Heating Rate", OutputProcessor::Unit::W, this->HeatingLoad, "System", "Average", ChillerName);
SetupOutputVariable("Chiller Heater Heating Energy",
OutputProcessor::Unit::J,
this->HeatingEnergy,
"System",
"Sum",
ChillerName,
_,
"ENERGYTRANSFER",
"BOILERS",
_,
"Plant");
SetupOutputVariable(
"Chiller Heater Condenser Heat Transfer Rate", OutputProcessor::Unit::W, this->TowerLoad, "System", "Average", ChillerName);
SetupOutputVariable("Chiller Heater Condenser Heat Transfer Energy",
OutputProcessor::Unit::J,
this->TowerEnergy,
"System",
"Sum",
ChillerName,
_,
"ENERGYTRANSFER",
"HEATREJECTION",
_,
"Plant");
SetupOutputVariable(
"Chiller Heater Cooling Source Heat COP", OutputProcessor::Unit::W_W, this->ThermalEnergyCOP, "System", "Average", ChillerName);
SetupOutputVariable("Chiller Heater Electric Power", OutputProcessor::Unit::W, this->ElectricPower, "System", "Average", ChillerName);
// Do not include this on meters, this would duplicate the cool electric and heat electric
SetupOutputVariable("Chiller Heater Electric Energy", OutputProcessor::Unit::J, this->ElectricEnergy, "System", "Sum", ChillerName);
SetupOutputVariable(
"Chiller Heater Cooling Electric Power", OutputProcessor::Unit::W, this->CoolElectricPower, "System", "Average", ChillerName);
SetupOutputVariable("Chiller Heater Cooling Electric Energy",
OutputProcessor::Unit::J,
this->CoolElectricEnergy,
"System",
"Sum",
ChillerName,
_,
"Electricity",
"Cooling",
_,
"Plant");
SetupOutputVariable(
"Chiller Heater Heating Electric Power", OutputProcessor::Unit::W, this->HeatElectricPower, "System", "Average", ChillerName);
SetupOutputVariable("Chiller Heater Heating Electric Energy",
OutputProcessor::Unit::J,
this->HeatElectricEnergy,
"System",
"Sum",
ChillerName,
_,
"Electricity",
"Heating",
_,
"Plant");
SetupOutputVariable(
"Chiller Heater Evaporator Inlet Temperature", OutputProcessor::Unit::C, this->ChillReturnTemp, "System", "Average", ChillerName);
SetupOutputVariable(
"Chiller Heater Evaporator Outlet Temperature", OutputProcessor::Unit::C, this->ChillSupplyTemp, "System", "Average", ChillerName);
SetupOutputVariable(
"Chiller Heater Evaporator Mass Flow Rate", OutputProcessor::Unit::kg_s, this->ChillWaterFlowRate, "System", "Average", ChillerName);
if (this->isWaterCooled) {
SetupOutputVariable(
"Chiller Heater Condenser Inlet Temperature", OutputProcessor::Unit::C, this->CondReturnTemp, "System", "Average", ChillerName);
SetupOutputVariable(
"Chiller Heater Condenser Outlet Temperature", OutputProcessor::Unit::C, this->CondSupplyTemp, "System", "Average", ChillerName);
SetupOutputVariable(
"Chiller Heater Condenser Mass Flow Rate", OutputProcessor::Unit::kg_s, this->CondWaterFlowRate, "System", "Average", ChillerName);
} else {
SetupOutputVariable(
"Chiller Heater Condenser Inlet Temperature", OutputProcessor::Unit::C, this->CondReturnTemp, "System", "Average", ChillerName);
}
SetupOutputVariable(
"Chiller Heater Heating Inlet Temperature", OutputProcessor::Unit::C, this->HotWaterReturnTemp, "System", "Average", ChillerName);
SetupOutputVariable(
"Chiller Heater Heating Outlet Temperature", OutputProcessor::Unit::C, this->HotWaterSupplyTemp, "System", "Average", ChillerName);
SetupOutputVariable(
"Chiller Heater Heating Mass Flow Rate", OutputProcessor::Unit::kg_s, this->HotWaterFlowRate, "System", "Average", ChillerName);
SetupOutputVariable(
"Chiller Heater Cooling Part Load Ratio", OutputProcessor::Unit::None, this->CoolPartLoadRatio, "System", "Average", ChillerName);
SetupOutputVariable("Chiller Heater Maximum Cooling Rate", OutputProcessor::Unit::W, this->CoolingCapacity, "System", "Average", ChillerName);
SetupOutputVariable(
"Chiller Heater Heating Part Load Ratio", OutputProcessor::Unit::None, this->HeatPartLoadRatio, "System", "Average", ChillerName);
SetupOutputVariable("Chiller Heater Maximum Heating Rate", OutputProcessor::Unit::W, this->HeatingCapacity, "System", "Average", ChillerName);
SetupOutputVariable(
"Chiller Heater Runtime Fraction", OutputProcessor::Unit::None, this->FractionOfPeriodRunning, "System", "Average", ChillerName);
SetupOutputVariable(
"Chiller Heater Source Exhaust Inlet Temperature", OutputProcessor::Unit::C, this->ExhaustInTemp, "System", "Average", ChillerName);
SetupOutputVariable(
"Chiller Heater Source Exhaust Inlet Mass Flow Rate", OutputProcessor::Unit::kg_s, this->ExhaustInFlow, "System", "Average", ChillerName);
SetupOutputVariable("Chiller Heater Heating Heat Recovery Potential Rate",
OutputProcessor::Unit::W,
this->ExhHeatRecPotentialHeat,
"System",
"Average",
ChillerName);
SetupOutputVariable("Chiller Heater Cooling Heat Recovery Potential Rate",
OutputProcessor::Unit::W,
this->ExhHeatRecPotentialCool,
"System",
"Average",
ChillerName);
SetupOutputVariable("Chiller Heater Cooling Source Heat Transfer Rate",
OutputProcessor::Unit::W,
this->CoolThermalEnergyUseRate,
"System",
"Average",
ChillerName);
SetupOutputVariable("Chiller Heater Heating Source Heat Transfer Rate",
OutputProcessor::Unit::W,
this->HeatThermalEnergyUseRate,
"System",
"Average",
ChillerName);
}
void ExhaustAbsorberSpecs::initialize()
{
// SUBROUTINE INFORMATION:
// AUTHOR Fred Buhl
// DATE WRITTEN June 2003
// MODIFIED na
// RE-ENGINEERED na
// PURPOSE OF THIS SUBROUTINE:
// This subroutine is for initializations of Exhaust Fired absorption chiller
// components.
// METHODOLOGY EMPLOYED:
// Uses the status flags to trigger initializations.
// SUBROUTINE PARAMETER DEFINITIONS:
std::string const RoutineName("InitExhaustAbsorber");
// SUBROUTINE LOCAL VARIABLE DECLARATIONS:
int CondInletNode; // node number of water inlet node to the condenser
int CondOutletNode; // node number of water outlet node from the condenser
int HeatInletNode; // node number of hot water inlet node
int HeatOutletNode; // node number of hot water outlet node
bool errFlag;
Real64 rho; // local fluid density
Real64 mdot; // lcoal fluid mass flow rate
if (this->oneTimeInit) {
this->setupOutputVariables();
this->oneTimeInit = false;
}
// Init more variables
if (this->plantScanInit) {
// Locate the chillers on the plant loops for later usage
errFlag = false;
PlantUtilities::ScanPlantLoopsForObject(this->Name,
DataPlant::TypeOf_Chiller_ExhFiredAbsorption,
this->CWLoopNum,
this->CWLoopSideNum,
this->CWBranchNum,
this->CWCompNum,
errFlag,
this->CHWLowLimitTemp,
_,
_,
this->ChillReturnNodeNum,
_);
if (errFlag) {
ShowFatalError("InitExhaustAbsorber: Program terminated due to previous condition(s).");
}
PlantUtilities::ScanPlantLoopsForObject(this->Name,
DataPlant::TypeOf_Chiller_ExhFiredAbsorption,
this->HWLoopNum,
this->HWLoopSideNum,
this->HWBranchNum,
this->HWCompNum,
errFlag,
_,
_,
_,
this->HeatReturnNodeNum,
_);
if (errFlag) {
ShowFatalError("InitExhaustAbsorber: Program terminated due to previous condition(s).");
}
if (this->isWaterCooled) {
PlantUtilities::ScanPlantLoopsForObject(this->Name,
DataPlant::TypeOf_Chiller_ExhFiredAbsorption,
this->CDLoopNum,
this->CDLoopSideNum,
this->CDBranchNum,
this->CDCompNum,
errFlag,
_,
_,
_,
this->CondReturnNodeNum,
_);
if (errFlag) {
ShowFatalError("InitExhaustAbsorber: Program terminated due to previous condition(s).");
}
PlantUtilities::InterConnectTwoPlantLoopSides(
this->CWLoopNum, this->CWLoopSideNum, this->CDLoopNum, this->CDLoopSideNum, DataPlant::TypeOf_Chiller_ExhFiredAbsorption, true);
PlantUtilities::InterConnectTwoPlantLoopSides(
this->HWLoopNum, this->HWLoopSideNum, this->CDLoopNum, this->CDLoopSideNum, DataPlant::TypeOf_Chiller_ExhFiredAbsorption, true);
}
PlantUtilities::InterConnectTwoPlantLoopSides(
this->CWLoopNum, this->CWLoopSideNum, this->HWLoopNum, this->HWLoopSideNum, DataPlant::TypeOf_Chiller_ExhFiredAbsorption, true);
// check if outlet node of chilled water side has a setpoint.
if ((DataLoopNode::Node(this->ChillSupplyNodeNum).TempSetPoint == DataLoopNode::SensedNodeFlagValue) &&
(DataLoopNode::Node(this->ChillSupplyNodeNum).TempSetPointHi == DataLoopNode::SensedNodeFlagValue)) {
if (!DataGlobals::AnyEnergyManagementSystemInModel) {
if (!this->ChillSetPointErrDone) {
ShowWarningError("Missing temperature setpoint on cool side for chiller heater named " + this->Name);
ShowContinueError(" A temperature setpoint is needed at the outlet node of this chiller, use a SetpointManager");
ShowContinueError(" The overall loop setpoint will be assumed for chiller. The simulation continues ... ");
this->ChillSetPointErrDone = true;
}
} else {
// need call to EMS to check node
errFlag = false; // but not really fatal yet, but should be.
EMSManager::CheckIfNodeSetPointManagedByEMS(this->ChillSupplyNodeNum, EMSManager::iTemperatureSetPoint, errFlag);
if (errFlag) {
if (!this->ChillSetPointErrDone) {
ShowWarningError("Missing temperature setpoint on cool side for chiller heater named " + this->Name);
ShowContinueError(" A temperature setpoint is needed at the outlet node of this chiller evaporator ");
ShowContinueError(" use a Setpoint Manager to establish a setpoint at the chiller evaporator outlet node ");
ShowContinueError(" or use an EMS actuator to establish a setpoint at the outlet node ");
ShowContinueError(" The overall loop setpoint will be assumed for chiller. The simulation continues ... ");
this->ChillSetPointErrDone = true;
}
}
}
this->ChillSetPointSetToLoop = true;
DataLoopNode::Node(this->ChillSupplyNodeNum).TempSetPoint =
DataLoopNode::Node(DataPlant::PlantLoop(this->CWLoopNum).TempSetPointNodeNum).TempSetPoint;
DataLoopNode::Node(this->ChillSupplyNodeNum).TempSetPointHi =
DataLoopNode::Node(DataPlant::PlantLoop(this->CWLoopNum).TempSetPointNodeNum).TempSetPointHi;
}
// check if outlet node of hot water side has a setpoint.
if ((DataLoopNode::Node(this->HeatSupplyNodeNum).TempSetPoint == DataLoopNode::SensedNodeFlagValue) &&
(DataLoopNode::Node(this->HeatSupplyNodeNum).TempSetPointLo == DataLoopNode::SensedNodeFlagValue)) {
if (!DataGlobals::AnyEnergyManagementSystemInModel) {
if (!this->HeatSetPointErrDone) {
ShowWarningError("Missing temperature setpoint on heat side for chiller heater named " + this->Name);
ShowContinueError(" A temperature setpoint is needed at the outlet node of this chiller, use a SetpointManager");
ShowContinueError(" The overall loop setpoint will be assumed for chiller. The simulation continues ... ");
this->HeatSetPointErrDone = true;
}
} else {
// need call to EMS to check node
errFlag = false; // but not really fatal yet, but should be.
EMSManager::CheckIfNodeSetPointManagedByEMS(this->HeatSupplyNodeNum, EMSManager::iTemperatureSetPoint, errFlag);
if (errFlag) {
if (!this->HeatSetPointErrDone) {
ShowWarningError("Missing temperature setpoint on heat side for chiller heater named " + this->Name);
ShowContinueError(" A temperature setpoint is needed at the outlet node of this chiller heater ");
ShowContinueError(" use a Setpoint Manager to establish a setpoint at the heater side outlet node ");
ShowContinueError(" or use an EMS actuator to establish a setpoint at the outlet node ");
ShowContinueError(" The overall loop setpoint will be assumed for heater side. The simulation continues ... ");
this->HeatSetPointErrDone = true;
}
}
}
this->HeatSetPointSetToLoop = true;
DataLoopNode::Node(this->HeatSupplyNodeNum).TempSetPoint =
DataLoopNode::Node(DataPlant::PlantLoop(this->HWLoopNum).TempSetPointNodeNum).TempSetPoint;
DataLoopNode::Node(this->HeatSupplyNodeNum).TempSetPointLo =
DataLoopNode::Node(DataPlant::PlantLoop(this->HWLoopNum).TempSetPointNodeNum).TempSetPointLo;
}
this->plantScanInit = false;
}
CondInletNode = this->CondReturnNodeNum;
CondOutletNode = this->CondSupplyNodeNum;
HeatInletNode = this->HeatReturnNodeNum;
HeatOutletNode = this->HeatSupplyNodeNum;
if (this->envrnInit && DataGlobals::BeginEnvrnFlag && (DataPlant::PlantFirstSizesOkayToFinalize)) {
if (this->isWaterCooled) {
// init max available condenser water flow rate
if (this->CDLoopNum > 0) {
rho = FluidProperties::GetDensityGlycol(DataPlant::PlantLoop(this->CDLoopNum).FluidName,
DataGlobals::CWInitConvTemp,
DataPlant::PlantLoop(this->CDLoopNum).FluidIndex,
RoutineName);
} else {
rho = Psychrometrics::RhoH2O(DataGlobals::InitConvTemp);
}
this->DesCondMassFlowRate = rho * this->CondVolFlowRate;
PlantUtilities::InitComponentNodes(0.0,
this->DesCondMassFlowRate,
CondInletNode,
CondOutletNode,
this->CDLoopNum,
this->CDLoopSideNum,
this->CDBranchNum,
this->CDCompNum);
}
if (this->HWLoopNum > 0) {
rho = FluidProperties::GetDensityGlycol(DataPlant::PlantLoop(this->HWLoopNum).FluidName,
DataGlobals::HWInitConvTemp,
DataPlant::PlantLoop(this->HWLoopNum).FluidIndex,
RoutineName);
} else {
rho = Psychrometrics::RhoH2O(DataGlobals::InitConvTemp);
}
this->DesHeatMassFlowRate = rho * this->HeatVolFlowRate;
// init available hot water flow rate
PlantUtilities::InitComponentNodes(0.0,
this->DesHeatMassFlowRate,
HeatInletNode,
HeatOutletNode,
this->HWLoopNum,
this->HWLoopSideNum,
this->HWBranchNum,
this->HWCompNum);
if (this->CWLoopNum > 0) {
rho = FluidProperties::GetDensityGlycol(DataPlant::PlantLoop(this->CWLoopNum).FluidName,
DataGlobals::CWInitConvTemp,
DataPlant::PlantLoop(this->CWLoopNum).FluidIndex,
RoutineName);
} else {
rho = Psychrometrics::RhoH2O(DataGlobals::InitConvTemp);
}
this->DesEvapMassFlowRate = rho * this->EvapVolFlowRate;
// init available hot water flow rate
PlantUtilities::InitComponentNodes(0.0,
this->DesEvapMassFlowRate,
this->ChillReturnNodeNum,
this->ChillSupplyNodeNum,
this->CWLoopNum,
this->CWLoopSideNum,
this->CWBranchNum,
this->CWCompNum);
this->envrnInit = false;
}
if (!DataGlobals::BeginEnvrnFlag) {
this->envrnInit = true;
}
// this component model works off setpoints on the leaving node
// fill from plant if needed
if (this->ChillSetPointSetToLoop) {
DataLoopNode::Node(this->ChillSupplyNodeNum).TempSetPoint =
DataLoopNode::Node(DataPlant::PlantLoop(this->CWLoopNum).TempSetPointNodeNum).TempSetPoint;
DataLoopNode::Node(this->ChillSupplyNodeNum).TempSetPointHi =
DataLoopNode::Node(DataPlant::PlantLoop(this->CWLoopNum).TempSetPointNodeNum).TempSetPointHi;
}
if (this->HeatSetPointSetToLoop) {
DataLoopNode::Node(this->HeatSupplyNodeNum).TempSetPoint =
DataLoopNode::Node(DataPlant::PlantLoop(this->HWLoopNum).TempSetPointNodeNum).TempSetPoint;
DataLoopNode::Node(this->HeatSupplyNodeNum).TempSetPointLo =
DataLoopNode::Node(DataPlant::PlantLoop(this->HWLoopNum).TempSetPointNodeNum).TempSetPointLo;
}
if ((this->isWaterCooled) && ((this->InHeatingMode) || (this->InCoolingMode)) && (!this->plantScanInit)) {
mdot = this->DesCondMassFlowRate;
PlantUtilities::SetComponentFlowRate(
mdot, this->CondReturnNodeNum, this->CondSupplyNodeNum, this->CDLoopNum, this->CDLoopSideNum, this->CDBranchNum, this->CDCompNum);
} else {
mdot = 0.0;
if (this->CDLoopNum > 0) {
PlantUtilities::SetComponentFlowRate(
mdot, this->CondReturnNodeNum, this->CondSupplyNodeNum, this->CDLoopNum, this->CDLoopSideNum, this->CDBranchNum, this->CDCompNum);
}
}
}
void ExhaustAbsorberSpecs::size()
{
// SUBROUTINE INFORMATION:
// AUTHOR Fred Buhl
// DATE WRITTEN June 2003
// MODIFIED November 2013 Daeho Kang, add component sizing table entries
// RE-ENGINEERED na
// PURPOSE OF THIS SUBROUTINE:
// This subroutine is for sizing Exhaust Fired absorption chiller components for which
// capacities and flow rates have not been specified in the input.
// METHODOLOGY EMPLOYED:
// Obtains evaporator flow rate from the plant sizing array. Calculates nominal capacity from
// the evaporator flow rate and the chilled water loop design delta T. The condenser flow rate
// is calculated from the nominal capacity, the COP, and the condenser loop design delta T.
// SUBROUTINE PARAMETER DEFINITIONS:
std::string const RoutineName("SizeExhaustAbsorber");
bool ErrorsFound; // If errors detected in input
std::string equipName;
Real64 Cp; // local fluid specific heat
Real64 rho; // local fluid density
Real64 tmpNomCap; // local nominal capacity cooling power
Real64 tmpEvapVolFlowRate; // local evaporator design volume flow rate
Real64 tmpCondVolFlowRate; // local condenser design volume flow rate
Real64 tmpHeatRecVolFlowRate; // local heat recovery design volume flow rate
Real64 NomCapUser; // Hardsized nominal capacity for reporting
Real64 EvapVolFlowRateUser; // Hardsized evaporator volume flow rate for reporting
Real64 CondVolFlowRateUser; // Hardsized condenser flow rate for reporting
Real64 HeatRecVolFlowRateUser; // Hardsized generator flow rate for reporting
ErrorsFound = false;
tmpNomCap = this->NomCoolingCap;
tmpEvapVolFlowRate = this->EvapVolFlowRate;
tmpCondVolFlowRate = this->CondVolFlowRate;
tmpHeatRecVolFlowRate = this->HeatVolFlowRate;
int PltSizCondNum = 0; // Plant Sizing index for condenser loop
if (this->isWaterCooled) PltSizCondNum = DataPlant::PlantLoop(this->CDLoopNum).PlantSizNum;
int PltSizHeatNum = DataPlant::PlantLoop(this->HWLoopNum).PlantSizNum;
int PltSizCoolNum = DataPlant::PlantLoop(this->CWLoopNum).PlantSizNum;
if (PltSizCoolNum > 0) {
if (DataSizing::PlantSizData(PltSizCoolNum).DesVolFlowRate >= DataHVACGlobals::SmallWaterVolFlow) {
Cp = FluidProperties::GetSpecificHeatGlycol(DataPlant::PlantLoop(this->CWLoopNum).FluidName,
DataGlobals::CWInitConvTemp,
DataPlant::PlantLoop(this->CWLoopNum).FluidIndex,
RoutineName);
rho = FluidProperties::GetDensityGlycol(DataPlant::PlantLoop(this->CWLoopNum).FluidName,
DataGlobals::CWInitConvTemp,
DataPlant::PlantLoop(this->CWLoopNum).FluidIndex,
RoutineName);
tmpNomCap =
Cp * rho * DataSizing::PlantSizData(PltSizCoolNum).DeltaT * DataSizing::PlantSizData(PltSizCoolNum).DesVolFlowRate * this->SizFac;
if (!this->NomCoolingCapWasAutoSized) tmpNomCap = this->NomCoolingCap;
} else {
if (this->NomCoolingCapWasAutoSized) tmpNomCap = 0.0;
}
if (DataPlant::PlantFirstSizesOkayToFinalize) {
if (this->NomCoolingCapWasAutoSized) {
this->NomCoolingCap = tmpNomCap;
if (DataPlant::PlantFinalSizesOkayToReport) {
ReportSizingManager::ReportSizingOutput(
"ChillerHeater:Absorption:DoubleEffect", this->Name, "Design Size Nominal Cooling Capacity [W]", tmpNomCap);
}
if (DataPlant::PlantFirstSizesOkayToReport) {
ReportSizingManager::ReportSizingOutput(
"ChillerHeater:Absorption:DoubleEffect", this->Name, "Initial Design Size Nominal Cooling Capacity [W]", tmpNomCap);
}
} else {
if (this->NomCoolingCap > 0.0 && tmpNomCap > 0.0) {
NomCapUser = this->NomCoolingCap;
if (DataPlant::PlantFinalSizesOkayToReport) {
ReportSizingManager::ReportSizingOutput("ChillerHeater:Absorption:DoubleEffect",
this->Name,
"Design Size Nominal Cooling Capacity [W]",
tmpNomCap,
"User-Specified Nominal Cooling Capacity [W]",
NomCapUser);
if (DataGlobals::DisplayExtraWarnings) {
if ((std::abs(tmpNomCap - NomCapUser) / NomCapUser) > DataSizing::AutoVsHardSizingThreshold) {
ShowMessage("SizeChillerHeaterAbsorptionDoubleEffect: Potential issue with equipment sizing for " + this->Name);
ShowContinueError("User-Specified Nominal Capacity of " + General::RoundSigDigits(NomCapUser, 2) + " [W]");
ShowContinueError("differs from Design Size Nominal Capacity of " + General::RoundSigDigits(tmpNomCap, 2) +
" [W]");
ShowContinueError("This may, or may not, indicate mismatched component sizes.");
ShowContinueError("Verify that the value entered is intended and is consistent with other components.");
}
}
}
tmpNomCap = NomCapUser;
}
}
}
} else {
if (this->NomCoolingCapWasAutoSized) {
if (DataPlant::PlantFirstSizesOkayToFinalize) {
ShowSevereError("SizeExhaustAbsorber: ChillerHeater:Absorption:DoubleEffect=\"" + this->Name + "\", autosize error.");
ShowContinueError("Autosizing of Exhaust Fired Absorption Chiller nominal cooling capacity requires");
ShowContinueError("a cooling loop Sizing:Plant object.");
ErrorsFound = true;
}
} else {
if (DataPlant::PlantFinalSizesOkayToReport) {
if (this->NomCoolingCap > 0.0) {
ReportSizingManager::ReportSizingOutput(
"Chiller:Absorption:DoubleEffect", this->Name, "User-Specified Nominal Capacity [W]", this->NomCoolingCap);
}
}
}
}
if (PltSizCoolNum > 0) {
if (DataSizing::PlantSizData(PltSizCoolNum).DesVolFlowRate >= DataHVACGlobals::SmallWaterVolFlow) {
tmpEvapVolFlowRate = DataSizing::PlantSizData(PltSizCoolNum).DesVolFlowRate * this->SizFac;
if (!this->EvapVolFlowRateWasAutoSized) tmpEvapVolFlowRate = this->EvapVolFlowRate;
} else {
if (this->EvapVolFlowRateWasAutoSized) tmpEvapVolFlowRate = 0.0;
}
if (DataPlant::PlantFirstSizesOkayToFinalize) {
if (this->EvapVolFlowRateWasAutoSized) {
this->EvapVolFlowRate = tmpEvapVolFlowRate;
if (DataPlant::PlantFinalSizesOkayToReport) {
ReportSizingManager::ReportSizingOutput("ChillerHeater:Absorption:DoubleEffect",
this->Name,
"Design Size Design Chilled Water Flow Rate [m3/s]",
tmpEvapVolFlowRate);
}
if (DataPlant::PlantFirstSizesOkayToReport) {
ReportSizingManager::ReportSizingOutput("ChillerHeater:Absorption:DoubleEffect",
this->Name,
"Initial Design Size Design Chilled Water Flow Rate [m3/s]",
tmpEvapVolFlowRate);
}
} else {
if (this->EvapVolFlowRate > 0.0 && tmpEvapVolFlowRate > 0.0) {
EvapVolFlowRateUser = this->EvapVolFlowRate;
if (DataPlant::PlantFinalSizesOkayToReport) {
ReportSizingManager::ReportSizingOutput("ChillerHeater:Absorption:DoubleEffect",
this->Name,
"Design Size Design Chilled Water Flow Rate [m3/s]",
tmpEvapVolFlowRate,
"User-Specified Design Chilled Water Flow Rate [m3/s]",
EvapVolFlowRateUser);
if (DataGlobals::DisplayExtraWarnings) {
if ((std::abs(tmpEvapVolFlowRate - EvapVolFlowRateUser) / EvapVolFlowRateUser) >
DataSizing::AutoVsHardSizingThreshold) {
ShowMessage("SizeChillerAbsorptionDoubleEffect: Potential issue with equipment sizing for " + this->Name);
ShowContinueError("User-Specified Design Chilled Water Flow Rate of " +
General::RoundSigDigits(EvapVolFlowRateUser, 5) + " [m3/s]");
ShowContinueError("differs from Design Size Design Chilled Water Flow Rate of " +
General::RoundSigDigits(tmpEvapVolFlowRate, 5) + " [m3/s]");
ShowContinueError("This may, or may not, indicate mismatched component sizes.");
ShowContinueError("Verify that the value entered is intended and is consistent with other components.");
}
}
}
tmpEvapVolFlowRate = EvapVolFlowRateUser;
}
}
}
} else {
if (this->EvapVolFlowRateWasAutoSized) {
if (DataPlant::PlantFirstSizesOkayToFinalize) {
ShowSevereError("SizeExhaustAbsorber: ChillerHeater:Absorption:DoubleEffect=\"" + this->Name + "\", autosize error.");
ShowContinueError("Autosizing of Exhaust Fired Absorption Chiller evap flow rate requires");
ShowContinueError("a cooling loop Sizing:Plant object.");
ErrorsFound = true;
}
} else {
if (DataPlant::PlantFinalSizesOkayToReport) {
if (this->EvapVolFlowRate > 0.0) {
ReportSizingManager::ReportSizingOutput("ChillerHeater:Absorption:DoubleEffect",
this->Name,
"User-Specified Design Chilled Water Flow Rate [m3/s]",
this->EvapVolFlowRate);
}
}
}
}
PlantUtilities::RegisterPlantCompDesignFlow(this->ChillReturnNodeNum, tmpEvapVolFlowRate);
if (PltSizHeatNum > 0) {
if (DataSizing::PlantSizData(PltSizHeatNum).DesVolFlowRate >= DataHVACGlobals::SmallWaterVolFlow) {
tmpHeatRecVolFlowRate = DataSizing::PlantSizData(PltSizHeatNum).DesVolFlowRate * this->SizFac;
if (!this->HeatVolFlowRateWasAutoSized) tmpHeatRecVolFlowRate = this->HeatVolFlowRate;
} else {
if (this->HeatVolFlowRateWasAutoSized) tmpHeatRecVolFlowRate = 0.0;
}
if (DataPlant::PlantFirstSizesOkayToFinalize) {
if (this->HeatVolFlowRateWasAutoSized) {
this->HeatVolFlowRate = tmpHeatRecVolFlowRate;
if (DataPlant::PlantFinalSizesOkayToReport) {
ReportSizingManager::ReportSizingOutput("ChillerHeater:Absorption:DoubleEffect",
this->Name,
"Design Size Design Hot Water Flow Rate [m3/s]",
tmpHeatRecVolFlowRate);
}
if (DataPlant::PlantFirstSizesOkayToReport) {
ReportSizingManager::ReportSizingOutput("ChillerHeater:Absorption:DoubleEffect",
this->Name,
"Initial Design Size Design Hot Water Flow Rate [m3/s]",
tmpHeatRecVolFlowRate);
}
} else {
if (this->HeatVolFlowRate > 0.0 && tmpHeatRecVolFlowRate > 0.0) {
HeatRecVolFlowRateUser = this->HeatVolFlowRate;
if (DataPlant::PlantFinalSizesOkayToReport) {
ReportSizingManager::ReportSizingOutput("ChillerHeater:Absorption:DoubleEffect",
this->Name,
"Design Size Design Hot Water Flow Rate [m3/s]",
tmpHeatRecVolFlowRate,
"User-Specified Design Hot Water Flow Rate [m3/s]",
HeatRecVolFlowRateUser);
if (DataGlobals::DisplayExtraWarnings) {
if ((std::abs(tmpHeatRecVolFlowRate - HeatRecVolFlowRateUser) / HeatRecVolFlowRateUser) >
DataSizing::AutoVsHardSizingThreshold) {
ShowMessage("SizeChillerHeaterAbsorptionDoubleEffect: Potential issue with equipment sizing for " + this->Name);
ShowContinueError("User-Specified Design Hot Water Flow Rate of " +
General::RoundSigDigits(HeatRecVolFlowRateUser, 5) + " [m3/s]");
ShowContinueError("differs from Design Size Design Hot Water Flow Rate of " +
General::RoundSigDigits(tmpHeatRecVolFlowRate, 5) + " [m3/s]");
ShowContinueError("This may, or may not, indicate mismatched component sizes.");
ShowContinueError("Verify that the value entered is intended and is consistent with other components.");
}
}
}
tmpHeatRecVolFlowRate = HeatRecVolFlowRateUser;
}
}
}
} else {
if (this->HeatVolFlowRateWasAutoSized) {
if (DataPlant::PlantFirstSizesOkayToFinalize) {
ShowSevereError("SizeExhaustAbsorber: ChillerHeater:Absorption:DoubleEffect=\"" + this->Name + "\", autosize error.");
ShowContinueError("Autosizing of Exhaust Fired Absorption Chiller hot water flow rate requires");
ShowContinueError("a heating loop Sizing:Plant object.");
ErrorsFound = true;
}
} else {
if (DataPlant::PlantFinalSizesOkayToReport) {
if (this->HeatVolFlowRate > 0.0) {
ReportSizingManager::ReportSizingOutput("ChillerHeater:Absorption:DoubleEffect",
this->Name,
"User-Specified Design Hot Water Flow Rate [m3/s]",
this->HeatVolFlowRate);
}
}
}
}
PlantUtilities::RegisterPlantCompDesignFlow(this->HeatReturnNodeNum, tmpHeatRecVolFlowRate);
if (PltSizCondNum > 0 && PltSizCoolNum > 0) {
if (DataSizing::PlantSizData(PltSizCoolNum).DesVolFlowRate >= DataHVACGlobals::SmallWaterVolFlow && tmpNomCap > 0.0) {
Cp = FluidProperties::GetSpecificHeatGlycol(DataPlant::PlantLoop(this->CDLoopNum).FluidName,
this->TempDesCondReturn,
DataPlant::PlantLoop(this->CDLoopNum).FluidIndex,
RoutineName);
rho = FluidProperties::GetDensityGlycol(DataPlant::PlantLoop(this->CDLoopNum).FluidName,
this->TempDesCondReturn,
DataPlant::PlantLoop(this->CDLoopNum).FluidIndex,
RoutineName);
tmpCondVolFlowRate = tmpNomCap * (1.0 + this->ThermalEnergyCoolRatio) / (DataSizing::PlantSizData(PltSizCondNum).DeltaT * Cp * rho);
if (!this->CondVolFlowRateWasAutoSized) tmpCondVolFlowRate = this->CondVolFlowRate;
} else {
if (this->CondVolFlowRateWasAutoSized) tmpCondVolFlowRate = 0.0;
}
if (DataPlant::PlantFirstSizesOkayToFinalize) {
if (this->CondVolFlowRateWasAutoSized) {
this->CondVolFlowRate = tmpCondVolFlowRate;
if (DataPlant::PlantFinalSizesOkayToReport) {
ReportSizingManager::ReportSizingOutput("ChillerHeater:Absorption:DoubleEffect",
this->Name,
"Design Size Design Condenser Water Flow Rate [m3/s]",
tmpCondVolFlowRate);
}
if (DataPlant::PlantFirstSizesOkayToReport) {
ReportSizingManager::ReportSizingOutput("ChillerHeater:Absorption:DoubleEffect",
this->Name,
"Initial Design Size Design Condenser Water Flow Rate [m3/s]",
tmpCondVolFlowRate);
}
} else {
if (this->CondVolFlowRate > 0.0 && tmpCondVolFlowRate > 0.0) {
CondVolFlowRateUser = this->CondVolFlowRate;
if (DataPlant::PlantFinalSizesOkayToReport) {
ReportSizingManager::ReportSizingOutput("ChillerHeater:Absorption:DoubleEffect",
this->Name,
"Design Size Design Condenser Water Flow Rate [m3/s]",
tmpCondVolFlowRate,
"User-Specified Design Condenser Water Flow Rate [m3/s]",
CondVolFlowRateUser);
if (DataGlobals::DisplayExtraWarnings) {
if ((std::abs(tmpCondVolFlowRate - CondVolFlowRateUser) / CondVolFlowRateUser) >
DataSizing::AutoVsHardSizingThreshold) {
ShowMessage("SizeChillerAbsorptionDoubleEffect: Potential issue with equipment sizing for " + this->Name);
ShowContinueError("User-Specified Design Condenser Water Flow Rate of " +
General::RoundSigDigits(CondVolFlowRateUser, 5) + " [m3/s]");
ShowContinueError("differs from Design Size Design Condenser Water Flow Rate of " +
General::RoundSigDigits(tmpCondVolFlowRate, 5) + " [m3/s]");
ShowContinueError("This may, or may not, indicate mismatched component sizes.");
ShowContinueError("Verify that the value entered is intended and is consistent with other components.");
}
}
}
tmpCondVolFlowRate = CondVolFlowRateUser;
}
}
}
} else {
if (this->CondVolFlowRateWasAutoSized) {
if (DataPlant::PlantFirstSizesOkayToFinalize) {
ShowSevereError("SizeExhaustAbsorber: ChillerHeater:Absorption:DoubleEffect=\"" + this->Name + "\", autosize error.");
ShowSevereError("Autosizing of Exhaust Fired Absorption Chiller condenser flow rate requires a condenser");
ShowContinueError("loop Sizing:Plant object.");
ErrorsFound = true;
}
} else {
if (DataPlant::PlantFinalSizesOkayToReport) {
if (this->CondVolFlowRate > 0.0) {
ReportSizingManager::ReportSizingOutput("ChillerHeater:Absorption:DoubleEffect",
this->Name,
"User-Specified Design Condenser Water Flow Rate [m3/s]",
this->CondVolFlowRate);
}
}
}
}
// save the design condenser water volumetric flow rate for use by the condenser water loop sizing algorithms
if (this->isWaterCooled) PlantUtilities::RegisterPlantCompDesignFlow(this->CondReturnNodeNum, tmpCondVolFlowRate);
if (ErrorsFound) {
ShowFatalError("Preceding sizing errors cause program termination");
}
if (DataPlant::PlantFinalSizesOkayToReport) {
// create predefined report
equipName = this->Name;
OutputReportPredefined::PreDefTableEntry(OutputReportPredefined::pdchMechType, equipName, "ChillerHeater:Absorption:DoubleEffect");
OutputReportPredefined::PreDefTableEntry(OutputReportPredefined::pdchMechNomEff, equipName, this->ThermalEnergyCoolRatio);
OutputReportPredefined::PreDefTableEntry(OutputReportPredefined::pdchMechNomCap, equipName, this->NomCoolingCap);
}
}
void ExhaustAbsorberSpecs::calcChiller(Real64 &MyLoad)
{
// SUBROUTINE INFORMATION:
// AUTHOR Jason Glazer
// DATE WRITTEN March 2001
// MODIFIED Mahabir Bhandari, ORNL, Aug 2011, modified to accomodate exhaust fired chiller
// RE-ENGINEERED na
// PURPOSE OF THIS SUBROUTINE:
// Simulate a Exhaust fired (Exhaust consuming) absorption chiller using
// curves and inputs similar to DOE-2.1e
// METHODOLOGY EMPLOYED:
// Curve fit of performance data
// REFERENCES:
// 1. DOE-2.1e Supplement and source code
// 2. CoolTools GasMod work
// FlowLock = 0 if mass flow rates may be changed by loop components
// FlowLock = 1 if mass flow rates may not be changed by loop components
// SUBROUTINE PARAMETER DEFINITIONS:
Real64 const AbsLeavingTemp(176.667); // C - Minimum temperature leaving the Chiller absorber (350 F)
std::string const RoutineName("CalcExhaustAbsorberChillerModel");
// SUBROUTINE LOCAL VARIABLE DECLARATIONS:
// Local copies of ExhaustAbsorberSpecs Type
// all variables that are local copies of data structure
// variables are prefaced with an "l" for local.
Real64 lNomCoolingCap; // W - design nominal capacity of Absorber
Real64 lThermalEnergyCoolRatio; // ratio of ThermalEnergy input to cooling output
Real64 lThermalEnergyHeatRatio; // ratio of ThermalEnergy input to heating output
Real64 lElecCoolRatio; // ratio of electricity input to cooling output
int lChillReturnNodeNum; // Node number on the inlet side of the plant
int lChillSupplyNodeNum; // Node number on the outlet side of the plant
int lCondReturnNodeNum; // Node number on the inlet side of the condenser
Real64 lMinPartLoadRat; // min allowed operating frac full load
Real64 lMaxPartLoadRat; // max allowed operating frac full load
int lCoolCapFTCurve; // cooling capacity as a function of temperature curve
int lThermalEnergyCoolFTCurve; // ThermalEnergy-Input-to cooling output Ratio Function of Temperature Curve
int lThermalEnergyCoolFPLRCurve; // ThermalEnergy-Input-to cooling output Ratio Function of Part Load Ratio Curve
int lElecCoolFTCurve; // Electric-Input-to cooling output Ratio Function of Temperature Curve
int lElecCoolFPLRCurve; // Electric-Input-to cooling output Ratio Function of Part Load Ratio Curve
bool lIsEnterCondensTemp; // if using entering conderser water temperature is TRUE, exiting is FALSE
bool lIsWaterCooled; // if water cooled it is TRUE
Real64 lCHWLowLimitTemp; // Chilled Water Lower Limit Temperature
int lExhaustAirInletNodeNum; // Combustion Air Inlet Node number
// Local copies of ExhaustAbsorberReportVars Type
Real64 lCoolingLoad(0.0); // cooling load on the chiller (previously called QEvap)
// Real64 lCoolingEnergy( 0.0 ); // variable to track total cooling load for period (was EvapEnergy)
Real64 lTowerLoad(0.0); // load on the cooling tower/condenser (previously called QCond)
// Real64 lTowerEnergy( 0.0 ); // variable to track total tower load for a period (was CondEnergy)
// Real64 lThermalEnergyUseRate( 0.0 ); // instantaneous use of exhaust for period
// Real64 lThermalEnergy( 0.0 ); // variable to track total ThermalEnergy used for a period
Real64 lCoolThermalEnergyUseRate(0.0); // instantaneous use of exhaust for period for cooling
// Real64 lCoolThermalEnergy( 0.0 ); // variable to track total ThermalEnergy used for a period for cooling
Real64 lHeatThermalEnergyUseRate(0.0); // instantaneous use of exhaust for period for heating
// Real64 lElectricPower( 0.0 ); // parasitic electric power used (was PumpingPower)
// Real64 lElectricEnergy( 0.0 ); // track the total electricity used for a period (was PumpingEnergy)
Real64 lCoolElectricPower(0.0); // parasitic electric power used for cooling
// Real64 lCoolElectricEnergy( 0.0 ); // track the total electricity used for a period for cooling
Real64 lHeatElectricPower(0.0); // parasitic electric power used for heating
Real64 lChillReturnTemp(0.0); // reporting: evaporator inlet temperature (was EvapInletTemp)
Real64 lChillSupplyTemp(0.0); // reporting: evaporator outlet temperature (was EvapOutletTemp)
Real64 lChillWaterMassFlowRate(0.0); // reporting: evaporator mass flow rate (was Evapmdot)
Real64 lCondReturnTemp(0.0); // reporting: condenser inlet temperature (was CondInletTemp)
Real64 lCondSupplyTemp(0.0); // reporting: condenser outlet temperature (was CondOutletTemp)
Real64 lCondWaterMassFlowRate(0.0); // reporting: condenser mass flow rate (was Condmdot)
Real64 lCoolPartLoadRatio(0.0); // operating part load ratio (load/capacity for cooling)
Real64 lHeatPartLoadRatio(0.0); // operating part load ratio (load/capacity for heating)
Real64 lAvailableCoolingCapacity(0.0); // current capacity after temperature adjustment
Real64 lFractionOfPeriodRunning(0.0);
Real64 PartLoadRat(0.0); // actual operating part load ratio of unit (ranges from minplr to 1)
Real64 lChillWaterMassflowratemax(0.0); // Maximum flow rate through the evaporator
Real64 lExhaustInTemp(0.0); // Exhaust inlet temperature
Real64 lExhaustInFlow(0.0); // Exhaust inlet flow rate
Real64 lExhHeatRecPotentialCool(0.0); // Exhaust heat recovery potential during cooling
Real64 lExhaustAirHumRat(0.0);
// other local variables
Real64 ChillDeltaTemp; // chilled water temperature difference
Real64 ChillSupplySetPointTemp(0.0);
Real64 calcCondTemp; // the condenser temperature used for curve calculation
// either return or supply depending on user input
Real64 revisedEstimateAvailCap; // final estimate of available capacity if using leaving
// condenser water temperature
Real64 errorAvailCap; // error fraction on final estimate of AvailableCoolingCapacity
int LoopNum;
int LoopSideNum;
Real64 Cp_CW; // local fluid specific heat for chilled water
Real64 Cp_CD = -1; // local fluid specific heat for condenser water -- initializing to negative to ensure it isn't used uninitialized
Real64 CpAir; // specific heat of exhaust air
// define constant values
// set node values to data structure values for nodes
lChillReturnNodeNum = this->ChillReturnNodeNum;
lChillSupplyNodeNum = this->ChillSupplyNodeNum;
lCondReturnNodeNum = this->CondReturnNodeNum;
lExhaustAirInletNodeNum = this->ExhaustAirInletNodeNum;
// set local copies of data from rest of input structure
lNomCoolingCap = this->NomCoolingCap;
lThermalEnergyCoolRatio = this->ThermalEnergyCoolRatio;
lThermalEnergyHeatRatio = this->ThermalEnergyHeatRatio;
lElecCoolRatio = this->ElecCoolRatio;
lMinPartLoadRat = this->MinPartLoadRat;
lMaxPartLoadRat = this->MaxPartLoadRat;
lCoolCapFTCurve = this->CoolCapFTCurve;
lThermalEnergyCoolFTCurve = this->ThermalEnergyCoolFTCurve;
lThermalEnergyCoolFPLRCurve = this->ThermalEnergyCoolFPLRCurve;
lElecCoolFTCurve = this->ElecCoolFTCurve;
lElecCoolFPLRCurve = this->ElecCoolFPLRCurve;
lIsEnterCondensTemp = this->isEnterCondensTemp;
lIsWaterCooled = this->isWaterCooled;
lCHWLowLimitTemp = this->CHWLowLimitTemp;
lHeatElectricPower = this->HeatElectricPower;
lHeatThermalEnergyUseRate = this->HeatThermalEnergyUseRate;
lHeatPartLoadRatio = this->HeatPartLoadRatio;
// initialize entering conditions
lChillReturnTemp = DataLoopNode::Node(lChillReturnNodeNum).Temp;
lChillWaterMassFlowRate = DataLoopNode::Node(lChillReturnNodeNum).MassFlowRate;
lCondReturnTemp = DataLoopNode::Node(lCondReturnNodeNum).Temp;
{
auto const SELECT_CASE_var(DataPlant::PlantLoop(this->CWLoopNum).LoopDemandCalcScheme);
if (SELECT_CASE_var == DataPlant::SingleSetPoint) {
ChillSupplySetPointTemp = DataLoopNode::Node(lChillSupplyNodeNum).TempSetPoint;
} else if (SELECT_CASE_var == DataPlant::DualSetPointDeadBand) {
ChillSupplySetPointTemp = DataLoopNode::Node(lChillSupplyNodeNum).TempSetPointHi;
} else {
assert(false);
}
}
ChillDeltaTemp = std::abs(lChillReturnTemp - ChillSupplySetPointTemp);
lExhaustInTemp = DataLoopNode::Node(lExhaustAirInletNodeNum).Temp;
lExhaustInFlow = DataLoopNode::Node(lExhaustAirInletNodeNum).MassFlowRate;
lExhaustAirHumRat = DataLoopNode::Node(lExhaustAirInletNodeNum).HumRat;
Cp_CW = FluidProperties::GetSpecificHeatGlycol(
DataPlant::PlantLoop(this->CWLoopNum).FluidName, lChillReturnTemp, DataPlant::PlantLoop(this->CWLoopNum).FluidIndex, RoutineName);
if (this->CDLoopNum > 0) {
Cp_CD = FluidProperties::GetSpecificHeatGlycol(
DataPlant::PlantLoop(this->CDLoopNum).FluidName, lChillReturnTemp, DataPlant::PlantLoop(this->CDLoopNum).FluidIndex, RoutineName);
}
// If no loop demand or Absorber OFF, return
// will need to modify when absorber can act as a boiler
if (MyLoad >= 0 || !((this->InHeatingMode) || (this->InCoolingMode))) {
// set node temperatures
lChillSupplyTemp = lChillReturnTemp;
lCondSupplyTemp = lCondReturnTemp;
lCondWaterMassFlowRate = 0.0;
if (lIsWaterCooled) {
PlantUtilities::SetComponentFlowRate(lCondWaterMassFlowRate,
this->CondReturnNodeNum,
this->CondSupplyNodeNum,
this->CDLoopNum,
this->CDLoopSideNum,
this->CDBranchNum,
this->CDCompNum);
}
lFractionOfPeriodRunning = min(1.0, max(lHeatPartLoadRatio, lCoolPartLoadRatio) / lMinPartLoadRat);
} else {
// if water cooled use the input node otherwise just use outside air temperature
if (lIsWaterCooled) {
// most manufacturers rate have tables of entering condenser water temperature
// but a few use leaving condenser water temperature so we have a flag
// when leaving is used it uses the previous iterations value of the value
lCondReturnTemp = DataLoopNode::Node(lCondReturnNodeNum).Temp;
if (lIsEnterCondensTemp) {
calcCondTemp = lCondReturnTemp;
} else {
if (this->oldCondSupplyTemp == 0) {
this->oldCondSupplyTemp = lCondReturnTemp + 8.0; // if not previously estimated assume 8C greater than return
}
calcCondTemp = this->oldCondSupplyTemp;
}
// Set mass flow rates
lCondWaterMassFlowRate = this->DesCondMassFlowRate;
PlantUtilities::SetComponentFlowRate(lCondWaterMassFlowRate,
this->CondReturnNodeNum,
this->CondSupplyNodeNum,
this->CDLoopNum,
this->CDLoopSideNum,
this->CDBranchNum,
this->CDCompNum);
} else {
// air cooled
DataLoopNode::Node(lCondReturnNodeNum).Temp = DataLoopNode::Node(lCondReturnNodeNum).OutAirDryBulb;
calcCondTemp = DataLoopNode::Node(lCondReturnNodeNum).OutAirDryBulb;
lCondReturnTemp = DataLoopNode::Node(lCondReturnNodeNum).Temp;
lCondWaterMassFlowRate = 0.0;
if (this->CDLoopNum > 0) {
PlantUtilities::SetComponentFlowRate(lCondWaterMassFlowRate,
this->CondReturnNodeNum,
this->CondSupplyNodeNum,
this->CDLoopNum,
this->CDLoopSideNum,
this->CDBranchNum,
this->CDCompNum);
}
}
// Determine available cooling capacity using the setpoint temperature
lAvailableCoolingCapacity = lNomCoolingCap * CurveManager::CurveValue(lCoolCapFTCurve, ChillSupplySetPointTemp, calcCondTemp);
// Calculate current load for cooling
MyLoad = sign(max(std::abs(MyLoad), lAvailableCoolingCapacity * lMinPartLoadRat), MyLoad);
MyLoad = sign(min(std::abs(MyLoad), lAvailableCoolingCapacity * lMaxPartLoadRat), MyLoad);
// Determine the following variables depending on if the flow has been set in
// the nodes (flowlock=1 to 2) or if the amount of load is still be determined (flowlock=0)
// chilled water flow,
// cooling load taken by the chiller, and
// supply temperature
lChillWaterMassflowratemax = this->DesEvapMassFlowRate;
LoopNum = this->CWLoopNum;
LoopSideNum = this->CWLoopSideNum;
{
auto const SELECT_CASE_var(DataPlant::PlantLoop(LoopNum).LoopSide(LoopSideNum).FlowLock);
if (SELECT_CASE_var == 0) { // mass flow rates may be changed by loop components
this->PossibleSubcooling = false;
lCoolingLoad = std::abs(MyLoad);
if (ChillDeltaTemp != 0.0) {
lChillWaterMassFlowRate = std::abs(lCoolingLoad / (Cp_CW * ChillDeltaTemp));
if (lChillWaterMassFlowRate - lChillWaterMassflowratemax > DataBranchAirLoopPlant::MassFlowTolerance)
this->PossibleSubcooling = true;
PlantUtilities::SetComponentFlowRate(lChillWaterMassFlowRate,
this->ChillReturnNodeNum,
this->ChillSupplyNodeNum,
this->CWLoopNum,
this->CWLoopSideNum,
this->CWBranchNum,
this->CWCompNum);
} else {
lChillWaterMassFlowRate = 0.0;
ShowRecurringWarningErrorAtEnd("ExhaustAbsorberChillerModel:Cooling\"" + this->Name +
"\", DeltaTemp = 0 in mass flow calculation",
this->DeltaTempCoolErrCount);
}
lChillSupplyTemp = ChillSupplySetPointTemp;
} else if (SELECT_CASE_var == 1) { // mass flow rates may not be changed by loop components
lChillWaterMassFlowRate = DataLoopNode::Node(lChillReturnNodeNum).MassFlowRate;
if (this->PossibleSubcooling) {
lCoolingLoad = std::abs(MyLoad);
ChillDeltaTemp = lCoolingLoad / lChillWaterMassFlowRate / Cp_CW;
lChillSupplyTemp = DataLoopNode::Node(lChillReturnNodeNum).Temp - ChillDeltaTemp;
} else {
ChillDeltaTemp = DataLoopNode::Node(lChillReturnNodeNum).Temp - ChillSupplySetPointTemp;
lCoolingLoad = std::abs(lChillWaterMassFlowRate * Cp_CW * ChillDeltaTemp);
lChillSupplyTemp = ChillSupplySetPointTemp;
}
// Check that the Chiller Supply outlet temp honors both plant loop temp low limit and also the chiller low limit
if (lChillSupplyTemp < lCHWLowLimitTemp) {
if ((DataLoopNode::Node(lChillReturnNodeNum).Temp - lCHWLowLimitTemp) > DataPlant::DeltaTempTol) {
lChillSupplyTemp = lCHWLowLimitTemp;
ChillDeltaTemp = DataLoopNode::Node(lChillReturnNodeNum).Temp - lChillSupplyTemp;
lCoolingLoad = lChillWaterMassFlowRate * Cp_CW * ChillDeltaTemp;
} else {
lChillSupplyTemp = DataLoopNode::Node(lChillReturnNodeNum).Temp;
ChillDeltaTemp = DataLoopNode::Node(lChillReturnNodeNum).Temp - lChillSupplyTemp;
lCoolingLoad = lChillWaterMassFlowRate * Cp_CW * ChillDeltaTemp;
}
}
if (lChillSupplyTemp < DataLoopNode::Node(lChillSupplyNodeNum).TempMin) {
if ((DataLoopNode::Node(lChillReturnNodeNum).Temp - DataLoopNode::Node(lChillSupplyNodeNum).TempMin) >
DataPlant::DeltaTempTol) {
lChillSupplyTemp = DataLoopNode::Node(lChillSupplyNodeNum).TempMin;
ChillDeltaTemp = DataLoopNode::Node(lChillReturnNodeNum).Temp - lChillSupplyTemp;
lCoolingLoad = lChillWaterMassFlowRate * Cp_CW * ChillDeltaTemp;
} else {
lChillSupplyTemp = DataLoopNode::Node(lChillReturnNodeNum).Temp;
ChillDeltaTemp = DataLoopNode::Node(lChillReturnNodeNum).Temp - lChillSupplyTemp;
lCoolingLoad = lChillWaterMassFlowRate * Cp_CW * ChillDeltaTemp;
}
}
// Checks Coolingload on the basis of the machine limits.
if (lCoolingLoad > std::abs(MyLoad)) {
if (lChillWaterMassFlowRate > DataBranchAirLoopPlant::MassFlowTolerance) {
lCoolingLoad = std::abs(MyLoad);
ChillDeltaTemp = lCoolingLoad / lChillWaterMassFlowRate / Cp_CW;
lChillSupplyTemp = DataLoopNode::Node(lChillReturnNodeNum).Temp - ChillDeltaTemp;
} else {
lChillSupplyTemp = DataLoopNode::Node(lChillReturnNodeNum).Temp;
ChillDeltaTemp = DataLoopNode::Node(lChillReturnNodeNum).Temp - lChillSupplyTemp;
lCoolingLoad = lChillWaterMassFlowRate * Cp_CW * ChillDeltaTemp;
}
}
}
}
// Calculate operating part load ratio for cooling
PartLoadRat = min(std::abs(MyLoad) / lAvailableCoolingCapacity, lMaxPartLoadRat);
PartLoadRat = max(lMinPartLoadRat, PartLoadRat);
if (lAvailableCoolingCapacity > 0.0) {
if (std::abs(MyLoad) / lAvailableCoolingCapacity < lMinPartLoadRat) {
lCoolPartLoadRatio = MyLoad / lAvailableCoolingCapacity;
} else {
lCoolPartLoadRatio = PartLoadRat;
}
} else { // Else if AvailableCoolingCapacity < 0.0
lCoolPartLoadRatio = 0.0;
}
// calculate the fraction of the time period that the chiller would be running
// use maximum from heating and cooling sides
if (lCoolPartLoadRatio < lMinPartLoadRat || lHeatPartLoadRatio < lMinPartLoadRat) {
lFractionOfPeriodRunning = min(1.0, max(lHeatPartLoadRatio, lCoolPartLoadRatio) / lMinPartLoadRat);
} else {
lFractionOfPeriodRunning = 1.0;
}
// Calculate thermal energy consumption for cooling
// Thermal Energy used for cooling availCap * TeFIR * TeFIR-FT * TeFIR-FPLR
lCoolThermalEnergyUseRate = lAvailableCoolingCapacity * lThermalEnergyCoolRatio *
CurveManager::CurveValue(lThermalEnergyCoolFTCurve, lChillSupplyTemp, calcCondTemp) *
CurveManager::CurveValue(lThermalEnergyCoolFPLRCurve, lCoolPartLoadRatio) * lFractionOfPeriodRunning;
// Calculate electric parasitics used
// based on nominal capacity, not available capacity,
// electric used for cooling nomCap * %OP * EIR * EIR-FT * EIR-FPLR
lCoolElectricPower = lNomCoolingCap * lElecCoolRatio * lFractionOfPeriodRunning *
CurveManager::CurveValue(lElecCoolFTCurve, lChillSupplyTemp, calcCondTemp) *
CurveManager::CurveValue(lElecCoolFPLRCurve, lCoolPartLoadRatio);
// determine conderser load which is cooling load plus the
// ThermalEnergy used for cooling plus
// the electricity used
lTowerLoad = lCoolingLoad + lCoolThermalEnergyUseRate / lThermalEnergyHeatRatio + lCoolElectricPower;
lExhaustInTemp = DataLoopNode::Node(lExhaustAirInletNodeNum).Temp;
lExhaustInFlow = DataLoopNode::Node(lExhaustAirInletNodeNum).MassFlowRate;
CpAir = Psychrometrics::PsyCpAirFnW(lExhaustAirHumRat);
lExhHeatRecPotentialCool = lExhaustInFlow * CpAir * (lExhaustInTemp - AbsLeavingTemp);
// If Microturbine Exhaust temperature and flow rate is not sufficient to run the chiller, then chiller will not run
// lCoolThermalEnergyUseRate , lTowerLoad and lCoolElectricPower will be set to 0.0
if (lExhHeatRecPotentialCool < lCoolThermalEnergyUseRate) {
if (this->ExhTempLTAbsLeavingTempIndex == 0) {
ShowWarningError("ChillerHeater:Absorption:DoubleEffect \"" + this->Name + "\"");
ShowContinueError(
"...Exhaust temperature and flow input from Micro Turbine is not sufficient during cooling to run the chiller ");
ShowContinueError("...Value of Exhaust air inlet temp =" + General::TrimSigDigits(lExhaustInTemp, 4) + " C.");
ShowContinueError("... and Exhaust air flow rate of " + General::TrimSigDigits(lExhaustInFlow, 2) + " kg/s.");
ShowContinueError("...Value of minimum absorber leaving temp =" + General::TrimSigDigits(AbsLeavingTemp, 4) + " C.");
ShowContinueError("...Either increase the Exhaust temperature (min required = 350 C ) or flow or both of Micro Turbine to meet "
"the min available potential criteria.");
ShowContinueErrorTimeStamp("... Simulation will continue.");
}
ShowRecurringWarningErrorAtEnd(
"ChillerHeater:Absorption:DoubleEffect \"" + this->Name +
"\": Exhaust temperature from Micro Turbine is not sufficient to run the chiller during cooling warning continues...",
this->ExhTempLTAbsLeavingTempIndex,
lExhaustInTemp,
AbsLeavingTemp);
// If exhaust is not available, it means the avilable thermal energy is 0.0 and Chiller is not available
lCoolThermalEnergyUseRate = 0.0;
lTowerLoad = 0.0;
lCoolElectricPower = 0.0;
lChillSupplyTemp = lChillReturnTemp;
lCondSupplyTemp = lCondReturnTemp;
lFractionOfPeriodRunning = min(1.0, max(lHeatPartLoadRatio, lCoolPartLoadRatio) / lMinPartLoadRat);
}
// for water cooled condenser make sure enough flow rate
// for air cooled condenser just set supply to return temperature
if (lIsWaterCooled) {
if (lCondWaterMassFlowRate > DataBranchAirLoopPlant::MassFlowTolerance) {
lCondSupplyTemp = lCondReturnTemp + lTowerLoad / (lCondWaterMassFlowRate * Cp_CD);
} else {
ShowSevereError("CalcExhaustAbsorberChillerModel: Condenser flow = 0, for Exhaust Absorber Chiller=" + this->Name);
ShowContinueErrorTimeStamp("");
ShowFatalError("Program Terminates due to previous error condition.");
}
} else {
lCondSupplyTemp = lCondReturnTemp; // if air cooled condenser just set supply and return to same temperature
}
// save the condenser water supply temperature for next iteration if that is used in lookup
// and if capacity is large enough error than report problem
this->oldCondSupplyTemp = lCondSupplyTemp;
if (!lIsEnterCondensTemp) {
// calculate the fraction of the estimated error between the capacity based on the previous
// iteration's value of condenser supply temperature and the actual calculated condenser supply
// temperature. If this becomes too common then may need to iterate a solution instead of
// relying on previous iteration method.
revisedEstimateAvailCap = lNomCoolingCap * CurveManager::CurveValue(lCoolCapFTCurve, ChillSupplySetPointTemp, lCondSupplyTemp);
if (revisedEstimateAvailCap > 0.0) {
errorAvailCap = std::abs((revisedEstimateAvailCap - lAvailableCoolingCapacity) / revisedEstimateAvailCap);
if (errorAvailCap > 0.05) { // if more than 5% error in estimate
ShowRecurringWarningErrorAtEnd("ExhaustAbsorberChillerModel:\"" + this->Name + "\", poor Condenser Supply Estimate",
this->CondErrCount,
errorAvailCap,
errorAvailCap);
}
}
}
} // IF(MyLoad>=0 .OR. .NOT. RunFlag)
// Write into the Report Variables except for nodes
this->CoolingLoad = lCoolingLoad;
this->TowerLoad = lTowerLoad;
this->CoolThermalEnergyUseRate = lCoolThermalEnergyUseRate;
this->CoolElectricPower = lCoolElectricPower;
this->CondReturnTemp = lCondReturnTemp;
this->ChillReturnTemp = lChillReturnTemp;
this->CondSupplyTemp = lCondSupplyTemp;
this->ChillSupplyTemp = lChillSupplyTemp;
this->ChillWaterFlowRate = lChillWaterMassFlowRate;
this->CondWaterFlowRate = lCondWaterMassFlowRate;
this->CoolPartLoadRatio = lCoolPartLoadRatio;
this->CoolingCapacity = lAvailableCoolingCapacity;
this->FractionOfPeriodRunning = lFractionOfPeriodRunning;
this->ExhaustInTemp = lExhaustInTemp;
this->ExhaustInFlow = lExhaustInFlow;
this->ExhHeatRecPotentialCool = lExhHeatRecPotentialCool;
// write the combined heating and cooling ThermalEnergy used and electric used
this->ThermalEnergyUseRate = lCoolThermalEnergyUseRate + lHeatThermalEnergyUseRate;
this->ElectricPower = lCoolElectricPower + lHeatElectricPower;
}
void ExhaustAbsorberSpecs::calcHeater(Real64 &MyLoad, bool RunFlag)
{
// SUBROUTINE INFORMATION:
// AUTHOR Jason Glazer and Michael J. Witte
// DATE WRITTEN March 2001
// MODIFIED Mahabir Bhandari, ORNL, Aug 2011, modified to accomodate exhaust fired double effect absorption chiller
// RE-ENGINEERED na
// PURPOSE OF THIS SUBROUTINE:
// Simulate a Exhaust fired (Exhaust consuming) absorption chiller using
// curves and inputs similar to DOE-2.1e
// METHODOLOGY EMPLOYED:
// Curve fit of performance data
// REFERENCES:
// 1. DOE-2.1e Supplement and source code
// 2. CoolTools GasMod work
// Locals
// SUBROUTINE ARGUMENT DEFINITIONS:
// FlowLock = 0 if mass flow rates may be changed by loop components
// FlowLock = 1 if mass flow rates may not be changed by loop components
// FlowLock = 2 if overloaded and mass flow rates has changed to a small amount and Tout drops
// below Setpoint
// SUBROUTINE PARAMETER DEFINITIONS:
Real64 const AbsLeavingTemp(176.667); // C - Minimum temperature leaving the Chiller absorber (350 F)
static std::string const RoutineName("CalcExhaustAbsorberHeaterModel");
// SUBROUTINE LOCAL VARIABLE DECLARATIONS:
// Local copies of ExhaustAbsorberSpecs Type
// all variables that are local copies of data structure
// variables are prefaced with an "l" for local.
Real64 lNomCoolingCap; // W - design nominal capacity of Absorber
Real64 lNomHeatCoolRatio; // ratio of heating to cooling capacity
Real64 lThermalEnergyHeatRatio; // ratio of ThermalEnergy input to heating output
Real64 lElecHeatRatio; // ratio of electricity input to heating output
int lHeatReturnNodeNum; // absorber hot water inlet node number, water side
int lHeatSupplyNodeNum; // absorber hot water outlet node number, water side
Real64 lMinPartLoadRat; // min allowed operating frac full load
Real64 lMaxPartLoadRat; // max allowed operating frac full load
int lHeatCapFCoolCurve; // Heating Capacity Function of Cooling Capacity Curve
int lThermalEnergyHeatFHPLRCurve; // ThermalEnergy Input to heat output ratio during heating only function
// Local copies of ExhaustAbsorberReportVars Type
Real64 lHeatingLoad(0.0); // heating load on the chiller
// Real64 lHeatingEnergy( 0.0 ); // heating energy
// Real64 lThermalEnergyUseRate( 0.0 ); // instantaneous use of Thermal Energy for period
// Real64 lThermalEnergy( 0.0 ); // variable to track total Thermal Energy used for a period (reference only)
Real64 lCoolThermalEnergyUseRate(0.0); // instantaneous use of thermal energy for period for cooling
Real64 lHeatThermalEnergyUseRate(0.0); // instantaneous use of thermal energy for period for heating
Real64 lCoolElectricPower(0.0); // parasitic electric power used for cooling
Real64 lHeatElectricPower(0.0); // parasitic electric power used for heating
Real64 lHotWaterReturnTemp(0.0); // reporting: hot water return (inlet) temperature
Real64 lHotWaterSupplyTemp(0.0); // reporting: hot water supply (outlet) temperature
Real64 lHotWaterMassFlowRate(0.0); // reporting: hot water mass flow rate
Real64 lCoolPartLoadRatio(0.0); // operating part load ratio (load/capacity for cooling)
Real64 lHeatPartLoadRatio(0.0); // operating part load ratio (load/capacity for heating)
Real64 lAvailableHeatingCapacity(0.0); // current heating capacity
Real64 lFractionOfPeriodRunning(0.0);
Real64 lExhaustInTemp(0.0); // Exhaust inlet temperature
Real64 lExhaustInFlow(0.0); // Exhaust inlet flow rate
Real64 lExhHeatRecPotentialHeat(0.0); // Exhaust heat recovery potential
Real64 lExhaustAirHumRat(0.0);
// other local variables
Real64 HeatDeltaTemp(0.0); // hot water temperature difference
Real64 HeatSupplySetPointTemp(0.0);
int LoopNum;
int LoopSideNum;
Real64 Cp_HW; // local fluid specific heat for hot water
Real64 CpAir;
int lExhaustAirInletNodeNum; // Combustion Air Inlet Node number
// set node values to data structure values for nodes
lHeatReturnNodeNum = this->HeatReturnNodeNum;
lHeatSupplyNodeNum = this->HeatSupplyNodeNum;
lExhaustAirInletNodeNum = this->ExhaustAirInletNodeNum;
// set local copies of data from rest of input structure
lNomCoolingCap = this->NomCoolingCap;
lNomHeatCoolRatio = this->NomHeatCoolRatio;
lThermalEnergyHeatRatio = this->ThermalEnergyHeatRatio;
lElecHeatRatio = this->ElecHeatRatio;
lMinPartLoadRat = this->MinPartLoadRat;
lMaxPartLoadRat = this->MaxPartLoadRat;
lHeatCapFCoolCurve = this->HeatCapFCoolCurve;
lThermalEnergyHeatFHPLRCurve = this->ThermalEnergyHeatFHPLRCurve;
LoopNum = this->HWLoopNum;
LoopSideNum = this->HWLoopSideNum;
Cp_HW = FluidProperties::GetSpecificHeatGlycol(
DataPlant::PlantLoop(LoopNum).FluidName, lHotWaterReturnTemp, DataPlant::PlantLoop(LoopNum).FluidIndex, RoutineName);
lCoolElectricPower = this->CoolElectricPower;
lCoolThermalEnergyUseRate = this->CoolThermalEnergyUseRate;
lCoolPartLoadRatio = this->CoolPartLoadRatio;
// initialize entering conditions
lHotWaterReturnTemp = DataLoopNode::Node(lHeatReturnNodeNum).Temp;
lHotWaterMassFlowRate = DataLoopNode::Node(lHeatReturnNodeNum).MassFlowRate;
{
auto const SELECT_CASE_var(DataPlant::PlantLoop(LoopNum).LoopDemandCalcScheme);
if (SELECT_CASE_var == DataPlant::SingleSetPoint) {
HeatSupplySetPointTemp = DataLoopNode::Node(lHeatSupplyNodeNum).TempSetPoint;
} else if (SELECT_CASE_var == DataPlant::DualSetPointDeadBand) {
HeatSupplySetPointTemp = DataLoopNode::Node(lHeatSupplyNodeNum).TempSetPointLo;
} else {
assert(false);
}
}
HeatDeltaTemp = std::abs(lHotWaterReturnTemp - HeatSupplySetPointTemp);
// If no loop demand or Absorber OFF, return
// will need to modify when absorber can act as a boiler
if (MyLoad <= 0 || !RunFlag) {
// set node temperatures
lHotWaterSupplyTemp = lHotWaterReturnTemp;
lFractionOfPeriodRunning = min(1.0, max(lHeatPartLoadRatio, lCoolPartLoadRatio) / lMinPartLoadRat);
} else {
// Determine available heating capacity using the current cooling load
lAvailableHeatingCapacity = this->NomHeatCoolRatio * this->NomCoolingCap *
CurveManager::CurveValue(lHeatCapFCoolCurve, (this->CoolingLoad / this->NomCoolingCap));
// Calculate current load for heating
MyLoad = sign(max(std::abs(MyLoad), this->HeatingCapacity * lMinPartLoadRat), MyLoad);
MyLoad = sign(min(std::abs(MyLoad), this->HeatingCapacity * lMaxPartLoadRat), MyLoad);
// Determine the following variables depending on if the flow has been set in
// the nodes (flowlock=1 to 2) or if the amount of load is still be determined (flowlock=0)
// chilled water flow,
// cooling load taken by the chiller, and
// supply temperature
{
auto const SELECT_CASE_var(DataPlant::PlantLoop(LoopNum).LoopSide(LoopSideNum).FlowLock);
if (SELECT_CASE_var == 0) { // mass flow rates may be changed by loop components
lHeatingLoad = std::abs(MyLoad);
if (HeatDeltaTemp != 0) {
lHotWaterMassFlowRate = std::abs(lHeatingLoad / (Cp_HW * HeatDeltaTemp));
PlantUtilities::SetComponentFlowRate(lHotWaterMassFlowRate,
this->HeatReturnNodeNum,
this->HeatSupplyNodeNum,
this->HWLoopNum,
this->HWLoopSideNum,
this->HWBranchNum,
this->HWCompNum);
} else {
lHotWaterMassFlowRate = 0.0;
ShowRecurringWarningErrorAtEnd("ExhaustAbsorberChillerModel:Heating\"" + this->Name +
"\", DeltaTemp = 0 in mass flow calculation",
this->DeltaTempHeatErrCount);
}
lHotWaterSupplyTemp = HeatSupplySetPointTemp;
} else if (SELECT_CASE_var == 1) { // mass flow rates may not be changed by loop components
lHotWaterSupplyTemp = HeatSupplySetPointTemp;
lHeatingLoad = std::abs(lHotWaterMassFlowRate * Cp_HW * HeatDeltaTemp);
// DSU this "2" is not a real state for flowLock
} else if (SELECT_CASE_var ==
2) { // chiller is underloaded and mass flow rates has changed to a small amount and Tout drops below Setpoint
// MJW 07MAR01 Borrow logic from steam absorption module
// The following conditional statements are made to avoid extremely small EvapMdot
// & unreasonable EvapOutletTemp due to overloading.
// Avoid 'divide by zero' due to small EvapMdot
if (lHotWaterMassFlowRate < DataBranchAirLoopPlant::MassFlowTolerance) {
HeatDeltaTemp = 0.0;
} else {
HeatDeltaTemp = std::abs(MyLoad) / (Cp_HW * lHotWaterMassFlowRate);
}
lHotWaterSupplyTemp = lHotWaterReturnTemp + HeatDeltaTemp;
lHeatingLoad = std::abs(lHotWaterMassFlowRate * Cp_HW * HeatDeltaTemp);
}
}
// Calculate operating part load ratio for cooling
lHeatPartLoadRatio = lHeatingLoad / lAvailableHeatingCapacity;
// Calculate ThermalEnergy consumption for heating
// ThermalEnergy used for heating availCap * HIR * HIR-FT * HIR-FPLR
lHeatThermalEnergyUseRate =
lAvailableHeatingCapacity * lThermalEnergyHeatRatio * CurveManager::CurveValue(lThermalEnergyHeatFHPLRCurve, lHeatPartLoadRatio);
// calculate the fraction of the time period that the chiller would be running
// use maximum from heating and cooling sides
lFractionOfPeriodRunning = min(1.0, max(lHeatPartLoadRatio, lCoolPartLoadRatio) / lMinPartLoadRat);
// Calculate electric parasitics used
// for heating based on nominal capacity not available capacity
lHeatElectricPower = lNomCoolingCap * lNomHeatCoolRatio * lElecHeatRatio * lFractionOfPeriodRunning;
// Coodinate electric parasitics for heating and cooling to avoid double counting
// Total electric is the max of heating electric or cooling electric
// If heating electric is greater, leave cooling electric and subtract if off of heating elec
// If cooling electric is greater, set heating electric to zero
lExhaustInTemp = DataLoopNode::Node(lExhaustAirInletNodeNum).Temp;
lExhaustInFlow = DataLoopNode::Node(lExhaustAirInletNodeNum).MassFlowRate;
CpAir = Psychrometrics::PsyCpAirFnW(lExhaustAirHumRat);
lExhHeatRecPotentialHeat = lExhaustInFlow * CpAir * (lExhaustInTemp - AbsLeavingTemp);
if (lExhHeatRecPotentialHeat < lHeatThermalEnergyUseRate) {
if (this->ExhTempLTAbsLeavingHeatingTempIndex == 0) {
ShowWarningError("ChillerHeater:Absorption:DoubleEffect \"" + this->Name + "\"");
ShowContinueError(
"...Exhaust temperature and flow input from Micro Turbine is not sufficient to run the chiller during heating .");
ShowContinueError("...Value of Exhaust air inlet temp =" + General::TrimSigDigits(lExhaustInTemp, 4) + " C.");
ShowContinueError("... and Exhaust air flow rate of " + General::TrimSigDigits(lExhaustInFlow, 2) + " kg/s.");
ShowContinueError("...Value of minimum absorber leaving temp =" + General::TrimSigDigits(AbsLeavingTemp, 4) + " C.");
ShowContinueError("...Either increase the Exhaust temperature (min required = 350 C ) or flow or both of Micro Turbine to meet "
"the min available potential criteria.");
ShowContinueErrorTimeStamp("... Simulation will continue.");
}
ShowRecurringWarningErrorAtEnd(
"ChillerHeater:Absorption:DoubleEffect \"" + this->Name +
"\": Exhaust temperature from Micro Turbine is not sufficient to run the chiller during heating warning continues...",
this->ExhTempLTAbsLeavingHeatingTempIndex,
lExhaustInTemp,
AbsLeavingTemp);
// If exhaust is not available, it means the avilable thermal energy is 0.0 and Chiller is not available
lHeatThermalEnergyUseRate = 0.0;
lHeatElectricPower = 0.0;
lHotWaterSupplyTemp = lHotWaterReturnTemp;
lFractionOfPeriodRunning = min(1.0, max(lHeatPartLoadRatio, lCoolPartLoadRatio) / lMinPartLoadRat);
}
if (lHeatElectricPower <= lCoolElectricPower) {
lHeatElectricPower = 0.0;
} else {
lHeatElectricPower -= lCoolElectricPower;
}
} // IF(MyLoad==0 .OR. .NOT. RunFlag)
// Write into the Report Variables except for nodes
this->HeatingLoad = lHeatingLoad;
this->HeatThermalEnergyUseRate = lHeatThermalEnergyUseRate;
this->HeatElectricPower = lHeatElectricPower;
this->HotWaterReturnTemp = lHotWaterReturnTemp;
this->HotWaterSupplyTemp = lHotWaterSupplyTemp;
this->HotWaterFlowRate = lHotWaterMassFlowRate;
this->HeatPartLoadRatio = lHeatPartLoadRatio;
this->HeatingCapacity = lAvailableHeatingCapacity;
this->FractionOfPeriodRunning = lFractionOfPeriodRunning;
// write the combined heating and cooling ThermalEnergy used and electric used
this->ThermalEnergyUseRate = lCoolThermalEnergyUseRate + lHeatThermalEnergyUseRate;
this->ElectricPower = lCoolElectricPower + lHeatElectricPower;
this->ExhaustInTemp = lExhaustInTemp;
this->ExhaustInFlow = lExhaustInFlow;
this->ExhHeatRecPotentialHeat = lExhHeatRecPotentialHeat;
}
void ExhaustAbsorberSpecs::updateCoolRecords(Real64 MyLoad, bool RunFlag)
{
// SUBROUTINE INFORMATION:
// AUTHOR Jason Glazer
// DATE WRITTEN March 2001
// PURPOSE OF THIS SUBROUTINE:
// reporting
// SUBROUTINE LOCAL VARIABLE DECLARATIONS:
int lChillReturnNodeNum; // Node number on the inlet side of the plant
int lChillSupplyNodeNum; // Node number on the outlet side of the plant
int lCondReturnNodeNum; // Node number on the inlet side of the condenser
int lCondSupplyNodeNum; // Node number on the outlet side of the condenser
int lExhaustAirInletNodeNum; // Node number on the inlet side of the plant
Real64 RptConstant;
lChillReturnNodeNum = this->ChillReturnNodeNum;
lChillSupplyNodeNum = this->ChillSupplyNodeNum;
lCondReturnNodeNum = this->CondReturnNodeNum;
lCondSupplyNodeNum = this->CondSupplyNodeNum;
lExhaustAirInletNodeNum = this->ExhaustAirInletNodeNum;
if (MyLoad == 0 || !RunFlag) {
DataLoopNode::Node(lChillSupplyNodeNum).Temp = DataLoopNode::Node(lChillReturnNodeNum).Temp;
if (this->isWaterCooled) {
DataLoopNode::Node(lCondSupplyNodeNum).Temp = DataLoopNode::Node(lCondReturnNodeNum).Temp;
}
DataLoopNode::Node(lExhaustAirInletNodeNum).Temp = DataLoopNode::Node(lExhaustAirInletNodeNum).Temp;
DataLoopNode::Node(lExhaustAirInletNodeNum).MassFlowRate = this->ExhaustInFlow;
} else {
DataLoopNode::Node(lChillSupplyNodeNum).Temp = this->ChillSupplyTemp;
if (this->isWaterCooled) {
DataLoopNode::Node(lCondSupplyNodeNum).Temp = this->CondSupplyTemp;
}
DataLoopNode::Node(lExhaustAirInletNodeNum).Temp = this->ExhaustInTemp;
DataLoopNode::Node(lExhaustAirInletNodeNum).MassFlowRate = this->ExhaustInFlow;
}
// convert power to energy and instantaneous use to use over the time step
RptConstant = DataHVACGlobals::TimeStepSys * DataGlobals::SecInHour;
this->CoolingEnergy = this->CoolingLoad * RptConstant;
this->TowerEnergy = this->TowerLoad * RptConstant;
this->ThermalEnergy = this->ThermalEnergyUseRate * RptConstant;
this->CoolThermalEnergy = this->CoolThermalEnergyUseRate * RptConstant;
this->ElectricEnergy = this->ElectricPower * RptConstant;
this->CoolElectricEnergy = this->CoolElectricPower * RptConstant;
if (this->CoolThermalEnergyUseRate != 0.0) {
this->ThermalEnergyCOP = this->CoolingLoad / this->CoolThermalEnergyUseRate;
} else {
this->ThermalEnergyCOP = 0.0;
}
}
void ExhaustAbsorberSpecs::updateHeatRecords(Real64 MyLoad, bool RunFlag)
{
// SUBROUTINE INFORMATION:
// AUTHOR Jason Glazer
// DATE WRITTEN March 2001
// PURPOSE OF THIS SUBROUTINE:
// reporting
// SUBROUTINE LOCAL VARIABLE DECLARATIONS:
int lHeatReturnNodeNum; // absorber steam inlet node number, water side
int lHeatSupplyNodeNum; // absorber steam outlet node number, water side
Real64 RptConstant;
lHeatReturnNodeNum = this->HeatReturnNodeNum;
lHeatSupplyNodeNum = this->HeatSupplyNodeNum;
if (MyLoad == 0 || !RunFlag) {
DataLoopNode::Node(lHeatSupplyNodeNum).Temp = DataLoopNode::Node(lHeatReturnNodeNum).Temp;
} else {
DataLoopNode::Node(lHeatSupplyNodeNum).Temp = this->HotWaterSupplyTemp;
}
// convert power to energy and instantaneous use to use over the time step
RptConstant = DataHVACGlobals::TimeStepSys * DataGlobals::SecInHour;
this->HeatingEnergy = this->HeatingLoad * RptConstant;
this->ThermalEnergy = this->ThermalEnergyUseRate * RptConstant;
this->HeatThermalEnergy = this->HeatThermalEnergyUseRate * RptConstant;
this->ElectricEnergy = this->ElectricPower * RptConstant;
this->HeatElectricEnergy = this->HeatElectricPower * RptConstant;
}
void clear_state()
{
ExhaustAbsorber.deallocate();
Sim_GetInput = true;
}
} // namespace ChillerExhaustAbsorption
} // namespace EnergyPlus
| [
"ffeng@tamu.edu"
] | ffeng@tamu.edu |
b4ec4973a91c039ff99aee9c5c045c954dc0994f | 3dd41434dbf7f11f4ef99aa55c72607ac78dd3b2 | /server/server/src/im/db_proxy_server/business/AudioModel.cpp | c5ba404f2b8d0d77d57779c70857db51147b6b16 | [] | no_license | JCGit/ttchat | 963561885546702d9468282702004dcf032bb8c1 | e4bb2e631ac2cba4542674f406be74f144b11889 | refs/heads/master | 2020-03-09T04:49:39.966293 | 2018-07-20T10:51:31 | 2018-07-20T10:51:31 | 128,596,746 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 5,690 | cpp | /*================================================================
* Copyright (C) 2014 All rights reserved.
*
* ๆไปถๅ็งฐ๏ผAudioModel.cpp
* ๅ ๅปบ ่
๏ผZhang Yuanhao
* ้ฎ ็ฎฑ๏ผbluefoxah@gmail.com
* ๅๅปบๆฅๆ๏ผ2014ๅนด12ๆ15ๆฅ
* ๆ ่ฟฐ๏ผ
*
================================================================*/
#include "../DBPool.h"
#include "../HttpClient.h"
#include "AudioModel.h"
using namespace std;
//AudioModel
CAudioModel* CAudioModel::m_pInstance = NULL;
/**
* ๆ้ ๅฝๆฐ
*/
CAudioModel::CAudioModel()
{
}
/**
* ๆๆๅฝๆฐ
*/
CAudioModel::~CAudioModel()
{
}
/**
* ๅไพ
*
* @return ๅไพ็ๆ้
*/
CAudioModel* CAudioModel::getInstance()
{
if (!m_pInstance) {
m_pInstance = new CAudioModel();
}
return m_pInstance;
}
/**
* ่ฟๅช่ฏญ้ณๅญๅจ็urlๅฐๅ
*
* @param strFileSite ไธไผ ็url
*/
void CAudioModel::setUrl(string& strFileSite)
{
m_strFileSite = strFileSite;
if(m_strFileSite[m_strFileSite.length()] != '/')
{
m_strFileSite += "/";
}
}
/**
* ่ฏปๅ่ฏญ้ณๆถๆฏ
*
* @param nAudioId ่ฏญ้ณ็Id
* @param cMsg ่ฏญ้ณๆถๆฏ๏ผๅผ็จ
*
* @return bool ๆๅ่ฟๅtrue๏ผๅคฑ่ดฅ่ฟๅfalse
*/
bool CAudioModel::readAudios(list<IM::BaseDefine::MsgInfo>& lsMsg)
{
if(lsMsg.empty())
{
return true;
}
bool bRet = false;
auto const pDBConn = CDBManager::getInstance()->getdbconn("teamtalk_slave");
if (pDBConn)
{
for (auto it=lsMsg.begin(); it!=lsMsg.end(); )
{
IM::BaseDefine::MsgType nType = it->msg_type();
if((IM::BaseDefine::MSG_TYPE_GROUP_AUDIO == nType) || (IM::BaseDefine::MSG_TYPE_SINGLE_AUDIO == nType))
{
string strSql = "select * from IMAudio where id=" + it->msg_data();
CResultSet* pResultSet = pDBConn->ExecuteQuery(strSql.c_str());
if (pResultSet)
{
while (pResultSet->Next()) {
uint32_t nCostTime = pResultSet->GetInt("duration");
uint32_t nSize = pResultSet->GetInt("size");
string strPath = pResultSet->GetString("path");
readAudioContent(nCostTime, nSize, strPath, *it);
}
++it;
delete pResultSet;
}
else
{
log("no result for sql:%s", strSql.c_str());
it = lsMsg.erase(it);
}
}
else
{
++it;
}
}
bRet = true;
}
else
{
log("no connection for teamtalk_slave");
}
return bRet;
}
/**
* ๅญๅจ่ฏญ้ณๆถๆฏ
*
* @param nFromId ๅ้่
Id
* @param nToId ๆฅๆถ่
Id
* @param nCreateTime ๅ้ๆถ้ด
* @param pAudioData ๆๅ่ฏญ้ณๆถๆฏ็ๆ้
* @param nAudioLen ่ฏญ้ณๆถๆฏ็้ฟๅบฆ
*
* @return ๆๅ่ฟๅ่ฏญ้ณid๏ผๅคฑ่ดฅ่ฟๅ-1
*/
int CAudioModel::saveAudioInfo(uint32_t nFromId, uint32_t nToId, uint32_t nCreateTime, const char* pAudioData, uint32_t nAudioLen)
{
// parse audio data
uint32_t nCostTime = CByteStream::ReadUint32((uchar_t*)pAudioData);
uchar_t* pRealData = (uchar_t*)pAudioData + 4;
uint32_t nRealLen = nAudioLen - 4;
int nAudioId = -1;
CHttpClient httpClient;
string strPath = httpClient.UploadByteFile(m_strFileSite, pRealData, nRealLen);
if (!strPath.empty())
{
auto const pDBConn = CDBManager::getInstance()->getdbconn("teamtalk_master");
if (pDBConn)
{
uint32_t nStartPos = 0;
string strSql = "insert into IMAudio(`fromId`, `toId`, `path`, `size`, `duration`, `created`) "\
"values(?, ?, ?, ?, ?, ?)";
replace_mark(strSql, nFromId, nStartPos);
replace_mark(strSql, nToId, nStartPos);
replace_mark(strSql, strPath, nStartPos);
replace_mark(strSql, nRealLen, nStartPos);
replace_mark(strSql, nCostTime, nStartPos);
replace_mark(strSql, nCreateTime, nStartPos);
if (pDBConn->ExecuteUpdate(strSql.c_str()))
{
nAudioId = pDBConn->GetInsertId();
log("audioId=%d", nAudioId);
} else
{
log("sql failed: %s", strSql.c_str());
}
}
else
{
log("no db connection for teamtalk_master");
}
}
else
{
log("upload file failed");
}
return nAudioId;
}
/**
* ่ฏปๅ่ฏญ้ณ็ๅ
ทไฝๅ
ๅฎน
*
* @param nCostTime ่ฏญ้ณๆถ้ฟ
* @param nSize ่ฏญ้ณๅคงๅฐ
* @param strPath ่ฏญ้ณๅญๅจ็url
* @param cMsg msg็ปๆไฝ
*
* @return ๆๅ่ฟๅtrue๏ผๅคฑ่ดฅ่ฟๅfalse
*/
bool CAudioModel::readAudioContent(uint32_t nCostTime, uint32_t nSize, const string& strPath, IM::BaseDefine::MsgInfo& cMsg)
{
if (strPath.empty() || nCostTime == 0 || nSize == 0) {
return false;
}
// ๅ้
ๅ
ๅญ๏ผๅๅ
ฅ้ณ้ขๆถ้ฟ
AudioMsgInfo cAudioMsg;
uchar_t* pData = new uchar_t [4 + nSize];
cAudioMsg.data = pData;
CByteStream::WriteUint32(cAudioMsg.data, nCostTime);
cAudioMsg.data_len = 4;
cAudioMsg.fileSize = nSize;
// ่ทๅ้ณ้ขๆฐๆฎ๏ผๅๅ
ฅไธ้ขๅ้
็ๅ
ๅญ
CHttpClient httpClient;
if(!httpClient.DownloadByteFile(strPath, &cAudioMsg))
{
delete [] pData;
return false;
}
log("download_path=%s, data_len=%d", strPath.c_str(), cAudioMsg.data_len);
cMsg.set_msg_data((const char*)cAudioMsg.data, cAudioMsg.data_len);
delete [] pData;
return true;
}
| [
"1027718562@qq.com"
] | 1027718562@qq.com |
412e29c23e0939fc655b65b98dafd6a969ac41aa | f68a5f06ad64f31e09f7b86862e9437a389dd464 | /Src/Window/Blackman.cpp | 769f02f32f23c7c28347353daacc10b5e0df043e | [] | no_license | LiuPeiqi/DSP | 68ec54bcbb20add77d4ba94ff338e2cde492aac5 | 09d3efa1713d868c7595f7eff9a9a2a67e5f8095 | refs/heads/master | 2021-01-19T07:17:50.652006 | 2016-06-21T15:43:35 | 2016-06-21T15:43:35 | 61,643,803 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 317 | cpp | #include <cmath>
#include "WindowConstNumber.h"
double BlackmanItem(size_t n, size_t N)
{
double f = n / (N - 1);
return 0.42 - 0.5 * cos(M_2_PI * f) + 0.08 * cos(M_4_PI * f);
}
void Blackman(double *blackman, size_t N)
{
for (size_t i = 0; i < N; ++i) {
blackman[i] = BlackmanItem(i, N);
}
} | [
"liu_peiqi@163.com"
] | liu_peiqi@163.com |
ff4b323fa550e8e80ee150d8cab5eff75eaf8090 | bd836081502105e472df1d0a99881deed61ce048 | /marketlink/MKLrmdsRecordHandler.cpp | 7a79094ed070f321f6e2db050170512476431b86 | [] | no_license | mitkatch/BPE | 9f34064778c25cc8dcb8225ed9f2252a3d431fb3 | 27985cb5da5045b797e67ec8c2a93e0f50ee6c09 | refs/heads/master | 2020-03-30T22:18:51.194908 | 2018-10-05T02:48:32 | 2018-10-05T02:48:32 | 151,662,346 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,440 | cpp |
/************************************************************************
||
|| DATE: $Date:$
|| SOURCE: $Source:$
|| STATE: $State:$
|| ID: $Id:$
|| REVISION: $Revision:$
|| LOG: $Log:$
|| LOG:
************************************************************************/
// System includes
#include <string>
// Application includes
#include "MKLrmdsRecordHandler.hpp"
#include "DataGraph.hpp"
#include "DataCache.hpp"
// RFA includes
#include "TIBMsg/TibMsg.h"
// Namespace resolution
using namespace std;
using namespace rfa::sessionLayer;
using namespace rfa::common;
MKLrmdsRecordHandler::MKLrmdsRecordHandler(const ConfigMap &configMap) : rmdsRecordHandler(configMap)
{
}
MKLrmdsRecordHandler::~MKLrmdsRecordHandler()
{
}
void MKLrmdsRecordHandler::processStatus(const MarketDataItemEvent& event)
{
const string& service = event.getServiceName();
const string& item = event.getItemName();
string address = event.getServiceName() + "." + event.getItemName();
DataGraph* data = (DataGraph *)DataCache::getCache()->getData(address, Datum::GRAPH);
if ( data != NULL )
{
// Notify of change
data->updated();
}
Logger::getLogger()->log(Logger::TYPE_INFO, "MKL RMDS item status for service: %s, Item: %s [%s]",
service.c_str(), item.c_str(),
event.getStatus().getStatusText().c_str());
}
| [
"mikhail_tkatchenko@yahoo.com"
] | mikhail_tkatchenko@yahoo.com |
b3af205822e80b8955eed3a86dbd7ff82952de5e | d0e0745ca2c2fd1fd096114596cefa42498b6d59 | /vhodno_nivo/Veselin_Dechev_11a/Veselin_Dechev_4.cpp | 54f3ecda53e2b78ce13d37d1b544d59804031393 | [] | no_license | thebravoman/software_engineering_2014 | d7fde1b2a31c07bceb2b6f76f6c200379a69d04d | e63968236ff2d8ab5b4a31515223097dc8d1e486 | refs/heads/master | 2021-01-25T08:55:25.431767 | 2015-06-19T08:34:43 | 2015-06-19T08:34:43 | 24,090,881 | 5 | 0 | null | 2016-05-01T21:20:09 | 2014-09-16T08:05:57 | Ruby | UTF-8 | C++ | false | false | 383 | cpp | #include<iostream>
using namespace std;
int main(){
int x,y,first=0,second=1,next;
do{
cin>>x>>y;
}while(x>y && x<=0);
for (int a=0;a!=y+1;a++){
if (a<=1){
next=a;
}else{
next = first + second;
first = second;
second = next;
}
if(a>x-1){
cout<<next<<endl;
}
}
return 0;
}
| [
"ahhak123@gmail.com"
] | ahhak123@gmail.com |
755371f7155df1fe5940933b1e2b2f32a54d626a | 2c642ac5e22d15055ebf54936898a8f542e24f14 | /Example/Pods/Headers/Public/boost/boost/container/flat_map.hpp | 8e441b3d3439ee1422da0f7fa696fd2cfb772e6f | [
"Apache-2.0"
] | permissive | TheClimateCorporation/geofeatures-ios | 488d95084806f69fb6e42d7d0da73bb2f818f19e | cf6a5c4eb2918bb5f3dcd0898501d52d92de7b1f | refs/heads/master | 2020-04-15T05:34:06.491186 | 2015-08-14T20:28:31 | 2015-08-14T20:28:31 | 40,622,132 | 0 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 61 | hpp | ../../../../../boost/Pod/Classes/boost/container/flat_map.hpp | [
"tony@mobilegridinc.com"
] | tony@mobilegridinc.com |
32dabf2ee39da9d74c615b92c49120440752c85b | 36e453a9ec047e38b54690b7c3a50d00d1c042e6 | /src/RE/ExtraTextDisplayData.cpp | ed02b6be2da8dbc3c3928190126641bc87947262 | [
"MIT"
] | permissive | powerof3/CommonLibVR | 9200ca84d4866eaf18a92f23ef5dd375b5c69db8 | c84cd2c63ccba0cc88a212fe9cf86b5470b10a4f | refs/heads/master | 2023-07-12T04:56:36.970046 | 2021-08-21T18:08:34 | 2021-08-21T18:08:34 | 398,626,573 | 2 | 3 | null | null | null | null | UTF-8 | C++ | false | false | 2,256 | cpp | #include "RE/ExtraTextDisplayData.h"
#include "REL/Relocation.h"
namespace RE
{
ExtraTextDisplayData::ExtraTextDisplayData() :
BSExtraData(),
displayName(""),
displayNameText(nullptr),
ownerQuest(nullptr),
ownerInstance(DisplayDataType::kUninitialized),
temperFactor(1.0F),
customNameLength(0),
pad32(0),
pad34(0)
{
//REL::Offset<std::uintptr_t> vtbl = REL::ID(229625);
REL::Offset<std::uintptr_t> vtbl = 0x15A3E30;
((std::uintptr_t*)this)[0] = vtbl.GetAddress();
}
ExtraTextDisplayData::ExtraTextDisplayData(const char* a_name) :
BSExtraData(),
displayName(""),
displayNameText(nullptr),
ownerQuest(nullptr),
ownerInstance(DisplayDataType::kUninitialized),
temperFactor(1.0F),
customNameLength(0),
pad32(0),
pad34(0)
{
//REL::Offset<std::uintptr_t> vtbl = REL::ID(229625);
REL::Offset<std::uintptr_t> vtbl = 0x15A3E30;
((std::uintptr_t*)this)[0] = vtbl.GetAddress();
SetName(a_name);
}
ExtraTextDisplayData::ExtraTextDisplayData(TESBoundObject* a_baseObject, float a_temperFactor) :
BSExtraData(),
displayName(""),
displayNameText(nullptr),
ownerQuest(nullptr),
ownerInstance(DisplayDataType::kUninitialized),
temperFactor(1.0F),
customNameLength(0),
pad32(0),
pad34(0)
{
//REL::Offset<std::uintptr_t> vtbl = REL::ID(229625);
REL::Offset<std::uintptr_t> vtbl = 0x15A3E30;
((std::uintptr_t*)this)[0] = vtbl.GetAddress();
GetDisplayName(a_baseObject, a_temperFactor);
}
ExtraDataType ExtraTextDisplayData::GetType() const
{
return ExtraDataType::kTextDisplayData;
}
const char* ExtraTextDisplayData::GetDisplayName(TESBoundObject* a_baseObject, float a_temperFactor)
{
using func_t = decltype(&ExtraTextDisplayData::GetDisplayName);
//REL::Offset<func_t> func = REL::ID(12626);
REL::Offset<func_t> func = 0x014D130;
return func(this, a_baseObject, a_temperFactor);
}
bool ExtraTextDisplayData::IsPlayerSet() const
{
return ownerInstance == DisplayDataType::kCustomName;
}
void ExtraTextDisplayData::SetName(const char* a_name)
{
if (displayNameText) {
return;
}
displayName = a_name;
customNameLength = static_cast<UInt16>(displayName.length());
ownerInstance = DisplayDataType::kCustomName;
temperFactor = 1.0F;
}
}
| [
"32599957+powerof3@users.noreply.github.com"
] | 32599957+powerof3@users.noreply.github.com |
89c7b18dd07bb4c63dd253b046e64a943211191e | e94e8d8c7ae6be06c82d7e8abdef7f0260ff9ad5 | /234tree/234tree/node.cpp | 288e4e92beff53ec940c503928ba92f5a2cf99db | [] | no_license | KookHoiKim/Sorting | 32c6a1f5ffb98915514ba0b25020d47496967d66 | cb43856bad344855801de99e8110a7b885416413 | refs/heads/master | 2020-04-03T15:43:29.646618 | 2018-11-21T01:53:27 | 2018-11-21T01:53:27 | 155,374,378 | 0 | 0 | null | null | null | null | UHC | C++ | false | false | 4,146 | cpp | #include "node.h"
node::node() {}
node::node(int val) {
value[1] = val;
value[SIZE] = 1;
}
node::node(int* val, node** cd) {
value[SIZE] = val[SIZE];
for (int i = 1; i <= val[SIZE]; i++) {
value[i] = val[i];
}
for (int j = 0; j <= val[SIZE]; j++) {
child[j] = cd[j];
}
}
node::~node() {}
void node::getNode(int* val, node** cd) {
for (int i = 0; i < 5; i++) {
value[i] = val[i];
child[i] = cd[i];
}
}
int node::getSize() {
return value[SIZE];
}
int node::getValue(int idx) {
return value[idx];
}
int* node::getValueAll() {
return value;
}
int node::getSizeSilbling() {
return getSibling()->getSize();
/*
if (parent == NULL) {
cout << "parent node doesn't exist" << endl;
return 0;
}
int idx;
for (idx = 0; idx <= parent->value[SIZE]; idx++) {
if (parent->child[idx]->value == value&&idx < parent->value[SIZE])
return parent->child[idx + 1]->getSize();
else
return parent->child[idx - 1]->getSize();
}
return -1;
*/
}
int node::searchValue(int val) {
int idx = 1;
for (; idx <= value[SIZE]; idx++)
if (value[idx] == val) return idx;
return 0;
}
int node::insertValue(int val) {
if (value[SIZE] == 4) {
cout << "no more space to insert" << endl;
return 0;
}
int idx = 1;
for (; idx <= value[SIZE]; idx++)
if (value[idx] >= val) break;
for (int j = value[SIZE]; j >= idx; j--) {
value[j + 1] = value[j];
}
value[idx] = val;
return ++value[SIZE];
}
int node::deleteValue(int val) {
int idx = searchValue(val);
if (!idx) {
cout << "no value in this node" << endl;
return -1;
}
else if (idx == value[SIZE]) {
value[idx] = 0;
return --value[SIZE];
}
else {
for (int i = idx + 1; i <= value[SIZE]; i++)
value[i - 1] = value[i];
value[value[SIZE]] = 0;
return --value[SIZE];
}
return -1;
}
int node::deleteValueIdx(int idx) {
if (idx > value[SIZE] || idx < 0) {
cout << "wrong index" << endl;
return -1;
}
int size = deleteValue(value[idx]);
return size;
}
node* node::split() {
// size property ๊ฐ ๋ง์กฑํ๋ฉด splitํ์ง ์๋๋ค
if (value[SIZE] < 4) {
cout << "this node doesn't violate size property" << endl;
return this;
}
int leftval[5] = { 2, value[1], value[2], };
int rightval[5] = { 1, value[4], };
node* cd1[5] = { child[0], child[1],child[2], };
node* cd2[5] = { child[3],child[4], };
// split ํ๊ณ 3node์ 2node๋ก ๋ถ๋ฆฌ๋ ๋ ์์
node* leftnode = new node;
node* rightnode = new node;
leftnode->getNode(leftval, cd1);
rightnode->getNode(rightval, cd2);
// ๋ถ๋ชจ ๋
ธ๋๊ฐ ์กด์ฌํ๋ค๋ฉด
if (parent) {
// ๋ถ๋ชจ ๋
ธ๋๊ฐ 5๋
ธ๋์ผ ๊ฒฝ์ฐ ๋จผ์ split์ ํ๋ค
// propagation์ด ์๋
// ๊ฐ์ ์ฌ๋ฆฌ๊ธฐ ์ ๋ถํฐ 5๋
ธ๋์ธ ์์ธ ์ผ์ด์ค๋ฅผ ์ฒ๋ฆฌํ๊ธฐ ์ํจ
if (parent->value[0] == 4)
parent->split();
node* pr = parent;
int idx = pr->insertValue(value[3]);
for (int i = pr->value[SIZE]; i > idx; i--) {
pr->child[i] = pr->child[i - 1];
}
pr->child[idx - 1] = leftnode;
pr->child[idx] = rightnode;
leftnode->parent = pr;
rightnode->parent = pr;
return pr;
}
// ๋ถ๋ชจ ๋
ธ๋๊ฐ ์์ ๋
// ์ฆ ์ด ๋
ธ๋๊ฐ root์ธ ์ํฉ
for (int i = 4; i > 0; i--) {
if (i == 3) continue;
deleteValueIdx(i);
}
for (int i = 2; i < 5; i++)
child[i] = 0;
child[0] = leftnode;
child[1] = rightnode;
leftnode->parent = this;
rightnode->parent = this;
// splitํ๊ณ ์๋ก ์ฌ๋ผ๊ฐ ๋ถ๋ชจ ๋
ธ๋๋ฅผ ๋ฐํํ๋ค
return this;
}
node* node::getSibling() {
if (parent == NULL) {
cout << "parent node doesn't exist" << endl;
return NULL;
}
int idx;
for (idx = 0; idx <= parent->value[SIZE]; idx++) {
if (parent->child[idx]->value == value && idx < parent->value[SIZE])
return parent->child[idx + 1];
else
return parent->child[idx - 1];
}
return NULL;
}
node* node::getParent() {
return parent;
}
node* node::getChild(int idx) {
return child[idx];
}
node** node::getChildAll() {
return child;
}
node* node::getPredecessor(int val) {
if (getChild(0) == NULL)
return NULL;
node* nd = child[searchValue(val) - 1];
while (1) {
if (nd->getChild(0) == NULL) break;
nd = nd->getChild(nd->getSize());
}
return nd;
} | [
"rlarnrghlapz@gmail.com"
] | rlarnrghlapz@gmail.com |
702b20b69c3ee60389cf28284cc5e4ff5bd2a9c5 | 6b2a8dd202fdce77c971c412717e305e1caaac51 | /solutions_1482492_0/C++/dkorduban/B.cpp | 5aa2199fb40cfbc965e2fd75778d21a4415490c2 | [] | no_license | alexandraback/datacollection | 0bc67a9ace00abbc843f4912562f3a064992e0e9 | 076a7bc7693f3abf07bfdbdac838cb4ef65ccfcf | refs/heads/master | 2021-01-24T18:27:24.417992 | 2017-05-23T09:23:38 | 2017-05-23T09:23:38 | 84,313,442 | 2 | 4 | null | null | null | null | UTF-8 | C++ | false | false | 1,072 | cpp | // MS Visual Studio
#include<cstdio>
#include<cstring>
#include<cstdio>
#include<cmath>
#include<iostream>
#include<map>
#include<vector>
using namespace std;
#define REP(i,n) FOR(i,0,n)
#define FOR(i,s,n) for(int i=(s); i<(n); ++i)
#define sz(X) int((X).size())
#define pb push_back
#define X first
#define Y second
typedef long long lint;
double T[1000], x[1000];
int main() {
freopen("B-small-attempt0.in", "r", stdin);
freopen("B.out", "w", stdout);
int tc;
scanf("%d", &tc);
FOR(t, 1, tc+1) {
//cerr << t << endl;
printf("Case #%d:\n", t);
int n, a;
double X;
cin >> X >> n >> a;
REP(i, n) {
cin >> T[i] >> x[i];
}
double to;
if(n == 1) {
to = 0;
} else {
to = ((X - x[0]) / (x[1] - x[0])) * T[1];
}
REP(i, a) {
double g;
cin >> g;
double t_our = sqrt(2 * X / g);
printf("%.10lf\n", max(to, t_our));
}
}
} | [
"eewestman@gmail.com"
] | eewestman@gmail.com |
7fbb6b91b8277188815990b954070751907ddf09 | d9169bed9c9ecad89932b0e05f979f9bb1922c37 | /Part-2/include/file_system_interface.h | 0854b6b6dd9367d604c272519b4665e873454c1c | [] | no_license | Moridi/AP-Spring-98-CA-6-Inheritance | 7d15cb1005a353401c360028e2bdfa2bf3fda7df | 1922206b4c63595f80ae865ca7696560e69249b7 | refs/heads/master | 2020-05-15T03:13:04.869687 | 2019-05-14T11:25:23 | 2019-05-14T11:25:23 | 182,064,437 | 2 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 917 | h | #ifndef FILE_SYSTEM_H_
#define FILE_SYSTEM_H_
#include <string>
#include <vector>
#include <memory>
class Element;
class FileSystemInterface
{
public:
typedef std::shared_ptr<Element> ElementSharedPointer;
inline FileSystemInterface();
void add_directory(int id, std::string title, int parent_id);
void add_file(int id, std::string title, std::string content, int parent_id);
void add_link(int id, std::string title, int element_id, int parent_id);
void view(int id);
void add_element(ElementSharedPointer new_element, int parent_id);
inline ElementSharedPointer get_element(int id) const;
inline void check_id_validity(int id) const;
inline void check_parent_id_validity(int id) const;
inline ElementSharedPointer get_linked_element(int element_id) const;
private:
std::vector<ElementSharedPointer> elements;
};
#include "file_system_interface-inl.h"
#endif | [
"m.moridi.2009@gmail.com"
] | m.moridi.2009@gmail.com |
c08db733302eeede19438e16b701641ac7b4b750 | 84491309d9aa15f1da13e7cbbc2486dd95b2e5a1 | /Data Structures Implementation/Stack/stack.cpp | 95a8df587974f6a453e11870052f4367387adfc7 | [] | no_license | iksanov/algorithms_data-structures_OOP | d8befe4df618994ff505a0e44f73601ccd69ccb5 | 0967c7179699fbb888e1cc22b6497951fc53342b | refs/heads/master | 2021-08-20T02:53:24.387581 | 2017-11-28T02:26:31 | 2017-11-28T02:26:31 | 111,935,555 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,090 | cpp | #include "stack.h"
#include <new>
#include <stdexcept>
#include <iostream>
using std::runtime_error;
using std::cout;
using std::endl;
Stack::Stack(int init_size)
{
cout << "I'm inside the constructor\n";
arr = new int[init_size];
capacity = init_size;
count = 0;
}
Stack::Stack(const Stack &stack)
{
cout << "I'm inside the copy-constructor\n";
arr = new int[stack.capacity];
memcpy(arr, stack.arr, sizeof(int) * stack.size());
count = stack.count;
capacity = stack.capacity;
}
Stack::~Stack()
{
cout << "I'm inside the destructor" << endl;
delete[] arr;
}
void Stack::push(int number)
{
if (count < capacity)
{
arr[count] = number;
++count;
}
else
throw runtime_error("Stack::push - no memory");
}
int Stack::top()
{
if (count > 0)
return arr[count - 1];
else
throw runtime_error("Stack::top - no elements");
}
int Stack::pop()
{
if (count > 0){
int tmp = top();
arr[--count] = 0;
return tmp;
}
else
throw runtime_error("Stack::pop - no elements");
}
int Stack::size() const
{
return count;
} | [
"iksanov@yahoo.com"
] | iksanov@yahoo.com |
bbe68f9c3beaf69a463ad6cdd31f93e1e8781bd9 | 4015f8bd0d1bd8306f6ec80524a891df369544c0 | /11/11/11.cpp | 8399b2a042dd6a06cb01604e7087b0c7b3002532 | [] | no_license | andyyin15/forthrepository | b18834c46d81c565e0d932cba70a1d260c9325cb | 85c3c4fad188ce5391eed1aa880117098e51cc90 | refs/heads/master | 2020-11-27T16:41:14.621627 | 2020-06-30T13:17:25 | 2020-06-30T13:17:25 | 229,530,174 | 0 | 0 | null | null | null | null | GB18030 | C++ | false | false | 262 | cpp | // 11.cpp : ๅฎไนๆงๅถๅฐๅบ็จ็จๅบ็ๅ
ฅๅฃ็นใ
//
#include "stdafx.h"
#include<stdio.h>
#include"iostream"
int main(void)
{
int a[5] = { 1,2,3,4,5 };
int *ptr = (int *)(a + 1);
printf("%d,%d", *(a + 1), *(ptr - 1));
system("pause");
return 0;
} | [
"3223939902@qq.com"
] | 3223939902@qq.com |
322462cfca9134c90fd7923c21992ad6c8d56b45 | 75c952df608927b957f7969383d1e7f0f5e71d4e | /Busca/include/Griffon.h | 7ba7f16db74e5d7dddfe9647156e968225912992 | [] | no_license | igmsantos/AIcutter | b281b77d8f28f5172e0bbfa76cad2b349117a2d0 | 4d614c8779a21ccf3831f6da27c4ac97625dfdf6 | refs/heads/master | 2021-01-10T20:49:31.208887 | 2015-08-25T15:35:01 | 2015-08-25T15:35:01 | 41,368,391 | 1 | 1 | null | null | null | null | ISO-8859-1 | C++ | false | false | 1,250 | h | #ifndef GRIFFON_H_
#define GRIFFON_H_
/** TODO
*
* buscaCadernos
* leCadernos
* leCaderno
* analisaLayout
* identificaLinhas
* separaRecortes
* IdentificaRecortes
*
*/
/**
*
* A classe Griffon รฉ responsavel por englobar as funรงรตes do ator (usuรกrio) ao realizar as tarefas necessรกrias
* de identificaรงรฃo de cabeรงalhos e recortes (artigos), e identificaรงรฃo dos clientes em que o recorte se refere.
* As tarefas foram divididas em subtarefas de acordo com o fluxo de entrada e saida dos processos nos quais o
* usuรกrio interage com o documento atรฉ a obtenรงรฃo dos recortes identificados:
*
* - Procurar documentos PDF
* - Analisar inicialmente
* - Identificar inicialmente as linhas
* - Aguardar a verificaรงรฃo
* - Separar recortes
* - Identificar recortes
*
*/
class CGriffon;
#include "Cerebro.h"
#include "DocumentoIA.h"
class CGriffon{
public:
CCerebro *cerebro;
CDocumentoIA *documentos;
CGriffon();
CDocumentoIA *buscaDocumentos();
CDocumentoIA *pegaDocumento(char*);
int analisaLayout();
int generalizaLayout();
int identificaLinhas();
CBloco *separaRecortes();
int identificaRecortes();
int Work(char*);
int Work();
};
#endif /*GRIFFON_H_*/
| [
"ivanmunix@gmail.com"
] | ivanmunix@gmail.com |
3c9da29f1b78e7493e9464525db1c484d20f3d1b | 0b95ece2228853e93506c9177359c7251bfacc65 | /Arduino_code/calibration/MatlabSerial_forverification/MatlabSerial_forverification.ino | fa41ef6c488c07336a435ca4b99d086240e8088c | [] | no_license | RoshanPasupathy/Smartwing_GDP1617 | 81a974f67bf30f102d7d6c2e51c036e941b937e0 | 198d2ff8297d7e053cf7434dfc2572e14e285bd3 | refs/heads/master | 2021-01-22T19:22:01.900476 | 2017-03-16T12:15:31 | 2017-03-16T12:15:31 | 85,193,825 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,198 | ino | #include "HX711.h"
//function definition
void send_routine(void);
volatile byte state = LOW;
int switchPin = 2;
int ledPin = 14;
int redledPin = 15;
HX711 l1;
HX711 l2;
HX711 l3;
HX711 d1;
HX711 d2;
//Number of loading conditions
//int N = 5;
void setup() {
// Initialise loadcells
l1.begin(11,12);
l2.begin(9,10);
l3.begin(7,8);
d1.begin(3,4);
d2.begin(5,6);
//initialise pins
pinMode(ledPin, OUTPUT);
pinMode(switchPin, INPUT);
pinMode(redledPin, OUTPUT);
//Procedure
digitalWrite(redledPin, LOW);
//Green LED stays lit while waiting
//for connection
digitalWrite(ledPin, HIGH);
Serial.begin(9600);
Serial.println('a');
char a = 'b';
while (a != 'a'){
a = Serial.read();
}
digitalWrite(ledPin, LOW);
send_routine();
}
void loop() {
// put your main code here, to run repeatedly:
}
/**
* Synchronises matlab and arduino serial
to prevent overflow
* Synchronisation done by acknowledgement chars
* Arduino prints data -> matlab reads when it detects
presence of bytes in serial buffer
* Acknowledgement procedure:
- Arduino waits for matlab acknowledgement
- When available -> read
- If unexpected char -> light Red LED
else blink green LED twice
*/
void send_routine(){
blinkled(ledPin, 3, 200);
blinkled(redledPin, 3, 200);
volatile byte runflag = LOW;
char val = 'a';
//Waits for matlab to begin request
// request char = 'c'
while (Serial.available() == 0){
}
if (Serial.available() > 0){
val = Serial.read();
if (val == 'c'){
//data received as expected
//blink green twice
runflag = HIGH;
blinkled(ledPin, 2, 300);
}
else {
//Unexpected output -> Something went wrong
digitalWrite(redledPin, HIGH);
}
}
//Green led lights up to indicate ready for next stage
digitalWrite(ledPin, HIGH);
//Send data for each loading condition
//for (int i = 0; i < N; i++){
while (runflag == HIGH){
digitalWrite(ledPin, HIGH);
state = digitalRead(switchPin);
//Halt till load is placed
while (digitalRead(switchPin) == state){
}
//Switch toggled -> load placed -> green led goes off
digitalWrite(ledPin, LOW);
//send data
Serial.println(l1.read_average(10));
Serial.println(l2.read_average(10));
Serial.println(l3.read_average(10));
Serial.println(d1.read_average(10));
Serial.println(d2.read_average(10));
//before proceeding check if data is received by matlab
while (Serial.available() == 0){
}
if (Serial.available() > 0){
val = Serial.read();
if (val == 'g'){
//blink green twice
blinkled(ledPin, 2, 300);
}
else if (val == 'e'){
runflag = LOW;
}
else {
//Received something but it's not expected
digitalWrite(redledPin, HIGH);
//abort
}
}
}
blinkled(redledPin, 3, 300);
blinkled(ledPin, 3, 300);
}
void blinkled(int pinl, int times, int milsec){
for (int i = 0; i < times; i++){
delay(milsec);
digitalWrite(pinl, LOW);
delay(milsec);
digitalWrite(pinl, HIGH);
}
digitalWrite(pinl, LOW);
}
| [
"roshan.pasupathy@gmail.com"
] | roshan.pasupathy@gmail.com |
95bd8196713248910ebb7a4be055fb36d21b554e | de0b00d9d18c7b7776ceee1163ab1b07b9e80ec8 | /Level 5_Inheritance_Generalisation_Specialisation/Section 3_5/Exercise 1/Exercise1/Point.cpp | a45dd4c808d5da47d454a2b01e961d37b3f72efd | [] | no_license | FinancialEngineerLab/quantnet-baruch-certificate-cpp | e4187dcc74d1c0521f5f071f980b4be274448f35 | 4f555a76f196fb392189574be23223350a317960 | refs/heads/master | 2023-03-15T16:13:07.671250 | 2016-10-20T05:19:58 | 2016-10-20T05:19:58 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,267 | cpp | // Point.cpp
// Function implementation for the functions in the header file Point.hpp(Point classs with x- and y- coordinates.)
// Implementation of added operators to the Point class.
#include "Point.hpp"
#include <cmath>
#include <sstream>
#
using namespace std;
namespace Shihan {
namespace CAD {
// Default constructor
Point::Point(): Shape(), m_x(0), m_y(0) // Initializing data members and calling base class at the same time.
{
}
// Initialize using newx and newy ; Calling the base class
Point::Point(double newx, double newy) : Shape(), m_x(newx),m_y(newy)
{
}
// Copy constructor
Point::Point(const Point& source) :Shape(source), m_x(source.m_x),m_y(source.m_y)
{
}
// Destructor
Point::~Point()
{
}
// Getter function for coordinate x.
double Point::X() const
{
return m_x;
}
//Setter function for coordinate x.
void Point::X(double newX)
{
m_x = newX;
}
// Getter function for coordinate y.
double Point::Y() const
{
return m_y;
}
//Setter function for coordinate y.
void Point::Y(double newY)
{
m_y = newY;
}
// Returns a string description of the point.
std::string Point::ToString() const
{
std::stringstream sm_x, sm_y;
sm_x << m_x;
sm_y << m_y;
std::string str;
str = "\"Point("+sm_x.str()+","+sm_y.str()+")\"";
return str;
}
//Calculate the distance to the origin (0,0).
double Point::Distance() const // DistanceOrigin() is changed to Distance().
{
double dist_to_origin;
dist_to_origin = sqrt(pow((m_x- 0),2) + pow((m_y- 0),2)); //sqrt returns only positive sqrt value. I didn't consider abs value.
return dist_to_origin;
}
// Calculate the distance between two given points.
// Distance function will be implemented by passing the argument as a "const reference". Therefore at this occasion copy constructor will not be
//called.
double Point::Distance(const Point& p) const
{
double dist_to_point;
dist_to_point = sqrt(pow((m_x- p.X()),2) + pow((m_y- p.Y()),2));//sqrt returns only positive sqrt value. I didn't consider abs value.
return dist_to_point;
}
/* Implementation of added operators to the Point class. */
//Negate the coordinates operator
Point Point::operator - () const
{
return Point(-m_x,-m_y);
}
//Scale the coordinates operator
Point Point::operator * (double factor) const
{
return Point(factor*m_x, factor*m_y);
}
//Add coordinates operator
Point Point::operator + (const Point& p) const
{
return Point(m_x + p.m_x, m_y + p.m_y);
}
//Equally compare operator
bool Point::operator== (const Point& P) const
{
return (m_x == P.m_x && m_y == P.m_y );
}
//Assignment operator
Point& Point::operator = (const Point& source)
{
// Avoid doing assign to myself
if (this == &source)
return *this;
Shape::operator =(source);
m_x = source.m_x;
m_y = source.m_y;
//std:: cout <<"I am the Assignment operator for the Point class \n "<< endl;
return *this;
}
//Scale the coordinates and assign
Point& Point::operator *= (double factor)
{
(*this).m_x= (*this).m_x * factor;
(*this).m_y= (*this).m_y * factor;
return *this;
}
}
}
// Global function to send a point directlry to the cout object.
std::ostream& operator << (ostream& os_P, const Shihan::CAD::Point& P)
{
os_P << P.ToString()<<endl;
return os_P;
}
| [
"shihanutb@gmail.com"
] | shihanutb@gmail.com |
afa27aac4fe5729d7addff9efcc6f44c5d70ec75 | b82d54e98101e2cd6278ef014fe97b2b2e10a181 | /grid.h | b08704a13e498e4c2d5ae2a8cdf97e98f2c8730f | [
"MIT"
] | permissive | binarydream01/reversAI | ebf192e219b4e1a5ce5f431a7d723226e8c8646e | 1e990605aa99c0596910e227625ad418f06e497d | refs/heads/master | 2021-01-18T21:42:42.067287 | 2017-04-03T01:40:28 | 2017-04-03T01:40:28 | 87,020,094 | 0 | 0 | null | 2017-04-02T22:23:26 | 2017-04-02T22:23:26 | null | UTF-8 | C++ | false | false | 839 | h | //Name: Tobias Hughes
//Purpose: An abstract representation of the reversi game board. Is an 8x8 grid
//that can be one of three states, E, W, B which represent 'empty',
//'white', and 'black'
//Date: 3/22/17
#ifndef GRID_H
#define GRID_H
#include <string>
using namespace std;
#define GRID_SIZE 64
class grid{
private:
char board[GRID_SIZE];
char turn;
char turn_char[2];
bool checkRight(int);
bool checkLeft(int);
bool checkUp(int);
bool checkDown(int);
bool checkNE(int);
bool checkNW(int);
bool checkSE(int);
bool checkSW(int);
public:
grid();
grid(const grid&);
char getState(string);
void setState(string);
void setTurn(char);
int boardIndex(string);
unsigned char checkBound(int);
bool goalState();
};
#endif
| [
"tobywhughes@gmail.com"
] | tobywhughes@gmail.com |
96cb419b2c776ee59933338c05d72172917d09ce | 914a83057719d6b9276b1a0ec4f9c66fea064276 | /test/cpp/accumulator/accum_lazy0.cpp | 52750f426feb2e461de7f8746989baa2e2b16701 | [
"BSD-2-Clause"
] | permissive | jjwilke/hclib | e8970675bf49f89c1e5e2120b06387d0b14b6645 | 5c57408ac009386702e9b96ec2401da0e8369dbe | refs/heads/master | 2020-03-31T19:38:28.239603 | 2018-12-21T20:29:44 | 2018-12-21T20:29:44 | 152,505,070 | 0 | 0 | Apache-2.0 | 2018-10-11T00:02:52 | 2018-10-11T00:02:51 | null | UTF-8 | C++ | false | false | 2,683 | cpp | /* Copyright (c) 2013, Rice University
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are
met:
1. Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above
copyright notice, this list of conditions and the following
disclaimer in the documentation and/or other materials provided
with the distribution.
3. Neither the name of Rice University
nor the names of its contributors may be used to endorse or
promote products derived from this software without specific
prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
/**
* DESC: Recursive accumulator
*/
#include <stdlib.h>
#include <stdio.h>
#include <assert.h>
#include "hclib_cpp.h"
int ran = 0;
void async_fct(void * arg) {
printf("Running Async\n");
ran = 1;
}
void accum_create_n(accum_t ** accums, int n) {
int i = 0;
while(i < n) {
accums[i] = accum_create_int(ACCUM_OP_PLUS, ACCUM_MODE_LAZY, 0);
i++;
}
}
void accum_destroy_n(accum_t ** accums, int n) {
int i = 0;
while(i < n) {
accum_destroy(accums[i]);
i++;
}
}
void accum_print_n(accum_t ** accums, int n) {
int i = 0;
while(i < n) {
int res = accum_get_int(accums[i]);
printf("Hello[%d] = %d\n", i, res);
i++;
}
}
int main (int argc, char ** argv) {
hclib_init(&argc, argv);
int n = 10;
accum_t * accums_s[n];
accum_t ** accums = (accum_t **) accums_s;
accum_create_n(accums, n);
start_finish();
accum_register(accums, n);
accum_put_int(accums[3], 2);
accum_put_int(accums[4], 2);
accum_put_int(accums[5], 2);
end_finish();
accum_print_n(accums, n);
accum_destroy_n(accums, n);
hclib_finalize();
return 0;
}
| [
"jmaxg3@gmail.com"
] | jmaxg3@gmail.com |
6b4f39fca4ae3bd2667ce60c26ddd692b5235f66 | 4432c7fad4af2925a0b3dd26c5236d1c22997551 | /src/main/interpreted_vm.h | 78590199bf3143a281540a9ee2e1d6622cf0bfda | [] | no_license | gitter-badger/otherside | 53025be2b0c985451ec5977641375aebc1c49283 | 5178b934a110a41bcdddfb74a154e1eff44e34e6 | refs/heads/master | 2021-01-16T20:51:35.674343 | 2015-08-03T12:47:00 | 2015-08-03T12:47:00 | 40,125,819 | 0 | 0 | null | 2015-08-03T13:19:52 | 2015-08-03T13:19:51 | null | UTF-8 | C++ | false | false | 1,524 | h | #pragma once
#include "vm.h"
#include <memory>
#include <vector>
#include "parser_definitions.h"
struct Function;
class InterpretedVM : public VM {
private:
Program& prog;
Environment& env;
std::map<uint32, uint32> TypeByteSizes;
std::vector<std::unique_ptr<byte>> VmMemory;
byte* VmAlloc(uint32 typeId) override;
Value TextureSample(Value sampler, Value coord, Value bias, uint32 resultTypeId);
uint32 Execute(Function* func);
void * ReadVariable(uint32 id) const;
bool SetVariable(uint32 id, void * value);
bool InitializeConstants();
void ImportExt(SExtInstImport import);
public:
InterpretedVM(Program& prog, Environment& env) : prog(prog), env(env) {
for (auto& ext : prog.ExtensionImports) {
ImportExt(ext.second);
}
}
virtual bool Run() override;
bool SetVariable(std::string name, void * value) override;
void * ReadVariable(std::string name) const override;
Value VmInit(uint32 typeId, void * val) override;
Value Dereference(Value val) const override;
Value IndexMemberValue(Value val, uint32 index) const override;
Value IndexMemberValue(uint32 typeId, byte * val, uint32 index) const override;
uint32 GetTypeByteSize(uint32 typeId) const override;
byte * GetPointerInComposite(uint32 typeId, byte * composite, uint32 indexCount, uint32 * indices, uint32 currLevel) const override;
SOp GetType(uint32 typeId) const override;
bool IsVectorType(uint32 typeId) const override;
uint32 ElementCount(uint32 typeId) const override;
}; | [
"dario.seyb@gmail.com"
] | dario.seyb@gmail.com |
54c3f666cf1e686aa89142cc5e7304c6a0c77fd5 | ff7f4d1db50802fff5ef30dbc070deae61562ac2 | /RecoBTag/SecondaryVertex/src/CombinedSVSoftLeptonComputer.cc | 7e80ce45d90fefeceaa37cc85a7a22d2e221be04 | [] | no_license | chenxvan/cmssw | c76aaab6b7529ddcea32c235999207d98cdac3f7 | 5a62631dbbe35410e816ca1b35682203ceaa64f9 | refs/heads/CMSSW_7_1_X | 2021-01-09T07:33:32.267995 | 2017-06-01T20:05:26 | 2017-06-01T20:05:26 | 19,713,080 | 0 | 0 | null | 2017-06-01T20:05:27 | 2014-05-12T19:54:48 | C++ | UTF-8 | C++ | false | false | 20,599 | cc | #include <iostream>
#include <cstddef>
#include <string>
#include <cmath>
#include <vector>
#include <Math/VectorUtil.h>
#include "FWCore/Utilities/interface/Exception.h"
#include "FWCore/ParameterSet/interface/ParameterSet.h"
#include "DataFormats/Math/interface/Vector3D.h"
#include "DataFormats/Math/interface/LorentzVector.h"
#include "DataFormats/GeometryCommonDetAlgo/interface/Measurement1D.h"
#include "DataFormats/GeometryVector/interface/GlobalPoint.h"
#include "DataFormats/GeometryVector/interface/GlobalVector.h"
#include "DataFormats/GeometryVector/interface/VectorUtil.h"
#include "DataFormats/TrackReco/interface/Track.h"
#include "DataFormats/TrackReco/interface/TrackFwd.h"
#include "DataFormats/BTauReco/interface/TrackIPTagInfo.h"
#include "DataFormats/BTauReco/interface/SecondaryVertexTagInfo.h"
#include "DataFormats/BTauReco/interface/SoftLeptonTagInfo.h"
#include "DataFormats/BTauReco/interface/TaggingVariable.h"
#include "DataFormats/BTauReco/interface/VertexTypes.h"
#include "DataFormats/JetReco/interface/PFJet.h"
#include "DataFormats/PatCandidates/interface/Jet.h"
#include "RecoVertex/VertexPrimitives/interface/ConvertToFromReco.h"
#include "RecoBTag/SecondaryVertex/interface/ParticleMasses.h"
#include "RecoBTag/SecondaryVertex/interface/TrackSorting.h"
#include "RecoBTag/SecondaryVertex/interface/TrackSelector.h"
#include "RecoBTag/SecondaryVertex/interface/TrackKinematics.h"
#include "RecoBTag/SecondaryVertex/interface/V0Filter.h"
#include "RecoBTag/SecondaryVertex/interface/CombinedSVSoftLeptonComputer.h"
using namespace reco;
using namespace std;
struct CombinedSVSoftLeptonComputer::IterationRange {
int begin, end, increment;
};
#define range_for(i, x) \
for(int i = (x).begin; i != (x).end; i += (x).increment)
static edm::ParameterSet dropDeltaR(const edm::ParameterSet &pset)
{
edm::ParameterSet psetCopy(pset);
psetCopy.addParameter<double>("jetDeltaRMax", 99999.0);
return psetCopy;
}
CombinedSVSoftLeptonComputer::CombinedSVSoftLeptonComputer(const edm::ParameterSet ¶ms) :
trackFlip(params.getParameter<bool>("trackFlip")),
vertexFlip(params.getParameter<bool>("vertexFlip")),
charmCut(params.getParameter<double>("charmCut")),
sortCriterium(TrackSorting::getCriterium(params.getParameter<std::string>("trackSort"))),
trackSelector(params.getParameter<edm::ParameterSet>("trackSelection")),
trackNoDeltaRSelector(dropDeltaR(params.getParameter<edm::ParameterSet>("trackSelection"))),
trackPseudoSelector(params.getParameter<edm::ParameterSet>("trackPseudoSelection")),
pseudoMultiplicityMin(params.getParameter<unsigned int>("pseudoMultiplicityMin")),
trackMultiplicityMin(params.getParameter<unsigned int>("trackMultiplicityMin")),
minTrackWeight(params.getParameter<double>("minimumTrackWeight")),
useTrackWeights(params.getParameter<bool>("useTrackWeights")),
vertexMassCorrection(params.getParameter<bool>("correctVertexMass")),
pseudoVertexV0Filter(params.getParameter<edm::ParameterSet>("pseudoVertexV0Filter")),
trackPairV0Filter(params.getParameter<edm::ParameterSet>("trackPairV0Filter"))
{
}
inline double CombinedSVSoftLeptonComputer::flipValue(double value, bool vertex) const
{
return (vertex ? vertexFlip : trackFlip) ? -value : value;
}
inline CombinedSVSoftLeptonComputer::IterationRange CombinedSVSoftLeptonComputer::flipIterate(
int size, bool vertex) const
{
IterationRange range;
if (vertex ? vertexFlip : trackFlip) {
range.begin = size - 1;
range.end = -1;
range.increment = -1;
} else {
range.begin = 0;
range.end = size;
range.increment = +1;
}
return range;
}
const TrackIPTagInfo::TrackIPData &
CombinedSVSoftLeptonComputer::threshTrack(const TrackIPTagInfo &trackIPTagInfo,
const TrackIPTagInfo::SortCriteria sort,
const reco::Jet &jet,
const GlobalPoint &pv) const
{
const edm::RefVector<TrackCollection> &tracks =
trackIPTagInfo.selectedTracks();
const std::vector<TrackIPTagInfo::TrackIPData> &ipData =
trackIPTagInfo.impactParameterData();
std::vector<std::size_t> indices = trackIPTagInfo.sortedIndexes(sort);
IterationRange range = flipIterate(indices.size(), false);
TrackKinematics kin;
range_for(i, range) {
std::size_t idx = indices[i];
const TrackIPTagInfo::TrackIPData &data = ipData[idx];
const Track &track = *tracks[idx];
if (!trackNoDeltaRSelector(track, data, jet, pv))
continue;
kin.add(track);
if (kin.vectorSum().M() > charmCut)
return data;
}
static const TrackIPTagInfo::TrackIPData dummy = {
GlobalPoint(),
GlobalPoint(),
Measurement1D(-1.0, 1.0),
Measurement1D(-1.0, 1.0),
Measurement1D(-1.0, 1.0),
Measurement1D(-1.0, 1.0),
0.
};
return dummy;
}
static double etaRel(const math::XYZVector &dir, const math::XYZVector &track)
{
double momPar = dir.Dot(track);
double energy = std::sqrt(track.Mag2() + ROOT::Math::Square(ParticleMasses::piPlus));
return 0.5 * std::log((energy + momPar) / (energy - momPar));
}
TaggingVariableList
CombinedSVSoftLeptonComputer::operator () (const TrackIPTagInfo &ipInfo,
const SecondaryVertexTagInfo &svInfo,
const SoftLeptonTagInfo &muonInfo,
const SoftLeptonTagInfo &elecInfo
) const
{
using namespace ROOT::Math;
edm::RefToBase<Jet> jet = ipInfo.jet();
math::XYZVector jetDir = jet->momentum().Unit();
bool havePv = ipInfo.primaryVertex().isNonnull();
GlobalPoint pv;
if (havePv)
pv = GlobalPoint(ipInfo.primaryVertex()->x(), ipInfo.primaryVertex()->y(), ipInfo.primaryVertex()->z());
btag::Vertices::VertexType vtxType = btag::Vertices::NoVertex;
TaggingVariableList vars;
vars.insert(btau::jetPt, jet->pt(), true);
vars.insert(btau::jetEta, jet->eta(), true);
if (ipInfo.selectedTracks().size() < trackMultiplicityMin)
return vars;
vars.insert(btau::jetNTracks, ipInfo.selectedTracks().size(), true);
TrackKinematics allKinematics;
TrackKinematics vertexKinematics;
TrackKinematics trackJetKinematics;
double vtx_track_ptSum= 0.;
double vtx_track_ESum= 0.;
double jet_track_ESum= 0.;
int vtx = -1;
unsigned int numberofvertextracks = 0;
//IF THERE ARE SECONDARY VERTICES THE JET FALLS IN THE RECOVERTEX CATEGORY
IterationRange range = flipIterate(svInfo.nVertices(), true);
range_for(i, range) {
if (vtx < 0) vtx = i; //RecoVertex category (vtx=0) if we enter at least one time in this loop!
numberofvertextracks = numberofvertextracks + (svInfo.secondaryVertex(i)).nTracks();
const Vertex &vertex = svInfo.secondaryVertex(i);
bool hasRefittedTracks = vertex.hasRefittedTracks();
TrackRefVector tracks = svInfo.vertexTracks(i);
for(TrackRefVector::const_iterator track = tracks.begin(); track != tracks.end(); track++) {
double w = svInfo.trackWeight(i, *track);
if (w < minTrackWeight)
continue;
if (hasRefittedTracks) {
Track actualTrack = vertex.refittedTrack(*track);
vars.insert(btau::trackEtaRel, etaRel(jetDir,actualTrack.momentum()), true);
vertexKinematics.add(actualTrack, w);
if(i==0)
{
math::XYZVector vtx_trackMom = actualTrack.momentum();
vtx_track_ptSum += std::sqrt(std::pow(vtx_trackMom.X(),2) + std::pow(vtx_trackMom.Y(),2));
vtx_track_ESum += std::sqrt(vtx_trackMom.Mag2() + ROOT::Math::Square(ParticleMasses::piPlus));
}
} else { //THIS ONE IS TAKEN...
vars.insert(btau::trackEtaRel, etaRel(jetDir,(*track)->momentum()), true);
vertexKinematics.add(**track, w);
if(i==0) // calculate this only for the first vertex
{
math::XYZVector vtx_trackMom = (*track)->momentum();
vtx_track_ptSum += std::sqrt(std::pow(vtx_trackMom.X(),2) + std::pow(vtx_trackMom.Y(),2));
vtx_track_ESum += std::sqrt(vtx_trackMom.Mag2() + std::pow(ParticleMasses::piPlus,2));
}
}
}
}
if (vtx >= 0) {
vtxType = btag::Vertices::RecoVertex;
vars.insert(btau::flightDistance2dVal,flipValue(svInfo.flightDistance(vtx, true).value(),true),true);
vars.insert(btau::flightDistance2dSig,flipValue(svInfo.flightDistance(vtx, true).significance(),true),true);
vars.insert(btau::flightDistance3dVal,flipValue(svInfo.flightDistance(vtx, false).value(),true),true);
vars.insert(btau::flightDistance3dSig,flipValue(svInfo.flightDistance(vtx, false).significance(),true),true);
vars.insert(btau::vertexJetDeltaR,Geom::deltaR(svInfo.flightDirection(vtx), jetDir),true);
vars.insert(btau::jetNSecondaryVertices, svInfo.nVertices(), true);
vars.insert(btau::vertexNTracks, numberofvertextracks, true);
vars.insert(btau::vertexFitProb,(svInfo.secondaryVertex(vtx)).normalizedChi2(), true);
}
//NOW ATTEMPT TO RECONSTRUCT PSEUDOVERTEX!!!
std::vector<std::size_t> indices = ipInfo.sortedIndexes(sortCriterium);
const std::vector<TrackIPTagInfo::TrackIPData> &ipData = ipInfo.impactParameterData();
const edm::RefVector<TrackCollection> &tracks = ipInfo.selectedTracks();
std::vector<TrackRef> pseudoVertexTracks;
range = flipIterate(indices.size(), false);
range_for(i, range) {
std::size_t idx = indices[i];
const TrackIPTagInfo::TrackIPData &data = ipData[idx];
const TrackRef &trackRef = tracks[idx];
const Track &track = *trackRef;
// if no vertex was reconstructed, attempt pseudo vertex
if (vtxType == btag::Vertices::NoVertex && trackPseudoSelector(track, data, *jet, pv)) {
pseudoVertexTracks.push_back(trackRef);
vertexKinematics.add(track);
}
}
if (vtxType == btag::Vertices::NoVertex && vertexKinematics.numberOfTracks() >= pseudoMultiplicityMin && pseudoVertexV0Filter(pseudoVertexTracks))
{
vtxType = btag::Vertices::PseudoVertex;
for(std::vector<TrackRef>::const_iterator track = pseudoVertexTracks.begin(); track != pseudoVertexTracks.end(); ++track)
{
vars.insert(btau::trackEtaRel, etaRel(jetDir, (*track)->momentum()), true);
math::XYZVector vtx_trackMom = (*track)->momentum();
vtx_track_ptSum += std::sqrt(std::pow(vtx_trackMom.X(),2) + std::pow(vtx_trackMom.Y(),2));
vtx_track_ESum += std::sqrt(vtx_trackMom.Mag2() + std::pow(ParticleMasses::piPlus,2));
}
}
vars.insert(btau::vertexCategory, vtxType, true);
// do a tighter track selection to fill the variable plots...
TrackRef trackPairV0Test[2];
range = flipIterate(indices.size(), false);
range_for(i, range) {
std::size_t idx = indices[i];
const TrackIPTagInfo::TrackIPData &data = ipData[idx];
const TrackRef &trackRef = tracks[idx];
const Track &track = *trackRef;
jet_track_ESum += std::sqrt((track.momentum()).Mag2() + std::pow(ParticleMasses::piPlus,2));
// add track to kinematics for all tracks in jet
//allKinematics.add(track); //would make more sense for some variables, e.g. vertexEnergyRatio nicely between 0 and 1, but not necessarily the best option for the discriminating power...
// filter tracks -> this track selection can be more tight (used to fill the track related variables...)
if (!trackSelector(track, data, *jet, pv))
continue;
// add track to kinematics for all tracks in jet
allKinematics.add(track);
// check against all other tracks for K0 track pairs setting the track mass to pi+
trackPairV0Test[0] = tracks[idx];
bool ok = true;
range_for(j, range) {
if (i == j)
continue;
std::size_t pairIdx = indices[j];
const TrackIPTagInfo::TrackIPData &pairTrackData = ipData[pairIdx];
const TrackRef &pairTrackRef = tracks[pairIdx];
const Track &pairTrack = *pairTrackRef;
if (!trackSelector(pairTrack, pairTrackData, *jet, pv))
continue;
trackPairV0Test[1] = pairTrackRef;
if (!trackPairV0Filter(trackPairV0Test, 2)) { //V0 filter is more tight (0.03) than the one used for the RecoVertex and PseudoVertex tracks (0.05)
ok = false;
break;
}
}
if (!ok)
continue;
trackJetKinematics.add(track);
// add track variables
math::XYZVector trackMom = track.momentum();
double trackMag = std::sqrt(trackMom.Mag2());
vars.insert(btau::trackSip3dVal, flipValue(data.ip3d.value(), false), true);
vars.insert(btau::trackSip3dSig, flipValue(data.ip3d.significance(), false), true);
vars.insert(btau::trackSip2dVal, flipValue(data.ip2d.value(), false), true);
vars.insert(btau::trackSip2dSig, flipValue(data.ip2d.significance(), false), true);
vars.insert(btau::trackJetDistVal, data.distanceToJetAxis.value(), true);
vars.insert(btau::trackDecayLenVal, havePv ? (data.closestToJetAxis - pv).mag() : -1.0, true);
vars.insert(btau::trackPtRel, VectorUtil::Perp(trackMom, jetDir), true);
vars.insert(btau::trackPPar, jetDir.Dot(trackMom), true);
vars.insert(btau::trackDeltaR, VectorUtil::DeltaR(trackMom, jetDir), true);
vars.insert(btau::trackPtRatio, VectorUtil::Perp(trackMom, jetDir) / trackMag, true);
vars.insert(btau::trackPParRatio, jetDir.Dot(trackMom) / trackMag, true);
}
vars.insert(btau::trackJetPt, trackJetKinematics.vectorSum().Pt(), true);
vars.insert(btau::trackSumJetDeltaR,VectorUtil::DeltaR(allKinematics.vectorSum(), jetDir), true);
vars.insert(btau::trackSumJetEtRatio,allKinematics.vectorSum().Et() / ipInfo.jet()->et(), true);
vars.insert(btau::trackSip3dSigAboveCharm, flipValue(threshTrack(ipInfo, TrackIPTagInfo::IP3DSig, *jet, pv).ip3d.significance(),false),true);
vars.insert(btau::trackSip3dValAboveCharm, flipValue(threshTrack(ipInfo, TrackIPTagInfo::IP3DSig, *jet, pv).ip3d.value(),false),true);
vars.insert(btau::trackSip2dSigAboveCharm, flipValue(threshTrack(ipInfo, TrackIPTagInfo::IP2DSig, *jet, pv).ip2d.significance(),false),true);
vars.insert(btau::trackSip2dValAboveCharm, flipValue(threshTrack(ipInfo, TrackIPTagInfo::IP2DSig, *jet, pv).ip2d.value(),false),true);
if (vtxType != btag::Vertices::NoVertex) {
math::XYZTLorentzVector allSum = useTrackWeights ? allKinematics.weightedVectorSum() : allKinematics.vectorSum();
math::XYZTLorentzVector vertexSum = useTrackWeights ? vertexKinematics.weightedVectorSum() : vertexKinematics.vectorSum();
if (vtxType != btag::Vertices::RecoVertex) {
vars.insert(btau::vertexNTracks,vertexKinematics.numberOfTracks(), true);
vars.insert(btau::vertexJetDeltaR,VectorUtil::DeltaR(vertexSum, jetDir), true);
}
double vertexMass = vertexSum.M();
double varPi = 0;
double varB = 0;
if (vtxType == btag::Vertices::RecoVertex) {
if(vertexMassCorrection)
{
GlobalVector dir = svInfo.flightDirection(vtx);
double vertexPt2 = math::XYZVector(dir.x(), dir.y(), dir.z()).Cross(vertexSum).Mag2() / dir.mag2();
vertexMass = std::sqrt(vertexMass * vertexMass + vertexPt2) + std::sqrt(vertexPt2);
}
}
vars.insert(btau::vertexMass, vertexMass, true);
varPi = (vertexMass/5.2794) * (vtx_track_ESum /jet_track_ESum); //5.2794 should be average B meson mass of PDG! CHECK!!!
vars.insert(btau::massVertexEnergyFraction, varPi, true);
varB = (std::sqrt(5.2794) * vtx_track_ptSum) / ( vertexMass * std::sqrt(jet->pt()));
vars.insert(btau::vertexBoostOverSqrtJetPt,varB*varB/(varB*varB + 10.), true);
if (allKinematics.numberOfTracks())
vars.insert(btau::vertexEnergyRatio, vertexSum.E() / allSum.E(), true);
else
vars.insert(btau::vertexEnergyRatio, 1, true);
}
reco::PFJet const * pfJet = dynamic_cast<reco::PFJet const *>( &* jet ) ;
pat::Jet const * patJet = dynamic_cast<pat::Jet const *>( &* jet ) ;
if ( pfJet != 0 ) {
vars.insert(btau::chargedHadronEnergyFraction,pfJet->chargedHadronEnergyFraction(), true);
vars.insert(btau::neutralHadronEnergyFraction,pfJet->neutralHadronEnergyFraction(), true);
vars.insert(btau::photonEnergyFraction,pfJet->photonEnergyFraction(), true);
vars.insert(btau::electronEnergyFraction,pfJet->electronEnergyFraction(), true);
vars.insert(btau::muonEnergyFraction,pfJet->muonEnergyFraction(), true);
vars.insert(btau::chargedHadronMultiplicity,pfJet->chargedHadronMultiplicity(), true);
vars.insert(btau::neutralHadronMultiplicity,pfJet->neutralHadronMultiplicity(), true);
vars.insert(btau::photonMultiplicity,pfJet->photonMultiplicity(), true);
vars.insert(btau::electronMultiplicity,pfJet->electronMultiplicity(), true);
vars.insert(btau::muonMultiplicity,pfJet->muonMultiplicity(), true);
vars.insert(btau::hadronMultiplicity,pfJet->chargedHadronMultiplicity()+pfJet->neutralHadronMultiplicity(), true);
vars.insert(btau::hadronPhotonMultiplicity,pfJet->chargedHadronMultiplicity()+pfJet->neutralHadronMultiplicity()+pfJet->photonMultiplicity(), true);
vars.insert(btau::totalMultiplicity,pfJet->chargedHadronMultiplicity()+pfJet->neutralHadronMultiplicity()+pfJet->photonMultiplicity()+pfJet->electronMultiplicity()+pfJet->muonMultiplicity(), true);
}
else if( patJet != 0)
{
vars.insert(btau::chargedHadronEnergyFraction,patJet->chargedHadronEnergyFraction(), true);
vars.insert(btau::neutralHadronEnergyFraction,patJet->neutralHadronEnergyFraction(), true);
vars.insert(btau::photonEnergyFraction,patJet->photonEnergyFraction(), true);
vars.insert(btau::electronEnergyFraction,patJet->electronEnergyFraction(), true);
vars.insert(btau::muonEnergyFraction,patJet->muonEnergyFraction(), true);
vars.insert(btau::chargedHadronMultiplicity,patJet->chargedHadronMultiplicity(), true);
vars.insert(btau::neutralHadronMultiplicity,patJet->neutralHadronMultiplicity(), true);
vars.insert(btau::photonMultiplicity,patJet->photonMultiplicity(), true);
vars.insert(btau::electronMultiplicity,patJet->electronMultiplicity(), true);
vars.insert(btau::muonMultiplicity,patJet->muonMultiplicity(), true);
vars.insert(btau::hadronMultiplicity,patJet->chargedHadronMultiplicity()+patJet->neutralHadronMultiplicity(), true);
vars.insert(btau::hadronPhotonMultiplicity,patJet->chargedHadronMultiplicity()+patJet->neutralHadronMultiplicity()+patJet->photonMultiplicity(), true);
vars.insert(btau::totalMultiplicity,patJet->chargedHadronMultiplicity()+patJet->neutralHadronMultiplicity()+patJet->photonMultiplicity()+patJet->electronMultiplicity()+patJet->muonMultiplicity(), true);
}
else
{
throw cms::Exception("InvalidConfiguration") << "From CombinedSVSoftLeptonComputer::operator: reco::PFJet OR pat::Jet are required by this module" << std::endl;
}
int leptonCategory = 0; //0 = no lepton, 1 = muon, 2 = electron
for (unsigned int i = 0; i < muonInfo.leptons(); i++) {// loop over all muons, not optimal -> find the best or use ranking from best to worst
leptonCategory = 1; // muon category
const SoftLeptonProperties & propertiesMuon = muonInfo.properties(i);
vars.insert(btau::leptonPtRel,propertiesMuon.ptRel , true);
vars.insert(btau::leptonSip3d,propertiesMuon.sip3d , true);
vars.insert(btau::leptonDeltaR,propertiesMuon.deltaR , true);
vars.insert(btau::leptonRatioRel,propertiesMuon.ratioRel , true);
vars.insert(btau::leptonEtaRel,propertiesMuon.etaRel , true);
vars.insert(btau::leptonRatio,propertiesMuon.ratio , true);
}
if(leptonCategory != 1){ //no soft muon found, try soft electron
for (unsigned int i = 0; i < elecInfo.leptons(); i++) { // loop over all electrons, not optimal -> find the best or use ranking from best to worst
leptonCategory = 2; // electron category
const SoftLeptonProperties & propertiesElec = elecInfo.properties(i);
vars.insert(btau::leptonPtRel,propertiesElec.ptRel , true);
vars.insert(btau::leptonSip3d,propertiesElec.sip3d , true);
vars.insert(btau::leptonDeltaR,propertiesElec.deltaR , true);
vars.insert(btau::leptonRatioRel,propertiesElec.ratioRel , true);
vars.insert(btau::leptonP0Par,propertiesElec.p0Par , true);
vars.insert(btau::leptonEtaRel,propertiesElec.etaRel , true);
vars.insert(btau::leptonRatio,propertiesElec.ratio , true);
}
}
//put default value for vertexLeptonCategory on 2 = NoVertexNoSoftLepton
int vertexLepCat = 2;
if(leptonCategory == 0){ // no soft lepton
if (vtxType == btag::Vertices::RecoVertex)
vertexLepCat = 0;
else if (vtxType == btag::Vertices::PseudoVertex)
vertexLepCat = 1;
else
vertexLepCat = 2;
} else if(leptonCategory == 1){ // soft muon
if (vtxType == btag::Vertices::RecoVertex)
vertexLepCat = 3;
else if(vtxType == btag::Vertices::PseudoVertex)
vertexLepCat = 4;
else vertexLepCat = 5;
} else if(leptonCategory == 2){ // soft electron
if (vtxType == btag::Vertices::RecoVertex)
vertexLepCat = 6;
else if (vtxType == btag::Vertices::PseudoVertex)
vertexLepCat = 7;
else
vertexLepCat = 8;
}
vars.insert(btau::vertexLeptonCategory, vertexLepCat , true);
vars.finalize();
return vars;
}
| [
"pvmulder@cern.ch"
] | pvmulder@cern.ch |
70f0e2dfac6172c3de53b93b6adca04cebb030d6 | d4faf4a70781a661ef6a1ef35f106dfee5f60bb0 | /ConsoleApplication1/src/game_object.h | b710ab4990c8696ae5aff79437ff16942b19b813 | [] | no_license | zqztxdi/Opengl_game | ee9b3da084b18ce7330d30dbc8f7a1a01520fac8 | b7131937d41bc5396d5014fb0d777fcd00c0f979 | refs/heads/master | 2022-11-16T19:50:33.288653 | 2020-07-11T10:28:11 | 2020-07-11T10:28:11 | 278,837,677 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 791 | h | #pragma once
#ifndef GAMEOBJECT_H
#define GAMEOBJECT_H
#include <GL/glew.h>
#include <glm/glm.hpp>
#include "texture.h"
#include "sprite_renderer.h"
// Container object for holding all state relevant for a single
// game object entity. Each object in the game likely needs the
// minimal of state as described within GameObject.
class GameObject
{
public:
// Object state
glm::vec2 Position, Size, Velocity;
glm::vec3 Color;
GLfloat Rotation;
GLboolean IsSolid;
GLboolean Destroyed;
// Render state
Texture2D Sprite;
// Constructor(s)
GameObject();
GameObject(glm::vec2 pos, glm::vec2 size, Texture2D sprite, glm::vec3 color = glm::vec3(1.0f), glm::vec2 velocity = glm::vec2(0.0f, 0.0f));
// Draw sprite
virtual void Draw(SpriteRenderer &renderer);
};
#endif | [
"1139266767@qq.com"
] | 1139266767@qq.com |
837d4550a31dc6aeb97aa44a29c00ba4ddc2427a | 74c1a55594ac409d505a96eb57a3ce02c2dd7d93 | /leetcode/remove-duplicates-from-sorted-array/Accepted/5-11-2021, 9:16:37 PM/Solution.cpp | f89776ca8d6eb86f4c19ee78ee13850342ddb1db | [] | no_license | jungsu-kwon/ps-records | f9f201791c7a56b012d370569aba9eb1c5cb03a5 | cc909a871a0a72ce0a1c31586e9e65f969900a7b | refs/heads/master | 2023-06-28T20:52:43.492100 | 2021-08-06T04:45:21 | 2021-08-06T04:45:21 | 392,259,235 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 563 | cpp | // https://leetcode.com/problems/remove-duplicates-from-sorted-array
class Solution {
public:
int removeDuplicates(vector<int>& nums)
{
if (nums.size()<=1) return nums.size();
int write_ind = 0, read_ind = 0;
int cur = nums[0] - 1;
while (read_ind != nums.size())
{
cur = nums[read_ind];
nums[write_ind] = cur;
while (read_ind != nums.size() && cur == nums[read_ind])
read_ind++;
write_ind++;
}
return write_ind;
}
}; | [
"git@jungsu.io"
] | git@jungsu.io |
37607c873e8f01e35a33a9d53472d130ddd8f6d5 | 6059ef7bc48ab49c938f075dc5210a19ec08538e | /src/plugins/poshuku/plugins/webkitview/settingsglobalhandler.cpp | 023c6b2f77f26edbeed138271583ff391d2779ff | [
"BSL-1.0"
] | permissive | Laura-lc/leechcraft | 92b40aff06af9667aca9edd0489407ffc22db116 | 8cd066ad6a6ae5ee947919a97b2a4dc96ff00742 | refs/heads/master | 2021-01-13T19:34:09.767365 | 2020-01-11T15:25:31 | 2020-01-11T15:25:31 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 3,011 | cpp | /**********************************************************************
* LeechCraft - modular cross-platform feature rich internet client.
* Copyright (C) 2006-2014 Georg Rudoy
*
* Boost Software License - Version 1.0 - August 17th, 2003
*
* Permission is hereby granted, free of charge, to any person or organization
* obtaining a copy of the software and accompanying documentation covered by
* this license (the "Software") to use, reproduce, display, distribute,
* execute, and transmit the Software, and to prepare derivative works of the
* Software, and to permit third-parties to whom the Software is furnished to
* do so, all subject to the following:
*
* The copyright notices in the Software and this entire statement, including
* the above license grant, this restriction and the following disclaimer,
* must be included in all copies of the Software, in whole or in part, and
* all derivative works of the Software, unless such copies or derivative
* works are solely in the form of machine-executable object code generated by
* a source language processor.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
* SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
* FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
* ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
* DEALINGS IN THE SOFTWARE.
**********************************************************************/
#include "settingsglobalhandler.h"
#include <QtDebug>
#include <qwebsettings.h>
#include "xmlsettingsmanager.h"
namespace LC
{
namespace Poshuku
{
namespace WebKitView
{
SettingsGlobalHandler::SettingsGlobalHandler (QObject *parent)
: QObject { parent }
{
XmlSettingsManager::Instance ().RegisterObject ({
"MaximumPagesInCache",
"MinDeadCapacity",
"MaxDeadCapacity",
"TotalCapacity",
"OfflineStorageQuota"
},
this, "cacheSettingsChanged");
cacheSettingsChanged ();
}
void SettingsGlobalHandler::cacheSettingsChanged ()
{
auto& xsm = XmlSettingsManager::Instance ();
QWebSettings::setMaximumPagesInCache (xsm.property ("MaximumPagesInCache").toInt ());
auto megs = [&xsm] (const char *prop) { return xsm.property (prop).toDouble () * 1024 * 1024; };
QWebSettings::setObjectCacheCapacities (megs ("MinDeadCapacity"),
megs ("MaxDeadCapacity"),
megs ("TotalCapacity"));
QWebSettings::setOfflineStorageDefaultQuota (xsm.property ("OfflineStorageQuota").toInt () * 1024);
}
void SettingsGlobalHandler::handleSettingsClicked (const QString& name)
{
if (name == "ClearIconDatabase")
QWebSettings::clearIconDatabase ();
else if (name == "ClearMemoryCaches")
QWebSettings::clearMemoryCaches ();
else
qWarning () << Q_FUNC_INFO
<< "unknown button"
<< name;
}
}
}
}
| [
"0xd34df00d@gmail.com"
] | 0xd34df00d@gmail.com |
cee5c3c5f2b47f2a22fae989d8970b2a2962544e | fdc522072a2a998b40ca5695e387a428f0a2ad5a | /Link/Windows Kits/8.0/Include/winrt/Windows.Media.Streaming.h | c5677922c020bf216a42b53adf11a9374faf5023 | [] | no_license | fajaralmu/kufi-sqr-open-gl | 876d163ef4edc7d2a278ace42a9505659f13a2ca | da30611f55e29e75094a9e085c1adc6dbe9d34ee | refs/heads/master | 2021-07-12T01:41:00.349589 | 2020-10-20T06:21:48 | 2020-10-20T06:21:48 | 203,924,499 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 357,600 | h |
/* this ALWAYS GENERATED file contains the definitions for the interfaces */
/* File created by MIDL compiler version 8.00.0595 */
/* @@MIDL_FILE_HEADING( ) */
#pragma warning( disable: 4049 ) /* more than 64k source lines */
/* verify that the <rpcndr.h> version is high enough to compile this file*/
#ifndef __REQUIRED_RPCNDR_H_VERSION__
#define __REQUIRED_RPCNDR_H_VERSION__ 500
#endif
/* verify that the <rpcsal.h> version is high enough to compile this file*/
#ifndef __REQUIRED_RPCSAL_H_VERSION__
#define __REQUIRED_RPCSAL_H_VERSION__ 100
#endif
#include "rpc.h"
#include "rpcndr.h"
#ifndef __RPCNDR_H_VERSION__
#error this stub requires an updated version of <rpcndr.h>
#endif // __RPCNDR_H_VERSION__
#ifndef COM_NO_WINDOWS_H
#include "windows.h"
#include "ole2.h"
#endif /*COM_NO_WINDOWS_H*/
#ifndef __windows2Emedia2Estreaming_h__
#define __windows2Emedia2Estreaming_h__
#if defined(_MSC_VER) && (_MSC_VER >= 1020)
#pragma once
#endif
/* Forward Declarations */
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler_FWD_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler_FWD_DEFINED__
typedef interface __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler;
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
interface IConnectionStatusHandler;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
#endif /* __cplusplus */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler_FWD_DEFINED__ */
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler_FWD_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler_FWD_DEFINED__
typedef interface __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler;
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
interface IDeviceControllerFinderHandler;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
#endif /* __cplusplus */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler_FWD_DEFINED__ */
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler_FWD_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler_FWD_DEFINED__
typedef interface __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler;
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
interface ITransportParametersUpdateHandler;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
#endif /* __cplusplus */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler_FWD_DEFINED__ */
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler_FWD_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler_FWD_DEFINED__
typedef interface __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler;
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
interface IRenderingParametersUpdateHandler;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
#endif /* __cplusplus */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler_FWD_DEFINED__ */
#ifndef ____FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__
#define ____FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__
typedef interface __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice;
#endif /* ____FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__ */
#ifndef ____FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__
#define ____FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__
typedef interface __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice;
#endif /* ____FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__ */
#ifndef ____FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__
#define ____FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__
typedef interface __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice;
#endif /* ____FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__ */
#ifndef ____FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__
#define ____FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__
typedef interface __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice;
#endif /* ____FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__ */
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_FWD_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_FWD_DEFINED__
typedef interface __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController;
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
interface IDeviceController;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
#endif /* __cplusplus */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_FWD_DEFINED__ */
#ifndef ____FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__
#define ____FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__
typedef interface __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon;
#endif /* ____FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__ */
#ifndef ____FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__
#define ____FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__
typedef interface __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon;
#endif /* ____FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__ */
#ifndef ____FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__
#define ____FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__
typedef interface __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon;
#endif /* ____FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__ */
#ifndef ____FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__
#define ____FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__
typedef interface __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon;
#endif /* ____FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__ */
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_FWD_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_FWD_DEFINED__
typedef interface __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice;
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
interface IBasicDevice;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
#endif /* __cplusplus */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_FWD_DEFINED__ */
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_FWD_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_FWD_DEFINED__
typedef interface __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon;
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
interface IDeviceIcon;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
#endif /* __cplusplus */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_FWD_DEFINED__ */
#ifndef ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_FWD_DEFINED__
#define ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_FWD_DEFINED__
typedef interface __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation;
#endif /* ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_FWD_DEFINED__ */
#ifndef ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_FWD_DEFINED__
#define ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_FWD_DEFINED__
typedef interface __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation;
#endif /* ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_FWD_DEFINED__ */
#ifndef ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_FWD_DEFINED__
#define ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_FWD_DEFINED__
typedef interface __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation;
#endif /* ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_FWD_DEFINED__ */
#ifndef ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_FWD_DEFINED__
#define ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_FWD_DEFINED__
typedef interface __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation;
#endif /* ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_FWD_DEFINED__ */
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_FWD_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_FWD_DEFINED__
typedef interface __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer;
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
interface IMediaRenderer;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
#endif /* __cplusplus */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_FWD_DEFINED__ */
#ifndef ____FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__
#define ____FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__
typedef interface __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed;
#endif /* ____FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__ */
#ifndef ____FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__
#define ____FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__
typedef interface __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed;
#endif /* ____FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__ */
#ifndef ____FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__
#define ____FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__
typedef interface __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed;
#endif /* ____FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__ */
#ifndef ____FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__
#define ____FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__
typedef interface __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed;
#endif /* ____FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__ */
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_FWD_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_FWD_DEFINED__
typedef interface __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation;
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
interface IMediaRendererActionInformation;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
#endif /* __cplusplus */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_FWD_DEFINED__ */
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_FWD_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_FWD_DEFINED__
typedef interface __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters;
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
interface ITransportParameters;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
#endif /* __cplusplus */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_FWD_DEFINED__ */
#ifndef ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_FWD_DEFINED__
#define ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_FWD_DEFINED__
typedef interface __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer;
#endif /* ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_FWD_DEFINED__ */
#ifndef ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_FWD_DEFINED__
#define ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_FWD_DEFINED__
typedef interface __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer;
#endif /* ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_FWD_DEFINED__ */
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_FWD_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_FWD_DEFINED__
typedef interface __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory;
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
interface IMediaRendererFactory;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
#endif /* __cplusplus */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_FWD_DEFINED__ */
#ifndef ____FIIterator_1___F__CIPropertySet_FWD_DEFINED__
#define ____FIIterator_1___F__CIPropertySet_FWD_DEFINED__
typedef interface __FIIterator_1___F__CIPropertySet __FIIterator_1___F__CIPropertySet;
#endif /* ____FIIterator_1___F__CIPropertySet_FWD_DEFINED__ */
#ifndef ____FIIterable_1___F__CIPropertySet_FWD_DEFINED__
#define ____FIIterable_1___F__CIPropertySet_FWD_DEFINED__
typedef interface __FIIterable_1___F__CIPropertySet __FIIterable_1___F__CIPropertySet;
#endif /* ____FIIterable_1___F__CIPropertySet_FWD_DEFINED__ */
#ifndef ____FIVectorView_1___F__CIPropertySet_FWD_DEFINED__
#define ____FIVectorView_1___F__CIPropertySet_FWD_DEFINED__
typedef interface __FIVectorView_1___F__CIPropertySet __FIVectorView_1___F__CIPropertySet;
#endif /* ____FIVectorView_1___F__CIPropertySet_FWD_DEFINED__ */
#ifndef ____FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_FWD_DEFINED__
#define ____FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_FWD_DEFINED__
typedef interface __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet;
#endif /* ____FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_FWD_DEFINED__ */
#ifndef ____FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_FWD_DEFINED__
#define ____FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_FWD_DEFINED__
typedef interface __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet;
#endif /* ____FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_FWD_DEFINED__ */
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_FWD_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_FWD_DEFINED__
typedef interface __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics;
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
interface IStreamSelectorStatics;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
#endif /* __cplusplus */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_FWD_DEFINED__ */
/* header files for imported files */
#include "windows.foundation.h"
#include "Windows.Storage.Streams.h"
#ifdef __cplusplus
extern "C"{
#endif
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0000 */
/* [local] */
#ifdef __cplusplus
} /*extern "C"*/
#endif
#include <windows.foundation.collections.h>
#ifdef __cplusplus
extern "C" {
#endif
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
interface IBasicDevice;
} /*Streaming*/
} /*Media*/
} /*Windows*/
}
#endif
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0000 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0000_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0000_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0431 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0431 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0431_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0431_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0001 */
/* [local] */
#ifndef DEF___FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_USE
#define DEF___FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("84a8c766-4bc5-5757-9f1b-f61cfd9e5693"))
IIterator<ABI::Windows::Media::Streaming::IBasicDevice*> : IIterator_impl<ABI::Windows::Media::Streaming::IBasicDevice*> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IIterator`1<Windows.Media.Streaming.IBasicDevice>"; }
};
typedef IIterator<ABI::Windows::Media::Streaming::IBasicDevice*> __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_t;
#define ____FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__
#define __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice ABI::Windows::Foundation::Collections::__FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0001 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0001_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0001_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0432 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0432 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0432_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0432_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0002 */
/* [local] */
#ifndef DEF___FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_USE
#define DEF___FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("7d468b5e-763b-59cd-a086-ec6d8be0d858"))
IIterable<ABI::Windows::Media::Streaming::IBasicDevice*> : IIterable_impl<ABI::Windows::Media::Streaming::IBasicDevice*> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IIterable`1<Windows.Media.Streaming.IBasicDevice>"; }
};
typedef IIterable<ABI::Windows::Media::Streaming::IBasicDevice*> __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_t;
#define ____FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__
#define __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice ABI::Windows::Foundation::Collections::__FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0002 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0002_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0002_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0433 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0433 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0433_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0433_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0003 */
/* [local] */
#ifndef DEF___FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_USE
#define DEF___FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("a55cf16b-71a2-5525-ac3b-2f5bc1eeec46"))
IVectorView<ABI::Windows::Media::Streaming::IBasicDevice*> : IVectorView_impl<ABI::Windows::Media::Streaming::IBasicDevice*> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IVectorView`1<Windows.Media.Streaming.IBasicDevice>"; }
};
typedef IVectorView<ABI::Windows::Media::Streaming::IBasicDevice*> __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_t;
#define ____FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice ABI::Windows::Foundation::Collections::__FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0003 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0003_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0003_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0434 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0434 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0434_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0434_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0004 */
/* [local] */
#ifndef DEF___FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_USE
#define DEF___FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("4c58be45-d16f-5b3a-840d-a6b4e20b7088"))
IVector<ABI::Windows::Media::Streaming::IBasicDevice*> : IVector_impl<ABI::Windows::Media::Streaming::IBasicDevice*> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IVector`1<Windows.Media.Streaming.IBasicDevice>"; }
};
typedef IVector<ABI::Windows::Media::Streaming::IBasicDevice*> __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_t;
#define ____FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_FWD_DEFINED__
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice ABI::Windows::Foundation::Collections::__FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0004 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0004_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0004_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0435 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0435 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0435_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0435_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0005 */
/* [local] */
#ifndef DEF___FIIterator_1_HSTRING_USE
#define DEF___FIIterator_1_HSTRING_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("8c304ebb-6615-50a4-8829-879ecd443236"))
IIterator<HSTRING> : IIterator_impl<HSTRING> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IIterator`1<String>"; }
};
typedef IIterator<HSTRING> __FIIterator_1_HSTRING_t;
#define ____FIIterator_1_HSTRING_FWD_DEFINED__
#define __FIIterator_1_HSTRING ABI::Windows::Foundation::Collections::__FIIterator_1_HSTRING_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIIterator_1_HSTRING_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0005 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0005_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0005_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0436 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0436 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0436_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0436_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0006 */
/* [local] */
#ifndef DEF___FIIterable_1_HSTRING_USE
#define DEF___FIIterable_1_HSTRING_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("e2fcc7c1-3bfc-5a0b-b2b0-72e769d1cb7e"))
IIterable<HSTRING> : IIterable_impl<HSTRING> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IIterable`1<String>"; }
};
typedef IIterable<HSTRING> __FIIterable_1_HSTRING_t;
#define ____FIIterable_1_HSTRING_FWD_DEFINED__
#define __FIIterable_1_HSTRING ABI::Windows::Foundation::Collections::__FIIterable_1_HSTRING_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIIterable_1_HSTRING_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0006 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0006_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0006_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0437 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0437 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0437_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0437_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0007 */
/* [local] */
#ifndef DEF___FIVectorView_1_HSTRING_USE
#define DEF___FIVectorView_1_HSTRING_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("2f13c006-a03a-5f69-b090-75a43e33423e"))
IVectorView<HSTRING> : IVectorView_impl<HSTRING> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IVectorView`1<String>"; }
};
typedef IVectorView<HSTRING> __FIVectorView_1_HSTRING_t;
#define ____FIVectorView_1_HSTRING_FWD_DEFINED__
#define __FIVectorView_1_HSTRING ABI::Windows::Foundation::Collections::__FIVectorView_1_HSTRING_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIVectorView_1_HSTRING_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0007 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0007_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0007_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0438 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0438 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0438_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0438_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0008 */
/* [local] */
#ifndef DEF___FIVector_1_HSTRING_USE
#define DEF___FIVector_1_HSTRING_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("98b9acc1-4b56-532e-ac73-03d5291cca90"))
IVector<HSTRING> : IVector_impl<HSTRING> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IVector`1<String>"; }
};
typedef IVector<HSTRING> __FIVector_1_HSTRING_t;
#define ____FIVector_1_HSTRING_FWD_DEFINED__
#define __FIVector_1_HSTRING ABI::Windows::Foundation::Collections::__FIVector_1_HSTRING_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIVector_1_HSTRING_USE */
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
interface IDeviceIcon;
} /*Streaming*/
} /*Media*/
} /*Windows*/
}
#endif
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0008 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0008_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0008_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0439 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0439 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0439_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0439_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0009 */
/* [local] */
#ifndef DEF___FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_USE
#define DEF___FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("57fd211a-4ef0-58a0-90e2-7c3b816102c9"))
IIterator<ABI::Windows::Media::Streaming::IDeviceIcon*> : IIterator_impl<ABI::Windows::Media::Streaming::IDeviceIcon*> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IIterator`1<Windows.Media.Streaming.IDeviceIcon>"; }
};
typedef IIterator<ABI::Windows::Media::Streaming::IDeviceIcon*> __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_t;
#define ____FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__
#define __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon ABI::Windows::Foundation::Collections::__FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0009 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0009_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0009_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0440 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0440 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0440_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0440_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0010 */
/* [local] */
#ifndef DEF___FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_USE
#define DEF___FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("16077ee6-dcfc-53aa-ab0e-d666ac819d6c"))
IIterable<ABI::Windows::Media::Streaming::IDeviceIcon*> : IIterable_impl<ABI::Windows::Media::Streaming::IDeviceIcon*> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IIterable`1<Windows.Media.Streaming.IDeviceIcon>"; }
};
typedef IIterable<ABI::Windows::Media::Streaming::IDeviceIcon*> __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_t;
#define ____FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__
#define __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon ABI::Windows::Foundation::Collections::__FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0010 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0010_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0010_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0441 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0441 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0441_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0441_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0011 */
/* [local] */
#ifndef DEF___FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_USE
#define DEF___FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("ff195e52-48eb-5709-be50-3a3914c189db"))
IVectorView<ABI::Windows::Media::Streaming::IDeviceIcon*> : IVectorView_impl<ABI::Windows::Media::Streaming::IDeviceIcon*> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IVectorView`1<Windows.Media.Streaming.IDeviceIcon>"; }
};
typedef IVectorView<ABI::Windows::Media::Streaming::IDeviceIcon*> __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_t;
#define ____FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon ABI::Windows::Foundation::Collections::__FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0011 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0011_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0011_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0442 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0442 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0442_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0442_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0012 */
/* [local] */
#ifndef DEF___FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_USE
#define DEF___FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("a32d7731-05f6-55a2-930f-1cf5a12b19ae"))
IVector<ABI::Windows::Media::Streaming::IDeviceIcon*> : IVector_impl<ABI::Windows::Media::Streaming::IDeviceIcon*> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IVector`1<Windows.Media.Streaming.IDeviceIcon>"; }
};
typedef IVector<ABI::Windows::Media::Streaming::IDeviceIcon*> __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_t;
#define ____FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_FWD_DEFINED__
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon ABI::Windows::Foundation::Collections::__FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0012 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0012_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0012_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0443 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0443 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0443_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0443_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0013 */
/* [local] */
#ifndef DEF___FIAsyncOperationCompletedHandler_1_UINT32_USE
#define DEF___FIAsyncOperationCompletedHandler_1_UINT32_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation {
template <>
struct __declspec(uuid("9343b6e7-e3d2-5e4a-ab2d-2bce4919a6a4"))
IAsyncOperationCompletedHandler<UINT32> : IAsyncOperationCompletedHandler_impl<UINT32> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.AsyncOperationCompletedHandler`1<UInt32>"; }
};
typedef IAsyncOperationCompletedHandler<UINT32> __FIAsyncOperationCompletedHandler_1_UINT32_t;
#define ____FIAsyncOperationCompletedHandler_1_UINT32_FWD_DEFINED__
#define __FIAsyncOperationCompletedHandler_1_UINT32 ABI::Windows::Foundation::__FIAsyncOperationCompletedHandler_1_UINT32_t
/* ABI */ } /* Windows */ } /* Foundation */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIAsyncOperationCompletedHandler_1_UINT32_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0013 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0013_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0013_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0444 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0444 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0444_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0444_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0014 */
/* [local] */
#ifndef DEF___FIAsyncOperation_1_UINT32_USE
#define DEF___FIAsyncOperation_1_UINT32_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation {
template <>
struct __declspec(uuid("ef60385f-be78-584b-aaef-7829ada2b0de"))
IAsyncOperation<UINT32> : IAsyncOperation_impl<UINT32> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.IAsyncOperation`1<UInt32>"; }
};
typedef IAsyncOperation<UINT32> __FIAsyncOperation_1_UINT32_t;
#define ____FIAsyncOperation_1_UINT32_FWD_DEFINED__
#define __FIAsyncOperation_1_UINT32 ABI::Windows::Foundation::__FIAsyncOperation_1_UINT32_t
/* ABI */ } /* Windows */ } /* Foundation */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIAsyncOperation_1_UINT32_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0014 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0014_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0014_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0445 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0445 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0445_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0445_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0015 */
/* [local] */
#ifndef DEF___FIAsyncOperationCompletedHandler_1_boolean_USE
#define DEF___FIAsyncOperationCompletedHandler_1_boolean_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation {
template <>
struct __declspec(uuid("c1d3d1a2-ae17-5a5f-b5a2-bdcc8844889a"))
IAsyncOperationCompletedHandler<bool> : IAsyncOperationCompletedHandler_impl<ABI::Windows::Foundation::Internal::AggregateType<bool, boolean>> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.AsyncOperationCompletedHandler`1<Boolean>"; }
};
typedef IAsyncOperationCompletedHandler<bool> __FIAsyncOperationCompletedHandler_1_boolean_t;
#define ____FIAsyncOperationCompletedHandler_1_boolean_FWD_DEFINED__
#define __FIAsyncOperationCompletedHandler_1_boolean ABI::Windows::Foundation::__FIAsyncOperationCompletedHandler_1_boolean_t
/* ABI */ } /* Windows */ } /* Foundation */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIAsyncOperationCompletedHandler_1_boolean_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0015 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0015_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0015_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0446 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0446 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0446_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0446_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0016 */
/* [local] */
#ifndef DEF___FIAsyncOperation_1_boolean_USE
#define DEF___FIAsyncOperation_1_boolean_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation {
template <>
struct __declspec(uuid("cdb5efb3-5788-509d-9be1-71ccb8a3362a"))
IAsyncOperation<bool> : IAsyncOperation_impl<ABI::Windows::Foundation::Internal::AggregateType<bool, boolean>> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.IAsyncOperation`1<Boolean>"; }
};
typedef IAsyncOperation<bool> __FIAsyncOperation_1_boolean_t;
#define ____FIAsyncOperation_1_boolean_FWD_DEFINED__
#define __FIAsyncOperation_1_boolean ABI::Windows::Foundation::__FIAsyncOperation_1_boolean_t
/* ABI */ } /* Windows */ } /* Foundation */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIAsyncOperation_1_boolean_USE */
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
struct TransportInformation;
} /*Streaming*/
} /*Media*/
} /*Windows*/
}
#endif
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0016 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0016_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0016_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0447 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0447 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0447_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0447_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0017 */
/* [local] */
#ifndef DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_USE
#define DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation {
template <>
struct __declspec(uuid("9970f463-bcd0-55b9-94cd-8932d42446ca"))
IAsyncOperationCompletedHandler<struct ABI::Windows::Media::Streaming::TransportInformation> : IAsyncOperationCompletedHandler_impl<struct ABI::Windows::Media::Streaming::TransportInformation> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.AsyncOperationCompletedHandler`1<Windows.Media.Streaming.TransportInformation>"; }
};
typedef IAsyncOperationCompletedHandler<struct ABI::Windows::Media::Streaming::TransportInformation> __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_t;
#define ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_FWD_DEFINED__
#define __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation ABI::Windows::Foundation::__FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_t
/* ABI */ } /* Windows */ } /* Foundation */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0017 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0017_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0017_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0448 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0448 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0448_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0448_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0018 */
/* [local] */
#ifndef DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_USE
#define DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation {
template <>
struct __declspec(uuid("f99e7d9c-2274-5f3d-89e7-f5f862ba0334"))
IAsyncOperation<struct ABI::Windows::Media::Streaming::TransportInformation> : IAsyncOperation_impl<struct ABI::Windows::Media::Streaming::TransportInformation> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.IAsyncOperation`1<Windows.Media.Streaming.TransportInformation>"; }
};
typedef IAsyncOperation<struct ABI::Windows::Media::Streaming::TransportInformation> __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_t;
#define ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_FWD_DEFINED__
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation ABI::Windows::Foundation::__FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_t
/* ABI */ } /* Windows */ } /* Foundation */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_USE */
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
struct PositionInformation;
} /*Streaming*/
} /*Media*/
} /*Windows*/
}
#endif
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0018 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0018_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0018_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0449 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0449 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0449_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0449_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0019 */
/* [local] */
#ifndef DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_USE
#define DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation {
template <>
struct __declspec(uuid("adc7daf4-9a69-5d0b-aec8-e2ee3292d178"))
IAsyncOperationCompletedHandler<struct ABI::Windows::Media::Streaming::PositionInformation> : IAsyncOperationCompletedHandler_impl<struct ABI::Windows::Media::Streaming::PositionInformation> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.AsyncOperationCompletedHandler`1<Windows.Media.Streaming.PositionInformation>"; }
};
typedef IAsyncOperationCompletedHandler<struct ABI::Windows::Media::Streaming::PositionInformation> __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_t;
#define ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_FWD_DEFINED__
#define __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation ABI::Windows::Foundation::__FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_t
/* ABI */ } /* Windows */ } /* Foundation */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0019 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0019_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0019_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0450 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0450 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0450_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0450_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0020 */
/* [local] */
#ifndef DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_USE
#define DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation {
template <>
struct __declspec(uuid("e2b45a37-e1c1-5e80-8962-a134d7f3557c"))
IAsyncOperation<struct ABI::Windows::Media::Streaming::PositionInformation> : IAsyncOperation_impl<struct ABI::Windows::Media::Streaming::PositionInformation> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.IAsyncOperation`1<Windows.Media.Streaming.PositionInformation>"; }
};
typedef IAsyncOperation<struct ABI::Windows::Media::Streaming::PositionInformation> __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_t;
#define ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_FWD_DEFINED__
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation ABI::Windows::Foundation::__FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_t
/* ABI */ } /* Windows */ } /* Foundation */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_USE */
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
struct PlaySpeed;
} /*Streaming*/
} /*Media*/
} /*Windows*/
}
#endif
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0020 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0020_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0020_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0451 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0451 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0451_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0451_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0021 */
/* [local] */
#ifndef DEF___FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_USE
#define DEF___FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("fd051cd8-25c7-5780-9606-b35062137d21"))
IIterator<struct ABI::Windows::Media::Streaming::PlaySpeed> : IIterator_impl<struct ABI::Windows::Media::Streaming::PlaySpeed> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IIterator`1<Windows.Media.Streaming.PlaySpeed>"; }
};
typedef IIterator<struct ABI::Windows::Media::Streaming::PlaySpeed> __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_t;
#define ____FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__
#define __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed ABI::Windows::Foundation::Collections::__FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0021 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0021_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0021_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0452 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0452 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0452_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0452_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0022 */
/* [local] */
#ifndef DEF___FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_USE
#define DEF___FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("c4a17a40-8c62-5884-822b-502526970b0d"))
IIterable<struct ABI::Windows::Media::Streaming::PlaySpeed> : IIterable_impl<struct ABI::Windows::Media::Streaming::PlaySpeed> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IIterable`1<Windows.Media.Streaming.PlaySpeed>"; }
};
typedef IIterable<struct ABI::Windows::Media::Streaming::PlaySpeed> __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_t;
#define ____FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__
#define __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed ABI::Windows::Foundation::Collections::__FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0022 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0022_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0022_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0453 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0453 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0453_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0453_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0023 */
/* [local] */
#ifndef DEF___FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_USE
#define DEF___FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("1295caf3-c1da-54ea-ac66-da2c044f9eb0"))
IVectorView<struct ABI::Windows::Media::Streaming::PlaySpeed> : IVectorView_impl<struct ABI::Windows::Media::Streaming::PlaySpeed> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IVectorView`1<Windows.Media.Streaming.PlaySpeed>"; }
};
typedef IVectorView<struct ABI::Windows::Media::Streaming::PlaySpeed> __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_t;
#define ____FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__
#define __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed ABI::Windows::Foundation::Collections::__FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0023 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0023_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0023_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0454 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0454 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0454_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0454_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0024 */
/* [local] */
#ifndef DEF___FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_USE
#define DEF___FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("fde57c75-5b86-5921-8ffb-101b0a184230"))
IVector<struct ABI::Windows::Media::Streaming::PlaySpeed> : IVector_impl<struct ABI::Windows::Media::Streaming::PlaySpeed> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IVector`1<Windows.Media.Streaming.PlaySpeed>"; }
};
typedef IVector<struct ABI::Windows::Media::Streaming::PlaySpeed> __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_t;
#define ____FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_FWD_DEFINED__
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed ABI::Windows::Foundation::Collections::__FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_USE */
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
class MediaRenderer;
} /*Streaming*/
} /*Media*/
} /*Windows*/
}
#endif
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
interface IMediaRenderer;
} /*Streaming*/
} /*Media*/
} /*Windows*/
}
#endif
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0024 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0024_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0024_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0455 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0455 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0455_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0455_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0025 */
/* [local] */
#ifndef DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_USE
#define DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation {
template <>
struct __declspec(uuid("f0d971af-e054-5616-9fdf-0903b9ceb182"))
IAsyncOperationCompletedHandler<ABI::Windows::Media::Streaming::MediaRenderer*> : IAsyncOperationCompletedHandler_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::Media::Streaming::MediaRenderer*, ABI::Windows::Media::Streaming::IMediaRenderer*>> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.AsyncOperationCompletedHandler`1<Windows.Media.Streaming.MediaRenderer>"; }
};
typedef IAsyncOperationCompletedHandler<ABI::Windows::Media::Streaming::MediaRenderer*> __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_t;
#define ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_FWD_DEFINED__
#define __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer ABI::Windows::Foundation::__FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_t
/* ABI */ } /* Windows */ } /* Foundation */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0025 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0025_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0025_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0456 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0456 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0456_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0456_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0026 */
/* [local] */
#ifndef DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_USE
#define DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation {
template <>
struct __declspec(uuid("557dd3fb-4710-5059-921c-0dee68361fb5"))
IAsyncOperation<ABI::Windows::Media::Streaming::MediaRenderer*> : IAsyncOperation_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::Media::Streaming::MediaRenderer*, ABI::Windows::Media::Streaming::IMediaRenderer*>> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.IAsyncOperation`1<Windows.Media.Streaming.MediaRenderer>"; }
};
typedef IAsyncOperation<ABI::Windows::Media::Streaming::MediaRenderer*> __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_t;
#define ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_FWD_DEFINED__
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer ABI::Windows::Foundation::__FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_t
/* ABI */ } /* Windows */ } /* Foundation */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_USE */
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Storage {
namespace Streams {
interface IRandomAccessStreamWithContentType;
} /*Streams*/
} /*Storage*/
} /*Windows*/
}
#endif
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0026 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0026_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0026_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0457 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0457 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0457_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0457_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0027 */
/* [local] */
#ifndef DEF___FIAsyncOperationCompletedHandler_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType_USE
#define DEF___FIAsyncOperationCompletedHandler_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation {
template <>
struct __declspec(uuid("3dddecf4-1d39-58e8-83b1-dbed541c7f35"))
IAsyncOperationCompletedHandler<ABI::Windows::Storage::Streams::IRandomAccessStreamWithContentType*> : IAsyncOperationCompletedHandler_impl<ABI::Windows::Storage::Streams::IRandomAccessStreamWithContentType*> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.AsyncOperationCompletedHandler`1<Windows.Storage.Streams.IRandomAccessStreamWithContentType>"; }
};
typedef IAsyncOperationCompletedHandler<ABI::Windows::Storage::Streams::IRandomAccessStreamWithContentType*> __FIAsyncOperationCompletedHandler_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType_t;
#define ____FIAsyncOperationCompletedHandler_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType_FWD_DEFINED__
#define __FIAsyncOperationCompletedHandler_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType ABI::Windows::Foundation::__FIAsyncOperationCompletedHandler_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType_t
/* ABI */ } /* Windows */ } /* Foundation */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIAsyncOperationCompletedHandler_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0027 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0027_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0027_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0458 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0458 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0458_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0458_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0028 */
/* [local] */
#ifndef DEF___FIAsyncOperation_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType_USE
#define DEF___FIAsyncOperation_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation {
template <>
struct __declspec(uuid("c4a57c5e-32b0-55b3-ad13-ce1c23041ed6"))
IAsyncOperation<ABI::Windows::Storage::Streams::IRandomAccessStreamWithContentType*> : IAsyncOperation_impl<ABI::Windows::Storage::Streams::IRandomAccessStreamWithContentType*> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.IAsyncOperation`1<Windows.Storage.Streams.IRandomAccessStreamWithContentType>"; }
};
typedef IAsyncOperation<ABI::Windows::Storage::Streams::IRandomAccessStreamWithContentType*> __FIAsyncOperation_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType_t;
#define ____FIAsyncOperation_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType_FWD_DEFINED__
#define __FIAsyncOperation_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType ABI::Windows::Foundation::__FIAsyncOperation_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType_t
/* ABI */ } /* Windows */ } /* Foundation */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIAsyncOperation_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType_USE */
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Foundation {
namespace Collections {
interface IPropertySet;
} /*Collections*/
} /*Foundation*/
} /*Windows*/
}
#endif
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0028 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0028_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0028_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0459 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0459 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0459_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0459_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0029 */
/* [local] */
#ifndef DEF___FIIterator_1___F__CIPropertySet_USE
#define DEF___FIIterator_1___F__CIPropertySet_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("d79a75c8-b1d2-544d-9b09-7f7900a34efb"))
IIterator<ABI::Windows::Foundation::Collections::IPropertySet*> : IIterator_impl<ABI::Windows::Foundation::Collections::IPropertySet*> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IIterator`1<Windows.Foundation.Collections.IPropertySet>"; }
};
typedef IIterator<ABI::Windows::Foundation::Collections::IPropertySet*> __FIIterator_1___F__CIPropertySet_t;
#define ____FIIterator_1___F__CIPropertySet_FWD_DEFINED__
#define __FIIterator_1___F__CIPropertySet ABI::Windows::Foundation::Collections::__FIIterator_1___F__CIPropertySet_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIIterator_1___F__CIPropertySet_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0029 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0029_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0029_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0460 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0460 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0460_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0460_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0030 */
/* [local] */
#ifndef DEF___FIIterable_1___F__CIPropertySet_USE
#define DEF___FIIterable_1___F__CIPropertySet_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("489b756d-be43-5abb-b9a0-a47254103339"))
IIterable<ABI::Windows::Foundation::Collections::IPropertySet*> : IIterable_impl<ABI::Windows::Foundation::Collections::IPropertySet*> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IIterable`1<Windows.Foundation.Collections.IPropertySet>"; }
};
typedef IIterable<ABI::Windows::Foundation::Collections::IPropertySet*> __FIIterable_1___F__CIPropertySet_t;
#define ____FIIterable_1___F__CIPropertySet_FWD_DEFINED__
#define __FIIterable_1___F__CIPropertySet ABI::Windows::Foundation::Collections::__FIIterable_1___F__CIPropertySet_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIIterable_1___F__CIPropertySet_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0030 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0030_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0030_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0461 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0461 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0461_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0461_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0031 */
/* [local] */
#ifndef DEF___FIVectorView_1___F__CIPropertySet_USE
#define DEF___FIVectorView_1___F__CIPropertySet_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation { namespace Collections {
template <>
struct __declspec(uuid("c25d9a17-c31e-5311-8122-3c04d28af9fc"))
IVectorView<ABI::Windows::Foundation::Collections::IPropertySet*> : IVectorView_impl<ABI::Windows::Foundation::Collections::IPropertySet*> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.Collections.IVectorView`1<Windows.Foundation.Collections.IPropertySet>"; }
};
typedef IVectorView<ABI::Windows::Foundation::Collections::IPropertySet*> __FIVectorView_1___F__CIPropertySet_t;
#define ____FIVectorView_1___F__CIPropertySet_FWD_DEFINED__
#define __FIVectorView_1___F__CIPropertySet ABI::Windows::Foundation::Collections::__FIVectorView_1___F__CIPropertySet_t
/* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIVectorView_1___F__CIPropertySet_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0031 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0031_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0031_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0462 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0462 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0462_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0462_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0032 */
/* [local] */
#ifndef DEF___FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_USE
#define DEF___FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation {
template <>
struct __declspec(uuid("af4e2f8a-92ca-5640-865c-9948fbde4495"))
IAsyncOperationCompletedHandler<__FIVectorView_1___F__CIPropertySet*> : IAsyncOperationCompletedHandler_impl<__FIVectorView_1___F__CIPropertySet*> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.AsyncOperationCompletedHandler`1<Windows.Foundation.Collections.IVectorView`1<Windows.Foundation.Collections.IPropertySet>>"; }
};
typedef IAsyncOperationCompletedHandler<__FIVectorView_1___F__CIPropertySet*> __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_t;
#define ____FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_FWD_DEFINED__
#define __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet ABI::Windows::Foundation::__FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_t
/* ABI */ } /* Windows */ } /* Foundation */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_USE */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0032 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0032_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0032_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0463 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0463 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0463_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0463_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0033 */
/* [local] */
#ifndef DEF___FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_USE
#define DEF___FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_USE
#if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME)
} /*extern "C"*/
namespace ABI { namespace Windows { namespace Foundation {
template <>
struct __declspec(uuid("216f9390-ea3d-5465-a789-6394a47eb4a4"))
IAsyncOperation<__FIVectorView_1___F__CIPropertySet*> : IAsyncOperation_impl<__FIVectorView_1___F__CIPropertySet*> {
static const wchar_t* z_get_rc_name_impl() {
return L"Windows.Foundation.IAsyncOperation`1<Windows.Foundation.Collections.IVectorView`1<Windows.Foundation.Collections.IPropertySet>>"; }
};
typedef IAsyncOperation<__FIVectorView_1___F__CIPropertySet*> __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_t;
#define ____FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_FWD_DEFINED__
#define __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet ABI::Windows::Foundation::__FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_t
/* ABI */ } /* Windows */ } /* Foundation */ }
extern "C" {
#endif //__cplusplus
#endif /* DEF___FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_USE */
#pragma warning(push)
#pragma warning(disable:4001)
#pragma once
#pragma warning(pop)
#if !defined(__cplusplus)
#if !defined(__cplusplus)
typedef /* [v1_enum][v1_enum] */
enum __x_ABI_CWindows_CMedia_CStreaming_CDeviceTypes
{
DeviceTypes_Unknown = 0,
DeviceTypes_DigitalMediaRenderer = 0x1,
DeviceTypes_DigitalMediaServer = 0x2,
DeviceTypes_DigitalMediaPlayer = 0x4
} __x_ABI_CWindows_CMedia_CStreaming_CDeviceTypes;
#endif /* end if !defined(__cplusplus) */
#else
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
typedef enum DeviceTypes DeviceTypes;
DEFINE_ENUM_FLAG_OPERATORS(DeviceTypes)
} /*Streaming*/
} /*Media*/
} /*Windows*/
}
#endif
#if !defined(__cplusplus)
#if !defined(__cplusplus)
typedef /* [v1_enum][v1_enum] */
enum __x_ABI_CWindows_CMedia_CStreaming_CTransportState
{
TransportState_Unknown = 0,
TransportState_Stopped = ( TransportState_Unknown + 1 ) ,
TransportState_Playing = ( TransportState_Stopped + 1 ) ,
TransportState_Transitioning = ( TransportState_Playing + 1 ) ,
TransportState_Paused = ( TransportState_Transitioning + 1 ) ,
TransportState_Recording = ( TransportState_Paused + 1 ) ,
TransportState_NoMediaPresent = ( TransportState_Recording + 1 ) ,
TransportState_Last = ( TransportState_NoMediaPresent + 1 )
} __x_ABI_CWindows_CMedia_CStreaming_CTransportState;
#endif /* end if !defined(__cplusplus) */
#endif
#if !defined(__cplusplus)
#if !defined(__cplusplus)
typedef /* [v1_enum][v1_enum] */
enum __x_ABI_CWindows_CMedia_CStreaming_CTransportStatus
{
TransportStatus_Unknown = 0,
TransportStatus_Ok = ( TransportStatus_Unknown + 1 ) ,
TransportStatus_ErrorOccurred = ( TransportStatus_Ok + 1 ) ,
TransportStatus_Last = ( TransportStatus_ErrorOccurred + 1 )
} __x_ABI_CWindows_CMedia_CStreaming_CTransportStatus;
#endif /* end if !defined(__cplusplus) */
#endif
#if !defined(__cplusplus)
#if !defined(__cplusplus)
typedef /* [v1_enum][v1_enum] */
enum __x_ABI_CWindows_CMedia_CStreaming_CConnectionStatus
{
ConnectionStatus_Online = 0,
ConnectionStatus_Offline = ( ConnectionStatus_Online + 1 ) ,
ConnectionStatus_Sleeping = ( ConnectionStatus_Offline + 1 )
} __x_ABI_CWindows_CMedia_CStreaming_CConnectionStatus;
#endif /* end if !defined(__cplusplus) */
#endif
#if !defined(__cplusplus)
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CRenderingParameters
{
UINT volume;
boolean mute;
} __x_ABI_CWindows_CMedia_CStreaming_CRenderingParameters;
#endif
#if !defined(__cplusplus)
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed
{
INT32 Numerator;
UINT32 Denominator;
} __x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed;
#endif
#if !defined(__cplusplus)
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CTransportInformation
{
__x_ABI_CWindows_CMedia_CStreaming_CTransportState CurrentTransportState;
__x_ABI_CWindows_CMedia_CStreaming_CTransportStatus CurrentTransportStatus;
__x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed CurrentSpeed;
} __x_ABI_CWindows_CMedia_CStreaming_CTransportInformation;
#endif
typedef UINT32 __x_ABI_CWindows_CMedia_CStreaming_CTrackId;
#if !defined(__cplusplus)
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CTrackInformation
{
UINT32 Track;
__x_ABI_CWindows_CMedia_CStreaming_CTrackId TrackId;
__x_ABI_CWindows_CFoundation_CTimeSpan TrackDuration;
} __x_ABI_CWindows_CMedia_CStreaming_CTrackInformation;
#endif
#if !defined(__cplusplus)
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CPositionInformation
{
__x_ABI_CWindows_CMedia_CStreaming_CTrackInformation trackInformation;
__x_ABI_CWindows_CFoundation_CTimeSpan relativeTime;
} __x_ABI_CWindows_CMedia_CStreaming_CPositionInformation;
#endif
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0033 */
/* [local] */
#ifdef __cplusplus
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
typedef /* [v1_enum][v1_enum] */
enum DeviceTypes
{
DeviceTypes_Unknown = 0,
DeviceTypes_DigitalMediaRenderer = 0x1,
DeviceTypes_DigitalMediaServer = 0x2,
DeviceTypes_DigitalMediaPlayer = 0x4
} DeviceTypes;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#endif
#ifdef __cplusplus
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
typedef /* [v1_enum][v1_enum] */
enum TransportState
{
TransportState_Unknown = 0,
TransportState_Stopped = ( TransportState_Unknown + 1 ) ,
TransportState_Playing = ( TransportState_Stopped + 1 ) ,
TransportState_Transitioning = ( TransportState_Playing + 1 ) ,
TransportState_Paused = ( TransportState_Transitioning + 1 ) ,
TransportState_Recording = ( TransportState_Paused + 1 ) ,
TransportState_NoMediaPresent = ( TransportState_Recording + 1 ) ,
TransportState_Last = ( TransportState_NoMediaPresent + 1 )
} TransportState;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#endif
#ifdef __cplusplus
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
typedef /* [v1_enum][v1_enum] */
enum TransportStatus
{
TransportStatus_Unknown = 0,
TransportStatus_Ok = ( TransportStatus_Unknown + 1 ) ,
TransportStatus_ErrorOccurred = ( TransportStatus_Ok + 1 ) ,
TransportStatus_Last = ( TransportStatus_ErrorOccurred + 1 )
} TransportStatus;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#endif
#ifdef __cplusplus
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
typedef /* [v1_enum][v1_enum] */
enum ConnectionStatus
{
ConnectionStatus_Online = 0,
ConnectionStatus_Offline = ( ConnectionStatus_Online + 1 ) ,
ConnectionStatus_Sleeping = ( ConnectionStatus_Offline + 1 )
} ConnectionStatus;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#endif
#ifdef __cplusplus
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
typedef struct RenderingParameters
{
UINT volume;
boolean mute;
} RenderingParameters;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#endif
#ifdef __cplusplus
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
typedef struct PlaySpeed
{
INT32 Numerator;
UINT32 Denominator;
} PlaySpeed;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#endif
#ifdef __cplusplus
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
typedef struct TransportInformation
{
TransportState CurrentTransportState;
TransportStatus CurrentTransportStatus;
PlaySpeed CurrentSpeed;
} TransportInformation;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#endif
#ifdef __cplusplus
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
typedef UINT32 TrackId;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#endif
#ifdef __cplusplus
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
typedef struct TrackInformation
{
UINT32 Track;
TrackId TrackId;
ABI::Windows::Foundation::TimeSpan TrackDuration;
} TrackInformation;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#endif
#ifdef __cplusplus
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
typedef struct PositionInformation
{
TrackInformation trackInformation;
ABI::Windows::Foundation::TimeSpan relativeTime;
} PositionInformation;
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#endif
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0033_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0033_v0_0_s_ifspec;
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler_INTERFACE_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler_INTERFACE_DEFINED__
/* interface __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler */
/* [uuid][object] */
/* interface ABI::Windows::Media::Streaming::IConnectionStatusHandler */
/* [uuid][object] */
EXTERN_C const IID IID___x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler;
#if defined(__cplusplus) && !defined(CINTERFACE)
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
MIDL_INTERFACE("b571c28c-a472-48d5-88d2-8adcaf1b8813")
IConnectionStatusHandler : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE Invoke(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IBasicDevice *sender,
/* [in] */ ABI::Windows::Media::Streaming::ConnectionStatus arg) = 0;
};
extern const __declspec(selectany) IID & IID_IConnectionStatusHandler = __uuidof(IConnectionStatusHandler);
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#else /* C style interface */
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandlerVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler * This);
HRESULT ( STDMETHODCALLTYPE *Invoke )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice *sender,
/* [in] */ __x_ABI_CWindows_CMedia_CStreaming_CConnectionStatus arg);
END_INTERFACE
} __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandlerVtbl;
interface __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler
{
CONST_VTBL struct __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandlerVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler_Invoke(This,sender,arg) \
( (This)->lpVtbl -> Invoke(This,sender,arg) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler_INTERFACE_DEFINED__ */
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler_INTERFACE_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler_INTERFACE_DEFINED__
/* interface __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler */
/* [uuid][object] */
/* interface ABI::Windows::Media::Streaming::IDeviceControllerFinderHandler */
/* [uuid][object] */
EXTERN_C const IID IID___x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler;
#if defined(__cplusplus) && !defined(CINTERFACE)
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
MIDL_INTERFACE("a88a7d06-988c-4403-9d8a-015bed140b34")
IDeviceControllerFinderHandler : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE Invoke(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IDeviceController *sender,
/* [in] */ __RPC__in HSTRING uniqueDeviceName,
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IBasicDevice *device) = 0;
};
extern const __declspec(selectany) IID & IID_IDeviceControllerFinderHandler = __uuidof(IDeviceControllerFinderHandler);
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#else /* C style interface */
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandlerVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler * This);
HRESULT ( STDMETHODCALLTYPE *Invoke )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController *sender,
/* [in] */ __RPC__in HSTRING uniqueDeviceName,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice *device);
END_INTERFACE
} __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandlerVtbl;
interface __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler
{
CONST_VTBL struct __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandlerVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler_Invoke(This,sender,uniqueDeviceName,device) \
( (This)->lpVtbl -> Invoke(This,sender,uniqueDeviceName,device) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler_INTERFACE_DEFINED__ */
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler_INTERFACE_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler_INTERFACE_DEFINED__
/* interface __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler */
/* [uuid][object] */
/* interface ABI::Windows::Media::Streaming::ITransportParametersUpdateHandler */
/* [uuid][object] */
EXTERN_C const IID IID___x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler;
#if defined(__cplusplus) && !defined(CINTERFACE)
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
MIDL_INTERFACE("16fd02d5-da61-49d7-aab2-76867dd42db7")
ITransportParametersUpdateHandler : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE Invoke(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IMediaRenderer *sender,
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::ITransportParameters *arg) = 0;
};
extern const __declspec(selectany) IID & IID_ITransportParametersUpdateHandler = __uuidof(ITransportParametersUpdateHandler);
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#else /* C style interface */
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandlerVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler * This);
HRESULT ( STDMETHODCALLTYPE *Invoke )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer *sender,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters *arg);
END_INTERFACE
} __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandlerVtbl;
interface __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler
{
CONST_VTBL struct __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandlerVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler_Invoke(This,sender,arg) \
( (This)->lpVtbl -> Invoke(This,sender,arg) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler_INTERFACE_DEFINED__ */
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler_INTERFACE_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler_INTERFACE_DEFINED__
/* interface __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler */
/* [uuid][object] */
/* interface ABI::Windows::Media::Streaming::IRenderingParametersUpdateHandler */
/* [uuid][object] */
EXTERN_C const IID IID___x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler;
#if defined(__cplusplus) && !defined(CINTERFACE)
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
MIDL_INTERFACE("3a2d9d45-72e9-4311-b46c-27c8bb7e6cb3")
IRenderingParametersUpdateHandler : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE Invoke(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IMediaRenderer *sender,
/* [in] */ ABI::Windows::Media::Streaming::RenderingParameters arg) = 0;
};
extern const __declspec(selectany) IID & IID_IRenderingParametersUpdateHandler = __uuidof(IRenderingParametersUpdateHandler);
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#else /* C style interface */
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandlerVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler * This);
HRESULT ( STDMETHODCALLTYPE *Invoke )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer *sender,
/* [in] */ __x_ABI_CWindows_CMedia_CStreaming_CRenderingParameters arg);
END_INTERFACE
} __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandlerVtbl;
interface __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler
{
CONST_VTBL struct __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandlerVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler_Invoke(This,sender,arg) \
( (This)->lpVtbl -> Invoke(This,sender,arg) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0464 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0464 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0464_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0464_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0038 */
/* [local] */
#ifndef DEF___FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice
#define DEF___FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0038 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0038_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0038_v0_0_s_ifspec;
#ifndef ____FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_INTERFACE_DEFINED__
#define ____FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_INTERFACE_DEFINED__
/* interface __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice */
/* [unique][uuid][object] */
/* interface __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("84a8c766-4bc5-5757-9f1b-f61cfd9e5693")
__FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice : public IInspectable
{
public:
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Current(
/* [retval][out] */ __RPC__deref_out_opt ABI::Windows::Media::Streaming::IBasicDevice **current) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_HasCurrent(
/* [retval][out] */ __RPC__out boolean *hasCurrent) = 0;
virtual HRESULT STDMETHODCALLTYPE MoveNext(
/* [retval][out] */ __RPC__out boolean *hasCurrent) = 0;
virtual HRESULT STDMETHODCALLTYPE GetMany(
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) ABI::Windows::Media::Streaming::IBasicDevice **items,
/* [retval][out] */ __RPC__out unsigned int *actual) = 0;
};
#else /* C style interface */
typedef struct __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDeviceVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Current )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [retval][out] */ __RPC__deref_out_opt __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice **current);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_HasCurrent )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [retval][out] */ __RPC__out boolean *hasCurrent);
HRESULT ( STDMETHODCALLTYPE *MoveNext )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [retval][out] */ __RPC__out boolean *hasCurrent);
HRESULT ( STDMETHODCALLTYPE *GetMany )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice **items,
/* [retval][out] */ __RPC__out unsigned int *actual);
END_INTERFACE
} __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDeviceVtbl;
interface __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice
{
CONST_VTBL struct __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDeviceVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_get_Current(This,current) \
( (This)->lpVtbl -> get_Current(This,current) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_get_HasCurrent(This,hasCurrent) \
( (This)->lpVtbl -> get_HasCurrent(This,hasCurrent) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_MoveNext(This,hasCurrent) \
( (This)->lpVtbl -> MoveNext(This,hasCurrent) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_GetMany(This,capacity,items,actual) \
( (This)->lpVtbl -> GetMany(This,capacity,items,actual) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0039 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0039 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0039_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0039_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0465 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0465 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0465_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0465_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0040 */
/* [local] */
#ifndef DEF___FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice
#define DEF___FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0040 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0040_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0040_v0_0_s_ifspec;
#ifndef ____FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_INTERFACE_DEFINED__
#define ____FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_INTERFACE_DEFINED__
/* interface __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice */
/* [unique][uuid][object] */
/* interface __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("7d468b5e-763b-59cd-a086-ec6d8be0d858")
__FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice : public IInspectable
{
public:
virtual HRESULT STDMETHODCALLTYPE First(
/* [retval][out] */ __RPC__deref_out_opt __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice **first) = 0;
};
#else /* C style interface */
typedef struct __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDeviceVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
HRESULT ( STDMETHODCALLTYPE *First )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [retval][out] */ __RPC__deref_out_opt __FIIterator_1_Windows__CMedia__CStreaming__CIBasicDevice **first);
END_INTERFACE
} __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDeviceVtbl;
interface __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice
{
CONST_VTBL struct __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDeviceVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_First(This,first) \
( (This)->lpVtbl -> First(This,first) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0041 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIIterable_1_Windows__CMedia__CStreaming__CIBasicDevice */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0041 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0041_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0041_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0466 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0466 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0466_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0466_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0042 */
/* [local] */
#ifndef DEF___FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice
#define DEF___FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0042 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0042_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0042_v0_0_s_ifspec;
#ifndef ____FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_INTERFACE_DEFINED__
#define ____FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_INTERFACE_DEFINED__
/* interface __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice */
/* [unique][uuid][object] */
/* interface __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("a55cf16b-71a2-5525-ac3b-2f5bc1eeec46")
__FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice : public IInspectable
{
public:
virtual HRESULT STDMETHODCALLTYPE GetAt(
/* [in] */ unsigned int index,
/* [retval][out] */ __RPC__deref_out_opt ABI::Windows::Media::Streaming::IBasicDevice **item) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Size(
/* [retval][out] */ __RPC__out unsigned int *size) = 0;
virtual HRESULT STDMETHODCALLTYPE IndexOf(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IBasicDevice *item,
/* [out] */ __RPC__out unsigned int *index,
/* [retval][out] */ __RPC__out boolean *found) = 0;
virtual HRESULT STDMETHODCALLTYPE GetMany(
/* [in] */ unsigned int startIndex,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) ABI::Windows::Media::Streaming::IBasicDevice **items,
/* [retval][out] */ __RPC__out unsigned int *actual) = 0;
};
#else /* C style interface */
typedef struct __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDeviceVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
HRESULT ( STDMETHODCALLTYPE *GetAt )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ unsigned int index,
/* [retval][out] */ __RPC__deref_out_opt __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice **item);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Size )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [retval][out] */ __RPC__out unsigned int *size);
HRESULT ( STDMETHODCALLTYPE *IndexOf )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice *item,
/* [out] */ __RPC__out unsigned int *index,
/* [retval][out] */ __RPC__out boolean *found);
HRESULT ( STDMETHODCALLTYPE *GetMany )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ unsigned int startIndex,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice **items,
/* [retval][out] */ __RPC__out unsigned int *actual);
END_INTERFACE
} __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDeviceVtbl;
interface __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice
{
CONST_VTBL struct __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDeviceVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_GetAt(This,index,item) \
( (This)->lpVtbl -> GetAt(This,index,item) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_get_Size(This,size) \
( (This)->lpVtbl -> get_Size(This,size) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_IndexOf(This,item,index,found) \
( (This)->lpVtbl -> IndexOf(This,item,index,found) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_GetMany(This,startIndex,capacity,items,actual) \
( (This)->lpVtbl -> GetMany(This,startIndex,capacity,items,actual) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0043 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0043 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0043_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0043_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0467 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0467 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0467_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0467_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0044 */
/* [local] */
#ifndef DEF___FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice
#define DEF___FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0044 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0044_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0044_v0_0_s_ifspec;
#ifndef ____FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_INTERFACE_DEFINED__
#define ____FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_INTERFACE_DEFINED__
/* interface __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice */
/* [unique][uuid][object] */
/* interface __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("4c58be45-d16f-5b3a-840d-a6b4e20b7088")
__FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice : public IInspectable
{
public:
virtual HRESULT STDMETHODCALLTYPE GetAt(
/* [in] */ unsigned int index,
/* [retval][out] */ __RPC__deref_out_opt ABI::Windows::Media::Streaming::IBasicDevice **item) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Size(
/* [retval][out] */ __RPC__out unsigned int *size) = 0;
virtual HRESULT STDMETHODCALLTYPE GetView(
/* [retval][out] */ __RPC__deref_out_opt __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice **view) = 0;
virtual HRESULT STDMETHODCALLTYPE IndexOf(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IBasicDevice *item,
/* [out] */ __RPC__out unsigned int *index,
/* [retval][out] */ __RPC__out boolean *found) = 0;
virtual HRESULT STDMETHODCALLTYPE SetAt(
/* [in] */ unsigned int index,
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IBasicDevice *item) = 0;
virtual HRESULT STDMETHODCALLTYPE InsertAt(
/* [in] */ unsigned int index,
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IBasicDevice *item) = 0;
virtual HRESULT STDMETHODCALLTYPE RemoveAt(
/* [in] */ unsigned int index) = 0;
virtual HRESULT STDMETHODCALLTYPE Append(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IBasicDevice *item) = 0;
virtual HRESULT STDMETHODCALLTYPE RemoveAtEnd( void) = 0;
virtual HRESULT STDMETHODCALLTYPE Clear( void) = 0;
virtual HRESULT STDMETHODCALLTYPE GetMany(
/* [in] */ unsigned int startIndex,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) ABI::Windows::Media::Streaming::IBasicDevice **items,
/* [retval][out] */ __RPC__out unsigned int *actual) = 0;
virtual HRESULT STDMETHODCALLTYPE ReplaceAll(
/* [in] */ unsigned int count,
/* [size_is][in] */ __RPC__in_ecount_full(count) ABI::Windows::Media::Streaming::IBasicDevice **value) = 0;
};
#else /* C style interface */
typedef struct __FIVector_1_Windows__CMedia__CStreaming__CIBasicDeviceVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
HRESULT ( STDMETHODCALLTYPE *GetAt )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ unsigned int index,
/* [retval][out] */ __RPC__deref_out_opt __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice **item);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Size )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [retval][out] */ __RPC__out unsigned int *size);
HRESULT ( STDMETHODCALLTYPE *GetView )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [retval][out] */ __RPC__deref_out_opt __FIVectorView_1_Windows__CMedia__CStreaming__CIBasicDevice **view);
HRESULT ( STDMETHODCALLTYPE *IndexOf )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice *item,
/* [out] */ __RPC__out unsigned int *index,
/* [retval][out] */ __RPC__out boolean *found);
HRESULT ( STDMETHODCALLTYPE *SetAt )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ unsigned int index,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice *item);
HRESULT ( STDMETHODCALLTYPE *InsertAt )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ unsigned int index,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice *item);
HRESULT ( STDMETHODCALLTYPE *RemoveAt )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ unsigned int index);
HRESULT ( STDMETHODCALLTYPE *Append )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice *item);
HRESULT ( STDMETHODCALLTYPE *RemoveAtEnd )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This);
HRESULT ( STDMETHODCALLTYPE *Clear )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This);
HRESULT ( STDMETHODCALLTYPE *GetMany )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ unsigned int startIndex,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice **items,
/* [retval][out] */ __RPC__out unsigned int *actual);
HRESULT ( STDMETHODCALLTYPE *ReplaceAll )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice * This,
/* [in] */ unsigned int count,
/* [size_is][in] */ __RPC__in_ecount_full(count) __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice **value);
END_INTERFACE
} __FIVector_1_Windows__CMedia__CStreaming__CIBasicDeviceVtbl;
interface __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice
{
CONST_VTBL struct __FIVector_1_Windows__CMedia__CStreaming__CIBasicDeviceVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_GetAt(This,index,item) \
( (This)->lpVtbl -> GetAt(This,index,item) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_get_Size(This,size) \
( (This)->lpVtbl -> get_Size(This,size) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_GetView(This,view) \
( (This)->lpVtbl -> GetView(This,view) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_IndexOf(This,item,index,found) \
( (This)->lpVtbl -> IndexOf(This,item,index,found) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_SetAt(This,index,item) \
( (This)->lpVtbl -> SetAt(This,index,item) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_InsertAt(This,index,item) \
( (This)->lpVtbl -> InsertAt(This,index,item) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_RemoveAt(This,index) \
( (This)->lpVtbl -> RemoveAt(This,index) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_Append(This,item) \
( (This)->lpVtbl -> Append(This,item) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_RemoveAtEnd(This) \
( (This)->lpVtbl -> RemoveAtEnd(This) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_Clear(This) \
( (This)->lpVtbl -> Clear(This) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_GetMany(This,startIndex,capacity,items,actual) \
( (This)->lpVtbl -> GetMany(This,startIndex,capacity,items,actual) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_ReplaceAll(This,count,value) \
( (This)->lpVtbl -> ReplaceAll(This,count,value) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0045 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice */
#if !defined(____x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_INTERFACE_DEFINED__)
extern const __declspec(selectany) WCHAR InterfaceName_Windows_Media_Streaming_IDeviceController[] = L"Windows.Media.Streaming.IDeviceController";
#endif /* !defined(____x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_INTERFACE_DEFINED__) */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0045 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0045_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0045_v0_0_s_ifspec;
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_INTERFACE_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_INTERFACE_DEFINED__
/* interface __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController */
/* [uuid][object] */
/* interface ABI::Windows::Media::Streaming::IDeviceController */
/* [uuid][object] */
EXTERN_C const IID IID___x_ABI_CWindows_CMedia_CStreaming_CIDeviceController;
#if defined(__cplusplus) && !defined(CINTERFACE)
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
MIDL_INTERFACE("4feeb26d-50a7-402b-896a-be95064d6bff")
IDeviceController : public IInspectable
{
public:
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_CachedDevices(
/* [out][retval] */ __RPC__deref_out_opt __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice **value) = 0;
virtual HRESULT STDMETHODCALLTYPE AddDevice(
/* [in] */ __RPC__in HSTRING uniqueDeviceName) = 0;
virtual HRESULT STDMETHODCALLTYPE RemoveDevice(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IBasicDevice *device) = 0;
virtual HRESULT STDMETHODCALLTYPE add_DeviceArrival(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IDeviceControllerFinderHandler *handler,
/* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0;
virtual HRESULT STDMETHODCALLTYPE remove_DeviceArrival(
/* [in] */ EventRegistrationToken token) = 0;
virtual HRESULT STDMETHODCALLTYPE add_DeviceDeparture(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IDeviceControllerFinderHandler *handler,
/* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0;
virtual HRESULT STDMETHODCALLTYPE remove_DeviceDeparture(
/* [in] */ EventRegistrationToken token) = 0;
};
extern const __declspec(selectany) IID & IID_IDeviceController = __uuidof(IDeviceController);
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#else /* C style interface */
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_CachedDevices )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController * This,
/* [out][retval] */ __RPC__deref_out_opt __FIVector_1_Windows__CMedia__CStreaming__CIBasicDevice **value);
HRESULT ( STDMETHODCALLTYPE *AddDevice )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController * This,
/* [in] */ __RPC__in HSTRING uniqueDeviceName);
HRESULT ( STDMETHODCALLTYPE *RemoveDevice )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice *device);
HRESULT ( STDMETHODCALLTYPE *add_DeviceArrival )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler *handler,
/* [out][retval] */ __RPC__out EventRegistrationToken *token);
HRESULT ( STDMETHODCALLTYPE *remove_DeviceArrival )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController * This,
/* [in] */ EventRegistrationToken token);
HRESULT ( STDMETHODCALLTYPE *add_DeviceDeparture )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerFinderHandler *handler,
/* [out][retval] */ __RPC__out EventRegistrationToken *token);
HRESULT ( STDMETHODCALLTYPE *remove_DeviceDeparture )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController * This,
/* [in] */ EventRegistrationToken token);
END_INTERFACE
} __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerVtbl;
interface __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController
{
CONST_VTBL struct __x_ABI_CWindows_CMedia_CStreaming_CIDeviceControllerVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_get_CachedDevices(This,value) \
( (This)->lpVtbl -> get_CachedDevices(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_AddDevice(This,uniqueDeviceName) \
( (This)->lpVtbl -> AddDevice(This,uniqueDeviceName) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_RemoveDevice(This,device) \
( (This)->lpVtbl -> RemoveDevice(This,device) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_add_DeviceArrival(This,handler,token) \
( (This)->lpVtbl -> add_DeviceArrival(This,handler,token) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_remove_DeviceArrival(This,token) \
( (This)->lpVtbl -> remove_DeviceArrival(This,token) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_add_DeviceDeparture(This,handler,token) \
( (This)->lpVtbl -> add_DeviceDeparture(This,handler,token) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_remove_DeviceDeparture(This,token) \
( (This)->lpVtbl -> remove_DeviceDeparture(This,token) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceController_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0468 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0468 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0468_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0468_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0047 */
/* [local] */
#ifndef DEF___FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon
#define DEF___FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0047 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0047_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0047_v0_0_s_ifspec;
#ifndef ____FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_INTERFACE_DEFINED__
#define ____FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_INTERFACE_DEFINED__
/* interface __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon */
/* [unique][uuid][object] */
/* interface __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("57fd211a-4ef0-58a0-90e2-7c3b816102c9")
__FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon : public IInspectable
{
public:
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Current(
/* [retval][out] */ __RPC__deref_out_opt ABI::Windows::Media::Streaming::IDeviceIcon **current) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_HasCurrent(
/* [retval][out] */ __RPC__out boolean *hasCurrent) = 0;
virtual HRESULT STDMETHODCALLTYPE MoveNext(
/* [retval][out] */ __RPC__out boolean *hasCurrent) = 0;
virtual HRESULT STDMETHODCALLTYPE GetMany(
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) ABI::Windows::Media::Streaming::IDeviceIcon **items,
/* [retval][out] */ __RPC__out unsigned int *actual) = 0;
};
#else /* C style interface */
typedef struct __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIconVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Current )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [retval][out] */ __RPC__deref_out_opt __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon **current);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_HasCurrent )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [retval][out] */ __RPC__out boolean *hasCurrent);
HRESULT ( STDMETHODCALLTYPE *MoveNext )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [retval][out] */ __RPC__out boolean *hasCurrent);
HRESULT ( STDMETHODCALLTYPE *GetMany )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon **items,
/* [retval][out] */ __RPC__out unsigned int *actual);
END_INTERFACE
} __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIconVtbl;
interface __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon
{
CONST_VTBL struct __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIconVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_get_Current(This,current) \
( (This)->lpVtbl -> get_Current(This,current) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_get_HasCurrent(This,hasCurrent) \
( (This)->lpVtbl -> get_HasCurrent(This,hasCurrent) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_MoveNext(This,hasCurrent) \
( (This)->lpVtbl -> MoveNext(This,hasCurrent) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetMany(This,capacity,items,actual) \
( (This)->lpVtbl -> GetMany(This,capacity,items,actual) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0048 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0048 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0048_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0048_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0469 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0469 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0469_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0469_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0049 */
/* [local] */
#ifndef DEF___FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon
#define DEF___FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0049 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0049_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0049_v0_0_s_ifspec;
#ifndef ____FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_INTERFACE_DEFINED__
#define ____FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_INTERFACE_DEFINED__
/* interface __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon */
/* [unique][uuid][object] */
/* interface __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("16077ee6-dcfc-53aa-ab0e-d666ac819d6c")
__FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon : public IInspectable
{
public:
virtual HRESULT STDMETHODCALLTYPE First(
/* [retval][out] */ __RPC__deref_out_opt __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon **first) = 0;
};
#else /* C style interface */
typedef struct __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIconVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
HRESULT ( STDMETHODCALLTYPE *First )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [retval][out] */ __RPC__deref_out_opt __FIIterator_1_Windows__CMedia__CStreaming__CIDeviceIcon **first);
END_INTERFACE
} __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIconVtbl;
interface __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon
{
CONST_VTBL struct __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIconVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_First(This,first) \
( (This)->lpVtbl -> First(This,first) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0050 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIIterable_1_Windows__CMedia__CStreaming__CIDeviceIcon */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0050 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0050_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0050_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0470 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0470 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0470_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0470_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0051 */
/* [local] */
#ifndef DEF___FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon
#define DEF___FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0051 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0051_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0051_v0_0_s_ifspec;
#ifndef ____FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_INTERFACE_DEFINED__
#define ____FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_INTERFACE_DEFINED__
/* interface __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon */
/* [unique][uuid][object] */
/* interface __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("ff195e52-48eb-5709-be50-3a3914c189db")
__FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon : public IInspectable
{
public:
virtual HRESULT STDMETHODCALLTYPE GetAt(
/* [in] */ unsigned int index,
/* [retval][out] */ __RPC__deref_out_opt ABI::Windows::Media::Streaming::IDeviceIcon **item) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Size(
/* [retval][out] */ __RPC__out unsigned int *size) = 0;
virtual HRESULT STDMETHODCALLTYPE IndexOf(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IDeviceIcon *item,
/* [out] */ __RPC__out unsigned int *index,
/* [retval][out] */ __RPC__out boolean *found) = 0;
virtual HRESULT STDMETHODCALLTYPE GetMany(
/* [in] */ unsigned int startIndex,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) ABI::Windows::Media::Streaming::IDeviceIcon **items,
/* [retval][out] */ __RPC__out unsigned int *actual) = 0;
};
#else /* C style interface */
typedef struct __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIconVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
HRESULT ( STDMETHODCALLTYPE *GetAt )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ unsigned int index,
/* [retval][out] */ __RPC__deref_out_opt __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon **item);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Size )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [retval][out] */ __RPC__out unsigned int *size);
HRESULT ( STDMETHODCALLTYPE *IndexOf )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon *item,
/* [out] */ __RPC__out unsigned int *index,
/* [retval][out] */ __RPC__out boolean *found);
HRESULT ( STDMETHODCALLTYPE *GetMany )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ unsigned int startIndex,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon **items,
/* [retval][out] */ __RPC__out unsigned int *actual);
END_INTERFACE
} __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIconVtbl;
interface __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon
{
CONST_VTBL struct __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIconVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetAt(This,index,item) \
( (This)->lpVtbl -> GetAt(This,index,item) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_get_Size(This,size) \
( (This)->lpVtbl -> get_Size(This,size) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_IndexOf(This,item,index,found) \
( (This)->lpVtbl -> IndexOf(This,item,index,found) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetMany(This,startIndex,capacity,items,actual) \
( (This)->lpVtbl -> GetMany(This,startIndex,capacity,items,actual) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0052 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0052 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0052_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0052_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0471 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0471 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0471_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0471_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0053 */
/* [local] */
#ifndef DEF___FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon
#define DEF___FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0053 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0053_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0053_v0_0_s_ifspec;
#ifndef ____FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_INTERFACE_DEFINED__
#define ____FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_INTERFACE_DEFINED__
/* interface __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon */
/* [unique][uuid][object] */
/* interface __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("a32d7731-05f6-55a2-930f-1cf5a12b19ae")
__FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon : public IInspectable
{
public:
virtual HRESULT STDMETHODCALLTYPE GetAt(
/* [in] */ unsigned int index,
/* [retval][out] */ __RPC__deref_out_opt ABI::Windows::Media::Streaming::IDeviceIcon **item) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Size(
/* [retval][out] */ __RPC__out unsigned int *size) = 0;
virtual HRESULT STDMETHODCALLTYPE GetView(
/* [retval][out] */ __RPC__deref_out_opt __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon **view) = 0;
virtual HRESULT STDMETHODCALLTYPE IndexOf(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IDeviceIcon *item,
/* [out] */ __RPC__out unsigned int *index,
/* [retval][out] */ __RPC__out boolean *found) = 0;
virtual HRESULT STDMETHODCALLTYPE SetAt(
/* [in] */ unsigned int index,
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IDeviceIcon *item) = 0;
virtual HRESULT STDMETHODCALLTYPE InsertAt(
/* [in] */ unsigned int index,
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IDeviceIcon *item) = 0;
virtual HRESULT STDMETHODCALLTYPE RemoveAt(
/* [in] */ unsigned int index) = 0;
virtual HRESULT STDMETHODCALLTYPE Append(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IDeviceIcon *item) = 0;
virtual HRESULT STDMETHODCALLTYPE RemoveAtEnd( void) = 0;
virtual HRESULT STDMETHODCALLTYPE Clear( void) = 0;
virtual HRESULT STDMETHODCALLTYPE GetMany(
/* [in] */ unsigned int startIndex,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) ABI::Windows::Media::Streaming::IDeviceIcon **items,
/* [retval][out] */ __RPC__out unsigned int *actual) = 0;
virtual HRESULT STDMETHODCALLTYPE ReplaceAll(
/* [in] */ unsigned int count,
/* [size_is][in] */ __RPC__in_ecount_full(count) ABI::Windows::Media::Streaming::IDeviceIcon **value) = 0;
};
#else /* C style interface */
typedef struct __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIconVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
HRESULT ( STDMETHODCALLTYPE *GetAt )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ unsigned int index,
/* [retval][out] */ __RPC__deref_out_opt __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon **item);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Size )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [retval][out] */ __RPC__out unsigned int *size);
HRESULT ( STDMETHODCALLTYPE *GetView )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [retval][out] */ __RPC__deref_out_opt __FIVectorView_1_Windows__CMedia__CStreaming__CIDeviceIcon **view);
HRESULT ( STDMETHODCALLTYPE *IndexOf )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon *item,
/* [out] */ __RPC__out unsigned int *index,
/* [retval][out] */ __RPC__out boolean *found);
HRESULT ( STDMETHODCALLTYPE *SetAt )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ unsigned int index,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon *item);
HRESULT ( STDMETHODCALLTYPE *InsertAt )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ unsigned int index,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon *item);
HRESULT ( STDMETHODCALLTYPE *RemoveAt )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ unsigned int index);
HRESULT ( STDMETHODCALLTYPE *Append )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon *item);
HRESULT ( STDMETHODCALLTYPE *RemoveAtEnd )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This);
HRESULT ( STDMETHODCALLTYPE *Clear )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This);
HRESULT ( STDMETHODCALLTYPE *GetMany )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ unsigned int startIndex,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon **items,
/* [retval][out] */ __RPC__out unsigned int *actual);
HRESULT ( STDMETHODCALLTYPE *ReplaceAll )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon * This,
/* [in] */ unsigned int count,
/* [size_is][in] */ __RPC__in_ecount_full(count) __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon **value);
END_INTERFACE
} __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIconVtbl;
interface __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon
{
CONST_VTBL struct __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIconVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetAt(This,index,item) \
( (This)->lpVtbl -> GetAt(This,index,item) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_get_Size(This,size) \
( (This)->lpVtbl -> get_Size(This,size) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetView(This,view) \
( (This)->lpVtbl -> GetView(This,view) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_IndexOf(This,item,index,found) \
( (This)->lpVtbl -> IndexOf(This,item,index,found) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_SetAt(This,index,item) \
( (This)->lpVtbl -> SetAt(This,index,item) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_InsertAt(This,index,item) \
( (This)->lpVtbl -> InsertAt(This,index,item) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_RemoveAt(This,index) \
( (This)->lpVtbl -> RemoveAt(This,index) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_Append(This,item) \
( (This)->lpVtbl -> Append(This,item) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_RemoveAtEnd(This) \
( (This)->lpVtbl -> RemoveAtEnd(This) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_Clear(This) \
( (This)->lpVtbl -> Clear(This) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_GetMany(This,startIndex,capacity,items,actual) \
( (This)->lpVtbl -> GetMany(This,startIndex,capacity,items,actual) )
#define __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_ReplaceAll(This,count,value) \
( (This)->lpVtbl -> ReplaceAll(This,count,value) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0054 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon */
#if !defined(____x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_INTERFACE_DEFINED__)
extern const __declspec(selectany) WCHAR InterfaceName_Windows_Media_Streaming_IBasicDevice[] = L"Windows.Media.Streaming.IBasicDevice";
#endif /* !defined(____x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_INTERFACE_DEFINED__) */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0054 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0054_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0054_v0_0_s_ifspec;
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_INTERFACE_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_INTERFACE_DEFINED__
/* interface __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice */
/* [uuid][object] */
/* interface ABI::Windows::Media::Streaming::IBasicDevice */
/* [uuid][object] */
EXTERN_C const IID IID___x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice;
#if defined(__cplusplus) && !defined(CINTERFACE)
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
MIDL_INTERFACE("f4f26cbb-7962-48b7-80f7-c3a5d753bcb0")
IBasicDevice : public IInspectable
{
public:
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_FriendlyName(
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value) = 0;
virtual /* [propput] */ HRESULT STDMETHODCALLTYPE put_FriendlyName(
/* [in] */ __RPC__in HSTRING value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_ManufacturerName(
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_ManufacturerUrl(
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_UniqueDeviceName(
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_ModelName(
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_ModelNumber(
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_ModelUrl(
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Description(
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_SerialNumber(
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_PresentationUrl(
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_RemoteStreamingUrls(
/* [out][retval] */ __RPC__deref_out_opt __FIVector_1_HSTRING **value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_PhysicalAddresses(
/* [out][retval] */ __RPC__deref_out_opt __FIVector_1_HSTRING **value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IpAddresses(
/* [out][retval] */ __RPC__deref_out_opt __FIVector_1_HSTRING **value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_CanWakeDevices(
/* [out][retval] */ __RPC__out boolean *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_DiscoveredOnCurrentNetwork(
/* [out][retval] */ __RPC__out boolean *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Type(
/* [out][retval] */ __RPC__out ABI::Windows::Media::Streaming::DeviceTypes *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Icons(
/* [out][retval] */ __RPC__deref_out_opt __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon **value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_ConnectionStatus(
/* [out][retval] */ __RPC__out ABI::Windows::Media::Streaming::ConnectionStatus *value) = 0;
virtual HRESULT STDMETHODCALLTYPE add_ConnectionStatusChanged(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IConnectionStatusHandler *handler,
/* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0;
virtual HRESULT STDMETHODCALLTYPE remove_ConnectionStatusChanged(
/* [in] */ EventRegistrationToken token) = 0;
};
extern const __declspec(selectany) IID & IID_IBasicDevice = __uuidof(IBasicDevice);
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#else /* C style interface */
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CIBasicDeviceVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_FriendlyName )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value);
/* [propput] */ HRESULT ( STDMETHODCALLTYPE *put_FriendlyName )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [in] */ __RPC__in HSTRING value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_ManufacturerName )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_ManufacturerUrl )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_UniqueDeviceName )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_ModelName )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_ModelNumber )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_ModelUrl )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Description )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_SerialNumber )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_PresentationUrl )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_RemoteStreamingUrls )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__deref_out_opt __FIVector_1_HSTRING **value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_PhysicalAddresses )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__deref_out_opt __FIVector_1_HSTRING **value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_IpAddresses )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__deref_out_opt __FIVector_1_HSTRING **value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_CanWakeDevices )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__out boolean *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_DiscoveredOnCurrentNetwork )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__out boolean *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Type )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__out __x_ABI_CWindows_CMedia_CStreaming_CDeviceTypes *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Icons )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__deref_out_opt __FIVector_1_Windows__CMedia__CStreaming__CIDeviceIcon **value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_ConnectionStatus )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [out][retval] */ __RPC__out __x_ABI_CWindows_CMedia_CStreaming_CConnectionStatus *value);
HRESULT ( STDMETHODCALLTYPE *add_ConnectionStatusChanged )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIConnectionStatusHandler *handler,
/* [out][retval] */ __RPC__out EventRegistrationToken *token);
HRESULT ( STDMETHODCALLTYPE *remove_ConnectionStatusChanged )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice * This,
/* [in] */ EventRegistrationToken token);
END_INTERFACE
} __x_ABI_CWindows_CMedia_CStreaming_CIBasicDeviceVtbl;
interface __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice
{
CONST_VTBL struct __x_ABI_CWindows_CMedia_CStreaming_CIBasicDeviceVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_FriendlyName(This,value) \
( (This)->lpVtbl -> get_FriendlyName(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_put_FriendlyName(This,value) \
( (This)->lpVtbl -> put_FriendlyName(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_ManufacturerName(This,value) \
( (This)->lpVtbl -> get_ManufacturerName(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_ManufacturerUrl(This,value) \
( (This)->lpVtbl -> get_ManufacturerUrl(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_UniqueDeviceName(This,value) \
( (This)->lpVtbl -> get_UniqueDeviceName(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_ModelName(This,value) \
( (This)->lpVtbl -> get_ModelName(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_ModelNumber(This,value) \
( (This)->lpVtbl -> get_ModelNumber(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_ModelUrl(This,value) \
( (This)->lpVtbl -> get_ModelUrl(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_Description(This,value) \
( (This)->lpVtbl -> get_Description(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_SerialNumber(This,value) \
( (This)->lpVtbl -> get_SerialNumber(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_PresentationUrl(This,value) \
( (This)->lpVtbl -> get_PresentationUrl(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_RemoteStreamingUrls(This,value) \
( (This)->lpVtbl -> get_RemoteStreamingUrls(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_PhysicalAddresses(This,value) \
( (This)->lpVtbl -> get_PhysicalAddresses(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_IpAddresses(This,value) \
( (This)->lpVtbl -> get_IpAddresses(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_CanWakeDevices(This,value) \
( (This)->lpVtbl -> get_CanWakeDevices(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_DiscoveredOnCurrentNetwork(This,value) \
( (This)->lpVtbl -> get_DiscoveredOnCurrentNetwork(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_Type(This,value) \
( (This)->lpVtbl -> get_Type(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_Icons(This,value) \
( (This)->lpVtbl -> get_Icons(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_get_ConnectionStatus(This,value) \
( (This)->lpVtbl -> get_ConnectionStatus(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_add_ConnectionStatusChanged(This,handler,token) \
( (This)->lpVtbl -> add_ConnectionStatusChanged(This,handler,token) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_remove_ConnectionStatusChanged(This,token) \
( (This)->lpVtbl -> remove_ConnectionStatusChanged(This,token) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0055 */
/* [local] */
#if !defined(____x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_INTERFACE_DEFINED__)
extern const __declspec(selectany) WCHAR InterfaceName_Windows_Media_Streaming_IDeviceIcon[] = L"Windows.Media.Streaming.IDeviceIcon";
#endif /* !defined(____x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_INTERFACE_DEFINED__) */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0055 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0055_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0055_v0_0_s_ifspec;
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_INTERFACE_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_INTERFACE_DEFINED__
/* interface __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon */
/* [uuid][object] */
/* interface ABI::Windows::Media::Streaming::IDeviceIcon */
/* [uuid][object] */
EXTERN_C const IID IID___x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon;
#if defined(__cplusplus) && !defined(CINTERFACE)
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
MIDL_INTERFACE("8ffb1a1e-023d-4de1-b556-ab5abf01929c")
IDeviceIcon : public IInspectable
{
public:
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Width(
/* [out][retval] */ __RPC__out UINT32 *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Height(
/* [out][retval] */ __RPC__out UINT32 *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_ContentType(
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Stream(
/* [out][retval] */ __RPC__deref_out_opt ABI::Windows::Storage::Streams::IRandomAccessStreamWithContentType **value) = 0;
};
extern const __declspec(selectany) IID & IID_IDeviceIcon = __uuidof(IDeviceIcon);
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#else /* C style interface */
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIconVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Width )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon * This,
/* [out][retval] */ __RPC__out UINT32 *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Height )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon * This,
/* [out][retval] */ __RPC__out UINT32 *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_ContentType )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon * This,
/* [out][retval] */ __RPC__deref_out_opt HSTRING *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Stream )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon * This,
/* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CStorage_CStreams_CIRandomAccessStreamWithContentType **value);
END_INTERFACE
} __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIconVtbl;
interface __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon
{
CONST_VTBL struct __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIconVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_get_Width(This,value) \
( (This)->lpVtbl -> get_Width(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_get_Height(This,value) \
( (This)->lpVtbl -> get_Height(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_get_ContentType(This,value) \
( (This)->lpVtbl -> get_ContentType(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_get_Stream(This,value) \
( (This)->lpVtbl -> get_Stream(This,value) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIDeviceIcon_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0472 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0472 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0472_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0472_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0057 */
/* [local] */
#ifndef DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation
#define DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0057 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0057_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0057_v0_0_s_ifspec;
#ifndef ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_INTERFACE_DEFINED__
#define ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_INTERFACE_DEFINED__
/* interface __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation */
/* [unique][uuid][object] */
/* interface __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("9970f463-bcd0-55b9-94cd-8932d42446ca")
__FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE Invoke(
/* [in] */ __RPC__in_opt __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation *asyncInfo,
/* [in] */ AsyncStatus status) = 0;
};
#else /* C style interface */
typedef struct __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformationVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation * This);
HRESULT ( STDMETHODCALLTYPE *Invoke )(
__RPC__in __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation * This,
/* [in] */ __RPC__in_opt __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation *asyncInfo,
/* [in] */ AsyncStatus status);
END_INTERFACE
} __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformationVtbl;
interface __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation
{
CONST_VTBL struct __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformationVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_Invoke(This,asyncInfo,status) \
( (This)->lpVtbl -> Invoke(This,asyncInfo,status) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0058 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0058 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0058_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0058_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0473 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0473 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0473_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0473_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0059 */
/* [local] */
#ifndef DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation
#define DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0059 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0059_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0059_v0_0_s_ifspec;
#ifndef ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_INTERFACE_DEFINED__
#define ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_INTERFACE_DEFINED__
/* interface __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation */
/* [unique][uuid][object] */
/* interface __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("f99e7d9c-2274-5f3d-89e7-f5f862ba0334")
__FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation : public IInspectable
{
public:
virtual /* [propput] */ HRESULT STDMETHODCALLTYPE put_Completed(
/* [in] */ __RPC__in_opt __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation *handler) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Completed(
/* [retval][out] */ __RPC__deref_out_opt __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation **handler) = 0;
virtual HRESULT STDMETHODCALLTYPE GetResults(
/* [retval][out] */ __RPC__out struct ABI::Windows::Media::Streaming::TransportInformation *results) = 0;
};
#else /* C style interface */
typedef struct __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformationVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
/* [propput] */ HRESULT ( STDMETHODCALLTYPE *put_Completed )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation * This,
/* [in] */ __RPC__in_opt __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation *handler);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Completed )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation * This,
/* [retval][out] */ __RPC__deref_out_opt __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CTransportInformation **handler);
HRESULT ( STDMETHODCALLTYPE *GetResults )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation * This,
/* [retval][out] */ __RPC__out struct __x_ABI_CWindows_CMedia_CStreaming_CTransportInformation *results);
END_INTERFACE
} __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformationVtbl;
interface __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation
{
CONST_VTBL struct __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformationVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_put_Completed(This,handler) \
( (This)->lpVtbl -> put_Completed(This,handler) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_get_Completed(This,handler) \
( (This)->lpVtbl -> get_Completed(This,handler) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_GetResults(This,results) \
( (This)->lpVtbl -> GetResults(This,results) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0060 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0060 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0060_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0060_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0474 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0474 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0474_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0474_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0061 */
/* [local] */
#ifndef DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation
#define DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0061 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0061_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0061_v0_0_s_ifspec;
#ifndef ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_INTERFACE_DEFINED__
#define ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_INTERFACE_DEFINED__
/* interface __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation */
/* [unique][uuid][object] */
/* interface __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("adc7daf4-9a69-5d0b-aec8-e2ee3292d178")
__FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE Invoke(
/* [in] */ __RPC__in_opt __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation *asyncInfo,
/* [in] */ AsyncStatus status) = 0;
};
#else /* C style interface */
typedef struct __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformationVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation * This);
HRESULT ( STDMETHODCALLTYPE *Invoke )(
__RPC__in __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation * This,
/* [in] */ __RPC__in_opt __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation *asyncInfo,
/* [in] */ AsyncStatus status);
END_INTERFACE
} __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformationVtbl;
interface __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation
{
CONST_VTBL struct __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformationVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_Invoke(This,asyncInfo,status) \
( (This)->lpVtbl -> Invoke(This,asyncInfo,status) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0062 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0062 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0062_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0062_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0475 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0475 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0475_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0475_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0063 */
/* [local] */
#ifndef DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation
#define DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0063 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0063_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0063_v0_0_s_ifspec;
#ifndef ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_INTERFACE_DEFINED__
#define ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_INTERFACE_DEFINED__
/* interface __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation */
/* [unique][uuid][object] */
/* interface __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("e2b45a37-e1c1-5e80-8962-a134d7f3557c")
__FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation : public IInspectable
{
public:
virtual /* [propput] */ HRESULT STDMETHODCALLTYPE put_Completed(
/* [in] */ __RPC__in_opt __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation *handler) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Completed(
/* [retval][out] */ __RPC__deref_out_opt __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation **handler) = 0;
virtual HRESULT STDMETHODCALLTYPE GetResults(
/* [retval][out] */ __RPC__out struct ABI::Windows::Media::Streaming::PositionInformation *results) = 0;
};
#else /* C style interface */
typedef struct __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformationVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
/* [propput] */ HRESULT ( STDMETHODCALLTYPE *put_Completed )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation * This,
/* [in] */ __RPC__in_opt __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation *handler);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Completed )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation * This,
/* [retval][out] */ __RPC__deref_out_opt __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CPositionInformation **handler);
HRESULT ( STDMETHODCALLTYPE *GetResults )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation * This,
/* [retval][out] */ __RPC__out struct __x_ABI_CWindows_CMedia_CStreaming_CPositionInformation *results);
END_INTERFACE
} __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformationVtbl;
interface __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation
{
CONST_VTBL struct __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformationVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_put_Completed(This,handler) \
( (This)->lpVtbl -> put_Completed(This,handler) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_get_Completed(This,handler) \
( (This)->lpVtbl -> get_Completed(This,handler) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_GetResults(This,results) \
( (This)->lpVtbl -> GetResults(This,results) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0064 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation */
#if !defined(____x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_INTERFACE_DEFINED__)
extern const __declspec(selectany) WCHAR InterfaceName_Windows_Media_Streaming_IMediaRenderer[] = L"Windows.Media.Streaming.IMediaRenderer";
#endif /* !defined(____x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_INTERFACE_DEFINED__) */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0064 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0064_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0064_v0_0_s_ifspec;
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_INTERFACE_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_INTERFACE_DEFINED__
/* interface __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer */
/* [uuid][object] */
/* interface ABI::Windows::Media::Streaming::IMediaRenderer */
/* [uuid][object] */
EXTERN_C const IID IID___x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer;
#if defined(__cplusplus) && !defined(CINTERFACE)
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
MIDL_INTERFACE("2c012ec3-d975-47fb-96ac-a6418b326d2b")
IMediaRenderer : public IInspectable
{
public:
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IsAudioSupported(
/* [out][retval] */ __RPC__out boolean *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IsVideoSupported(
/* [out][retval] */ __RPC__out boolean *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IsImageSupported(
/* [out][retval] */ __RPC__out boolean *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_ActionInformation(
/* [out][retval] */ __RPC__deref_out_opt ABI::Windows::Media::Streaming::IMediaRendererActionInformation **value) = 0;
virtual HRESULT STDMETHODCALLTYPE SetSourceFromUriAsync(
/* [in] */ __RPC__in HSTRING URI,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_UINT32 **value) = 0;
virtual HRESULT STDMETHODCALLTYPE SetSourceFromStreamAsync(
/* [in] */ __RPC__in_opt IInspectable *stream,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_UINT32 **value) = 0;
virtual HRESULT STDMETHODCALLTYPE SetSourceFromMediaSourceAsync(
/* [in] */ __RPC__in_opt IInspectable *mediaSource,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_UINT32 **value) = 0;
virtual HRESULT STDMETHODCALLTYPE SetNextSourceFromUriAsync(
/* [in] */ __RPC__in HSTRING URI,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_UINT32 **value) = 0;
virtual HRESULT STDMETHODCALLTYPE SetNextSourceFromStreamAsync(
/* [in] */ __RPC__in_opt IInspectable *stream,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_UINT32 **value) = 0;
virtual HRESULT STDMETHODCALLTYPE SetNextSourceFromMediaSourceAsync(
/* [in] */ __RPC__in_opt IInspectable *mediaSource,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_UINT32 **value) = 0;
virtual HRESULT STDMETHODCALLTYPE PlayAsync(
/* [out][retval] */ __RPC__deref_out_opt ABI::Windows::Foundation::IAsyncAction **value) = 0;
virtual HRESULT STDMETHODCALLTYPE PlayAtSpeedAsync(
/* [in] */ ABI::Windows::Media::Streaming::PlaySpeed playSpeed,
/* [out][retval] */ __RPC__deref_out_opt ABI::Windows::Foundation::IAsyncAction **value) = 0;
virtual HRESULT STDMETHODCALLTYPE StopAsync(
/* [out][retval] */ __RPC__deref_out_opt ABI::Windows::Foundation::IAsyncAction **value) = 0;
virtual HRESULT STDMETHODCALLTYPE PauseAsync(
/* [out][retval] */ __RPC__deref_out_opt ABI::Windows::Foundation::IAsyncAction **value) = 0;
virtual HRESULT STDMETHODCALLTYPE GetMuteAsync(
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_boolean **value) = 0;
virtual HRESULT STDMETHODCALLTYPE SetMuteAsync(
/* [in] */ boolean mute,
/* [out][retval] */ __RPC__deref_out_opt ABI::Windows::Foundation::IAsyncAction **value) = 0;
virtual HRESULT STDMETHODCALLTYPE GetVolumeAsync(
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_UINT32 **value) = 0;
virtual HRESULT STDMETHODCALLTYPE SetVolumeAsync(
/* [in] */ UINT32 volume,
/* [out][retval] */ __RPC__deref_out_opt ABI::Windows::Foundation::IAsyncAction **value) = 0;
virtual HRESULT STDMETHODCALLTYPE SeekAsync(
/* [in] */ ABI::Windows::Foundation::TimeSpan target,
/* [out][retval] */ __RPC__deref_out_opt ABI::Windows::Foundation::IAsyncAction **value) = 0;
virtual HRESULT STDMETHODCALLTYPE GetTransportInformationAsync(
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation **value) = 0;
virtual HRESULT STDMETHODCALLTYPE GetPositionInformationAsync(
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation **value) = 0;
virtual HRESULT STDMETHODCALLTYPE add_TransportParametersUpdate(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::ITransportParametersUpdateHandler *handler,
/* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0;
virtual HRESULT STDMETHODCALLTYPE remove_TransportParametersUpdate(
/* [in] */ EventRegistrationToken token) = 0;
virtual HRESULT STDMETHODCALLTYPE add_RenderingParametersUpdate(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IRenderingParametersUpdateHandler *handler,
/* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0;
virtual HRESULT STDMETHODCALLTYPE remove_RenderingParametersUpdate(
/* [in] */ EventRegistrationToken token) = 0;
virtual HRESULT STDMETHODCALLTYPE NextAsync(
/* [out][retval] */ __RPC__deref_out_opt ABI::Windows::Foundation::IAsyncAction **value) = 0;
};
extern const __declspec(selectany) IID & IID_IMediaRenderer = __uuidof(IMediaRenderer);
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#else /* C style interface */
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_IsAudioSupported )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [out][retval] */ __RPC__out boolean *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_IsVideoSupported )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [out][retval] */ __RPC__out boolean *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_IsImageSupported )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [out][retval] */ __RPC__out boolean *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_ActionInformation )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation **value);
HRESULT ( STDMETHODCALLTYPE *SetSourceFromUriAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [in] */ __RPC__in HSTRING URI,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_UINT32 **value);
HRESULT ( STDMETHODCALLTYPE *SetSourceFromStreamAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [in] */ __RPC__in_opt IInspectable *stream,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_UINT32 **value);
HRESULT ( STDMETHODCALLTYPE *SetSourceFromMediaSourceAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [in] */ __RPC__in_opt IInspectable *mediaSource,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_UINT32 **value);
HRESULT ( STDMETHODCALLTYPE *SetNextSourceFromUriAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [in] */ __RPC__in HSTRING URI,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_UINT32 **value);
HRESULT ( STDMETHODCALLTYPE *SetNextSourceFromStreamAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [in] */ __RPC__in_opt IInspectable *stream,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_UINT32 **value);
HRESULT ( STDMETHODCALLTYPE *SetNextSourceFromMediaSourceAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [in] */ __RPC__in_opt IInspectable *mediaSource,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_UINT32 **value);
HRESULT ( STDMETHODCALLTYPE *PlayAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CFoundation_CIAsyncAction **value);
HRESULT ( STDMETHODCALLTYPE *PlayAtSpeedAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [in] */ __x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed playSpeed,
/* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CFoundation_CIAsyncAction **value);
HRESULT ( STDMETHODCALLTYPE *StopAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CFoundation_CIAsyncAction **value);
HRESULT ( STDMETHODCALLTYPE *PauseAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CFoundation_CIAsyncAction **value);
HRESULT ( STDMETHODCALLTYPE *GetMuteAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_boolean **value);
HRESULT ( STDMETHODCALLTYPE *SetMuteAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [in] */ boolean mute,
/* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CFoundation_CIAsyncAction **value);
HRESULT ( STDMETHODCALLTYPE *GetVolumeAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_UINT32 **value);
HRESULT ( STDMETHODCALLTYPE *SetVolumeAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [in] */ UINT32 volume,
/* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CFoundation_CIAsyncAction **value);
HRESULT ( STDMETHODCALLTYPE *SeekAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [in] */ __x_ABI_CWindows_CFoundation_CTimeSpan target,
/* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CFoundation_CIAsyncAction **value);
HRESULT ( STDMETHODCALLTYPE *GetTransportInformationAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_Windows__CMedia__CStreaming__CTransportInformation **value);
HRESULT ( STDMETHODCALLTYPE *GetPositionInformationAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_Windows__CMedia__CStreaming__CPositionInformation **value);
HRESULT ( STDMETHODCALLTYPE *add_TransportParametersUpdate )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersUpdateHandler *handler,
/* [out][retval] */ __RPC__out EventRegistrationToken *token);
HRESULT ( STDMETHODCALLTYPE *remove_TransportParametersUpdate )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [in] */ EventRegistrationToken token);
HRESULT ( STDMETHODCALLTYPE *add_RenderingParametersUpdate )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIRenderingParametersUpdateHandler *handler,
/* [out][retval] */ __RPC__out EventRegistrationToken *token);
HRESULT ( STDMETHODCALLTYPE *remove_RenderingParametersUpdate )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [in] */ EventRegistrationToken token);
HRESULT ( STDMETHODCALLTYPE *NextAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer * This,
/* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CFoundation_CIAsyncAction **value);
END_INTERFACE
} __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererVtbl;
interface __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer
{
CONST_VTBL struct __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_get_IsAudioSupported(This,value) \
( (This)->lpVtbl -> get_IsAudioSupported(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_get_IsVideoSupported(This,value) \
( (This)->lpVtbl -> get_IsVideoSupported(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_get_IsImageSupported(This,value) \
( (This)->lpVtbl -> get_IsImageSupported(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_get_ActionInformation(This,value) \
( (This)->lpVtbl -> get_ActionInformation(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_SetSourceFromUriAsync(This,URI,value) \
( (This)->lpVtbl -> SetSourceFromUriAsync(This,URI,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_SetSourceFromStreamAsync(This,stream,value) \
( (This)->lpVtbl -> SetSourceFromStreamAsync(This,stream,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_SetSourceFromMediaSourceAsync(This,mediaSource,value) \
( (This)->lpVtbl -> SetSourceFromMediaSourceAsync(This,mediaSource,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_SetNextSourceFromUriAsync(This,URI,value) \
( (This)->lpVtbl -> SetNextSourceFromUriAsync(This,URI,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_SetNextSourceFromStreamAsync(This,stream,value) \
( (This)->lpVtbl -> SetNextSourceFromStreamAsync(This,stream,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_SetNextSourceFromMediaSourceAsync(This,mediaSource,value) \
( (This)->lpVtbl -> SetNextSourceFromMediaSourceAsync(This,mediaSource,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_PlayAsync(This,value) \
( (This)->lpVtbl -> PlayAsync(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_PlayAtSpeedAsync(This,playSpeed,value) \
( (This)->lpVtbl -> PlayAtSpeedAsync(This,playSpeed,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_StopAsync(This,value) \
( (This)->lpVtbl -> StopAsync(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_PauseAsync(This,value) \
( (This)->lpVtbl -> PauseAsync(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_GetMuteAsync(This,value) \
( (This)->lpVtbl -> GetMuteAsync(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_SetMuteAsync(This,mute,value) \
( (This)->lpVtbl -> SetMuteAsync(This,mute,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_GetVolumeAsync(This,value) \
( (This)->lpVtbl -> GetVolumeAsync(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_SetVolumeAsync(This,volume,value) \
( (This)->lpVtbl -> SetVolumeAsync(This,volume,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_SeekAsync(This,target,value) \
( (This)->lpVtbl -> SeekAsync(This,target,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_GetTransportInformationAsync(This,value) \
( (This)->lpVtbl -> GetTransportInformationAsync(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_GetPositionInformationAsync(This,value) \
( (This)->lpVtbl -> GetPositionInformationAsync(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_add_TransportParametersUpdate(This,handler,token) \
( (This)->lpVtbl -> add_TransportParametersUpdate(This,handler,token) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_remove_TransportParametersUpdate(This,token) \
( (This)->lpVtbl -> remove_TransportParametersUpdate(This,token) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_add_RenderingParametersUpdate(This,handler,token) \
( (This)->lpVtbl -> add_RenderingParametersUpdate(This,handler,token) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_remove_RenderingParametersUpdate(This,token) \
( (This)->lpVtbl -> remove_RenderingParametersUpdate(This,token) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_NextAsync(This,value) \
( (This)->lpVtbl -> NextAsync(This,value) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0476 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0476 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0476_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0476_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0066 */
/* [local] */
#ifndef DEF___FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed
#define DEF___FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0066 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0066_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0066_v0_0_s_ifspec;
#ifndef ____FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_INTERFACE_DEFINED__
#define ____FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_INTERFACE_DEFINED__
/* interface __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed */
/* [unique][uuid][object] */
/* interface __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("fd051cd8-25c7-5780-9606-b35062137d21")
__FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed : public IInspectable
{
public:
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Current(
/* [retval][out] */ __RPC__out struct ABI::Windows::Media::Streaming::PlaySpeed *current) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_HasCurrent(
/* [retval][out] */ __RPC__out boolean *hasCurrent) = 0;
virtual HRESULT STDMETHODCALLTYPE MoveNext(
/* [retval][out] */ __RPC__out boolean *hasCurrent) = 0;
virtual HRESULT STDMETHODCALLTYPE GetMany(
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) struct ABI::Windows::Media::Streaming::PlaySpeed *items,
/* [retval][out] */ __RPC__out unsigned int *actual) = 0;
};
#else /* C style interface */
typedef struct __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeedVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Current )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [retval][out] */ __RPC__out struct __x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed *current);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_HasCurrent )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [retval][out] */ __RPC__out boolean *hasCurrent);
HRESULT ( STDMETHODCALLTYPE *MoveNext )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [retval][out] */ __RPC__out boolean *hasCurrent);
HRESULT ( STDMETHODCALLTYPE *GetMany )(
__RPC__in __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) struct __x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed *items,
/* [retval][out] */ __RPC__out unsigned int *actual);
END_INTERFACE
} __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeedVtbl;
interface __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed
{
CONST_VTBL struct __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeedVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_get_Current(This,current) \
( (This)->lpVtbl -> get_Current(This,current) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_get_HasCurrent(This,hasCurrent) \
( (This)->lpVtbl -> get_HasCurrent(This,hasCurrent) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_MoveNext(This,hasCurrent) \
( (This)->lpVtbl -> MoveNext(This,hasCurrent) )
#define __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_GetMany(This,capacity,items,actual) \
( (This)->lpVtbl -> GetMany(This,capacity,items,actual) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0067 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0067 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0067_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0067_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0477 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0477 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0477_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0477_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0068 */
/* [local] */
#ifndef DEF___FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed
#define DEF___FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0068 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0068_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0068_v0_0_s_ifspec;
#ifndef ____FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_INTERFACE_DEFINED__
#define ____FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_INTERFACE_DEFINED__
/* interface __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed */
/* [unique][uuid][object] */
/* interface __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("c4a17a40-8c62-5884-822b-502526970b0d")
__FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed : public IInspectable
{
public:
virtual HRESULT STDMETHODCALLTYPE First(
/* [retval][out] */ __RPC__deref_out_opt __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed **first) = 0;
};
#else /* C style interface */
typedef struct __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeedVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
HRESULT ( STDMETHODCALLTYPE *First )(
__RPC__in __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [retval][out] */ __RPC__deref_out_opt __FIIterator_1_Windows__CMedia__CStreaming__CPlaySpeed **first);
END_INTERFACE
} __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeedVtbl;
interface __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed
{
CONST_VTBL struct __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeedVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_First(This,first) \
( (This)->lpVtbl -> First(This,first) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0069 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIIterable_1_Windows__CMedia__CStreaming__CPlaySpeed */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0069 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0069_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0069_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0478 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0478 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0478_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0478_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0070 */
/* [local] */
#ifndef DEF___FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed
#define DEF___FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0070 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0070_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0070_v0_0_s_ifspec;
#ifndef ____FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_INTERFACE_DEFINED__
#define ____FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_INTERFACE_DEFINED__
/* interface __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed */
/* [unique][uuid][object] */
/* interface __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("1295caf3-c1da-54ea-ac66-da2c044f9eb0")
__FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed : public IInspectable
{
public:
virtual HRESULT STDMETHODCALLTYPE GetAt(
/* [in] */ unsigned int index,
/* [retval][out] */ __RPC__out struct ABI::Windows::Media::Streaming::PlaySpeed *item) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Size(
/* [retval][out] */ __RPC__out unsigned int *size) = 0;
virtual HRESULT STDMETHODCALLTYPE IndexOf(
/* [in] */ struct ABI::Windows::Media::Streaming::PlaySpeed item,
/* [out] */ __RPC__out unsigned int *index,
/* [retval][out] */ __RPC__out boolean *found) = 0;
virtual HRESULT STDMETHODCALLTYPE GetMany(
/* [in] */ unsigned int startIndex,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) struct ABI::Windows::Media::Streaming::PlaySpeed *items,
/* [retval][out] */ __RPC__out unsigned int *actual) = 0;
};
#else /* C style interface */
typedef struct __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeedVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
HRESULT ( STDMETHODCALLTYPE *GetAt )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ unsigned int index,
/* [retval][out] */ __RPC__out struct __x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed *item);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Size )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [retval][out] */ __RPC__out unsigned int *size);
HRESULT ( STDMETHODCALLTYPE *IndexOf )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ struct __x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed item,
/* [out] */ __RPC__out unsigned int *index,
/* [retval][out] */ __RPC__out boolean *found);
HRESULT ( STDMETHODCALLTYPE *GetMany )(
__RPC__in __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ unsigned int startIndex,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) struct __x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed *items,
/* [retval][out] */ __RPC__out unsigned int *actual);
END_INTERFACE
} __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeedVtbl;
interface __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed
{
CONST_VTBL struct __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeedVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_GetAt(This,index,item) \
( (This)->lpVtbl -> GetAt(This,index,item) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_get_Size(This,size) \
( (This)->lpVtbl -> get_Size(This,size) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_IndexOf(This,item,index,found) \
( (This)->lpVtbl -> IndexOf(This,item,index,found) )
#define __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_GetMany(This,startIndex,capacity,items,actual) \
( (This)->lpVtbl -> GetMany(This,startIndex,capacity,items,actual) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0071 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0071 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0071_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0071_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0479 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0479 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0479_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0479_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0072 */
/* [local] */
#ifndef DEF___FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed
#define DEF___FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0072 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0072_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0072_v0_0_s_ifspec;
#ifndef ____FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_INTERFACE_DEFINED__
#define ____FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_INTERFACE_DEFINED__
/* interface __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed */
/* [unique][uuid][object] */
/* interface __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("fde57c75-5b86-5921-8ffb-101b0a184230")
__FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed : public IInspectable
{
public:
virtual HRESULT STDMETHODCALLTYPE GetAt(
/* [in] */ unsigned int index,
/* [retval][out] */ __RPC__out struct ABI::Windows::Media::Streaming::PlaySpeed *item) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Size(
/* [retval][out] */ __RPC__out unsigned int *size) = 0;
virtual HRESULT STDMETHODCALLTYPE GetView(
/* [retval][out] */ __RPC__deref_out_opt __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed **view) = 0;
virtual HRESULT STDMETHODCALLTYPE IndexOf(
/* [in] */ struct ABI::Windows::Media::Streaming::PlaySpeed item,
/* [out] */ __RPC__out unsigned int *index,
/* [retval][out] */ __RPC__out boolean *found) = 0;
virtual HRESULT STDMETHODCALLTYPE SetAt(
/* [in] */ unsigned int index,
/* [in] */ struct ABI::Windows::Media::Streaming::PlaySpeed item) = 0;
virtual HRESULT STDMETHODCALLTYPE InsertAt(
/* [in] */ unsigned int index,
/* [in] */ struct ABI::Windows::Media::Streaming::PlaySpeed item) = 0;
virtual HRESULT STDMETHODCALLTYPE RemoveAt(
/* [in] */ unsigned int index) = 0;
virtual HRESULT STDMETHODCALLTYPE Append(
/* [in] */ struct ABI::Windows::Media::Streaming::PlaySpeed item) = 0;
virtual HRESULT STDMETHODCALLTYPE RemoveAtEnd( void) = 0;
virtual HRESULT STDMETHODCALLTYPE Clear( void) = 0;
virtual HRESULT STDMETHODCALLTYPE GetMany(
/* [in] */ unsigned int startIndex,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) struct ABI::Windows::Media::Streaming::PlaySpeed *items,
/* [retval][out] */ __RPC__out unsigned int *actual) = 0;
virtual HRESULT STDMETHODCALLTYPE ReplaceAll(
/* [in] */ unsigned int count,
/* [size_is][in] */ __RPC__in_ecount_full(count) struct ABI::Windows::Media::Streaming::PlaySpeed *value) = 0;
};
#else /* C style interface */
typedef struct __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeedVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
HRESULT ( STDMETHODCALLTYPE *GetAt )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ unsigned int index,
/* [retval][out] */ __RPC__out struct __x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed *item);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Size )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [retval][out] */ __RPC__out unsigned int *size);
HRESULT ( STDMETHODCALLTYPE *GetView )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [retval][out] */ __RPC__deref_out_opt __FIVectorView_1_Windows__CMedia__CStreaming__CPlaySpeed **view);
HRESULT ( STDMETHODCALLTYPE *IndexOf )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ struct __x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed item,
/* [out] */ __RPC__out unsigned int *index,
/* [retval][out] */ __RPC__out boolean *found);
HRESULT ( STDMETHODCALLTYPE *SetAt )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ unsigned int index,
/* [in] */ struct __x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed item);
HRESULT ( STDMETHODCALLTYPE *InsertAt )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ unsigned int index,
/* [in] */ struct __x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed item);
HRESULT ( STDMETHODCALLTYPE *RemoveAt )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ unsigned int index);
HRESULT ( STDMETHODCALLTYPE *Append )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ struct __x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed item);
HRESULT ( STDMETHODCALLTYPE *RemoveAtEnd )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This);
HRESULT ( STDMETHODCALLTYPE *Clear )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This);
HRESULT ( STDMETHODCALLTYPE *GetMany )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ unsigned int startIndex,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) struct __x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed *items,
/* [retval][out] */ __RPC__out unsigned int *actual);
HRESULT ( STDMETHODCALLTYPE *ReplaceAll )(
__RPC__in __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed * This,
/* [in] */ unsigned int count,
/* [size_is][in] */ __RPC__in_ecount_full(count) struct __x_ABI_CWindows_CMedia_CStreaming_CPlaySpeed *value);
END_INTERFACE
} __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeedVtbl;
interface __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed
{
CONST_VTBL struct __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeedVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_GetAt(This,index,item) \
( (This)->lpVtbl -> GetAt(This,index,item) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_get_Size(This,size) \
( (This)->lpVtbl -> get_Size(This,size) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_GetView(This,view) \
( (This)->lpVtbl -> GetView(This,view) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_IndexOf(This,item,index,found) \
( (This)->lpVtbl -> IndexOf(This,item,index,found) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_SetAt(This,index,item) \
( (This)->lpVtbl -> SetAt(This,index,item) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_InsertAt(This,index,item) \
( (This)->lpVtbl -> InsertAt(This,index,item) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_RemoveAt(This,index) \
( (This)->lpVtbl -> RemoveAt(This,index) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_Append(This,item) \
( (This)->lpVtbl -> Append(This,item) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_RemoveAtEnd(This) \
( (This)->lpVtbl -> RemoveAtEnd(This) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_Clear(This) \
( (This)->lpVtbl -> Clear(This) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_GetMany(This,startIndex,capacity,items,actual) \
( (This)->lpVtbl -> GetMany(This,startIndex,capacity,items,actual) )
#define __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_ReplaceAll(This,count,value) \
( (This)->lpVtbl -> ReplaceAll(This,count,value) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0073 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed */
#if !defined(____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_INTERFACE_DEFINED__)
extern const __declspec(selectany) WCHAR InterfaceName_Windows_Media_Streaming_IMediaRendererActionInformation[] = L"Windows.Media.Streaming.IMediaRendererActionInformation";
#endif /* !defined(____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_INTERFACE_DEFINED__) */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0073 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0073_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0073_v0_0_s_ifspec;
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_INTERFACE_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_INTERFACE_DEFINED__
/* interface __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation */
/* [uuid][object] */
/* interface ABI::Windows::Media::Streaming::IMediaRendererActionInformation */
/* [uuid][object] */
EXTERN_C const IID IID___x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation;
#if defined(__cplusplus) && !defined(CINTERFACE)
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
MIDL_INTERFACE("66fbbfee-5ab0-4a4f-8d15-e5056b26beda")
IMediaRendererActionInformation : public IInspectable
{
public:
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IsMuteAvailable(
/* [out][retval] */ __RPC__out boolean *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IsPauseAvailable(
/* [out][retval] */ __RPC__out boolean *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IsPlayAvailable(
/* [out][retval] */ __RPC__out boolean *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IsSeekAvailable(
/* [out][retval] */ __RPC__out boolean *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IsSetNextSourceAvailable(
/* [out][retval] */ __RPC__out boolean *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IsStopAvailable(
/* [out][retval] */ __RPC__out boolean *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IsVolumeAvailable(
/* [out][retval] */ __RPC__out boolean *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_PlaySpeeds(
/* [out][retval] */ __RPC__deref_out_opt __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed **value) = 0;
};
extern const __declspec(selectany) IID & IID_IMediaRendererActionInformation = __uuidof(IMediaRendererActionInformation);
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#else /* C style interface */
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformationVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_IsMuteAvailable )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation * This,
/* [out][retval] */ __RPC__out boolean *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_IsPauseAvailable )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation * This,
/* [out][retval] */ __RPC__out boolean *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_IsPlayAvailable )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation * This,
/* [out][retval] */ __RPC__out boolean *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_IsSeekAvailable )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation * This,
/* [out][retval] */ __RPC__out boolean *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_IsSetNextSourceAvailable )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation * This,
/* [out][retval] */ __RPC__out boolean *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_IsStopAvailable )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation * This,
/* [out][retval] */ __RPC__out boolean *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_IsVolumeAvailable )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation * This,
/* [out][retval] */ __RPC__out boolean *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_PlaySpeeds )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation * This,
/* [out][retval] */ __RPC__deref_out_opt __FIVector_1_Windows__CMedia__CStreaming__CPlaySpeed **value);
END_INTERFACE
} __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformationVtbl;
interface __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation
{
CONST_VTBL struct __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformationVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_get_IsMuteAvailable(This,value) \
( (This)->lpVtbl -> get_IsMuteAvailable(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_get_IsPauseAvailable(This,value) \
( (This)->lpVtbl -> get_IsPauseAvailable(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_get_IsPlayAvailable(This,value) \
( (This)->lpVtbl -> get_IsPlayAvailable(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_get_IsSeekAvailable(This,value) \
( (This)->lpVtbl -> get_IsSeekAvailable(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_get_IsSetNextSourceAvailable(This,value) \
( (This)->lpVtbl -> get_IsSetNextSourceAvailable(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_get_IsStopAvailable(This,value) \
( (This)->lpVtbl -> get_IsStopAvailable(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_get_IsVolumeAvailable(This,value) \
( (This)->lpVtbl -> get_IsVolumeAvailable(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_get_PlaySpeeds(This,value) \
( (This)->lpVtbl -> get_PlaySpeeds(This,value) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0074 */
/* [local] */
#if !defined(____x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_INTERFACE_DEFINED__)
extern const __declspec(selectany) WCHAR InterfaceName_Windows_Media_Streaming_ITransportParameters[] = L"Windows.Media.Streaming.ITransportParameters";
#endif /* !defined(____x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_INTERFACE_DEFINED__) */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0074 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0074_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0074_v0_0_s_ifspec;
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_INTERFACE_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_INTERFACE_DEFINED__
/* interface __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters */
/* [uuid][object] */
/* interface ABI::Windows::Media::Streaming::ITransportParameters */
/* [uuid][object] */
EXTERN_C const IID IID___x_ABI_CWindows_CMedia_CStreaming_CITransportParameters;
#if defined(__cplusplus) && !defined(CINTERFACE)
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
MIDL_INTERFACE("eb0c4e24-2283-438d-8fff-dbe9df1cb2cc")
ITransportParameters : public IInspectable
{
public:
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_ActionInformation(
/* [out][retval] */ __RPC__deref_out_opt ABI::Windows::Media::Streaming::IMediaRendererActionInformation **value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_TrackInformation(
/* [out][retval] */ __RPC__out ABI::Windows::Media::Streaming::TrackInformation *value) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_TransportInformation(
/* [out][retval] */ __RPC__out ABI::Windows::Media::Streaming::TransportInformation *value) = 0;
};
extern const __declspec(selectany) IID & IID_ITransportParameters = __uuidof(ITransportParameters);
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#else /* C style interface */
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_ActionInformation )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters * This,
/* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererActionInformation **value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_TrackInformation )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters * This,
/* [out][retval] */ __RPC__out __x_ABI_CWindows_CMedia_CStreaming_CTrackInformation *value);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_TransportInformation )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters * This,
/* [out][retval] */ __RPC__out __x_ABI_CWindows_CMedia_CStreaming_CTransportInformation *value);
END_INTERFACE
} __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersVtbl;
interface __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters
{
CONST_VTBL struct __x_ABI_CWindows_CMedia_CStreaming_CITransportParametersVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_get_ActionInformation(This,value) \
( (This)->lpVtbl -> get_ActionInformation(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_get_TrackInformation(This,value) \
( (This)->lpVtbl -> get_TrackInformation(This,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_get_TransportInformation(This,value) \
( (This)->lpVtbl -> get_TransportInformation(This,value) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CITransportParameters_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0075 */
/* [local] */
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
class CreateMediaRendererOperation;
} /*Streaming*/
} /*Media*/
} /*Windows*/
}
#endif
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0075 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0075_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0075_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0480 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0480 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0480_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0480_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0076 */
/* [local] */
#ifndef DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer
#define DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0076 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0076_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0076_v0_0_s_ifspec;
#ifndef ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_INTERFACE_DEFINED__
#define ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_INTERFACE_DEFINED__
/* interface __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer */
/* [unique][uuid][object] */
/* interface __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("f0d971af-e054-5616-9fdf-0903b9ceb182")
__FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE Invoke(
/* [in] */ __RPC__in_opt __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer *asyncInfo,
/* [in] */ AsyncStatus status) = 0;
};
#else /* C style interface */
typedef struct __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRendererVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer * This);
HRESULT ( STDMETHODCALLTYPE *Invoke )(
__RPC__in __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer * This,
/* [in] */ __RPC__in_opt __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer *asyncInfo,
/* [in] */ AsyncStatus status);
END_INTERFACE
} __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRendererVtbl;
interface __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer
{
CONST_VTBL struct __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRendererVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_Invoke(This,asyncInfo,status) \
( (This)->lpVtbl -> Invoke(This,asyncInfo,status) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0077 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0077 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0077_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0077_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0481 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0481 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0481_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0481_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0078 */
/* [local] */
#ifndef DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer
#define DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0078 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0078_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0078_v0_0_s_ifspec;
#ifndef ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_INTERFACE_DEFINED__
#define ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_INTERFACE_DEFINED__
/* interface __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer */
/* [unique][uuid][object] */
/* interface __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("557dd3fb-4710-5059-921c-0dee68361fb5")
__FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer : public IInspectable
{
public:
virtual /* [propput] */ HRESULT STDMETHODCALLTYPE put_Completed(
/* [in] */ __RPC__in_opt __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer *handler) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Completed(
/* [retval][out] */ __RPC__deref_out_opt __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer **handler) = 0;
virtual HRESULT STDMETHODCALLTYPE GetResults(
/* [retval][out] */ __RPC__deref_out_opt ABI::Windows::Media::Streaming::IMediaRenderer **results) = 0;
};
#else /* C style interface */
typedef struct __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRendererVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
/* [propput] */ HRESULT ( STDMETHODCALLTYPE *put_Completed )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer * This,
/* [in] */ __RPC__in_opt __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer *handler);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Completed )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer * This,
/* [retval][out] */ __RPC__deref_out_opt __FIAsyncOperationCompletedHandler_1_Windows__CMedia__CStreaming__CMediaRenderer **handler);
HRESULT ( STDMETHODCALLTYPE *GetResults )(
__RPC__in __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer * This,
/* [retval][out] */ __RPC__deref_out_opt __x_ABI_CWindows_CMedia_CStreaming_CIMediaRenderer **results);
END_INTERFACE
} __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRendererVtbl;
interface __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer
{
CONST_VTBL struct __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRendererVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_put_Completed(This,handler) \
( (This)->lpVtbl -> put_Completed(This,handler) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_get_Completed(This,handler) \
( (This)->lpVtbl -> get_Completed(This,handler) )
#define __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_GetResults(This,results) \
( (This)->lpVtbl -> GetResults(This,results) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0079 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer */
#ifndef RUNTIMECLASS_Windows_Media_Streaming_CreateMediaRendererOperation_DEFINED
#define RUNTIMECLASS_Windows_Media_Streaming_CreateMediaRendererOperation_DEFINED
extern const __declspec(selectany) WCHAR RuntimeClass_Windows_Media_Streaming_CreateMediaRendererOperation[] = L"Windows.Media.Streaming.CreateMediaRendererOperation";
#endif
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
class DeviceController;
} /*Streaming*/
} /*Media*/
} /*Windows*/
}
#endif
#ifndef RUNTIMECLASS_Windows_Media_Streaming_DeviceController_DEFINED
#define RUNTIMECLASS_Windows_Media_Streaming_DeviceController_DEFINED
extern const __declspec(selectany) WCHAR RuntimeClass_Windows_Media_Streaming_DeviceController[] = L"Windows.Media.Streaming.DeviceController";
#endif
#ifdef __cplusplus
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
class BasicDevice;
} /*Streaming*/
} /*Media*/
} /*Windows*/
}
#endif
#ifndef RUNTIMECLASS_Windows_Media_Streaming_BasicDevice_DEFINED
#define RUNTIMECLASS_Windows_Media_Streaming_BasicDevice_DEFINED
extern const __declspec(selectany) WCHAR RuntimeClass_Windows_Media_Streaming_BasicDevice[] = L"Windows.Media.Streaming.BasicDevice";
#endif
#ifndef RUNTIMECLASS_Windows_Media_Streaming_MediaRenderer_DEFINED
#define RUNTIMECLASS_Windows_Media_Streaming_MediaRenderer_DEFINED
extern const __declspec(selectany) WCHAR RuntimeClass_Windows_Media_Streaming_MediaRenderer[] = L"Windows.Media.Streaming.MediaRenderer";
#endif
#if !defined(____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_INTERFACE_DEFINED__)
extern const __declspec(selectany) WCHAR InterfaceName_Windows_Media_Streaming_IMediaRendererFactory[] = L"Windows.Media.Streaming.IMediaRendererFactory";
#endif /* !defined(____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_INTERFACE_DEFINED__) */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0079 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0079_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0079_v0_0_s_ifspec;
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_INTERFACE_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_INTERFACE_DEFINED__
/* interface __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory */
/* [uuid][object] */
/* interface ABI::Windows::Media::Streaming::IMediaRendererFactory */
/* [uuid][object] */
EXTERN_C const IID IID___x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory;
#if defined(__cplusplus) && !defined(CINTERFACE)
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
MIDL_INTERFACE("657ab43d-b909-42b2-94d0-e3a0b134e8c9")
IMediaRendererFactory : public IInspectable
{
public:
virtual HRESULT STDMETHODCALLTYPE CreateMediaRendererAsync(
/* [in] */ __RPC__in HSTRING deviceIdentifier,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer **value) = 0;
virtual HRESULT STDMETHODCALLTYPE CreateMediaRendererFromBasicDeviceAsync(
/* [in] */ __RPC__in_opt ABI::Windows::Media::Streaming::IBasicDevice *basicDevice,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer **value) = 0;
};
extern const __declspec(selectany) IID & IID_IMediaRendererFactory = __uuidof(IMediaRendererFactory);
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#else /* C style interface */
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactoryVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
HRESULT ( STDMETHODCALLTYPE *CreateMediaRendererAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory * This,
/* [in] */ __RPC__in HSTRING deviceIdentifier,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer **value);
HRESULT ( STDMETHODCALLTYPE *CreateMediaRendererFromBasicDeviceAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CMedia_CStreaming_CIBasicDevice *basicDevice,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_Windows__CMedia__CStreaming__CMediaRenderer **value);
END_INTERFACE
} __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactoryVtbl;
interface __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory
{
CONST_VTBL struct __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactoryVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_CreateMediaRendererAsync(This,deviceIdentifier,value) \
( (This)->lpVtbl -> CreateMediaRendererAsync(This,deviceIdentifier,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_CreateMediaRendererFromBasicDeviceAsync(This,basicDevice,value) \
( (This)->lpVtbl -> CreateMediaRendererFromBasicDeviceAsync(This,basicDevice,value) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIMediaRendererFactory_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0080 */
/* [local] */
#ifndef RUNTIMECLASS_Windows_Media_Streaming_StreamSelector_DEFINED
#define RUNTIMECLASS_Windows_Media_Streaming_StreamSelector_DEFINED
extern const __declspec(selectany) WCHAR RuntimeClass_Windows_Media_Streaming_StreamSelector[] = L"Windows.Media.Streaming.StreamSelector";
#endif
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0080 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0080_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0080_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0482 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0482 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0482_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0482_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0081 */
/* [local] */
#ifndef DEF___FIIterator_1___F__CIPropertySet
#define DEF___FIIterator_1___F__CIPropertySet
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0081 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0081_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0081_v0_0_s_ifspec;
#ifndef ____FIIterator_1___F__CIPropertySet_INTERFACE_DEFINED__
#define ____FIIterator_1___F__CIPropertySet_INTERFACE_DEFINED__
/* interface __FIIterator_1___F__CIPropertySet */
/* [unique][uuid][object] */
/* interface __FIIterator_1___F__CIPropertySet */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIIterator_1___F__CIPropertySet;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("d79a75c8-b1d2-544d-9b09-7f7900a34efb")
__FIIterator_1___F__CIPropertySet : public IInspectable
{
public:
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Current(
/* [retval][out] */ __RPC__deref_out_opt ABI::Windows::Foundation::Collections::IPropertySet **current) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_HasCurrent(
/* [retval][out] */ __RPC__out boolean *hasCurrent) = 0;
virtual HRESULT STDMETHODCALLTYPE MoveNext(
/* [retval][out] */ __RPC__out boolean *hasCurrent) = 0;
virtual HRESULT STDMETHODCALLTYPE GetMany(
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) ABI::Windows::Foundation::Collections::IPropertySet **items,
/* [retval][out] */ __RPC__out unsigned int *actual) = 0;
};
#else /* C style interface */
typedef struct __FIIterator_1___F__CIPropertySetVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIIterator_1___F__CIPropertySet * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIIterator_1___F__CIPropertySet * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIIterator_1___F__CIPropertySet * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIIterator_1___F__CIPropertySet * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIIterator_1___F__CIPropertySet * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIIterator_1___F__CIPropertySet * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Current )(
__RPC__in __FIIterator_1___F__CIPropertySet * This,
/* [retval][out] */ __RPC__deref_out_opt __x_ABI_CWindows_CFoundation_CCollections_CIPropertySet **current);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_HasCurrent )(
__RPC__in __FIIterator_1___F__CIPropertySet * This,
/* [retval][out] */ __RPC__out boolean *hasCurrent);
HRESULT ( STDMETHODCALLTYPE *MoveNext )(
__RPC__in __FIIterator_1___F__CIPropertySet * This,
/* [retval][out] */ __RPC__out boolean *hasCurrent);
HRESULT ( STDMETHODCALLTYPE *GetMany )(
__RPC__in __FIIterator_1___F__CIPropertySet * This,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) __x_ABI_CWindows_CFoundation_CCollections_CIPropertySet **items,
/* [retval][out] */ __RPC__out unsigned int *actual);
END_INTERFACE
} __FIIterator_1___F__CIPropertySetVtbl;
interface __FIIterator_1___F__CIPropertySet
{
CONST_VTBL struct __FIIterator_1___F__CIPropertySetVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIIterator_1___F__CIPropertySet_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIIterator_1___F__CIPropertySet_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIIterator_1___F__CIPropertySet_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIIterator_1___F__CIPropertySet_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIIterator_1___F__CIPropertySet_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIIterator_1___F__CIPropertySet_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIIterator_1___F__CIPropertySet_get_Current(This,current) \
( (This)->lpVtbl -> get_Current(This,current) )
#define __FIIterator_1___F__CIPropertySet_get_HasCurrent(This,hasCurrent) \
( (This)->lpVtbl -> get_HasCurrent(This,hasCurrent) )
#define __FIIterator_1___F__CIPropertySet_MoveNext(This,hasCurrent) \
( (This)->lpVtbl -> MoveNext(This,hasCurrent) )
#define __FIIterator_1___F__CIPropertySet_GetMany(This,capacity,items,actual) \
( (This)->lpVtbl -> GetMany(This,capacity,items,actual) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIIterator_1___F__CIPropertySet_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0082 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIIterator_1___F__CIPropertySet */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0082 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0082_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0082_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0483 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0483 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0483_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0483_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0083 */
/* [local] */
#ifndef DEF___FIIterable_1___F__CIPropertySet
#define DEF___FIIterable_1___F__CIPropertySet
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0083 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0083_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0083_v0_0_s_ifspec;
#ifndef ____FIIterable_1___F__CIPropertySet_INTERFACE_DEFINED__
#define ____FIIterable_1___F__CIPropertySet_INTERFACE_DEFINED__
/* interface __FIIterable_1___F__CIPropertySet */
/* [unique][uuid][object] */
/* interface __FIIterable_1___F__CIPropertySet */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIIterable_1___F__CIPropertySet;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("489b756d-be43-5abb-b9a0-a47254103339")
__FIIterable_1___F__CIPropertySet : public IInspectable
{
public:
virtual HRESULT STDMETHODCALLTYPE First(
/* [retval][out] */ __RPC__deref_out_opt __FIIterator_1___F__CIPropertySet **first) = 0;
};
#else /* C style interface */
typedef struct __FIIterable_1___F__CIPropertySetVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIIterable_1___F__CIPropertySet * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIIterable_1___F__CIPropertySet * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIIterable_1___F__CIPropertySet * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIIterable_1___F__CIPropertySet * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIIterable_1___F__CIPropertySet * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIIterable_1___F__CIPropertySet * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
HRESULT ( STDMETHODCALLTYPE *First )(
__RPC__in __FIIterable_1___F__CIPropertySet * This,
/* [retval][out] */ __RPC__deref_out_opt __FIIterator_1___F__CIPropertySet **first);
END_INTERFACE
} __FIIterable_1___F__CIPropertySetVtbl;
interface __FIIterable_1___F__CIPropertySet
{
CONST_VTBL struct __FIIterable_1___F__CIPropertySetVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIIterable_1___F__CIPropertySet_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIIterable_1___F__CIPropertySet_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIIterable_1___F__CIPropertySet_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIIterable_1___F__CIPropertySet_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIIterable_1___F__CIPropertySet_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIIterable_1___F__CIPropertySet_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIIterable_1___F__CIPropertySet_First(This,first) \
( (This)->lpVtbl -> First(This,first) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIIterable_1___F__CIPropertySet_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0084 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIIterable_1___F__CIPropertySet */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0084 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0084_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0084_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0484 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0484 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0484_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0484_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0085 */
/* [local] */
#ifndef DEF___FIVectorView_1___F__CIPropertySet
#define DEF___FIVectorView_1___F__CIPropertySet
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0085 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0085_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0085_v0_0_s_ifspec;
#ifndef ____FIVectorView_1___F__CIPropertySet_INTERFACE_DEFINED__
#define ____FIVectorView_1___F__CIPropertySet_INTERFACE_DEFINED__
/* interface __FIVectorView_1___F__CIPropertySet */
/* [unique][uuid][object] */
/* interface __FIVectorView_1___F__CIPropertySet */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIVectorView_1___F__CIPropertySet;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("c25d9a17-c31e-5311-8122-3c04d28af9fc")
__FIVectorView_1___F__CIPropertySet : public IInspectable
{
public:
virtual HRESULT STDMETHODCALLTYPE GetAt(
/* [in] */ unsigned int index,
/* [retval][out] */ __RPC__deref_out_opt ABI::Windows::Foundation::Collections::IPropertySet **item) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Size(
/* [retval][out] */ __RPC__out unsigned int *size) = 0;
virtual HRESULT STDMETHODCALLTYPE IndexOf(
/* [in] */ __RPC__in_opt ABI::Windows::Foundation::Collections::IPropertySet *item,
/* [out] */ __RPC__out unsigned int *index,
/* [retval][out] */ __RPC__out boolean *found) = 0;
virtual HRESULT STDMETHODCALLTYPE GetMany(
/* [in] */ unsigned int startIndex,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) ABI::Windows::Foundation::Collections::IPropertySet **items,
/* [retval][out] */ __RPC__out unsigned int *actual) = 0;
};
#else /* C style interface */
typedef struct __FIVectorView_1___F__CIPropertySetVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIVectorView_1___F__CIPropertySet * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIVectorView_1___F__CIPropertySet * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIVectorView_1___F__CIPropertySet * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIVectorView_1___F__CIPropertySet * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIVectorView_1___F__CIPropertySet * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIVectorView_1___F__CIPropertySet * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
HRESULT ( STDMETHODCALLTYPE *GetAt )(
__RPC__in __FIVectorView_1___F__CIPropertySet * This,
/* [in] */ unsigned int index,
/* [retval][out] */ __RPC__deref_out_opt __x_ABI_CWindows_CFoundation_CCollections_CIPropertySet **item);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Size )(
__RPC__in __FIVectorView_1___F__CIPropertySet * This,
/* [retval][out] */ __RPC__out unsigned int *size);
HRESULT ( STDMETHODCALLTYPE *IndexOf )(
__RPC__in __FIVectorView_1___F__CIPropertySet * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CFoundation_CCollections_CIPropertySet *item,
/* [out] */ __RPC__out unsigned int *index,
/* [retval][out] */ __RPC__out boolean *found);
HRESULT ( STDMETHODCALLTYPE *GetMany )(
__RPC__in __FIVectorView_1___F__CIPropertySet * This,
/* [in] */ unsigned int startIndex,
/* [in] */ unsigned int capacity,
/* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) __x_ABI_CWindows_CFoundation_CCollections_CIPropertySet **items,
/* [retval][out] */ __RPC__out unsigned int *actual);
END_INTERFACE
} __FIVectorView_1___F__CIPropertySetVtbl;
interface __FIVectorView_1___F__CIPropertySet
{
CONST_VTBL struct __FIVectorView_1___F__CIPropertySetVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIVectorView_1___F__CIPropertySet_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIVectorView_1___F__CIPropertySet_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIVectorView_1___F__CIPropertySet_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIVectorView_1___F__CIPropertySet_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIVectorView_1___F__CIPropertySet_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIVectorView_1___F__CIPropertySet_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIVectorView_1___F__CIPropertySet_GetAt(This,index,item) \
( (This)->lpVtbl -> GetAt(This,index,item) )
#define __FIVectorView_1___F__CIPropertySet_get_Size(This,size) \
( (This)->lpVtbl -> get_Size(This,size) )
#define __FIVectorView_1___F__CIPropertySet_IndexOf(This,item,index,found) \
( (This)->lpVtbl -> IndexOf(This,item,index,found) )
#define __FIVectorView_1___F__CIPropertySet_GetMany(This,startIndex,capacity,items,actual) \
( (This)->lpVtbl -> GetMany(This,startIndex,capacity,items,actual) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIVectorView_1___F__CIPropertySet_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0086 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIVectorView_1___F__CIPropertySet */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0086 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0086_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0086_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0485 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0485 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0485_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0485_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0087 */
/* [local] */
#ifndef DEF___FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet
#define DEF___FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0087 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0087_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0087_v0_0_s_ifspec;
#ifndef ____FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_INTERFACE_DEFINED__
#define ____FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_INTERFACE_DEFINED__
/* interface __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet */
/* [unique][uuid][object] */
/* interface __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("af4e2f8a-92ca-5640-865c-9948fbde4495")
__FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet : public IUnknown
{
public:
virtual HRESULT STDMETHODCALLTYPE Invoke(
/* [in] */ __RPC__in_opt __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet *asyncInfo,
/* [in] */ AsyncStatus status) = 0;
};
#else /* C style interface */
typedef struct __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySetVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet * This);
HRESULT ( STDMETHODCALLTYPE *Invoke )(
__RPC__in __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet * This,
/* [in] */ __RPC__in_opt __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet *asyncInfo,
/* [in] */ AsyncStatus status);
END_INTERFACE
} __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySetVtbl;
interface __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet
{
CONST_VTBL struct __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySetVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_Invoke(This,asyncInfo,status) \
( (This)->lpVtbl -> Invoke(This,asyncInfo,status) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0088 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0088 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0088_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0088_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0486 */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0486 */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0486_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0486_v0_0_s_ifspec;
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0089 */
/* [local] */
#ifndef DEF___FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet
#define DEF___FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet
#if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME)
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0089 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0089_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0089_v0_0_s_ifspec;
#ifndef ____FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_INTERFACE_DEFINED__
#define ____FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_INTERFACE_DEFINED__
/* interface __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet */
/* [unique][uuid][object] */
/* interface __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet */
/* [unique][uuid][object] */
EXTERN_C const IID IID___FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet;
#if defined(__cplusplus) && !defined(CINTERFACE)
MIDL_INTERFACE("216f9390-ea3d-5465-a789-6394a47eb4a4")
__FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet : public IInspectable
{
public:
virtual /* [propput] */ HRESULT STDMETHODCALLTYPE put_Completed(
/* [in] */ __RPC__in_opt __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet *handler) = 0;
virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Completed(
/* [retval][out] */ __RPC__deref_out_opt __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet **handler) = 0;
virtual HRESULT STDMETHODCALLTYPE GetResults(
/* [retval][out] */ __RPC__deref_out_opt __FIVectorView_1___F__CIPropertySet **results) = 0;
};
#else /* C style interface */
typedef struct __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySetVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
/* [propput] */ HRESULT ( STDMETHODCALLTYPE *put_Completed )(
__RPC__in __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet * This,
/* [in] */ __RPC__in_opt __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet *handler);
/* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Completed )(
__RPC__in __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet * This,
/* [retval][out] */ __RPC__deref_out_opt __FIAsyncOperationCompletedHandler_1___FIVectorView_1___F__CIPropertySet **handler);
HRESULT ( STDMETHODCALLTYPE *GetResults )(
__RPC__in __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet * This,
/* [retval][out] */ __RPC__deref_out_opt __FIVectorView_1___F__CIPropertySet **results);
END_INTERFACE
} __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySetVtbl;
interface __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet
{
CONST_VTBL struct __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySetVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_put_Completed(This,handler) \
( (This)->lpVtbl -> put_Completed(This,handler) )
#define __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_get_Completed(This,handler) \
( (This)->lpVtbl -> get_Completed(This,handler) )
#define __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_GetResults(This,results) \
( (This)->lpVtbl -> GetResults(This,results) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet_INTERFACE_DEFINED__ */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0090 */
/* [local] */
#endif /* pinterface */
#endif /* DEF___FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet */
#if !defined(____x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_INTERFACE_DEFINED__)
extern const __declspec(selectany) WCHAR InterfaceName_Windows_Media_Streaming_IStreamSelectorStatics[] = L"Windows.Media.Streaming.IStreamSelectorStatics";
#endif /* !defined(____x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_INTERFACE_DEFINED__) */
/* interface __MIDL_itf_windows2Emedia2Estreaming_0000_0090 */
/* [local] */
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0090_v0_0_c_ifspec;
extern RPC_IF_HANDLE __MIDL_itf_windows2Emedia2Estreaming_0000_0090_v0_0_s_ifspec;
#ifndef ____x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_INTERFACE_DEFINED__
#define ____x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_INTERFACE_DEFINED__
/* interface __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics */
/* [uuid][object] */
/* interface ABI::Windows::Media::Streaming::IStreamSelectorStatics */
/* [uuid][object] */
EXTERN_C const IID IID___x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics;
#if defined(__cplusplus) && !defined(CINTERFACE)
} /* end extern "C" */
namespace ABI {
namespace Windows {
namespace Media {
namespace Streaming {
MIDL_INTERFACE("8a4cd4a1-ed85-4e0f-bd68-8a6862e4636d")
IStreamSelectorStatics : public IInspectable
{
public:
virtual HRESULT STDMETHODCALLTYPE SelectBestStreamAsync(
/* [in] */ __RPC__in_opt ABI::Windows::Storage::IStorageFile *storageFile,
/* [in] */ __RPC__in_opt ABI::Windows::Foundation::Collections::IPropertySet *selectorProperties,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType **value) = 0;
virtual HRESULT STDMETHODCALLTYPE GetStreamPropertiesAsync(
/* [in] */ __RPC__in_opt ABI::Windows::Storage::IStorageFile *storageFile,
/* [in] */ __RPC__in_opt ABI::Windows::Foundation::Collections::IPropertySet *selectorProperties,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet **value) = 0;
virtual HRESULT STDMETHODCALLTYPE SelectBestStreamFromStreamAsync(
/* [in] */ __RPC__in_opt ABI::Windows::Storage::Streams::IRandomAccessStream *stream,
/* [in] */ __RPC__in_opt ABI::Windows::Foundation::Collections::IPropertySet *selectorProperties,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType **value) = 0;
virtual HRESULT STDMETHODCALLTYPE GetStreamPropertiesFromStreamAsync(
/* [in] */ __RPC__in_opt ABI::Windows::Storage::Streams::IRandomAccessStream *stream,
/* [in] */ __RPC__in_opt ABI::Windows::Foundation::Collections::IPropertySet *selectorProperties,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet **value) = 0;
};
extern const __declspec(selectany) IID & IID_IStreamSelectorStatics = __uuidof(IStreamSelectorStatics);
} /* end namespace */
} /* end namespace */
} /* end namespace */
} /* end namespace */
extern "C" {
#else /* C style interface */
typedef struct __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStaticsVtbl
{
BEGIN_INTERFACE
HRESULT ( STDMETHODCALLTYPE *QueryInterface )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics * This,
/* [in] */ __RPC__in REFIID riid,
/* [annotation][iid_is][out] */
_COM_Outptr_ void **ppvObject);
ULONG ( STDMETHODCALLTYPE *AddRef )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics * This);
ULONG ( STDMETHODCALLTYPE *Release )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics * This);
HRESULT ( STDMETHODCALLTYPE *GetIids )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics * This,
/* [out] */ __RPC__out ULONG *iidCount,
/* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids);
HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics * This,
/* [out] */ __RPC__deref_out_opt HSTRING *className);
HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics * This,
/* [out] */ __RPC__out TrustLevel *trustLevel);
HRESULT ( STDMETHODCALLTYPE *SelectBestStreamAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CStorage_CIStorageFile *storageFile,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CFoundation_CCollections_CIPropertySet *selectorProperties,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType **value);
HRESULT ( STDMETHODCALLTYPE *GetStreamPropertiesAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CStorage_CIStorageFile *storageFile,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CFoundation_CCollections_CIPropertySet *selectorProperties,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet **value);
HRESULT ( STDMETHODCALLTYPE *SelectBestStreamFromStreamAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CStorage_CStreams_CIRandomAccessStream *stream,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CFoundation_CCollections_CIPropertySet *selectorProperties,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_Windows__CStorage__CStreams__CIRandomAccessStreamWithContentType **value);
HRESULT ( STDMETHODCALLTYPE *GetStreamPropertiesFromStreamAsync )(
__RPC__in __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics * This,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CStorage_CStreams_CIRandomAccessStream *stream,
/* [in] */ __RPC__in_opt __x_ABI_CWindows_CFoundation_CCollections_CIPropertySet *selectorProperties,
/* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1___FIVectorView_1___F__CIPropertySet **value);
END_INTERFACE
} __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStaticsVtbl;
interface __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics
{
CONST_VTBL struct __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStaticsVtbl *lpVtbl;
};
#ifdef COBJMACROS
#define __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_QueryInterface(This,riid,ppvObject) \
( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_AddRef(This) \
( (This)->lpVtbl -> AddRef(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_Release(This) \
( (This)->lpVtbl -> Release(This) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_GetIids(This,iidCount,iids) \
( (This)->lpVtbl -> GetIids(This,iidCount,iids) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_GetRuntimeClassName(This,className) \
( (This)->lpVtbl -> GetRuntimeClassName(This,className) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_GetTrustLevel(This,trustLevel) \
( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_SelectBestStreamAsync(This,storageFile,selectorProperties,value) \
( (This)->lpVtbl -> SelectBestStreamAsync(This,storageFile,selectorProperties,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_GetStreamPropertiesAsync(This,storageFile,selectorProperties,value) \
( (This)->lpVtbl -> GetStreamPropertiesAsync(This,storageFile,selectorProperties,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_SelectBestStreamFromStreamAsync(This,stream,selectorProperties,value) \
( (This)->lpVtbl -> SelectBestStreamFromStreamAsync(This,stream,selectorProperties,value) )
#define __x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_GetStreamPropertiesFromStreamAsync(This,stream,selectorProperties,value) \
( (This)->lpVtbl -> GetStreamPropertiesFromStreamAsync(This,stream,selectorProperties,value) )
#endif /* COBJMACROS */
#endif /* C style interface */
#endif /* ____x_ABI_CWindows_CMedia_CStreaming_CIStreamSelectorStatics_INTERFACE_DEFINED__ */
/* Additional Prototypes for ALL interfaces */
unsigned long __RPC_USER HSTRING_UserSize( __RPC__in unsigned long *, unsigned long , __RPC__in HSTRING * );
unsigned char * __RPC_USER HSTRING_UserMarshal( __RPC__in unsigned long *, __RPC__inout_xcount(0) unsigned char *, __RPC__in HSTRING * );
unsigned char * __RPC_USER HSTRING_UserUnmarshal(__RPC__in unsigned long *, __RPC__in_xcount(0) unsigned char *, __RPC__out HSTRING * );
void __RPC_USER HSTRING_UserFree( __RPC__in unsigned long *, __RPC__in HSTRING * );
unsigned long __RPC_USER HSTRING_UserSize64( __RPC__in unsigned long *, unsigned long , __RPC__in HSTRING * );
unsigned char * __RPC_USER HSTRING_UserMarshal64( __RPC__in unsigned long *, __RPC__inout_xcount(0) unsigned char *, __RPC__in HSTRING * );
unsigned char * __RPC_USER HSTRING_UserUnmarshal64(__RPC__in unsigned long *, __RPC__in_xcount(0) unsigned char *, __RPC__out HSTRING * );
void __RPC_USER HSTRING_UserFree64( __RPC__in unsigned long *, __RPC__in HSTRING * );
/* end of Additional Prototypes */
#ifdef __cplusplus
}
#endif
#endif
| [
"fajaralmunawwar@yahoo.com"
] | fajaralmunawwar@yahoo.com |
97ac5d0a0df6c589fc5552cf2c7f44baad4dcf25 | 14ce01a6f9199d39e28d036e066d99cfb3e3f211 | /Cpp/SDK/BP_USCG_MediumSkiff_Debris_LeftRear_Minion_classes.h | 711e67a9bfeb828ca98286884b5155be4f3c385b | [] | no_license | zH4x-SDK/zManEater-SDK | 73f14dd8f758bb7eac649f0c66ce29f9974189b7 | d040c05a93c0935d8052dd3827c2ef91c128bce7 | refs/heads/main | 2023-07-19T04:54:51.672951 | 2021-08-27T13:47:27 | 2021-08-27T13:47:27 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 922 | h | ๏ปฟ#pragma once
// Name: ManEater, Version: 1.0.0
/*!!DEFINE!!*/
/*!!HELPER_DEF!!*/
/*!!HELPER_INC!!*/
#ifdef _MSC_VER
#pragma pack(push, 0x01)
#endif
namespace CG
{
//---------------------------------------------------------------------------
// Classes
//---------------------------------------------------------------------------
// BlueprintGeneratedClass BP_USCG_MediumSkiff_Debris_LeftRear_Minion.BP_USCG_MediumSkiff_Debris_LeftRear_Minion_C
// 0x0000 (FullSize[0x0230] - InheritedSize[0x0230])
class ABP_USCG_MediumSkiff_Debris_LeftRear_Minion_C : public ABP_VehicleDebris_C
{
public:
static UClass* StaticClass()
{
static auto ptr = UObject::FindClass("BlueprintGeneratedClass BP_USCG_MediumSkiff_Debris_LeftRear_Minion.BP_USCG_MediumSkiff_Debris_LeftRear_Minion_C");
return ptr;
}
int GetSizeLevel(class AME_AnimalCharacter* GrabbingAnimal);
};
}
#ifdef _MSC_VER
#pragma pack(pop)
#endif
| [
"zp2kshield@gmail.com"
] | zp2kshield@gmail.com |
cb2e6879706cf1c56bc33ee8877ed809dae40206 | f776316d0a7c44e887feaa675f030f27da2d022b | /4490/proj2/Parser.h | 25f8ad9de98c1a07a86cf3fbff4ebaa0578dabb0 | [] | no_license | taxilian/old_cs_vm | 647246e16e7d695833c5dc69b2c06eb9af24a739 | a83142afa8d52eb07c0a6d30ff57ffa7dbbc30de | refs/heads/master | 2016-09-06T16:45:12.267205 | 2011-04-27T19:03:20 | 2011-04-27T19:03:20 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,674 | h | /**
* Parser.h
*
* Richard Bateman
* Virtual Machine Assembly parser
*/
#pragma once
#ifndef H_PARSER
#define H_PARSER
#include <string>
#include <vector>
#include <fstream>
#include <deque>
#include <boost/shared_ptr.hpp>
#include <boost/tokenizer.hpp>
#include "VMConfig.h"
typedef boost::tokenizer< boost::escaped_list_separator<char> > Tokenizer;
struct ParserException : std::exception
{
ParserException(const std::string& error)
: m_error(error)
{ }
~ParserException() throw() { }
virtual const char* what() const throw() {
return m_error.c_str();
}
std::string m_error;
};
class Parser
{
public:
struct Line {
virtual ~Line() { };
std::string label;
};
struct Byte : public Line {
unsigned char value;
};
struct Int : public Line {
int value;
};
struct Instruction : public Line {
std::string name;
std::vector<std::string> args;
};
typedef boost::shared_ptr<Line> LinePtr;
typedef boost::shared_ptr<Byte> BytePtr;
typedef boost::shared_ptr<Int> IntPtr;
typedef boost::shared_ptr<Instruction> InstructionPtr;
public:
Parser(std::string filename, VMConfigPtr config);
~Parser(void);
protected:
std::string sanitizeString(const std::string &str);
std::vector<std::string> split(const std::string &str, const char *tokens);
public:
void processFile();
LinePtr getNextLine();
std::streamsize getLineNumber() { return m_lineNumber; }
protected:
std::streamsize m_lineNumber;
std::ifstream m_file;
std::deque<LinePtr> m_queue;
VMConfigPtr m_config;
bool end;
};
#endif
| [
"taxilian@gmail.com"
] | taxilian@gmail.com |
ecebfc74e19004d0eec21147d3968103330a8091 | 70022f7e5ac4c229e412b51db248fdd08a0a5b28 | /src/tests/frontend/Linux-g++_(GCC)_4.8.1/cpp/spec-smithwa/getUserParameters.c.pre.transformed.cpp | 32c5d74b78a32895a2d2704ccbff545434cd59a5 | [] | no_license | agrippa/chimes | 6465fc48f118154e9d42fbd26d6b87a7dce7c5e9 | 695bb5bb54efbcd61469acda79b6ba6532e2d1d9 | refs/heads/master | 2020-12-25T14:02:17.752481 | 2016-07-04T02:20:59 | 2016-07-04T02:20:59 | 23,259,130 | 0 | 1 | null | null | null | null | UTF-8 | C++ | false | false | 57,949 | cpp | # 1 "getUserParameters.c.pre.transformed.cpp"
# 1 "<command-line>"
# 1 "/gpfs-biou/jmg3/gcc-install/lib/gcc/powerpc64-unknown-linux-gnu/4.8.1/include/stddef.h" 1 3 4
# 147 "/gpfs-biou/jmg3/gcc-install/lib/gcc/powerpc64-unknown-linux-gnu/4.8.1/include/stddef.h" 3 4
typedef long int ptrdiff_t;
# 212 "/gpfs-biou/jmg3/gcc-install/lib/gcc/powerpc64-unknown-linux-gnu/4.8.1/include/stddef.h" 3 4
typedef long unsigned int size_t;
# 1 "<command-line>" 2
# 1 "getUserParameters.c.pre.transformed.cpp"
static int ____chimes_does_checkpoint_getUserParameters_npm = 1;
static int ____must_manage_getUserParameters = 2;
# 1 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
# 1 "/tmp/chimes-frontend//"
# 1 "<command-line>"
# 1 "/home/jmg3/chimes/src/libchimes/libchimes.h" 1
# 1 "/gpfs-biou/jmg3/gcc-install/lib/gcc/powerpc64-unknown-linux-gnu/4.8.1/include/stddef.h" 1 3 4
# 147 "/gpfs-biou/jmg3/gcc-install/lib/gcc/powerpc64-unknown-linux-gnu/4.8.1/include/stddef.h" 3 4
typedef long int ptrdiff_t;
# 212 "/gpfs-biou/jmg3/gcc-install/lib/gcc/powerpc64-unknown-linux-gnu/4.8.1/include/stddef.h" 3 4
typedef long unsigned int size_t;
# 5 "/home/jmg3/chimes/src/libchimes/libchimes.h" 2
extern void init_chimes(int argc, char **argv);
extern void checkpoint_transformed(int lbl, unsigned loc_id);
extern void *translate_fptr(void *fptr, int lbl, unsigned loc_id,
size_t return_alias, int n_params, ...);
extern void calling_npm(const char *name, unsigned loc_id);
extern void calling(void *func_ptr, int lbl, unsigned loc_id,
size_t set_return_alias, unsigned naliases, ...);
extern int get_next_call();
extern int new_stack(void *func_ptr, const char *funcname, int *conditional,
unsigned n_local_arg_aliases, unsigned nargs, ...);
extern void init_module(size_t module_id, int n_contains_mappings, int nfunctions,
int nvars, int n_change_locs, int n_provided_npm_functions,
int n_external_npm_functions, int n_npm_conditionals,
int n_static_merges, int n_dynamic_merges, int nstructs, ...);
extern void rm_stack(bool has_return_alias, size_t returned_alias,
const char *funcname, int *conditional, unsigned loc_id, int disabled,
bool is_allocator);
extern void register_stack_var(const char *mangled_name, int *cond_registration,
const char *full_type, void *ptr, size_t size, int is_ptr,
int is_struct, int n_ptr_fields, ...);
extern void register_stack_vars(int nvars, ...);
extern void register_global_var(const char *mangled_name, const char *full_type,
void *ptr, size_t size, int is_ptr, int is_struct, size_t group, int n_ptr_fields,
...);
extern void register_constant(size_t const_id, void *address,
size_t length);
extern int alias_group_changed(unsigned loc_id);
extern void malloc_helper(const void *ptr, size_t nbytes, size_t group, int is_ptr,
int is_struct, ...);
extern void calloc_helper(const void *ptr, size_t num, size_t size, size_t group, int is_ptr,
int is_struct, ...);
extern void realloc_helper(const void *new_ptr, const void *old_ptr,
void *header, size_t nbytes, size_t group, int is_ptr, int is_struct,
...);
extern void free_helper(const void *ptr, size_t group);
extern bool disable_current_thread();
extern void reenable_current_thread(bool was_disabled);
extern void thread_leaving();
extern void *get_thread_ctx();
extern unsigned entering_omp_parallel(unsigned lbl, size_t *region_id,
unsigned nlocals, ...);
extern void register_thread_local_stack_vars(unsigned relation,
unsigned parent, void *parent_ctx_ptr, unsigned threads_in_region,
unsigned parent_stack_depth,
size_t region_id, unsigned nlocals, ...);
extern void leaving_omp_parallel(unsigned expected_parent_stack_depth,
size_t region_id, int is_parallel_for);
extern unsigned get_parent_vars_stack_depth();
extern unsigned get_thread_stack_depth();
extern void chimes_error();
# 76 "/home/jmg3/chimes/src/libchimes/libchimes.h"
inline unsigned LIBCHIMES_THREAD_NUM() { return 0; }
inline unsigned LIBCHIMES_NUM_THREADS() { return 1; }
extern int ____chimes_replaying;
# 1 "<command-line>" 2
# 1 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
# 11 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
# 1 "/usr/include/stdio.h" 1 3 4
# 28 "/usr/include/stdio.h" 3 4
# 1 "/usr/include/features.h" 1 3 4
# 361 "/usr/include/features.h" 3 4
# 1 "/usr/include/sys/cdefs.h" 1 3 4
# 365 "/usr/include/sys/cdefs.h" 3 4
# 1 "/usr/include/bits/wordsize.h" 1 3 4
# 366 "/usr/include/sys/cdefs.h" 2 3 4
# 362 "/usr/include/features.h" 2 3 4
# 385 "/usr/include/features.h" 3 4
# 1 "/usr/include/gnu/stubs.h" 1 3 4
# 1 "/usr/include/bits/wordsize.h" 1 3 4
# 5 "/usr/include/gnu/stubs.h" 2 3 4
# 1 "/usr/include/gnu/stubs-64.h" 1 3 4
# 10 "/usr/include/gnu/stubs.h" 2 3 4
# 386 "/usr/include/features.h" 2 3 4
# 29 "/usr/include/stdio.h" 2 3 4
extern "C" {
# 1 "/gpfs-biou/jmg3/gcc-install/lib/gcc/powerpc64-unknown-linux-gnu/4.8.1/include/stddef.h" 1 3 4
# 35 "/usr/include/stdio.h" 2 3 4
# 1 "/usr/include/bits/types.h" 1 3 4
# 28 "/usr/include/bits/types.h" 3 4
# 1 "/usr/include/bits/wordsize.h" 1 3 4
# 29 "/usr/include/bits/types.h" 2 3 4
typedef unsigned char __u_char;
typedef unsigned short int __u_short;
typedef unsigned int __u_int;
typedef unsigned long int __u_long;
typedef signed char __int8_t;
typedef unsigned char __uint8_t;
typedef signed short int __int16_t;
typedef unsigned short int __uint16_t;
typedef signed int __int32_t;
typedef unsigned int __uint32_t;
typedef signed long int __int64_t;
typedef unsigned long int __uint64_t;
typedef long int __quad_t;
typedef unsigned long int __u_quad_t;
# 131 "/usr/include/bits/types.h" 3 4
# 1 "/usr/include/bits/typesizes.h" 1 3 4
# 132 "/usr/include/bits/types.h" 2 3 4
typedef unsigned long int __dev_t;
typedef unsigned int __uid_t;
typedef unsigned int __gid_t;
typedef unsigned long int __ino_t;
typedef unsigned long int __ino64_t;
typedef unsigned int __mode_t;
typedef unsigned long int __nlink_t;
typedef long int __off_t;
typedef long int __off64_t;
typedef int __pid_t;
typedef struct { int __val[2]; } __fsid_t;
typedef long int __clock_t;
typedef unsigned long int __rlim_t;
typedef unsigned long int __rlim64_t;
typedef unsigned int __id_t;
typedef long int __time_t;
typedef unsigned int __useconds_t;
typedef long int __suseconds_t;
typedef int __daddr_t;
typedef long int __swblk_t;
typedef int __key_t;
typedef int __clockid_t;
typedef void * __timer_t;
typedef long int __blksize_t;
typedef long int __blkcnt_t;
typedef long int __blkcnt64_t;
typedef unsigned long int __fsblkcnt_t;
typedef unsigned long int __fsblkcnt64_t;
typedef unsigned long int __fsfilcnt_t;
typedef unsigned long int __fsfilcnt64_t;
typedef long int __ssize_t;
typedef __off64_t __loff_t;
typedef __quad_t *__qaddr_t;
typedef char *__caddr_t;
typedef long int __intptr_t;
typedef unsigned int __socklen_t;
# 37 "/usr/include/stdio.h" 2 3 4
# 45 "/usr/include/stdio.h" 3 4
struct _IO_FILE;
typedef struct _IO_FILE FILE;
# 65 "/usr/include/stdio.h" 3 4
typedef struct _IO_FILE __FILE;
# 75 "/usr/include/stdio.h" 3 4
# 1 "/usr/include/libio.h" 1 3 4
# 32 "/usr/include/libio.h" 3 4
# 1 "/usr/include/_G_config.h" 1 3 4
# 15 "/usr/include/_G_config.h" 3 4
# 1 "/gpfs-biou/jmg3/gcc-install/lib/gcc/powerpc64-unknown-linux-gnu/4.8.1/include/stddef.h" 1 3 4
# 16 "/usr/include/_G_config.h" 2 3 4
# 1 "/usr/include/wchar.h" 1 3 4
# 83 "/usr/include/wchar.h" 3 4
typedef struct
{
int __count;
union
{
unsigned int __wch;
char __wchb[4];
} __value;
} __mbstate_t;
# 21 "/usr/include/_G_config.h" 2 3 4
typedef struct
{
__off_t __pos;
__mbstate_t __state;
} _G_fpos_t;
typedef struct
{
__off64_t __pos;
__mbstate_t __state;
} _G_fpos64_t;
# 53 "/usr/include/_G_config.h" 3 4
typedef int _G_int16_t __attribute__ ((__mode__ (__HI__)));
typedef int _G_int32_t __attribute__ ((__mode__ (__SI__)));
typedef unsigned int _G_uint16_t __attribute__ ((__mode__ (__HI__)));
typedef unsigned int _G_uint32_t __attribute__ ((__mode__ (__SI__)));
# 33 "/usr/include/libio.h" 2 3 4
# 53 "/usr/include/libio.h" 3 4
# 1 "/gpfs-biou/jmg3/gcc-install/lib/gcc/powerpc64-unknown-linux-gnu/4.8.1/include/stdarg.h" 1 3 4
# 40 "/gpfs-biou/jmg3/gcc-install/lib/gcc/powerpc64-unknown-linux-gnu/4.8.1/include/stdarg.h" 3 4
typedef __builtin_va_list __gnuc_va_list;
# 54 "/usr/include/libio.h" 2 3 4
# 170 "/usr/include/libio.h" 3 4
struct _IO_jump_t; struct _IO_FILE;
# 180 "/usr/include/libio.h" 3 4
typedef void _IO_lock_t;
struct _IO_marker {
struct _IO_marker *_next;
struct _IO_FILE *_sbuf;
int _pos;
# 203 "/usr/include/libio.h" 3 4
};
enum __codecvt_result
{
__codecvt_ok,
__codecvt_partial,
__codecvt_error,
__codecvt_noconv
};
# 271 "/usr/include/libio.h" 3 4
struct _IO_FILE {
int _flags;
char* _IO_read_ptr;
char* _IO_read_end;
char* _IO_read_base;
char* _IO_write_base;
char* _IO_write_ptr;
char* _IO_write_end;
char* _IO_buf_base;
char* _IO_buf_end;
char *_IO_save_base;
char *_IO_backup_base;
char *_IO_save_end;
struct _IO_marker *_markers;
struct _IO_FILE *_chain;
int _fileno;
int _flags2;
__off_t _old_offset;
unsigned short _cur_column;
signed char _vtable_offset;
char _shortbuf[1];
_IO_lock_t *_lock;
# 319 "/usr/include/libio.h" 3 4
__off64_t _offset;
# 328 "/usr/include/libio.h" 3 4
void *__pad1;
void *__pad2;
void *__pad3;
void *__pad4;
size_t __pad5;
int _mode;
char _unused2[15 * sizeof (int) - 4 * sizeof (void *) - sizeof (size_t)];
};
struct _IO_FILE_plus;
extern struct _IO_FILE_plus _IO_2_1_stdin_;
extern struct _IO_FILE_plus _IO_2_1_stdout_;
extern struct _IO_FILE_plus _IO_2_1_stderr_;
# 364 "/usr/include/libio.h" 3 4
typedef __ssize_t __io_read_fn (void *__cookie, char *__buf, size_t __nbytes);
typedef __ssize_t __io_write_fn (void *__cookie, __const char *__buf,
size_t __n);
typedef int __io_seek_fn (void *__cookie, __off64_t *__pos, int __w);
typedef int __io_close_fn (void *__cookie);
typedef __io_read_fn cookie_read_function_t;
typedef __io_write_fn cookie_write_function_t;
typedef __io_seek_fn cookie_seek_function_t;
typedef __io_close_fn cookie_close_function_t;
typedef struct
{
__io_read_fn *read;
__io_write_fn *write;
__io_seek_fn *seek;
__io_close_fn *close;
} _IO_cookie_io_functions_t;
typedef _IO_cookie_io_functions_t cookie_io_functions_t;
struct _IO_cookie_file;
extern void _IO_cookie_init (struct _IO_cookie_file *__cfile, int __read_write,
void *__cookie, _IO_cookie_io_functions_t __fns);
extern "C" {
extern int __underflow (_IO_FILE *);
extern int __uflow (_IO_FILE *);
extern int __overflow (_IO_FILE *, int);
# 460 "/usr/include/libio.h" 3 4
extern int _IO_getc (_IO_FILE *__fp);
extern int _IO_putc (int __c, _IO_FILE *__fp);
extern int _IO_feof (_IO_FILE *__fp) throw ();
extern int _IO_ferror (_IO_FILE *__fp) throw ();
extern int _IO_peekc_locked (_IO_FILE *__fp);
extern void _IO_flockfile (_IO_FILE *) throw ();
extern void _IO_funlockfile (_IO_FILE *) throw ();
extern int _IO_ftrylockfile (_IO_FILE *) throw ();
# 490 "/usr/include/libio.h" 3 4
extern int _IO_vfscanf (_IO_FILE * __restrict, const char * __restrict,
__gnuc_va_list, int *__restrict);
extern int _IO_vfprintf (_IO_FILE *__restrict, const char *__restrict,
__gnuc_va_list);
extern __ssize_t _IO_padn (_IO_FILE *, int, __ssize_t);
extern size_t _IO_sgetn (_IO_FILE *, void *, size_t);
extern __off64_t _IO_seekoff (_IO_FILE *, __off64_t, int, int);
extern __off64_t _IO_seekpos (_IO_FILE *, __off64_t, int);
extern void _IO_free_backup_area (_IO_FILE *) throw ();
# 552 "/usr/include/libio.h" 3 4
}
# 76 "/usr/include/stdio.h" 2 3 4
typedef __gnuc_va_list va_list;
# 91 "/usr/include/stdio.h" 3 4
typedef __off_t off_t;
typedef __off64_t off64_t;
typedef __ssize_t ssize_t;
typedef _G_fpos_t fpos_t;
typedef _G_fpos64_t fpos64_t;
# 161 "/usr/include/stdio.h" 3 4
# 1 "/usr/include/bits/stdio_lim.h" 1 3 4
# 162 "/usr/include/stdio.h" 2 3 4
extern struct _IO_FILE *stdin;
extern struct _IO_FILE *stdout;
extern struct _IO_FILE *stderr;
# 177 "/usr/include/stdio.h" 3 4
extern int remove (__const char *__filename) throw ();
extern int rename (__const char *__old, __const char *__new) throw ();
extern int renameat (int __oldfd, __const char *__old, int __newfd,
__const char *__new) throw ();
# 194 "/usr/include/stdio.h" 3 4
extern FILE *tmpfile (void) ;
# 204 "/usr/include/stdio.h" 3 4
extern FILE *tmpfile64 (void) ;
extern char *tmpnam (char *__s) throw () ;
extern char *tmpnam_r (char *__s) throw () ;
# 226 "/usr/include/stdio.h" 3 4
extern char *tempnam (__const char *__dir, __const char *__pfx)
throw () __attribute__ ((__malloc__)) ;
# 236 "/usr/include/stdio.h" 3 4
extern int fclose (FILE *__stream);
extern int fflush (FILE *__stream);
# 251 "/usr/include/stdio.h" 3 4
extern int fflush_unlocked (FILE *__stream);
# 261 "/usr/include/stdio.h" 3 4
extern int fcloseall (void);
# 271 "/usr/include/stdio.h" 3 4
extern FILE *fopen (__const char *__restrict __filename,
__const char *__restrict __modes) ;
extern FILE *freopen (__const char *__restrict __filename,
__const char *__restrict __modes,
FILE *__restrict __stream) ;
# 294 "/usr/include/stdio.h" 3 4
extern FILE *fopen64 (__const char *__restrict __filename,
__const char *__restrict __modes) ;
extern FILE *freopen64 (__const char *__restrict __filename,
__const char *__restrict __modes,
FILE *__restrict __stream) ;
extern FILE *fdopen (int __fd, __const char *__modes) throw () ;
extern FILE *fopencookie (void *__restrict __magic_cookie,
__const char *__restrict __modes,
_IO_cookie_io_functions_t __io_funcs) throw () ;
extern FILE *fmemopen (void *__s, size_t __len, __const char *__modes)
throw () ;
extern FILE *open_memstream (char **__bufloc, size_t *__sizeloc) throw () ;
extern void setbuf (FILE *__restrict __stream, char *__restrict __buf) throw ();
extern int setvbuf (FILE *__restrict __stream, char *__restrict __buf,
int __modes, size_t __n) throw ();
extern void setbuffer (FILE *__restrict __stream, char *__restrict __buf,
size_t __size) throw ();
extern void setlinebuf (FILE *__stream) throw ();
# 355 "/usr/include/stdio.h" 3 4
extern int fprintf (FILE *__restrict __stream,
__const char *__restrict __format, ...);
extern int printf (__const char *__restrict __format, ...);
extern int sprintf (char *__restrict __s,
__const char *__restrict __format, ...) throw ();
extern int vfprintf (FILE *__restrict __s, __const char *__restrict __format,
__gnuc_va_list __arg);
extern int vprintf (__const char *__restrict __format, __gnuc_va_list __arg);
extern int vsprintf (char *__restrict __s, __const char *__restrict __format,
__gnuc_va_list __arg) throw ();
extern int snprintf (char *__restrict __s, size_t __maxlen,
__const char *__restrict __format, ...)
throw () __attribute__ ((__format__ (__printf__, 3, 4)));
extern int vsnprintf (char *__restrict __s, size_t __maxlen,
__const char *__restrict __format, __gnuc_va_list __arg)
throw () __attribute__ ((__format__ (__printf__, 3, 0)));
extern int vasprintf (char **__restrict __ptr, __const char *__restrict __f,
__gnuc_va_list __arg)
throw () __attribute__ ((__format__ (__printf__, 2, 0))) ;
extern int __asprintf (char **__restrict __ptr,
__const char *__restrict __fmt, ...)
throw () __attribute__ ((__format__ (__printf__, 2, 3))) ;
extern int asprintf (char **__restrict __ptr,
__const char *__restrict __fmt, ...)
throw () __attribute__ ((__format__ (__printf__, 2, 3))) ;
# 416 "/usr/include/stdio.h" 3 4
extern int vdprintf (int __fd, __const char *__restrict __fmt,
__gnuc_va_list __arg)
__attribute__ ((__format__ (__printf__, 2, 0)));
extern int dprintf (int __fd, __const char *__restrict __fmt, ...)
__attribute__ ((__format__ (__printf__, 2, 3)));
# 429 "/usr/include/stdio.h" 3 4
extern int fscanf (FILE *__restrict __stream,
__const char *__restrict __format, ...) ;
extern int scanf (__const char *__restrict __format, ...) ;
extern int sscanf (__const char *__restrict __s,
__const char *__restrict __format, ...) throw ();
# 467 "/usr/include/stdio.h" 3 4
# 475 "/usr/include/stdio.h" 3 4
extern int vfscanf (FILE *__restrict __s, __const char *__restrict __format,
__gnuc_va_list __arg)
__attribute__ ((__format__ (__scanf__, 2, 0))) ;
extern int vscanf (__const char *__restrict __format, __gnuc_va_list __arg)
__attribute__ ((__format__ (__scanf__, 1, 0))) ;
extern int vsscanf (__const char *__restrict __s,
__const char *__restrict __format, __gnuc_va_list __arg)
throw () __attribute__ ((__format__ (__scanf__, 2, 0)));
# 526 "/usr/include/stdio.h" 3 4
# 535 "/usr/include/stdio.h" 3 4
extern int fgetc (FILE *__stream);
extern int getc (FILE *__stream);
extern int getchar (void);
# 554 "/usr/include/stdio.h" 3 4
extern int getc_unlocked (FILE *__stream);
extern int getchar_unlocked (void);
# 565 "/usr/include/stdio.h" 3 4
extern int fgetc_unlocked (FILE *__stream);
# 577 "/usr/include/stdio.h" 3 4
extern int fputc (int __c, FILE *__stream);
extern int putc (int __c, FILE *__stream);
extern int putchar (int __c);
# 598 "/usr/include/stdio.h" 3 4
extern int fputc_unlocked (int __c, FILE *__stream);
extern int putc_unlocked (int __c, FILE *__stream);
extern int putchar_unlocked (int __c);
extern int getw (FILE *__stream);
extern int putw (int __w, FILE *__stream);
# 626 "/usr/include/stdio.h" 3 4
extern char *fgets (char *__restrict __s, int __n, FILE *__restrict __stream)
;
extern char *gets (char *__s) ;
# 644 "/usr/include/stdio.h" 3 4
extern char *fgets_unlocked (char *__restrict __s, int __n,
FILE *__restrict __stream) ;
# 660 "/usr/include/stdio.h" 3 4
extern __ssize_t __getdelim (char **__restrict __lineptr,
size_t *__restrict __n, int __delimiter,
FILE *__restrict __stream) ;
extern __ssize_t getdelim (char **__restrict __lineptr,
size_t *__restrict __n, int __delimiter,
FILE *__restrict __stream) ;
extern __ssize_t getline (char **__restrict __lineptr,
size_t *__restrict __n,
FILE *__restrict __stream) ;
# 684 "/usr/include/stdio.h" 3 4
extern int fputs (__const char *__restrict __s, FILE *__restrict __stream);
extern int puts (__const char *__s);
extern int ungetc (int __c, FILE *__stream);
extern size_t fread (void *__restrict __ptr, size_t __size,
size_t __n, FILE *__restrict __stream) ;
extern size_t fwrite (__const void *__restrict __ptr, size_t __size,
size_t __n, FILE *__restrict __s) ;
# 721 "/usr/include/stdio.h" 3 4
extern int fputs_unlocked (__const char *__restrict __s,
FILE *__restrict __stream);
# 732 "/usr/include/stdio.h" 3 4
extern size_t fread_unlocked (void *__restrict __ptr, size_t __size,
size_t __n, FILE *__restrict __stream) ;
extern size_t fwrite_unlocked (__const void *__restrict __ptr, size_t __size,
size_t __n, FILE *__restrict __stream) ;
# 744 "/usr/include/stdio.h" 3 4
extern int fseek (FILE *__stream, long int __off, int __whence);
extern long int ftell (FILE *__stream) ;
extern void rewind (FILE *__stream);
# 768 "/usr/include/stdio.h" 3 4
extern int fseeko (FILE *__stream, __off_t __off, int __whence);
extern __off_t ftello (FILE *__stream) ;
# 787 "/usr/include/stdio.h" 3 4
extern int fgetpos (FILE *__restrict __stream, fpos_t *__restrict __pos);
extern int fsetpos (FILE *__stream, __const fpos_t *__pos);
# 810 "/usr/include/stdio.h" 3 4
extern int fseeko64 (FILE *__stream, __off64_t __off, int __whence);
extern __off64_t ftello64 (FILE *__stream) ;
extern int fgetpos64 (FILE *__restrict __stream, fpos64_t *__restrict __pos);
extern int fsetpos64 (FILE *__stream, __const fpos64_t *__pos);
extern void clearerr (FILE *__stream) throw ();
extern int feof (FILE *__stream) throw () ;
extern int ferror (FILE *__stream) throw () ;
extern void clearerr_unlocked (FILE *__stream) throw ();
extern int feof_unlocked (FILE *__stream) throw () ;
extern int ferror_unlocked (FILE *__stream) throw () ;
# 841 "/usr/include/stdio.h" 3 4
extern void perror (__const char *__s);
# 1 "/usr/include/bits/sys_errlist.h" 1 3 4
# 27 "/usr/include/bits/sys_errlist.h" 3 4
extern int sys_nerr;
extern __const char *__const sys_errlist[];
extern int _sys_nerr;
extern __const char *__const _sys_errlist[];
# 849 "/usr/include/stdio.h" 2 3 4
extern int fileno (FILE *__stream) throw () ;
extern int fileno_unlocked (FILE *__stream) throw () ;
# 868 "/usr/include/stdio.h" 3 4
extern FILE *popen (__const char *__command, __const char *__modes) ;
extern int pclose (FILE *__stream);
extern char *ctermid (char *__s) throw ();
extern char *cuserid (char *__s);
struct obstack;
extern int obstack_printf (struct obstack *__restrict __obstack,
__const char *__restrict __format, ...)
throw () __attribute__ ((__format__ (__printf__, 2, 3)));
extern int obstack_vprintf (struct obstack *__restrict __obstack,
__const char *__restrict __format,
__gnuc_va_list __args)
throw () __attribute__ ((__format__ (__printf__, 2, 0)));
extern void flockfile (FILE *__stream) throw ();
extern int ftrylockfile (FILE *__stream) throw () ;
extern void funlockfile (FILE *__stream) throw ();
# 929 "/usr/include/stdio.h" 3 4
# 1 "/usr/include/bits/stdio.h" 1 3 4
# 36 "/usr/include/bits/stdio.h" 3 4
extern __inline __attribute__ ((__gnu_inline__)) int
vprintf (__const char *__restrict __fmt, __gnuc_va_list __arg)
{
return vfprintf (stdout, __fmt, __arg);
}
extern __inline __attribute__ ((__gnu_inline__)) int
getchar (void)
{
return _IO_getc (stdin);
}
extern __inline __attribute__ ((__gnu_inline__)) int
fgetc_unlocked (FILE *__fp)
{
return (__builtin_expect (((__fp)->_IO_read_ptr >= (__fp)->_IO_read_end), 0) ? __uflow (__fp) : *(unsigned char *) (__fp)->_IO_read_ptr++);
}
extern __inline __attribute__ ((__gnu_inline__)) int
getc_unlocked (FILE *__fp)
{
return (__builtin_expect (((__fp)->_IO_read_ptr >= (__fp)->_IO_read_end), 0) ? __uflow (__fp) : *(unsigned char *) (__fp)->_IO_read_ptr++);
}
extern __inline __attribute__ ((__gnu_inline__)) int
getchar_unlocked (void)
{
return (__builtin_expect (((stdin)->_IO_read_ptr >= (stdin)->_IO_read_end), 0) ? __uflow (stdin) : *(unsigned char *) (stdin)->_IO_read_ptr++);
}
extern __inline __attribute__ ((__gnu_inline__)) int
putchar (int __c)
{
return _IO_putc (__c, stdout);
}
extern __inline __attribute__ ((__gnu_inline__)) int
fputc_unlocked (int __c, FILE *__stream)
{
return (__builtin_expect (((__stream)->_IO_write_ptr >= (__stream)->_IO_write_end), 0) ? __overflow (__stream, (unsigned char) (__c)) : (unsigned char) (*(__stream)->_IO_write_ptr++ = (__c)));
}
extern __inline __attribute__ ((__gnu_inline__)) int
putc_unlocked (int __c, FILE *__stream)
{
return (__builtin_expect (((__stream)->_IO_write_ptr >= (__stream)->_IO_write_end), 0) ? __overflow (__stream, (unsigned char) (__c)) : (unsigned char) (*(__stream)->_IO_write_ptr++ = (__c)));
}
extern __inline __attribute__ ((__gnu_inline__)) int
putchar_unlocked (int __c)
{
return (__builtin_expect (((stdout)->_IO_write_ptr >= (stdout)->_IO_write_end), 0) ? __overflow (stdout, (unsigned char) (__c)) : (unsigned char) (*(stdout)->_IO_write_ptr++ = (__c)));
}
extern __inline __attribute__ ((__gnu_inline__)) __ssize_t
getline (char **__lineptr, size_t *__n, FILE *__stream)
{
return __getdelim (__lineptr, __n, '\n', __stream);
}
extern __inline __attribute__ ((__gnu_inline__)) int
feof_unlocked (FILE *__stream) throw ()
{
return (((__stream)->_flags & 0x10) != 0);
}
extern __inline __attribute__ ((__gnu_inline__)) int
ferror_unlocked (FILE *__stream) throw ()
{
return (((__stream)->_flags & 0x20) != 0);
}
# 930 "/usr/include/stdio.h" 2 3 4
# 938 "/usr/include/stdio.h" 3 4
}
# 12 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c" 2
# 1 "/usr/include/stdlib.h" 1 3 4
# 33 "/usr/include/stdlib.h" 3 4
# 1 "/gpfs-biou/jmg3/gcc-install/lib/gcc/powerpc64-unknown-linux-gnu/4.8.1/include/stddef.h" 1 3 4
# 34 "/usr/include/stdlib.h" 2 3 4
extern "C" {
# 1 "/usr/include/bits/waitflags.h" 1 3 4
# 43 "/usr/include/stdlib.h" 2 3 4
# 1 "/usr/include/bits/waitstatus.h" 1 3 4
# 65 "/usr/include/bits/waitstatus.h" 3 4
# 1 "/usr/include/endian.h" 1 3 4
# 37 "/usr/include/endian.h" 3 4
# 1 "/usr/include/bits/endian.h" 1 3 4
# 38 "/usr/include/endian.h" 2 3 4
# 61 "/usr/include/endian.h" 3 4
# 1 "/usr/include/bits/byteswap.h" 1 3 4
# 62 "/usr/include/endian.h" 2 3 4
# 66 "/usr/include/bits/waitstatus.h" 2 3 4
union wait
{
int w_status;
struct
{
unsigned int:16;
unsigned int __w_retcode:8;
unsigned int __w_coredump:1;
unsigned int __w_termsig:7;
} __wait_terminated;
struct
{
unsigned int:16;
unsigned int __w_stopsig:8;
unsigned int __w_stopval:8;
} __wait_stopped;
};
# 44 "/usr/include/stdlib.h" 2 3 4
# 96 "/usr/include/stdlib.h" 3 4
typedef struct
{
int quot;
int rem;
} div_t;
typedef struct
{
long int quot;
long int rem;
} ldiv_t;
__extension__ typedef struct
{
long long int quot;
long long int rem;
} lldiv_t;
# 140 "/usr/include/stdlib.h" 3 4
extern size_t __ctype_get_mb_cur_max (void) throw () ;
extern double atof (__const char *__nptr)
throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ;
extern int atoi (__const char *__nptr)
throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ;
extern long int atol (__const char *__nptr)
throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ;
__extension__ extern long long int atoll (__const char *__nptr)
throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ;
extern double strtod (__const char *__restrict __nptr,
char **__restrict __endptr)
throw () __attribute__ ((__nonnull__ (1))) ;
extern float strtof (__const char *__restrict __nptr,
char **__restrict __endptr) throw () __attribute__ ((__nonnull__ (1))) ;
extern long double strtold (__const char *__restrict __nptr,
char **__restrict __endptr)
throw () __attribute__ ((__nonnull__ (1))) ;
extern long int strtol (__const char *__restrict __nptr,
char **__restrict __endptr, int __base)
throw () __attribute__ ((__nonnull__ (1))) ;
extern unsigned long int strtoul (__const char *__restrict __nptr,
char **__restrict __endptr, int __base)
throw () __attribute__ ((__nonnull__ (1))) ;
__extension__
extern long long int strtoq (__const char *__restrict __nptr,
char **__restrict __endptr, int __base)
throw () __attribute__ ((__nonnull__ (1))) ;
__extension__
extern unsigned long long int strtouq (__const char *__restrict __nptr,
char **__restrict __endptr, int __base)
throw () __attribute__ ((__nonnull__ (1))) ;
__extension__
extern long long int strtoll (__const char *__restrict __nptr,
char **__restrict __endptr, int __base)
throw () __attribute__ ((__nonnull__ (1))) ;
__extension__
extern unsigned long long int strtoull (__const char *__restrict __nptr,
char **__restrict __endptr, int __base)
throw () __attribute__ ((__nonnull__ (1))) ;
# 236 "/usr/include/stdlib.h" 3 4
# 1 "/usr/include/xlocale.h" 1 3 4
# 28 "/usr/include/xlocale.h" 3 4
typedef struct __locale_struct
{
struct __locale_data *__locales[13];
const unsigned short int *__ctype_b;
const int *__ctype_tolower;
const int *__ctype_toupper;
const char *__names[13];
} *__locale_t;
typedef __locale_t locale_t;
# 237 "/usr/include/stdlib.h" 2 3 4
extern long int strtol_l (__const char *__restrict __nptr,
char **__restrict __endptr, int __base,
__locale_t __loc) throw () __attribute__ ((__nonnull__ (1, 4))) ;
extern unsigned long int strtoul_l (__const char *__restrict __nptr,
char **__restrict __endptr,
int __base, __locale_t __loc)
throw () __attribute__ ((__nonnull__ (1, 4))) ;
__extension__
extern long long int strtoll_l (__const char *__restrict __nptr,
char **__restrict __endptr, int __base,
__locale_t __loc)
throw () __attribute__ ((__nonnull__ (1, 4))) ;
__extension__
extern unsigned long long int strtoull_l (__const char *__restrict __nptr,
char **__restrict __endptr,
int __base, __locale_t __loc)
throw () __attribute__ ((__nonnull__ (1, 4))) ;
extern double strtod_l (__const char *__restrict __nptr,
char **__restrict __endptr, __locale_t __loc)
throw () __attribute__ ((__nonnull__ (1, 3))) ;
extern float strtof_l (__const char *__restrict __nptr,
char **__restrict __endptr, __locale_t __loc)
throw () __attribute__ ((__nonnull__ (1, 3))) ;
extern long double strtold_l (__const char *__restrict __nptr,
char **__restrict __endptr,
__locale_t __loc)
throw () __attribute__ ((__nonnull__ (1, 3))) ;
extern __inline __attribute__ ((__gnu_inline__)) double
atof (__const char *__nptr) throw ()
{
return strtod (__nptr, (char **) __null);
}
extern __inline __attribute__ ((__gnu_inline__)) int
atoi (__const char *__nptr) throw ()
{
return (int) strtol (__nptr, (char **) __null, 10);
}
extern __inline __attribute__ ((__gnu_inline__)) long int
atol (__const char *__nptr) throw ()
{
return strtol (__nptr, (char **) __null, 10);
}
__extension__ extern __inline __attribute__ ((__gnu_inline__)) long long int
atoll (__const char *__nptr) throw ()
{
return strtoll (__nptr, (char **) __null, 10);
}
# 311 "/usr/include/stdlib.h" 3 4
extern char *l64a (long int __n) throw () ;
extern long int a64l (__const char *__s)
throw () __attribute__ ((__pure__)) __attribute__ ((__nonnull__ (1))) ;
# 1 "/usr/include/sys/types.h" 1 3 4
# 28 "/usr/include/sys/types.h" 3 4
extern "C" {
typedef __u_char u_char;
typedef __u_short u_short;
typedef __u_int u_int;
typedef __u_long u_long;
typedef __quad_t quad_t;
typedef __u_quad_t u_quad_t;
typedef __fsid_t fsid_t;
typedef __loff_t loff_t;
typedef __ino_t ino_t;
typedef __ino64_t ino64_t;
typedef __dev_t dev_t;
typedef __gid_t gid_t;
typedef __mode_t mode_t;
typedef __nlink_t nlink_t;
typedef __uid_t uid_t;
# 99 "/usr/include/sys/types.h" 3 4
typedef __pid_t pid_t;
typedef __id_t id_t;
# 116 "/usr/include/sys/types.h" 3 4
typedef __daddr_t daddr_t;
typedef __caddr_t caddr_t;
typedef __key_t key_t;
# 133 "/usr/include/sys/types.h" 3 4
# 1 "/usr/include/time.h" 1 3 4
# 58 "/usr/include/time.h" 3 4
typedef __clock_t clock_t;
# 74 "/usr/include/time.h" 3 4
typedef __time_t time_t;
# 92 "/usr/include/time.h" 3 4
typedef __clockid_t clockid_t;
# 104 "/usr/include/time.h" 3 4
typedef __timer_t timer_t;
# 134 "/usr/include/sys/types.h" 2 3 4
typedef __useconds_t useconds_t;
typedef __suseconds_t suseconds_t;
# 1 "/gpfs-biou/jmg3/gcc-install/lib/gcc/powerpc64-unknown-linux-gnu/4.8.1/include/stddef.h" 1 3 4
# 148 "/usr/include/sys/types.h" 2 3 4
typedef unsigned long int ulong;
typedef unsigned short int ushort;
typedef unsigned int uint;
# 195 "/usr/include/sys/types.h" 3 4
typedef int int8_t __attribute__ ((__mode__ (__QI__)));
typedef int int16_t __attribute__ ((__mode__ (__HI__)));
typedef int int32_t __attribute__ ((__mode__ (__SI__)));
typedef int int64_t __attribute__ ((__mode__ (__DI__)));
typedef unsigned int u_int8_t __attribute__ ((__mode__ (__QI__)));
typedef unsigned int u_int16_t __attribute__ ((__mode__ (__HI__)));
typedef unsigned int u_int32_t __attribute__ ((__mode__ (__SI__)));
typedef unsigned int u_int64_t __attribute__ ((__mode__ (__DI__)));
typedef int register_t __attribute__ ((__mode__ (__word__)));
# 220 "/usr/include/sys/types.h" 3 4
# 1 "/usr/include/sys/select.h" 1 3 4
# 31 "/usr/include/sys/select.h" 3 4
# 1 "/usr/include/bits/select.h" 1 3 4
# 32 "/usr/include/sys/select.h" 2 3 4
# 1 "/usr/include/bits/sigset.h" 1 3 4
# 24 "/usr/include/bits/sigset.h" 3 4
typedef int __sig_atomic_t;
typedef struct
{
unsigned long int __val[(1024 / (8 * sizeof (unsigned long int)))];
} __sigset_t;
# 35 "/usr/include/sys/select.h" 2 3 4
typedef __sigset_t sigset_t;
# 1 "/usr/include/time.h" 1 3 4
# 120 "/usr/include/time.h" 3 4
struct timespec
{
__time_t tv_sec;
long int tv_nsec;
};
# 45 "/usr/include/sys/select.h" 2 3 4
# 1 "/usr/include/bits/time.h" 1 3 4
# 75 "/usr/include/bits/time.h" 3 4
struct timeval
{
__time_t tv_sec;
__suseconds_t tv_usec;
};
# 47 "/usr/include/sys/select.h" 2 3 4
# 55 "/usr/include/sys/select.h" 3 4
typedef long int __fd_mask;
# 67 "/usr/include/sys/select.h" 3 4
typedef struct
{
__fd_mask fds_bits[1024 / (8 * (int) sizeof (__fd_mask))];
} fd_set;
typedef __fd_mask fd_mask;
# 99 "/usr/include/sys/select.h" 3 4
extern "C" {
# 109 "/usr/include/sys/select.h" 3 4
extern int select (int __nfds, fd_set *__restrict __readfds,
fd_set *__restrict __writefds,
fd_set *__restrict __exceptfds,
struct timeval *__restrict __timeout);
# 121 "/usr/include/sys/select.h" 3 4
extern int pselect (int __nfds, fd_set *__restrict __readfds,
fd_set *__restrict __writefds,
fd_set *__restrict __exceptfds,
const struct timespec *__restrict __timeout,
const __sigset_t *__restrict __sigmask);
}
# 221 "/usr/include/sys/types.h" 2 3 4
# 1 "/usr/include/sys/sysmacros.h" 1 3 4
# 30 "/usr/include/sys/sysmacros.h" 3 4
__extension__
extern unsigned int gnu_dev_major (unsigned long long int __dev)
throw ();
__extension__
extern unsigned int gnu_dev_minor (unsigned long long int __dev)
throw ();
__extension__
extern unsigned long long int gnu_dev_makedev (unsigned int __major,
unsigned int __minor)
throw ();
__extension__ extern __inline __attribute__ ((__gnu_inline__)) unsigned int
gnu_dev_major (unsigned long long int __dev) throw ()
{
return ((__dev >> 8) & 0xfff) | ((unsigned int) (__dev >> 32) & ~0xfff);
}
__extension__ extern __inline __attribute__ ((__gnu_inline__)) unsigned int
gnu_dev_minor (unsigned long long int __dev) throw ()
{
return (__dev & 0xff) | ((unsigned int) (__dev >> 12) & ~0xff);
}
__extension__ extern __inline __attribute__ ((__gnu_inline__)) unsigned long long int
gnu_dev_makedev (unsigned int __major, unsigned int __minor) throw ()
{
return ((__minor & 0xff) | ((__major & 0xfff) << 8)
| (((unsigned long long int) (__minor & ~0xff)) << 12)
| (((unsigned long long int) (__major & ~0xfff)) << 32));
}
# 224 "/usr/include/sys/types.h" 2 3 4
typedef __blksize_t blksize_t;
typedef __blkcnt_t blkcnt_t;
typedef __fsblkcnt_t fsblkcnt_t;
typedef __fsfilcnt_t fsfilcnt_t;
# 263 "/usr/include/sys/types.h" 3 4
typedef __blkcnt64_t blkcnt64_t;
typedef __fsblkcnt64_t fsblkcnt64_t;
typedef __fsfilcnt64_t fsfilcnt64_t;
# 1 "/usr/include/bits/pthreadtypes.h" 1 3 4
# 24 "/usr/include/bits/pthreadtypes.h" 3 4
# 1 "/usr/include/bits/wordsize.h" 1 3 4
# 25 "/usr/include/bits/pthreadtypes.h" 2 3 4
# 51 "/usr/include/bits/pthreadtypes.h" 3 4
typedef unsigned long int pthread_t;
typedef union
{
char __size[56];
long int __align;
} pthread_attr_t;
typedef struct __pthread_internal_list
{
struct __pthread_internal_list *__prev;
struct __pthread_internal_list *__next;
} __pthread_list_t;
# 77 "/usr/include/bits/pthreadtypes.h" 3 4
typedef union
{
struct __pthread_mutex_s
{
int __lock;
unsigned int __count;
int __owner;
unsigned int __nusers;
int __kind;
int __spins;
__pthread_list_t __list;
# 102 "/usr/include/bits/pthreadtypes.h" 3 4
} __data;
char __size[40];
long int __align;
} pthread_mutex_t;
typedef union
{
char __size[4];
int __align;
} pthread_mutexattr_t;
typedef union
{
struct
{
int __lock;
unsigned int __futex;
__extension__ unsigned long long int __total_seq;
__extension__ unsigned long long int __wakeup_seq;
__extension__ unsigned long long int __woken_seq;
void *__mutex;
unsigned int __nwaiters;
unsigned int __broadcast_seq;
} __data;
char __size[48];
__extension__ long long int __align;
} pthread_cond_t;
typedef union
{
char __size[4];
int __align;
} pthread_condattr_t;
typedef unsigned int pthread_key_t;
typedef int pthread_once_t;
typedef union
{
struct
{
int __lock;
unsigned int __nr_readers;
unsigned int __readers_wakeup;
unsigned int __writer_wakeup;
unsigned int __nr_readers_queued;
unsigned int __nr_writers_queued;
int __writer;
int __shared;
unsigned long int __pad1;
unsigned long int __pad2;
unsigned int __flags;
} __data;
# 188 "/usr/include/bits/pthreadtypes.h" 3 4
char __size[56];
long int __align;
} pthread_rwlock_t;
typedef union
{
char __size[8];
long int __align;
} pthread_rwlockattr_t;
typedef volatile int pthread_spinlock_t;
typedef union
{
char __size[32];
long int __align;
} pthread_barrier_t;
typedef union
{
char __size[4];
int __align;
} pthread_barrierattr_t;
# 272 "/usr/include/sys/types.h" 2 3 4
}
# 321 "/usr/include/stdlib.h" 2 3 4
extern long int random (void) throw ();
extern void srandom (unsigned int __seed) throw ();
extern char *initstate (unsigned int __seed, char *__statebuf,
size_t __statelen) throw () __attribute__ ((__nonnull__ (2)));
extern char *setstate (char *__statebuf) throw () __attribute__ ((__nonnull__ (1)));
struct random_data
{
int32_t *fptr;
int32_t *rptr;
int32_t *state;
int rand_type;
int rand_deg;
int rand_sep;
int32_t *end_ptr;
};
extern int random_r (struct random_data *__restrict __buf,
int32_t *__restrict __result) throw () __attribute__ ((__nonnull__ (1, 2)));
extern int srandom_r (unsigned int __seed, struct random_data *__buf)
throw () __attribute__ ((__nonnull__ (2)));
extern int initstate_r (unsigned int __seed, char *__restrict __statebuf,
size_t __statelen,
struct random_data *__restrict __buf)
throw () __attribute__ ((__nonnull__ (2, 4)));
extern int setstate_r (char *__restrict __statebuf,
struct random_data *__restrict __buf)
throw () __attribute__ ((__nonnull__ (1, 2)));
extern int rand (void) throw ();
extern void srand (unsigned int __seed) throw ();
extern int rand_r (unsigned int *__seed) throw ();
extern double drand48 (void) throw ();
extern double erand48 (unsigned short int __xsubi[3]) throw () __attribute__ ((__nonnull__ (1)));
extern long int lrand48 (void) throw ();
extern long int nrand48 (unsigned short int __xsubi[3])
throw () __attribute__ ((__nonnull__ (1)));
extern long int mrand48 (void) throw ();
extern long int jrand48 (unsigned short int __xsubi[3])
throw () __attribute__ ((__nonnull__ (1)));
extern void srand48 (long int __seedval) throw ();
extern unsigned short int *seed48 (unsigned short int __seed16v[3])
throw () __attribute__ ((__nonnull__ (1)));
extern void lcong48 (unsigned short int __param[7]) throw () __attribute__ ((__nonnull__ (1)));
struct drand48_data
{
unsigned short int __x[3];
unsigned short int __old_x[3];
unsigned short int __c;
unsigned short int __init;
unsigned long long int __a;
};
extern int drand48_r (struct drand48_data *__restrict __buffer,
double *__restrict __result) throw () __attribute__ ((__nonnull__ (1, 2)));
extern int erand48_r (unsigned short int __xsubi[3],
struct drand48_data *__restrict __buffer,
double *__restrict __result) throw () __attribute__ ((__nonnull__ (1, 2)));
extern int lrand48_r (struct drand48_data *__restrict __buffer,
long int *__restrict __result)
throw () __attribute__ ((__nonnull__ (1, 2)));
extern int nrand48_r (unsigned short int __xsubi[3],
struct drand48_data *__restrict __buffer,
long int *__restrict __result)
throw () __attribute__ ((__nonnull__ (1, 2)));
extern int mrand48_r (struct drand48_data *__restrict __buffer,
long int *__restrict __result)
throw () __attribute__ ((__nonnull__ (1, 2)));
extern int jrand48_r (unsigned short int __xsubi[3],
struct drand48_data *__restrict __buffer,
long int *__restrict __result)
throw () __attribute__ ((__nonnull__ (1, 2)));
extern int srand48_r (long int __seedval, struct drand48_data *__buffer)
throw () __attribute__ ((__nonnull__ (2)));
extern int seed48_r (unsigned short int __seed16v[3],
struct drand48_data *__buffer) throw () __attribute__ ((__nonnull__ (1, 2)));
extern int lcong48_r (unsigned short int __param[7],
struct drand48_data *__buffer)
throw () __attribute__ ((__nonnull__ (1, 2)));
# 471 "/usr/include/stdlib.h" 3 4
extern void *malloc (size_t __size) throw () __attribute__ ((__malloc__)) ;
extern void *calloc (size_t __nmemb, size_t __size)
throw () __attribute__ ((__malloc__)) ;
# 485 "/usr/include/stdlib.h" 3 4
extern void *realloc (void *__ptr, size_t __size)
throw () __attribute__ ((__warn_unused_result__));
extern void free (void *__ptr) throw ();
extern void cfree (void *__ptr) throw ();
# 1 "/usr/include/alloca.h" 1 3 4
# 25 "/usr/include/alloca.h" 3 4
# 1 "/gpfs-biou/jmg3/gcc-install/lib/gcc/powerpc64-unknown-linux-gnu/4.8.1/include/stddef.h" 1 3 4
# 26 "/usr/include/alloca.h" 2 3 4
extern "C" {
extern void *alloca (size_t __size) throw ();
}
# 498 "/usr/include/stdlib.h" 2 3 4
extern void *valloc (size_t __size) throw () __attribute__ ((__malloc__)) ;
extern int posix_memalign (void **__memptr, size_t __alignment, size_t __size)
throw () __attribute__ ((__nonnull__ (1))) ;
extern void abort (void) throw () __attribute__ ((__noreturn__));
extern int atexit (void (*__func) (void)) throw () __attribute__ ((__nonnull__ (1)));
extern "C++" int at_quick_exit (void (*__func) (void))
throw () __asm ("at_quick_exit") __attribute__ ((__nonnull__ (1)));
# 536 "/usr/include/stdlib.h" 3 4
extern int on_exit (void (*__func) (int __status, void *__arg), void *__arg)
throw () __attribute__ ((__nonnull__ (1)));
extern void exit (int __status) throw () __attribute__ ((__noreturn__));
extern void quick_exit (int __status) throw () __attribute__ ((__noreturn__));
extern void _Exit (int __status) throw () __attribute__ ((__noreturn__));
extern char *getenv (__const char *__name) throw () __attribute__ ((__nonnull__ (1))) ;
extern char *__secure_getenv (__const char *__name)
throw () __attribute__ ((__nonnull__ (1))) ;
extern int putenv (char *__string) throw () __attribute__ ((__nonnull__ (1)));
extern int setenv (__const char *__name, __const char *__value, int __replace)
throw () __attribute__ ((__nonnull__ (2)));
extern int unsetenv (__const char *__name) throw () __attribute__ ((__nonnull__ (1)));
extern int clearenv (void) throw ();
# 606 "/usr/include/stdlib.h" 3 4
extern char *mktemp (char *__template) throw () __attribute__ ((__nonnull__ (1))) ;
# 620 "/usr/include/stdlib.h" 3 4
extern int mkstemp (char *__template) __attribute__ ((__nonnull__ (1))) ;
# 630 "/usr/include/stdlib.h" 3 4
extern int mkstemp64 (char *__template) __attribute__ ((__nonnull__ (1))) ;
# 642 "/usr/include/stdlib.h" 3 4
extern int mkstemps (char *__template, int __suffixlen) __attribute__ ((__nonnull__ (1))) ;
# 652 "/usr/include/stdlib.h" 3 4
extern int mkstemps64 (char *__template, int __suffixlen)
__attribute__ ((__nonnull__ (1))) ;
# 663 "/usr/include/stdlib.h" 3 4
extern char *mkdtemp (char *__template) throw () __attribute__ ((__nonnull__ (1))) ;
# 674 "/usr/include/stdlib.h" 3 4
extern int mkostemp (char *__template, int __flags) __attribute__ ((__nonnull__ (1))) ;
# 684 "/usr/include/stdlib.h" 3 4
extern int mkostemp64 (char *__template, int __flags) __attribute__ ((__nonnull__ (1))) ;
# 694 "/usr/include/stdlib.h" 3 4
extern int mkostemps (char *__template, int __suffixlen, int __flags)
__attribute__ ((__nonnull__ (1))) ;
# 706 "/usr/include/stdlib.h" 3 4
extern int mkostemps64 (char *__template, int __suffixlen, int __flags)
__attribute__ ((__nonnull__ (1))) ;
# 717 "/usr/include/stdlib.h" 3 4
extern int system (__const char *__command) ;
extern char *canonicalize_file_name (__const char *__name)
throw () __attribute__ ((__nonnull__ (1))) ;
# 734 "/usr/include/stdlib.h" 3 4
extern char *realpath (__const char *__restrict __name,
char *__restrict __resolved) throw () ;
typedef int (*__compar_fn_t) (__const void *, __const void *);
typedef __compar_fn_t comparison_fn_t;
typedef int (*__compar_d_fn_t) (__const void *, __const void *, void *);
extern void *bsearch (__const void *__key, __const void *__base,
size_t __nmemb, size_t __size, __compar_fn_t __compar)
__attribute__ ((__nonnull__ (1, 2, 5))) ;
extern void qsort (void *__base, size_t __nmemb, size_t __size,
__compar_fn_t __compar) __attribute__ ((__nonnull__ (1, 4)));
extern void qsort_r (void *__base, size_t __nmemb, size_t __size,
__compar_d_fn_t __compar, void *__arg)
__attribute__ ((__nonnull__ (1, 4)));
extern int abs (int __x) throw () __attribute__ ((__const__)) ;
extern long int labs (long int __x) throw () __attribute__ ((__const__)) ;
__extension__ extern long long int llabs (long long int __x)
throw () __attribute__ ((__const__)) ;
extern div_t div (int __numer, int __denom)
throw () __attribute__ ((__const__)) ;
extern ldiv_t ldiv (long int __numer, long int __denom)
throw () __attribute__ ((__const__)) ;
__extension__ extern lldiv_t lldiv (long long int __numer,
long long int __denom)
throw () __attribute__ ((__const__)) ;
# 808 "/usr/include/stdlib.h" 3 4
extern char *ecvt (double __value, int __ndigit, int *__restrict __decpt,
int *__restrict __sign) throw () __attribute__ ((__nonnull__ (3, 4))) ;
extern char *fcvt (double __value, int __ndigit, int *__restrict __decpt,
int *__restrict __sign) throw () __attribute__ ((__nonnull__ (3, 4))) ;
extern char *gcvt (double __value, int __ndigit, char *__buf)
throw () __attribute__ ((__nonnull__ (3))) ;
extern char *qecvt (long double __value, int __ndigit,
int *__restrict __decpt, int *__restrict __sign)
throw () __attribute__ ((__nonnull__ (3, 4))) ;
extern char *qfcvt (long double __value, int __ndigit,
int *__restrict __decpt, int *__restrict __sign)
throw () __attribute__ ((__nonnull__ (3, 4))) ;
extern char *qgcvt (long double __value, int __ndigit, char *__buf)
throw () __attribute__ ((__nonnull__ (3))) ;
extern int ecvt_r (double __value, int __ndigit, int *__restrict __decpt,
int *__restrict __sign, char *__restrict __buf,
size_t __len) throw () __attribute__ ((__nonnull__ (3, 4, 5)));
extern int fcvt_r (double __value, int __ndigit, int *__restrict __decpt,
int *__restrict __sign, char *__restrict __buf,
size_t __len) throw () __attribute__ ((__nonnull__ (3, 4, 5)));
extern int qecvt_r (long double __value, int __ndigit,
int *__restrict __decpt, int *__restrict __sign,
char *__restrict __buf, size_t __len)
throw () __attribute__ ((__nonnull__ (3, 4, 5)));
extern int qfcvt_r (long double __value, int __ndigit,
int *__restrict __decpt, int *__restrict __sign,
char *__restrict __buf, size_t __len)
throw () __attribute__ ((__nonnull__ (3, 4, 5)));
extern int mblen (__const char *__s, size_t __n) throw () ;
extern int mbtowc (wchar_t *__restrict __pwc,
__const char *__restrict __s, size_t __n) throw () ;
extern int wctomb (char *__s, wchar_t __wchar) throw () ;
extern size_t mbstowcs (wchar_t *__restrict __pwcs,
__const char *__restrict __s, size_t __n) throw ();
extern size_t wcstombs (char *__restrict __s,
__const wchar_t *__restrict __pwcs, size_t __n)
throw ();
# 885 "/usr/include/stdlib.h" 3 4
extern int rpmatch (__const char *__response) throw () __attribute__ ((__nonnull__ (1))) ;
# 896 "/usr/include/stdlib.h" 3 4
extern int getsubopt (char **__restrict __optionp,
char *__const *__restrict __tokens,
char **__restrict __valuep)
throw () __attribute__ ((__nonnull__ (1, 2, 3))) ;
extern void setkey (__const char *__key) throw () __attribute__ ((__nonnull__ (1)));
extern int posix_openpt (int __oflag) ;
extern int grantpt (int __fd) throw ();
extern int unlockpt (int __fd) throw ();
extern char *ptsname (int __fd) throw () ;
extern int ptsname_r (int __fd, char *__buf, size_t __buflen)
throw () __attribute__ ((__nonnull__ (2)));
extern int getpt (void);
extern int getloadavg (double __loadavg[], int __nelem)
throw () __attribute__ ((__nonnull__ (1)));
# 964 "/usr/include/stdlib.h" 3 4
}
# 13 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c" 2
# 13 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
# 1 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/sequenceAlignment.h" 1
# 91 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/sequenceAlignment.h"
typedef struct simmat {
char similarity[((64) + 1)][((64) + 1)];
char aminoAcid[(((64) + 1) + 1)];
char *bases;
char *codon[(((64) + 1) + 1)];
unsigned char encode[((64) + ((64) + 1))];
unsigned char encode_first[((64) + ((64) + 1))];
char hyphen, star;
int exact, similar, dissimilar, gapStart, gapExtend, matchLimit;
} SIMMATRIX_T;
typedef struct seqdat {
unsigned char *main, *match;
int mainLen, matchLen, maxValidation;
} SEQDATA_T;
typedef struct astr {
SEQDATA_T *seqData;
SIMMATRIX_T *simMatrix;
long long **goodScores;
int numThreads, *numReports, **goodEndsI, **goodEndsJ;
} ASTR_T;
typedef struct bstr {
long long **bestScores;
int numThreads, *numReports;
int **bestStartsI, **bestStartsJ, **bestEndsI, **bestEndsJ;
unsigned char ***bestSeqsI, ***bestSeqsJ;
} BSTR_T;
typedef struct cstr {
long long *finalScores;
int numReports;
int *finalStartsI, *finalStartsJ, *finalEndsI, *finalEndsJ;
unsigned char **finalSeqsI, **finalSeqsJ;
} CSTR_T;
# 207 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/sequenceAlignment.h"
void getUserParameters(void);
SEQDATA_T *genScalData(unsigned int, SIMMATRIX_T*, int, int, int);
SEQDATA_T *freeSeqData(SEQDATA_T*);
SIMMATRIX_T *genSimMatrix(int, int, int, int, int, int, int);
SIMMATRIX_T *freeSimMatrix(SIMMATRIX_T*);
void verifyData(SIMMATRIX_T*, SEQDATA_T*, int, int);
int gridInfo(int*, int*, int*, int*);
void qSort(int*, const int*, const int, const int);
void qSort_both(long long*, int*, const long long*, const int);
ASTR_T *pairwiseAlign(SEQDATA_T*, SIMMATRIX_T*, int, int, int);
ASTR_T *freeA(ASTR_T*);
BSTR_T *scanBackward(ASTR_T*, int, int, int);
BSTR_T *freeB(BSTR_T*);
void verifyAlignment(SIMMATRIX_T*, BSTR_T*, int);
CSTR_T *mergeAlignment(BSTR_T*, int, int);
CSTR_T *freeC(CSTR_T*);
void verifyMergeAlignment(SIMMATRIX_T*, CSTR_T*, int);
double getSeconds(void);
void dispElapsedTime(double);
# 15 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c" 2
# 15 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
# 16 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
# 17 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
# 18 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
# 19 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
# 20 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
void getUserParameters_npm(void);
void getUserParameters_quick(void); void getUserParameters(void);
void getUserParameters_resumable(void) {const int ____chimes_did_disable0 = new_stack((void *)(&getUserParameters), "getUserParameters", &____must_manage_getUserParameters, 0, 0) ; if (____chimes_replaying) { switch(get_next_call()) { default: { chimes_error(); } } } ; ;
# 21 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
# 22 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
if ((5) <= 0 || (-3) >= 0 || (8) < 0 || (1) <= 0) {
# 23 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
fprintf(stderr,"Similarity parameters set in userParameters are invalid\n");
# 24 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
exit(1);
# 25 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
}
# 26 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
if ((200) <= 0) {
# 27 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
fprintf(stderr,"Kernel 1 parameters set in userParameters are invalid\n");
# 28 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
}
# 29 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
if (((200)/2) <= 0) {
# 30 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
fprintf(stderr,"Kernel 2 parameters set in userParameters are invalid\n");
# 31 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
}
# 32 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
rm_stack(false, 0UL, "getUserParameters", &____must_manage_getUserParameters, 0, ____chimes_did_disable0, false); }
# 20 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
void getUserParameters_quick(void) {const int ____chimes_did_disable0 = new_stack((void *)(&getUserParameters), "getUserParameters", &____must_manage_getUserParameters, 0, 0) ; ; ;
# 21 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
# 22 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
if ((5) <= 0 || (-3) >= 0 || (8) < 0 || (1) <= 0) {
# 23 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
fprintf(stderr,"Similarity parameters set in userParameters are invalid\n");
# 24 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
exit(1);
# 25 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
}
# 26 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
if ((200) <= 0) {
# 27 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
fprintf(stderr,"Kernel 1 parameters set in userParameters are invalid\n");
# 28 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
}
# 29 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
if (((200)/2) <= 0) {
# 30 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
fprintf(stderr,"Kernel 2 parameters set in userParameters are invalid\n");
# 31 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
}
# 32 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
rm_stack(false, 0UL, "getUserParameters", &____must_manage_getUserParameters, 0, ____chimes_did_disable0, false); }
void getUserParameters(void) { (____chimes_replaying ? getUserParameters_resumable() : getUserParameters_quick()); }
# 20 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
void getUserParameters_npm(void) {
# 21 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
# 22 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
if ((5) <= 0 || (-3) >= 0 || (8) < 0 || (1) <= 0) {
# 23 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
fprintf(stderr,"Similarity parameters set in userParameters are invalid\n");
# 24 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
exit(1);
# 25 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
}
# 26 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
if ((200) <= 0) {
# 27 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
fprintf(stderr,"Kernel 1 parameters set in userParameters are invalid\n");
# 28 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
}
# 29 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
if (((200)/2) <= 0) {
# 30 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
fprintf(stderr,"Kernel 2 parameters set in userParameters are invalid\n");
# 31 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
}
# 32 "/gpfs-biou/jmg3/spec/benchspec/OMP2012/372.smithwa/src/getUserParameters.c"
}
static int module_init() {
init_module(3803651465693704543UL, 0, 1, 0, 0, 1, 0, 1, 0, 0, 0,
"getUserParameters", 0, "_Z17getUserParametersv", "_Z21getUserParameters_npmv", 0, 0, 0UL, 0,
"getUserParameters", &(____chimes_does_checkpoint_getUserParameters_npm),
"getUserParameters", "_Z17getUserParametersv", 0, 0);
return 0;
}
static const int __libchimes_module_init = module_init();
| [
"jmaxg3@gmail.com"
] | jmaxg3@gmail.com |
90c22297fe7915a6bb6e33f8139d68b38a1cf059 | 5125535717f1f4c2123c666ea90e7041a9ac98dd | /_rings.ino | 2de79e36cfc3ddc9e3eb6813ed8be39af4debbc5 | [] | no_license | Jaharmi/pixelated | d07ee1cb5db684a08dd22c4f307da70814f9c377 | 88a3df2a44e49c79898d7c5b39d813a7bf664a58 | refs/heads/master | 2022-03-01T21:22:08.788118 | 2019-10-22T10:07:54 | 2019-10-22T10:07:54 | null | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,680 | ino | float noiseScale =0.2;
float fractalNoise (float x, float y, float z) {
float r=0;
float amp=1.0;
for (int octave=0; octave<4;octave ++){
r+=noise(x)+noise(y)+noise(z) * amp;
amp /=2;
x*=2;
y*=2;
z*=2;
}
return r;
}
float noise (float val) {
return (float (random( 0,1000)/1000.0));
}
float dx,dy,dz;
void DoRings() {
long now = millis();
float speed = 0.002;
float zspeed= 0.1;
float angle=sin (now * 0.001);
float z= now * 0.00008;
float hue= now *0.01;
float scale=0.005;
float saturation = 100* constrain(pow(1.15 * noise(now * 0.000122) ,2.5),0,1);
float spacing = noise (now*0.000124) * 0.1;
dx += cos(angle)*speed;
dy += sin(angle)*speed;
dz += (noise(now * 0.000014) -0.5) * zspeed;
float centerx = noise (now * 0.000125) * 1.25 * COLUMNS;
float centery = noise (now * -0.000125) * 1.25 * ROWS;
for (int x=0; x< COLUMNS; x++) {
for (int y=0; y< ROWS; y++){
float dist = sqrt(pow(x - centerx,2) + pow(y - centery,2));
float pulse = (sin (dz + dist* spacing) - 0.3) * 0.3;
float n = fractalNoise (dx+ x*scale + pulse , dy+y*scale,z) - 0.75;
float m = fractalNoise (dx + x*scale , dy + y* scale, z+10.0) - 0.75;
// color c= color ( ( hue+ 40.0 * m ) % 100.0, saturation, 100* constrain(pow(3.0*n,1.5) ,0,0.9) );
//matrix.drawPixelRGB888(x, y, red, green, blue);
matrix.drawPixel (x,y,BLUE);
// matrix.drawPixelRGB888 (x,y,int (( hue+ 40.0 * m ) % 100.0),int ( saturation) ,int ( 100* constrain(pow(3.0*n,1.5) ,0,0.9)) ); //c = color
}
}
}
| [
"lawrence@computersolutions.cn"
] | lawrence@computersolutions.cn |
1432004e909b981c63d8660a4c74696ec914f0eb | a495da70ed1f0450059f83e6163b9c011f3e3798 | /csUtil/src-Core/include/cs/Core/Endian.h | 44444c62e4ff111d7654747cefbf74835ba601fc | [] | no_license | CaSchmidt/csUtil | 20e58545edb09d5fdab55eb097d4b4c9e254ca53 | 9b8f1d5bbfd578f1f11d2e34eb94ddde2b3f3ae8 | refs/heads/master | 2023-08-18T06:35:21.274808 | 2023-08-09T18:50:54 | 2023-08-09T18:50:54 | 151,853,593 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 4,751 | h | /****************************************************************************
** Copyright (c) 2016, Carsten Schmidt. All rights reserved.
**
** Redistribution and use in source and binary forms, with or without
** modification, are permitted provided that the following conditions
** are met:
**
** 1. Redistributions of source code must retain the above copyright
** notice, this list of conditions and the following disclaimer.
**
** 2. Redistributions in binary form must reproduce the above copyright
** notice, this list of conditions and the following disclaimer in the
** documentation and/or other materials provided with the distribution.
**
** 3. Neither the name of the copyright holder nor the names of its
** contributors may be used to endorse or promote products derived from
** this software without specific prior written permission.
**
** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
** HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*****************************************************************************/
#pragma once
#ifdef _MSC_VER
# include <cstdlib>
#endif
#include <bit>
#include <cs/Core/TypeTraits.h>
namespace cs {
template<typename T>
using is_swappable = std::bool_constant<
is_char_v<T> ||
is_integral_v<T> ||
is_real_v<T>
>;
template<typename T>
inline constexpr bool is_swappable_v = is_swappable<T>::value;
template<typename T>
concept IsSwappable = is_swappable_v<T>;
// Implementation //////////////////////////////////////////////////////////
namespace impl_endian {
#if defined(_MSC_VER)
inline uint16_t impl_swap(const uint16_t& value)
{
return _byteswap_ushort(value);
}
inline uint32_t impl_swap(const uint32_t& value)
{
return _byteswap_ulong(value);
}
inline uint64_t impl_swap(const uint64_t& value)
{
return _byteswap_uint64(value);
}
#elif defined(__GNUC__)
inline uint16_t impl_swap(const uint16_t& value)
{
return __builtin_bswap16(value);
}
inline uint32_t impl_swap(const uint32_t& value)
{
return __builtin_bswap32(value);
}
inline uint64_t impl_swap(const uint64_t& value)
{
return __builtin_bswap64(value);
}
#else
# error Compiler not supported!
#endif
template<typename T>
inline T do_swap(const T& value)
{
using S = typename IntegralOfSize<sizeof(T)>::unsigned_type;
const S swapped = impl_swap(*reinterpret_cast<const S*>(&value));
return *reinterpret_cast<const T*>(&swapped);
}
template<bool SWAP, typename T>
constexpr std::enable_if_t<SWAP,T> dispatch(const T& value)
{
return do_swap<T>(value);
}
template<bool SWAP, typename T>
constexpr std::enable_if_t<!SWAP,T> dispatch(const T& value)
{
return value;
}
} // namespace impl_endian
// User Interface //////////////////////////////////////////////////////////
template<bool SWAP, typename T> requires IsSwappable<T>
constexpr T copy(const T& value)
{
return impl_endian::dispatch<SWAP && sizeof(T) >= 2,T>(value);
}
template<typename T> requires IsSwappable<T>
constexpr T swap(const T& value)
{
return impl_endian::dispatch<sizeof(T) >= 2,T>(value);
}
/*
* Convert endianness between host byte order and 'peer' byte order.
*/
template<typename T> requires IsSwappable<T>
constexpr T fromBigEndian(const T& peerValue)
{
return copy<std::endian::native != std::endian::big>(peerValue);
}
template<typename T> requires IsSwappable<T>
constexpr T fromLittleEndian(const T& peerValue)
{
return copy<std::endian::native != std::endian::little>(peerValue);
}
template<typename T> requires IsSwappable<T>
constexpr T toBigEndian(const T& hostValue)
{
return copy<std::endian::native != std::endian::big>(hostValue);
}
template<typename T> requires IsSwappable<T>
constexpr T toLittleEndian(const T& hostValue)
{
return copy<std::endian::native != std::endian::little>(hostValue);
}
} // namespace cs
| [
"CaSchmidt@users.noreply.github.com"
] | CaSchmidt@users.noreply.github.com |
c04e2ae16f44fc11e3e9c69c81331416f8243b9d | ddad5e9ee062d18c33b9192e3db95b58a4a67f77 | /util/math/float2decimal.cc | afe0af6e4440f94d1819902e6bfb96eae54f0bf8 | [
"BSD-2-Clause"
] | permissive | romange/gaia | c7115acf55e4b4939f8111f08e5331dff964fd02 | 8ef14627a4bf42eba83bb6df4d180beca305b307 | refs/heads/master | 2022-01-11T13:35:22.352252 | 2021-12-28T16:11:13 | 2021-12-28T16:11:13 | 114,404,005 | 84 | 17 | BSD-2-Clause | 2021-12-28T16:11:14 | 2017-12-15T19:20:34 | C++ | UTF-8 | C++ | false | false | 23,547 | cc | // Copyright 2017, Beeri 15. All rights reserved.
// Author: Roman Gershman (romange@gmail.com)
//
#include "util/math/float2decimal.h"
#include "base/logging.h"
#define FAST_DTOA_UNREACHABLE() __builtin_unreachable();
namespace util {
namespace dtoa {
namespace {
//
// Given a (normalized) floating-point number v and its neighbors m- and m+
//
// ---+---------------------------+---------------------------+---
// m- v m+
//
// Grisu first scales the input number w, and its boundaries w- and w+, by an
// approximate power-of-ten c ~= 10^-k (which needs to be precomputed using
// high-precision arithmetic and stored in a table) such that the exponent of
// the products lies within a certain range [alpha, gamma]. It then remains to
// produce the decimal digits of a DiyFp number M = f * 2^e, where
// alpha <= e <= gamma.
//
// The choice of alpha and gamma determines the digit generation procedure and
// the size of the look-up table (or vice versa...) and depends on the
// extended precision q.
//
// In other words, given normalized w, Grisu needs to find a (normalized) cached
// power-of-ten c, such that the exponent of the product c * w = f * 2^e
// satisfies (Definition 3.2)
//
// alpha <= e = e_c + e_w + q <= gamma
//
// or
//
// f_c * f_w * 2^alpha <= f_c 2^(e_c) * f_w 2^(e_w) * 2^q
// <= f_c * f_w * 2^gamma
//
// Since c and w are normalized, i.e. 2^(q-1) <= f < 2^q, this implies
//
// 2^(q-1) * 2^(q-1) * 2^alpha <= c * w * 2^q < 2^q * 2^q * 2^gamma
//
// or
//
// 2^(q - 2 + alpha) <= c * w < 2^(q + gamma)
//
// The distance (gamma - alpha) should be as large as possible in order to make
// the table as small as possible, but the digit generation procedure should
// still be efficient.
//
// Assume q = 64 and e < 0. The idea is to cut the number c * w = f * 2^e into
// two parts, which can be processed independently: An integral part p1, and a
// fractional part p2:
//
// f * 2^e = ( (f div 2^-e) * 2^-e + (f mod 2^-e) ) * 2^e
// = (f div 2^-e) + (f mod 2^-e) * 2^e
// = p1 + p2 * 2^e
//
// The conversion of p1 into decimal form requires some divisions and modulos by
// a power-of-ten. These operations are faster for 32-bit than for 64-bit
// integers, so p1 should ideally fit into a 32-bit integer. This be achieved by
// choosing
//
// -e >= 32 or e <= -32 := gamma
//
// In order to convert the fractional part
//
// p2 * 2^e = d[-1] / 10^1 + d[-2] / 10^2 + ... + d[-k] / 10^k
//
// into decimal form, the fraction is repeatedly multiplied by 10 and the digits
// d[-i] are extracted in order:
//
// (10 * p2) div 2^-e = d[-1]
// (10 * p2) mod 2^-e = d[-2] / 10^1 + ... + d[-k] / 10^(k-1)
//
// The multiplication by 10 must not overflow. For this it is sufficient to have
//
// 10 * p2 < 16 * p2 = 2^4 * p2 <= 2^64.
//
// Since p2 = f mod 2^-e < 2^-e one may choose
//
// -e <= 60 or e >= -60 := alpha
//
// Different considerations may lead to different digit generation procedures
// and different values of alpha and gamma...
//
constexpr int const kAlpha = -60;
constexpr int const kGamma = -32;
// Grisu needs to find a(normalized) cached power-of-ten c, such that the
// exponent of the product c * w = f * 2^e satisfies (Definition 3.2)
//
// alpha <= e = e_c + e_w + q <= gamma
//
// For IEEE double precision floating-point numbers v converted into a DiyFp's
// w = f * 2^e,
//
// e >= -1022 (min IEEE exponent)
// -52 (IEEE significand size)
// -52 (possibly normalize denormal IEEE numbers)
// -11 (normalize the DiyFp)
// = -1137
//
// and
//
// e <= +1023 (max IEEE exponent)
// -52 (IEEE significand size)
// -11 (normalize the DiyFp)
// = 960
//
// (For IEEE single precision the exponent range is [-196, 80].)
//
// Now
//
// alpha <= e_c + e + q <= gamma
// ==> f_c * 2^alpha <= c * 2^e * 2^q
//
// and since the c's are normalized, 2^(q-1) <= f_c,
//
// ==> 2^(q - 1 + alpha) <= c * 2^(e + q)
// ==> 2^(alpha - e - 1) <= c
//
// If c were an exakt power of ten, i.e. c = 10^k, one may determine k as
//
// k = ceil( log_10( 2^(alpha - e - 1) ) )
// = ceil( (alpha - e - 1) * log_10(2) )
//
// (From the paper)
// "In theory the result of the procedure could be wrong since c is rounded, and
// the computation itself is approximated [...]. In practice, however, this
// simple function is sufficient."
//
// The difference of the decimal exponents of adjacent table entries must be
// <= floor( (gamma - alpha) * log_10(2) ) = 8.
struct CachedPower { // c = f * 2^e ~= 10^k
uint64_t f;
int e;
int k;
};
// Returns a cached power-of-ten c, such that alpha <= e_c + e + q <= gamma.
CachedPower GetCachedPowerForBinaryExponent(int e) {
// NB:
// Actually this function returns c, such that -60 <= e_c + e + 64 <= -34.
static constexpr CachedPower const kCachedPowers[] = {
{0xAB70FE17C79AC6CA, -1060, -300}, // -1060 + 960 + 64 = -36
{0xFF77B1FCBEBCDC4F, -1034, -292}, {0xBE5691EF416BD60C, -1007, -284},
{0x8DD01FAD907FFC3C, -980, -276}, {0xD3515C2831559A83, -954, -268},
{0x9D71AC8FADA6C9B5, -927, -260}, {0xEA9C227723EE8BCB, -901, -252},
{0xAECC49914078536D, -874, -244}, {0x823C12795DB6CE57, -847, -236},
{0xC21094364DFB5637, -821, -228}, {0x9096EA6F3848984F, -794, -220},
{0xD77485CB25823AC7, -768, -212}, {0xA086CFCD97BF97F4, -741, -204},
{0xEF340A98172AACE5, -715, -196}, {0xB23867FB2A35B28E, -688, -188},
{0x84C8D4DFD2C63F3B, -661, -180}, {0xC5DD44271AD3CDBA, -635, -172},
{0x936B9FCEBB25C996, -608, -164}, {0xDBAC6C247D62A584, -582, -156},
{0xA3AB66580D5FDAF6, -555, -148}, {0xF3E2F893DEC3F126, -529, -140},
{0xB5B5ADA8AAFF80B8, -502, -132}, {0x87625F056C7C4A8B, -475, -124},
{0xC9BCFF6034C13053, -449, -116}, {0x964E858C91BA2655, -422, -108},
{0xDFF9772470297EBD, -396, -100}, {0xA6DFBD9FB8E5B88F, -369, -92},
{0xF8A95FCF88747D94, -343, -84}, {0xB94470938FA89BCF, -316, -76},
{0x8A08F0F8BF0F156B, -289, -68}, {0xCDB02555653131B6, -263, -60},
{0x993FE2C6D07B7FAC, -236, -52}, {0xE45C10C42A2B3B06, -210, -44},
{0xAA242499697392D3, -183, -36}, // -183 + 80 + 64 = -39
{0xFD87B5F28300CA0E, -157, -28}, //
{0xBCE5086492111AEB, -130, -20}, //
{0x8CBCCC096F5088CC, -103, -12}, //
{0xD1B71758E219652C, -77, -4}, //
{0x9C40000000000000, -50, 4}, //
{0xE8D4A51000000000, -24, 12}, //
{0xAD78EBC5AC620000, 3, 20}, //
{0x813F3978F8940984, 30, 28}, //
{0xC097CE7BC90715B3, 56, 36}, //
{0x8F7E32CE7BEA5C70, 83, 44}, // 83 - 196 + 64 = -49
{0xD5D238A4ABE98068, 109, 52}, {0x9F4F2726179A2245, 136, 60},
{0xED63A231D4C4FB27, 162, 68}, {0xB0DE65388CC8ADA8, 189, 76},
{0x83C7088E1AAB65DB, 216, 84}, {0xC45D1DF942711D9A, 242, 92},
{0x924D692CA61BE758, 269, 100}, {0xDA01EE641A708DEA, 295, 108},
{0xA26DA3999AEF774A, 322, 116}, {0xF209787BB47D6B85, 348, 124},
{0xB454E4A179DD1877, 375, 132}, {0x865B86925B9BC5C2, 402, 140},
{0xC83553C5C8965D3D, 428, 148}, {0x952AB45CFA97A0B3, 455, 156},
{0xDE469FBD99A05FE3, 481, 164}, {0xA59BC234DB398C25, 508, 172},
{0xF6C69A72A3989F5C, 534, 180}, {0xB7DCBF5354E9BECE, 561, 188},
{0x88FCF317F22241E2, 588, 196}, {0xCC20CE9BD35C78A5, 614, 204},
{0x98165AF37B2153DF, 641, 212}, {0xE2A0B5DC971F303A, 667, 220},
{0xA8D9D1535CE3B396, 694, 228}, {0xFB9B7CD9A4A7443C, 720, 236},
{0xBB764C4CA7A44410, 747, 244}, {0x8BAB8EEFB6409C1A, 774, 252},
{0xD01FEF10A657842C, 800, 260}, {0x9B10A4E5E9913129, 827, 268},
{0xE7109BFBA19C0C9D, 853, 276}, {0xAC2820D9623BF429, 880, 284},
{0x80444B5E7AA7CF85, 907, 292}, {0xBF21E44003ACDD2D, 933, 300},
{0x8E679C2F5E44FF8F, 960, 308}, {0xD433179D9C8CB841, 986, 316},
{0x9E19DB92B4E31BA9, 1013, 324}, // 1013 - 1137 + 64 = -60
};
constexpr int const kCachedPowersSize = 79;
constexpr int const kCachedPowersMinDecExp = -300;
// This computation gives exactly the same results for k as
//
// k = ceil((kAlpha - e - 1) * 0.30102999566398114)
//
// for |e| <= 1500, but doesn't require floating-point operations.
// NB: log_10(2) ~= 78913 / 2^18
assert(e >= -1500);
assert(e <= 1500);
int const f = kAlpha - e - 1;
int const k = (f * 78913) / (1 << 18) + (f > 0);
int const index = (-kCachedPowersMinDecExp + k + (8 - 1)) / 8;
assert(index >= 0);
assert(index < kCachedPowersSize);
static_cast<void>(kCachedPowersSize); // Fix warning.
CachedPower const cached = kCachedPowers[index];
assert(kAlpha <= cached.e + e + 64);
assert(kGamma >= cached.e + e + 64);
// XXX:
// cached.k = kCachedPowersMinDecExp + 8*index
return cached;
}
// For n != 0, returns k, such that 10^(k-1) <= n < 10^k.
// For n == 0, returns 1.
inline unsigned InitKappa(uint32_t n) {
return base::CountDecimalDigit32(n);
}
inline void Grisu2Round(char& digit, uint64_t dist, uint64_t delta, uint64_t rest,
uint64_t ten_k) {
// dist, delta, rest and ten_k all are the significands of
// floating-point numbers with an exponent e.
assert(dist <= delta);
assert(rest <= delta);
assert(ten_k > 0);
//
// <--------------------------- delta ---->
// <---- dist --------->
// --------------[------------------+-------------------]--------------
// w- w w+
//
// 10^k
// <------>
// <---- rest ---->
// --------------[------------------+----+--------------]--------------
// w V
// = buf * 10^k
//
// ten_k represents a unit-in-the-last-place in the decimal representation
// stored in buf.
// Decrement buf by ten_k while this takes buf closer to w.
//
while (rest < dist && delta - rest >= ten_k &&
(rest + ten_k < dist || dist - rest > rest + ten_k - dist)) {
DCHECK_NE('0', digit);
digit--;
rest += ten_k;
}
}
void SetDigits(uint32_t value, unsigned num_digits, char* buffer) {
const char DIGITS[] =
"0001020304050607080910111213141516171819"
"2021222324252627282930313233343536373839"
"4041424344454647484950515253545556575859"
"6061626364656667686970717273747576777879"
"8081828384858687888990919293949596979899";
buffer += num_digits;
while (value >= 100) {
// Integer division is slow so do it for a group of two digits instead
// of for every digit. The idea comes from the talk by Alexandrescu
// "Three Optimization Tips for C++".
unsigned index = static_cast<unsigned>((value % 100) * 2);
value /= 100;
*--buffer = DIGITS[index + 1];
*--buffer = DIGITS[index];
}
if (value < 10) {
*--buffer = static_cast<char>('0' + value);
return;
}
unsigned index = static_cast<unsigned>(value * 2);
*--buffer = DIGITS[index + 1];
*--buffer = DIGITS[index];
}
std::pair<unsigned, int> Grisu2DigitGen(char* buffer, int decimal_exponent,
const Fp& M_minus, const Fp& w, const Fp& M_plus) {
static constexpr char const* const kDigits = "0123456789";
static_assert(kAlpha >= -60, "invalid parameter");
static_assert(kGamma <= -32, "invalid parameter");
assert(M_plus.e >= kAlpha);
assert(M_plus.e <= kGamma);
uint64_t delta = M_plus.f - M_minus.f; // (significand of (w+ - w-), implicit exponent is e)
uint64_t dist = M_plus.f - w.f; // (significand of (w+ - w ), implicit exponent is e)
// <--------------------------- delta ---->
// <---- dist --------->
// --------------[------------------+-------------------]--------------
// w- w w+
//
// Split w+ = f * 2^e into two parts p1 and p2 (note: e < 0):
//
// w+ = f * 2^e
// = ((f div 2^-e) * 2^-e + (f mod 2^-e)) * 2^e
// = ((p1 ) * 2^-e + (p2 )) * 2^e
// = p1 + p2 * 2^e
// p1 = f div 2^-e (Since -e >= 32, p1 fits into a 32-bit int.)
const uint64_t e_shift = -M_plus.e;
const uint64_t e_mask = (1ULL << e_shift) - 1;
uint32_t p1 = M_plus.f >> e_shift;
uint64_t p2 = M_plus.f & e_mask; // p2 = f mod 2^-e
DCHECK_GT(p1, 0);
//
// 1.
// Generate the digits of the integral part p1 = d[n-1]...d[1]d[0]
//
unsigned kappa = InitKappa(p1);
// We now have
// (B = buffer, L = length = k - n)
//
// 10^(k-1) <= p1 < 10^k
//
// p1 = (p1 div 10^(k-1)) * 10^(k-1) + (p1 mod 10^(k-1))
// = (B[0] ) * 10^(k-1) + (p1 mod 10^(k-1))
//
// w+ = p1 + p2 * 2^e
// = B[0] * 10^(k-1) + (p1 mod 10^(k-1)) + p2 * 2^e
// = B[0] * 10^(k-1) + ((p1 mod 10^(k-1)) * 2^-e + p2) * 2^e
// = B[0] * 10^(k-1) + ( rest) * 2^e
//
// and generate the digits d of p1 from left to right:
//
// p1 = (B[0]B[1]...B[L -1]B[L]B[L+1] ...B[k-2]B[k-1])_10
// = (B[0]B[1]...B[L -1])_10 * 10^(k-L) + (B[L ]...B[k-2]B[k-1])_10 (L = 1...k)
// = (B[0]B[1]...B[k-n-1])_10 * 10^(n ) + (B[k-n ]...B[k-2]B[k-1])_10 (n = k...1)
bool cut_early = delta >= p2;
uint32_t length = kappa;
if (cut_early) {
uint32_t p1_remainder = 0;
uint32_t ten_n = 1;
unsigned power = 0;
uint32_t delta_shifted = (delta - p2) >> e_shift; // valid due to cut_early
bool check_increase_power = true;
if (delta_shifted > 0) {
power = base::CountDecimalDigit32(delta_shifted);
ten_n = base::Power10(power);
p1_remainder = p1 % ten_n;
if (p1_remainder > delta_shifted) {
--power;
ten_n /= 10;
p1_remainder %= ten_n;
check_increase_power = false;
}
DCHECK_LE(p1_remainder, delta_shifted);
p1 /= ten_n;
length -= power;
}
if (check_increase_power) {
while (p1 % 10 == 0) {
++power;
ten_n *= 10;
p1 /= 10;
--length;
}
}
SetDigits(p1, length, buffer);
// Found V = buffer * 10^n, with w- <= V <= w+.
// And V is correctly rounded.
//
decimal_exponent += power;
if (dist > p2) {
// We may now just stop. But instead look if the buffer could be
// decremented to bring V closer to w.
//
// 10^n is now 1 ulp in the decimal representation V.
//
// The rounding procedure works with DiyFp's with an implicit
// exponent e.
//
// 10^n = ten_n * 2^e = (10^n * 2^-e) * 2^e
//
// Note:
// n has been decremented above, i.e. pow10 = 10^n
//
uint64_t rest = (uint64_t(p1_remainder) << e_shift) + p2;
uint64_t ten_n64 = uint64_t(ten_n) << e_shift;
while (rest < dist && delta - rest >= ten_n64 &&
ten_n64 / 2 < (dist - rest)) {
DCHECK_NE('0', buffer[length-1]);
buffer[length-1]--;
rest += ten_n64;
}
}
return std::pair<unsigned, int>(length, decimal_exponent);
}
SetDigits(p1, length, buffer);
assert(p2 != 0);
// (otherwise the loop above would have been exited with rest <= delta)
//
// 2.
// The digits of the integral part have been generated:
//
// w+ = d[k-1]...d[1]d[0] + p2 * 2^e = buffer + p2 * 2^e
//
// Now generate the digits of the fractional part p2 * 2^e.
//
// Note:
// No decimal point is generated: the exponent is adjusted instead.
//
// p2 actually represents the fraction
//
// p2 * 2^e
// = p2 / 2^-e
// = d[-1] / 10^1 + d[-2] / 10^2 + d[-3] / 10^3 + ... + d[-m] / 10^m
//
// or
//
// 10 * p2 / 2^-e = d[-1] + (d[-2] / 10^1 + ... + d[-m] / 10^(m-1))
//
// and the digits can be obtained from left to right by
//
// (10 * p2) div 2^-e = d[-1]
// (10 * p2) mod 2^-e = d[-2] / 10^1 + ... + d[-m] / 10^(m-1)
//
DCHECK_GT(p2, delta);
int m = 0;
for (;;) {
// Invariant:
// 1. w+ = buffer * 10^m + 10^m * p2 * 2^e (Note: m <= 0)
// p2 * 10 < 2^60 * 10 < 2^60 * 2^4 = 2^64,
// so the multiplication by 10 does not overflow.
DCHECK_LE(p2, e_mask);
p2 *= 10;
uint64_t const d = p2 >> e_shift; // = p2 div 2^-e
uint64_t const r = p2 & e_mask; // = p2 mod 2^-e
// w+ = buffer * 10^m + 10^m * p2 * 2^e
// = buffer * 10^m + 10^(m-1) * (10 * p2 ) * 2^e
// = buffer * 10^m + 10^(m-1) * (d * 2^-e + r) * 2^e
// = buffer * 10^m + 10^(m-1) * d + 10^(m-1) * r * 2^e
// = (buffer * 10 + d) * 10^(m-1) + 10^(m-1) * r * 2^e
assert(d <= 9);
buffer[length++] = kDigits[d]; // buffer := buffer * 10 + d
// w+ = buffer * 10^(m-1) + 10^(m-1) * r * 2^e
p2 = r;
m -= 1;
// w+ = buffer * 10^m + 10^m * p2 * 2^e
//
// Invariant (1) restored.
// p2 is now scaled by 10^(-m) since it repeatedly is multiplied by 10.
// To keep the units in sync, delta and dist need to be scaled too.
delta *= 10;
dist *= 10;
uint64_t const rest = p2;
// Check if enough digits have been generated.
if (rest <= delta) {
decimal_exponent += m;
// ten_m represents 10^m as a Fp with an exponent e.
//
// Note: m < 0
//
// Note:
// delta and dist are now scaled by 10^(-m) (they are repeatedly
// multiplied by 10) and we need to do the same with ten_m.
//
// 10^(-m) * 10^m = 10^(-m) * ten_m * 2^e
// = (10^(-m) * 10^m * 2^-e) * 2^e
// = 2^-e * 2^e
//
// one.f = 2^-e and the exponent e is implicit.
//
uint64_t const ten_m = 1ULL << e_shift;
Grisu2Round(buffer[length-1], dist, delta, rest, ten_m);
return std::pair<unsigned, int>(length, decimal_exponent);
}
}
// By construction this algorithm generates the shortest possible decimal
// number (Loitsch, Theorem 6.2) which rounds back to w.
// For an input number of precision p, at least
//
// N = 1 + ceil(p * log_10(2))
//
// decimal digits are sufficient to identify all binary floating-point
// numbers (Matula, "In-and-Out conversions").
// This implies that the algorithm does not produce more than N decimal
// digits.
//
// N = 17 for p = 53 (IEEE double precision)
// N = 9 for p = 24 (IEEE single precision)
}
} // namespace
// v = buf * 10^decimal_exponent
// len is the length of the buffer (number of decimal digits)
std::pair<unsigned, int> Grisu2(Fp m_minus, Fp v, Fp m_plus, char* buf) {
assert(v.e == m_minus.e);
assert(v.e == m_plus.e);
//
// --------(-----------------------+-----------------------)-------- (A)
// m- v m+
//
// --------------------(-----------+-----------------------)-------- (B)
// m- v m+
//
// First scale v (and m- and m+) such that the exponent is in the range
// [alpha, beta].
//
CachedPower const cached = GetCachedPowerForBinaryExponent(m_plus.e);
Fp const c_minus_k(cached.f, cached.e); // = c ~= 10^k
Fp const w = v.Mul(c_minus_k); // Exponent of the products is v.e + c_minus_k.e + q
Fp const w_minus = m_minus.Mul(c_minus_k);
Fp const w_plus = m_plus.Mul(c_minus_k);
//
// ----(---+---)---------------(---+---)---------------(---+---)----
// w- w w+
// = c*m- = c*v = c*m+
//
// Fp::Mul rounds its result and c_minus_k is approximated too. w (as well
// as w- and w+) are now off by a small amount.
// In fact:
//
// w - v * 10^k < 1 ulp
//
// To account for this inaccuracy, add resp. subtract 1 ulp.
//
// --------+---[---------------(---+---)---------------]---+--------
// w- M- w M+ w+
//
// Now any number in [M-, M+] (bounds included) will round to w when input,
// regardless of how the input rounding algorithm breaks ties.
//
// And DigitGen generates the shortest possible such number in [M-, M+].
// This does not mean that Grisu2 always generates the shortest possible
// number in the interval (m-, m+).
//
Fp const M_minus = Fp(w_minus.f + 1, w_minus.e);
Fp const M_plus = Fp(w_plus.f - 1, w_plus.e);
return Grisu2DigitGen(buf, -cached.k, M_minus, w, M_plus);
}
//------------------------------------------------------------------------------
//
//------------------------------------------------------------------------------
// Returns a pointer to the element following the exponent
char* AppendExponent(char* buf, int e) {
static constexpr char const* const kDigits = "0123456789";
static constexpr char const* const kDigits100 =
"00010203040506070809"
"10111213141516171819"
"20212223242526272829"
"30313233343536373839"
"40414243444546474849"
"50515253545556575859"
"60616263646566676869"
"70717273747576777879"
"80818283848586878889"
"90919293949596979899";
assert(e > -1000);
assert(e < 1000);
if (e < 0)
*buf++ = '-', e = -e;
else
*buf++ = '+';
uint32_t const k = static_cast<uint32_t>(e);
if (k < 10) {
// *buf++ = kDigits[0];
*buf++ = kDigits[k];
} else if (k < 100) {
*buf++ = kDigits100[2 * k + 0];
*buf++ = kDigits100[2 * k + 1];
} else {
uint32_t const q = k / 100;
uint32_t const r = k % 100;
*buf++ = kDigits[q];
*buf++ = kDigits100[2 * r + 0];
*buf++ = kDigits100[2 * r + 1];
}
return buf;
}
char* FormatBuffer(char* buf, int k, int n) {
// v = digits * 10^(n-k)
// k is the length of the buffer (number of decimal digits)
// n is the position of the decimal point relative to the start of the buffer.
//
// Format the decimal floating-number v in the same way as JavaScript's ToString
// applied to number type.
//
// See:
// https://tc39.github.io/ecma262/#sec-tostring-applied-to-the-number-type
if (k <= n && n <= 21) {
// digits[000]
std::memset(buf + k, '0', static_cast<size_t>(n - k));
// if (trailing_dot_zero)
//{
// buf[n++] = '.';
// buf[n++] = '0';
//}
return buf + n; // (len <= 21 + 2 = 23)
}
if (0 < n && n <= 21) {
// dig.its
assert(k > n);
std::memmove(buf + (n + 1), buf + n, static_cast<size_t>(k - n));
buf[n] = '.';
return buf + (k + 1); // (len == k + 1 <= 18)
}
if (-6 < n && n <= 0) {
// 0.[000]digits
std::memmove(buf + (2 + -n), buf, static_cast<size_t>(k));
buf[0] = '0';
buf[1] = '.';
std::memset(buf + 2, '0', static_cast<size_t>(-n));
return buf + (2 + (-n) + k); // (len <= k + 7 <= 24)
}
if (k == 1) {
// dE+123
buf += 1; // (len <= 1 + 5 = 6)
} else {
// d.igitsE+123
std::memmove(buf + 2, buf + 1, static_cast<size_t>(k - 1));
buf[1] = '.';
buf += 1 + k; // (len <= k + 6 = 23)
}
*buf++ = 'e';
return AppendExponent(buf, n - 1);
}
} // namespace dtoa
} // namespace util
| [
"roman@ubimo.com"
] | roman@ubimo.com |
6622f687135a37e169893824b05b87dd56fefc25 | 04ecdf08a159fd9b469cf357657f46ec98517be7 | /sorting/squares-sorted-arr.cpp | d4b913c053fda696c0c78f0948cfaea4e6e99597 | [] | no_license | rjt007/LeetCode-Problems | d9cc890c2492d084e6035a69883a950c5985e976 | b0c02dcc6cb58439b8b94f40dcb3968cd6dfbcf1 | refs/heads/master | 2023-08-17T04:33:57.379783 | 2021-09-22T17:54:11 | 2021-09-22T17:54:11 | 382,655,578 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 901 | cpp | //https://leetcode.com/problems/squares-of-a-sorted-array/
#include <bits/stdc++.h>
using namespace std;
//T.C->O(N), S.C->O(1)
vector<int> sortedSquares(vector<int> &nums)
{
vector<int> ans;
int n = nums.size();
int i = 0, j = n - 1;
while (i <= j)
{
if (nums[j] * nums[j] >= nums[i] * nums[i])
{
ans.push_back(nums[j] * nums[j]);
j--;
}
else
{
ans.push_back(nums[i] * nums[i]);
i++;
}
}
reverse(ans.begin(), ans.end());
return ans;
}
int main()
{
int n;
cin >> n;
vector<int> v;
int val;
for (int i = 0; i < n; i++)
{
cin >> val;
v.push_back(val);
}
vector<int> ans = sortedSquares(v);
cout<<"Result is:\n";
for (int i = 0; i < ans.size(); i++)
{
cout<<ans[i]<<" ";
}
cout<<endl;
return 0;
} | [
"rajatagrawal007.ra@gmail.com"
] | rajatagrawal007.ra@gmail.com |
96a460d878a94ab50b6cf78fade83ccc3f946e86 | e1230a4aba63635e6bc2371e97f1d9a2ac069921 | /Server/SinBaram/sinSOD2.cpp | d9cacee443edc55ea50ec701ed867ac6d817e212 | [] | no_license | tobiasquinteiro/HonorPT | d900c80c2a92e0af792a1ea77e54f6bcd737d941 | 4845c7a03b12157f9de0040443a91e45b38e8ca0 | refs/heads/master | 2021-12-09T08:14:33.777333 | 2016-05-04T03:32:23 | 2016-05-04T03:32:23 | null | 0 | 0 | null | null | null | null | UHC | C++ | false | false | 87,806 | cpp | /*----------------------------------------------------------------------------*
* ํ์ผ๋ช
: sinSOD2.cpp
* ํ๋์ผ : ํ์ฌ Test ์ฉ์ผ๋ก ์ฐ์ด๊ณ ์๋ฐ
* ์์ฑ์ผ : ์ต์ข
์
๋ฐ์ดํธ 4์
* ์ ์ฑ์ : ๋ฐ์์ด
*-----------------------------------------------------------------------------*/
#include "sinLinkHeader.h"
#include "..\\tjboy\\clanmenu\\tjclan.h"
#include "..\\tjboy\\clanmenu\\clan_Enti.h"
#include "..\\tjboy\\isaocheck\\auth.h"
#include "..\\FontImage.h"
#include "..\\bellatraFontEffect.h" //ํฐํธ ์ดํํธ
#include "..\\field.h"
#include "..\\SrcServer\\onserver.h"
cSINSOD2 cSinSod2;
cSINSIEGE cSinSiege;
sinMESSAGEBOX_NEW sinMessageBox_New;
LPDIRECTDRAWSURFACE4 lpbltr_clanN;
LPDIRECTDRAWSURFACE4 lpbltr_clanB;
int Matbltr_Paper291;
int Matbltr_Paper291_Text;
LPDIRECTDRAWSURFACE4 lpbltr_ButtonBox;
LPDIRECTDRAWSURFACE4 lpbltr_Button_Clan;
LPDIRECTDRAWSURFACE4 lpbltr_Button_Clan_G;
LPDIRECTDRAWSURFACE4 lpbltr_Button_Prize;
LPDIRECTDRAWSURFACE4 lpbltr_Button_Prize_G;
LPDIRECTDRAWSURFACE4 lpbltr_Button_OK;
LPDIRECTDRAWSURFACE4 lpbltr_Button_OK_G;
int Matbltr_Logo;
LPDIRECTDRAWSURFACE4 lpbltr_ClanRank_Title;
int Matbltr_ClanRank_KindBar;
LPDIRECTDRAWSURFACE4 Matbltr_ClanRank_ListLine;
RECT SodButtonRect[3] = {
{111,393,111+68,393+23},
{189,393,189+68,393+23},
{267,393,267+68,393+23},
};
int MatSod2Box[10]; //๋ฐ์ค Mat
/*----------------------------------------------------------------------------*
* Init
*-----------------------------------------------------------------------------*/
void cSINSOD2::Init()
{
char szBuff[128];
for(int i = 0 ; i < 9 ; i++){
wsprintf(szBuff,"Image\\SinImage\\Help\\box%d.tga",i+1);
MatSod2Box[i] = CreateTextureMaterial( szBuff , 0, 0, 0,0, SMMAT_BLEND_ALPHA );
}
MatSod2Box[9] = CreateTextureMaterial( "Image\\SinImage\\Help\\Box_Line.tga" , 0, 0, 0,0, SMMAT_BLEND_ALPHA );
Matbltr_Paper291 = CreateTextureMaterial( "Image\\SinImage\\Help\\bltr_paper291_145.tga" , 0, 0, 0,0, SMMAT_BLEND_ALPHA );
Matbltr_Paper291_Text = CreateTextureMaterial( "Image\\SinImage\\Help\\bltr_paper_txt.tga" , 0, 0, 0,0, SMMAT_BLEND_ALPHA );
Matbltr_Logo = CreateTextureMaterial( "Image\\SinImage\\Help\\bltr.tga" , 0, 0, 0,0, SMMAT_BLEND_ALPHA );
Matbltr_ClanRank_KindBar = CreateTextureMaterial( "Image\\SinImage\\Help\\bltr_list-title.tga" , 0, 0, 0,0, SMMAT_BLEND_ALPHA );
Load();
}
/*----------------------------------------------------------------------------*
* Load
*-----------------------------------------------------------------------------*/
void cSINSOD2::Load()
{
//๋ฒจ๋ผํธ๋ผ ์ด์ํด๋
lpbltr_clanN = LoadDibSurfaceOffscreen( "Image\\SinImage\\Help\\bltr_clanN.bmp" );
lpbltr_clanB = LoadDibSurfaceOffscreen( "Image\\SinImage\\Help\\bltr_clanB.bmp" );
lpbltr_ButtonBox = LoadDibSurfaceOffscreen( "Image\\SinImage\\Help\\bltr_box.bmp" );
lpbltr_Button_Clan = LoadDibSurfaceOffscreen( "Image\\SinImage\\Help\\bltr_bt1.bmp" );
lpbltr_Button_Clan_G = LoadDibSurfaceOffscreen( "Image\\SinImage\\Help\\bltr_bt1_.bmp" );
lpbltr_Button_Prize = LoadDibSurfaceOffscreen( "Image\\SinImage\\Help\\bltr_bt2.bmp" );
lpbltr_Button_Prize_G = LoadDibSurfaceOffscreen( "Image\\SinImage\\Help\\bltr_bt2_.bmp" );
lpbltr_Button_OK = LoadDibSurfaceOffscreen( "Image\\SinImage\\Help\\bltr_bt3.bmp" );
lpbltr_Button_OK_G = LoadDibSurfaceOffscreen( "Image\\SinImage\\Help\\bltr_bt3_.bmp" );
lpbltr_ClanRank_Title = LoadDibSurfaceOffscreen( "Image\\SinImage\\Help\\bltr_list-title.bmp" );
Matbltr_ClanRank_ListLine = LoadDibSurfaceOffscreen( "Image\\SinImage\\Help\\bltr_list-line.bmp" );
}
/*----------------------------------------------------------------------------*
* Release
*-----------------------------------------------------------------------------*/
void cSINSOD2::Release()
{
}
/*----------------------------------------------------------------------------*
* Draw
*-----------------------------------------------------------------------------*/
void cSINSOD2::Draw()
{
int i = 0, j =0 , t = 0;
//๋ฐ์ค๋ฅผ ๊ทธ๋ฆฐ๋ค
if(sinMessageBox_New.Flag){
for(i = 0 ; i < 9 ; i++){
switch(i){
case 0: //์๋จ ์ผ์ชฝ ๊ทํ์ด
dsDrawTexImage( MatSod2Box[i] , sinMessageBox_New.PosiX, sinMessageBox_New.PosiY
, 64, 32 , 255 ); //์ธํฐํ์ด์ค ๋ฉ์ธ
break;
case 1: //์๋จ ์ค๊ฐ
dsDrawTexImage( MatSod2Box[i] , sinMessageBox_New.PosiX+64, sinMessageBox_New.PosiY
, sinMessageBox_New.SizeW-(64*2), 32 , 255 ); //์ธํฐํ์ด์ค ๋ฉ์ธ
break;
case 2: //์๋จ ์ค๋ฅธ์ชฝ
dsDrawTexImage( MatSod2Box[i] , sinMessageBox_New.PosiX+sinMessageBox_New.SizeW-64, sinMessageBox_New.PosiY
, 64, 32 , 255 ); //์ธํฐํ์ด์ค ๋ฉ์ธ
break;
case 3: //์ค๋จ ์ผ์ชฝ
dsDrawTexImage( MatSod2Box[i] , sinMessageBox_New.PosiX-1, sinMessageBox_New.PosiY+32
, 64, sinMessageBox_New.SizeH-(64+32), 255 ); //์ธํฐํ์ด์ค ๋ฉ์ธ
break;
case 4: //์ค๋จ ๊ฐ์ด๋ฐ
dsDrawTexImage( MatSod2Box[i] , sinMessageBox_New.PosiX+64-1, sinMessageBox_New.PosiY+32
, sinMessageBox_New.SizeW-(64*2)+1, sinMessageBox_New.SizeH-(64+32) , 255 ); //์ธํฐํ์ด์ค ๋ฉ์ธ
break;
case 5: //์ค๋จ ์ค๋ฅธ์ชฝ
dsDrawTexImage( MatSod2Box[i] , sinMessageBox_New.PosiX+sinMessageBox_New.SizeW-64, sinMessageBox_New.PosiY+32
, 64, sinMessageBox_New.SizeH-(64+32) , 255 ); //์ธํฐํ์ด์ค ๋ฉ์ธ
break;
case 6: //ํ๋จ ์ผ์ชฝ
dsDrawTexImage( MatSod2Box[i] , sinMessageBox_New.PosiX, sinMessageBox_New.PosiY+sinMessageBox_New.SizeH-64
, 64, 64 , 255 ); //์ธํฐํ์ด์ค ๋ฉ์ธ
break;
case 7: //ํ๋จ ์ค๊ฐ
for(t = 0 ; t < 6; t++){ //๊ท์ฐฎ์์ ์ด์ง๋๋นต ํํซ
dsDrawTexImage( MatSod2Box[i] , sinMessageBox_New.PosiX+64+(t*(32)), sinMessageBox_New.PosiY+sinMessageBox_New.SizeH-64
, 32, 64 , 255 ); //์ธํฐํ์ด์ค ๋ฉ์ธ
// dsDrawTexImage( MatSod2Box[i] , sinMessageBox_New.PosiX+64, sinMessageBox_New.PosiY+sinMessageBox_New.SizeH-64
// , sinMessageBox_New.SizeW-(64*2), 64 , 255 ); //์ธํฐํ์ด์ค ๋ฉ์ธ
}
break;
case 8: //ํ๋จ ์ค๋ฅธ์ชฝ
dsDrawTexImage( MatSod2Box[i] , sinMessageBox_New.PosiX+sinMessageBox_New.SizeW-64, sinMessageBox_New.PosiY+sinMessageBox_New.SizeH-64
, 64, 64 , 255 ); //์ธํฐํ์ด์ค ๋ฉ์ธ
break;
}
}
//๋ผ์ธ
dsDrawTexImage( MatSod2Box[9] , sinMessageBox_New.PosiX+7, sinMessageBox_New.PosiY+50
, sinMessageBox_New.SizeW-(7*2), 16 , 255 ); //์ธํฐํ์ด์ค ๋ฉ์ธ
}
if(BoxIndex == 1 ){ //์ฒซํ์ด์ง์ ์ผ๋ฐ์ ์
//๋ฒจ๋ผํธ๋ผ ๋ก๊ณ
dsDrawTexImage( Matbltr_Logo , 152, 97 , 128, 64 , 255 );
//๋ฒจ๋ผํธ๋ผ ์ด์ํด๋
DrawSprite(97,156 , lpbltr_clanN,0,0,116,12);
//๋ฒจ๋ผํธ๋ผ ์ด์ํด๋ ํ์ดํผ
dsDrawTexImage( Matbltr_Paper291 , 78, 241 , 291, 145 , 255 );
switch(UserType){
case 1: //์ผ๋ฐ์ ์
//์ด์ํด๋ ํด๋๋งํฌ ๋ฐ์ค
DrawSprite(97,284 , lpbltr_clanB,0,0,49,49);
DrawSprite(105,292 , ClanMark_32,0,0,32,32);
break;
case 2:
dsDrawTexImage( Matbltr_Paper291_Text , 95, 255 , 256, 128 , 255 );
break;
case 3:
dsDrawTexImage( Matbltr_Paper291_Text , 95, 255 , 256, 128 , 255 );
//์๊ธ์ฐพ๊ธฐ ๋ฐ์ค
DrawSprite(189,393 , lpbltr_ButtonBox,0,0,68,23);
//์๊ธ์ฐพ๊ธฐ (๊ทธ๋ ์ด
DrawSprite(199,399 , lpbltr_Button_Prize_G,0,0,47,12);
break;
case 4:
//์ด์ํด๋ ํด๋๋งํฌ ๋ฐ์ค
DrawSprite(97,284 , lpbltr_clanB,0,0,49,49);
DrawSprite(105,292 , ClanMark_32,0,0,32,32);
//์๊ธ์ฐพ๊ธฐ ๋ฐ์ค
DrawSprite(189,393 , lpbltr_ButtonBox,0,0,68,23);
//์๊ธ์ฐพ๊ธฐ (๊ทธ๋ ์ด
DrawSprite(199,399 , lpbltr_Button_Prize_G,0,0,47,12);
break;
case 6:
//์๊ธ์ฐพ๊ธฐ ๋ฐ์ค
DrawSprite(189,393 , lpbltr_ButtonBox,0,0,68,23);
//์๊ธ์ฐพ๊ธฐ (๊ทธ๋ ์ด
DrawSprite(199,399 , lpbltr_Button_Prize_G,0,0,47,12);
break;
}
/////////////////////////////๋ฒํผ
//ํด๋์์ ๋ฐ์ค
DrawSprite(111,393 , lpbltr_ButtonBox,0,0,68,23);
//ํ์ธ ๋ฐ์ค
DrawSprite(267,393 , lpbltr_ButtonBox,0,0,68,23);
//ํด๋์์ ๋ฒํผ (๊ทธ๋ ์ด)
DrawSprite(121,399 , lpbltr_Button_Clan_G,0,0,47,12);
//ํ์ธ ๋ฒํผ (๊ทธ๋ ์ด)
DrawSprite(277,399 , lpbltr_Button_OK_G,0,0,47,12);
}
vector<string>::size_type k = 0;
if(BoxIndex == 2 ){ //ํด๋์์ ํ์ด์ง
//ํด๋์์ ํ์ดํ
DrawSprite(152,97 , lpbltr_ClanRank_Title,0,0,143,19);
//No . ํด๋ . ํฌ์ธํธ . ๊ธฐ๋ก์ผ์ Bar
dsDrawTexImage( Matbltr_ClanRank_KindBar , 78, 147 , 512, 32 , 255 );
//List Line
for(j = 0; j < 10 ; j++){
DrawSprite(78,173+(j*20) , Matbltr_ClanRank_ListLine,0,0,287,20);
}
//ํ์ธ ๋ฐ์ค
DrawSprite(189,393 , lpbltr_ButtonBox,0,0,68,23);
//ํ์ธ (๊ทธ๋ ์ด)
DrawSprite(199,399 , lpbltr_Button_OK_G,0,0,47,12);
for(int t = 0; t < 10 ; t++){
if(ClanMarkIndex[t] >= 0){
DrawSprite(103,174+(t*20) , ClanMark[t],0,0,16,16);
}
}
}
if(sinMessageBox_New.ButtonIndex){
if(BoxIndex == 1){
switch(sinMessageBox_New.ButtonIndex){
case 1:
//ํด๋์์ ๋ฒํผ (ํ์ฑ)
DrawSprite(121,399 , lpbltr_Button_Clan,0,0,47,12);
break;
case 2:
//์๊ธ์ฐพ๊ธฐ (ํ์ฑ)
DrawSprite(199,399 , lpbltr_Button_Prize,0,0,47,12);
break;
case 3:
//ํ์ธ ๋ฒํผ (ํ์ฑ)
DrawSprite(277,399 , lpbltr_Button_OK,0,0,47,12);
break;
}
}
if(BoxIndex == 2){
if(sinMessageBox_New.ButtonIndex == 2){
//์๊ธ์ฐพ๊ธฐ (ํ์ฑ)
DrawSprite(199,399 , lpbltr_Button_OK,0,0,47,12);
}
}
}
}
/*----------------------------------------------------------------------------*
* DrawText
*-----------------------------------------------------------------------------*/
void cSINSOD2::DrawText()
{
int Posi[] = {103,120,230,296};
int i = 0, k=0;
vector<string>::size_type j = 0;
HDC hdc;
lpDDSBack->GetDC( &hdc );
SelectObject( hdc, sinFont);
SetBkMode( hdc, TRANSPARENT );
SetTextColor( hdc, RGB(255,244,201) );
char szTempBuff[128];
//๋ฌธ๊ตฌ
if(BoxIndex == 1){
switch(UserType){
case 1: //์ผ๋ฐ์ ์
for( i = 0 ; i < 3; i++){
if(i ==2){
wsprintf(szTempBuff,SodMessage_Etc[i],Tax,"%");
dsTextLineOut(hdc,97,182+(14*i), szTempBuff, lstrlen(szTempBuff));
}
else{
dsTextLineOut(hdc,97,182+(14*i), SodMessage_Etc[i], lstrlen(SodMessage_Etc[i]));
}
}
//ํด๋ ๋ฉ์ธ์ง๊ฐ ๋ค์ด๊ฐ๋ค
while(j != sinClanMessage.size()){
dsTextLineOut(hdc,154,281+(j*20),sinClanMessage[j].c_str() , lstrlen(sinClanMessage[j].c_str()));
j++;
}
//ํด๋ ์ฅ
wsprintf(szTempBuff,"%s : %s",sinClanMaster7,szClanMaster);
dsTextLineOut(hdc,230,355, szTempBuff, lstrlen(szTempBuff));
//์ด์ํด๋
SelectObject( hdc, sinBoldFont);
SetTextColor( hdc, RGB(255,244,201) );
dsTextLineOut(hdc,185,255, szClanName, lstrlen(szClanName));
break;
case 2: //ํด๋ ์ ์
for( i = 0 ; i < 2; i++){
dsTextLineOut(hdc,97,182+(14*i), SodMessage_Clan[i], lstrlen(SodMessage_Clan[i]));
}
memset(&szTempBuff,0,sizeof(szTempBuff));
NumLineComa(TotalEMoney,szTempBuff);
dsTextLineOut(hdc,170,283, szTempBuff, lstrlen(szTempBuff));
wsprintf(szTempBuff,"%d%s",Tax,"%");
dsTextLineOut(hdc,170,301, szTempBuff, lstrlen(szTempBuff));
memset(&szTempBuff,0,sizeof(szTempBuff));
NumLineComa(TotalMoney,szTempBuff);
dsTextLineOut(hdc,170,320, szTempBuff, lstrlen(szTempBuff));
break;
case 3: //ํด๋ ๋ง์คํฐ
for( i = 0 ; i < 3; i++){
dsTextLineOut(hdc,97,182+(14*i), SodMessage_Master[i], lstrlen(SodMessage_Master[i]));
}
memset(&szTempBuff,0,sizeof(szTempBuff));
NumLineComa(TotalEMoney,szTempBuff);
dsTextLineOut(hdc,170,283, szTempBuff, lstrlen(szTempBuff));
wsprintf(szTempBuff,"%d%s",Tax,"%");
dsTextLineOut(hdc,170,301, szTempBuff, lstrlen(szTempBuff));
memset(&szTempBuff,0,sizeof(szTempBuff));
NumLineComa(TotalMoney,szTempBuff);
dsTextLineOut(hdc,170,320, szTempBuff, lstrlen(szTempBuff));
break;
case 4: //์ฐพ์๋์ด ์๋ ํด๋
for( i = 0 ; i < 3; i++){
if(i ==2){
wsprintf(szTempBuff,SodMessage_Etc[i],Tax,"%");
dsTextLineOut(hdc,97,182+(14*i), szTempBuff, lstrlen(szTempBuff));
}
else{
dsTextLineOut(hdc,97,182+(14*i), SodMessage_Etc[i], lstrlen(SodMessage_Etc[i]));
}
}
//ํด๋ ๋ฉ์ธ์ง๊ฐ ๋ค์ด๊ฐ๋ค
while(j != sinClanMessage.size()){
dsTextLineOut(hdc,154,281+(j*20),sinClanMessage[j].c_str() , lstrlen(sinClanMessage[j].c_str()));
j++;
}
//ํด๋ ์ฅ
wsprintf(szTempBuff,"%s : %s",sinClanMaster7,szClanMaster);
dsTextLineOut(hdc,230,355, szTempBuff, lstrlen(szTempBuff));
//์ด์ํด๋
SelectObject( hdc, sinBoldFont);
SetTextColor( hdc, RGB(255,244,201) );
dsTextLineOut(hdc,185,255, szClanName, lstrlen(szClanName));
break;
case 6:
for( i = 0 ; i < 3; i++){
if(i ==2){
wsprintf(szTempBuff,SodMessage_Etc[i],Tax,"%");
dsTextLineOut(hdc,97,182+(14*i), szTempBuff, lstrlen(szTempBuff));
}
else{
dsTextLineOut(hdc,97,182+(14*i), SodMessage_Etc[i], lstrlen(SodMessage_Etc[i]));
}
}
SelectObject( hdc, sinBoldFont);
SetTextColor( hdc, RGB(255,244,201) );
dsTextLineOut(hdc,185,255, cldata.name, lstrlen(cldata.name));
SelectObject( hdc, sinFont);
wsprintf(szTempBuff,"%s : ",sinPrize7);
dsTextLineOut(hdc,110,283, szTempBuff, lstrlen(szTempBuff));
memset(&szTempBuff,0,sizeof(szTempBuff));
NumLineComa(ClanMoney,szTempBuff);
dsTextLineOut(hdc,152,283, szTempBuff, lstrlen(szTempBuff));
dsTextLineOut(hdc,110,301, OtherClanMaster[0], lstrlen(OtherClanMaster[0]));
dsTextLineOut(hdc,110,320, OtherClanMaster[1], lstrlen(OtherClanMaster[1]));
break;
}
//์ด์ํด๋
SelectObject( hdc, sinBoldFont);
SetTextColor( hdc, RGB(255,205,4) );
dsTextLineOut(hdc,223,157, szClanName, lstrlen(szClanName));
}
char szTempNum[16];
int TempNum;
char szTempBuff2[128];
memset(&szTempBuff2,0,sizeof(szTempBuff2));
if(BoxIndex == 2){
while(j != sinClanRank.size()){
if((j%4)!=0){
SelectObject( hdc, sinBoldFont);
SetTextColor( hdc, RGB(255,205,4) ); //์๋ฒ
wsprintf(szTempNum,"%d",k+1);
if(k+1 == 10){
dsTextLineOut(hdc,82,177+(k*20),szTempNum , lstrlen(szTempNum));
}
else{
dsTextLineOut(hdc,86,177+(k*20),szTempNum , lstrlen(szTempNum));
}
SelectObject( hdc, sinFont);
SetTextColor( hdc, RGB(255,255,255) );
if((j%4)== 2){
memset(&szTempBuff2,0,sizeof(szTempBuff2));
TempNum = atoi(sinClanRank[j].c_str());
NumLineComa(TempNum,szTempBuff2);
dsTextLineOut(hdc,5+Posi[j%4],177+(k*20),szTempBuff2 , lstrlen(szTempBuff2));
}
else{
dsTextLineOut(hdc,5+Posi[j%4],177+(k*20),sinClanRank[j].c_str() , lstrlen(sinClanRank[j].c_str()));
}
}
j++;
if((j%4)==0){
k++;
}
}
}
lpDDSBack->ReleaseDC( hdc );
}
/*----------------------------------------------------------------------------*
* Main
*-----------------------------------------------------------------------------*/
DWORD ClanRankFlagTime = 0;
void cSINSOD2::Main()
{
if(sinMessageBox_New.Flag){
sinMessageBoxShowFlag = 1; //๋ฉ์ธ์ง ๋ฐ์ค๋๋ฌธ์ ์ผ์ผํ๋ค
sinMessageBox_New.ButtonIndex = 0;
for(int i = 0 ; i < 3 ; i++){
if ( sinMessageBox_New.ButtonRect[i].left< pCursorPos.x && sinMessageBox_New.ButtonRect[i].right > pCursorPos.x &&
sinMessageBox_New.ButtonRect[i].top < pCursorPos.y && sinMessageBox_New.ButtonRect[i].bottom > pCursorPos.y ){
if(ClanMasterMessageBoxFlag)break;
if(BoxIndex == 1){
if((UserType == 3 || UserType == 4 || UserType == 6)){
sinMessageBox_New.ButtonIndex = i+1;
}
else{
if(i ==1)continue;
sinMessageBox_New.ButtonIndex = i+1;
}
}
if(BoxIndex == 2){
if(i != 1)continue;
sinMessageBox_New.ButtonIndex = i+1;
}
}
}
if(BoxIndex == 1){
if(!ClanMark_32){
ClanMark_32Time++;
if(ClanMark_32Time >= 70*3){
ClanMark_32Time = 0;
ClanMark_32Index = ReadClanInfo_32X32(ClanImageNum);
ClanMark_32 = ClanInfo[ClanMark_32Index].hClanMark32;
}
}
if(ClanRankFlag){
ClanRankFlagTime++;
if(ClanRankFlagTime >= 70*2){
ClanRankFlag = 0;
}
}
}
if(BoxIndex == 2){
for(int t = 0; t < 10 ; t++){
if(!ClanMark[t] ){
ClanMarkLoadTime[t]++;
if(ClanMarkLoadTime[t] >= 70*3){
ClanMarkLoadTime[t] = 0;
ClanMarkIndex[t] = ReadClanInfo( ClanMarkNum[t]);
if(ClanInfo[ClanMarkIndex[t]].hClanMark){
ClanMark[t] = ClanInfo[ClanMarkIndex[t]].hClanMark;
}
}
}
}
}
}
}
/*----------------------------------------------------------------------------*
* Close
*-----------------------------------------------------------------------------*/
void cSINSOD2::Close()
{
}
/*----------------------------------------------------------------------------*
* LbuttonDown
*-----------------------------------------------------------------------------*/
void cSINSOD2::LButtonDown(int x , int y)
{
if(sinMessageBox_New.Flag){
if(sinMessageBox_New.ButtonIndex){
if(BoxIndex == 1){
switch(sinMessageBox_New.ButtonIndex){
case 1:
//ํด๋์์ ๋ฒํผ (ํ์ฑ)
if(!ClanRankFlag){
sod2INFOindex(UserAccount, sinChar->szName,szConnServerName,3);
ClanRankFlag = 1;
}
//sod2INFOindex("inouess", "์์ฒ2002","์์ฐ",3);
//RecvClanRank(szTemp);
break;
case 2:
if(UserType != 6 ){
SendClanMoneyToServer(0,0);
}
if(UserType == 6){
if(ClanMoney){
cMessageBox.ShowMessage2(MESSAGE_SOD2_GET_MONEY);
ClanMasterMessageBoxFlag = 1;
}
else{
cMessageBox.ShowMessage(MESSAGE_DONT_HAVE_CLANMONEY);
}
}
break;
case 3:
//ํ์ธ ๋ฒํผ (ํ์ฑ)
CloseSod2MessageBox();
break;
}
}
if(BoxIndex == 2){
if(sinMessageBox_New.ButtonIndex == 2){
//ํ์ธ ๋ฒํผ (ํ์ฑ)
CloseSod2MessageBox();
}
}
}
}
}
/*----------------------------------------------------------------------------*
* LbuttonUp
*-----------------------------------------------------------------------------*/
void cSINSOD2::LButtonUp(int x , int y)
{
}
/*----------------------------------------------------------------------------*
* RbuttonDown
*-----------------------------------------------------------------------------*/
void cSINSOD2::RButtonDown(int x , int y)
{
}
/*----------------------------------------------------------------------------*
* RbuttonUp
*-----------------------------------------------------------------------------*/
void cSINSOD2::RButtonUp(int x, int y)
{
}
/*----------------------------------------------------------------------------*
* KeyDown
*-----------------------------------------------------------------------------*/
void cSINSOD2::KeyDown()
{
}
/*----------------------------------------------------------------------------*
* Sod2๋ฐ์ค๋ฅผ ๋ซ๋๋ค
*-----------------------------------------------------------------------------*/
void cSINSOD2::CloseSod2MessageBox()
{
memset(&sinMessageBox_New,0,sizeof(sinMESSAGEBOX_NEW));
BoxIndex = 0;
UserType = 0;
sinMessageBoxShowFlag = 0;
ClanRankFlag = 0;
}
/*----------------------------------------------------------------------------*
* Sod2๋ฐ์ค๋ฅผ ๋ณด์ฌ์ค๋ค
*-----------------------------------------------------------------------------*/
void cSINSOD2::ShowSod2MessageBox()
{
//์น DB์ ์ ์ํด์ ๋ฐ์ดํ๋ฅผ ๊ฐ์ ธ์จ๋ค
//sod2INFOindex("inouess", "์์ฒ2002","์์ฐ", 1);
sod2INFOindex(UserAccount, sinChar->szName,szConnServerName,1);
}
//์๋ก์ด ๋ฉ์ธ์ง ๋ฐ์ค๋ฅผ ๋์ด๋ค
int ShowSinMessageBox_New(int PosiX , int PosiY , int SizeW , int SizeH , RECT *rect ,int ButtonNum)
{
if(sinMessageBox_New.Flag)return FALSE; //๋ฉ์ธ์ง ๋ฐ์ค๋ฅผ ๋ซ๊ณ ์์ผํ๋ค ์๊ทธ๋ผ ์ฆ~
sinMessageBox_New.ButtonRect[0] = rect[0]; //3๊ฐ๊น์ง๋ง๋๋ค
sinMessageBox_New.ButtonRect[1] = rect[1];
sinMessageBox_New.ButtonRect[2] = rect[2];
sinMessageBox_New.PosiX = PosiX;
sinMessageBox_New.PosiY = PosiY;
sinMessageBox_New.SizeW = SizeW;
sinMessageBox_New.SizeH = SizeH;
sinMessageBox_New.ButtonNum = ButtonNum;
sinMessageBox_New.Flag = 1;
sinMessageBoxShowFlag = 1;
return TRUE;
}
/*----------------------------------------------------------------------------*
* Web Data ํด๋ผ์ด์ธํธ๋ก ํ์ฑ
*-----------------------------------------------------------------------------*/
void cSINSOD2::RecvWebDaTa() //ํ์ฌ๋ ํ
์คํธ๋ก ์ด๋ค
{
}
void cSINSOD2::RecvClanRank(char *szBuff)
{
//115001132 -์๋ง๊ฒ๋- 1329660 2004-05-07
//string Test ="1 ํธ๋ํ๋ฆฐ์คํด๋ 10010020 2004/05/05 2 ์ ๋ฐ๋ํด๋ 553340 2004/2332/1 3 ํญ๊ทํด๋ 12131001 2003/05/23";
//string Test = "Code=2 CIMG=121000196 CName=BS-ClaN_์์ฐ CPoint=591260 CRegistDay=2004/05/04 CIMG=103001219 CName=๋ณ๋์จ๋ฌ CPoint=546943 CRegistDay=2004/05/04 CIMG=104000979 CName=[NEO]์ค๋ฉ๊ฐ CPoint=479030 CRegistDay=2004/05/05 CIMG=112000075 CName=๋๊นจ๋น CPoint=454562 CRegistDay=2004/05/04 CIMG=115001132 CName=-์๋ง๊ฒ๋- CPoint=451679 CRegistDay=2004/05/04 CIMG=102001120 CName=[ํฌ์ง์ฌ๋] CPoint=438589 CRegistDay=2004/05/05 CIMG=109000660 CName=GladiaTor CPoint=364726 CRegistDay=2004/05/04 CIMG=118000957 CName=pUrplEviShop CPoint=357253 CRegistDay=2004/05/04 CIMG=111001179 CName=์ฝ๊ธํธ๋ฌ๊ฐ์กฑ CPoint=302324 CRegistDay=2004/05/04";
//sinClanRank = Split_ClanRankDaTa(Test);
}
// Space๋ฅผ ํค๊ฐ์ผ๋ก ์คํธ๋ง์ ๋ถ๋ฆฌํ๋ค
vector<string> cSINSOD2::Split_ClanRankDaTa(const string& s)
{
vector<string> ret;
typedef string::size_type string_size;
string_size i = 0;
while(i != s.size()){
while(i != s.size()){
if(s[i] & 0x80)break; //ํ๊ธ์ด๋ฉด ๊ฑด๋๋ฐ์
if(isspace(s[i])){
++i;
}
else break;
}
string_size j =i;
while(j != s.size()){
if((j-i) > 200 ){
i = s.size();
j = i;
break;
}
if(s[j] & 0x80){ //ํ๊ธ์ด๋ฉด ์ธ๋ฑ์ค 2์นธ์์ง๋ ๋ค์์ฒดํฌ (0x80์ ์ด์ง์๋กํ๋ฉด 128 )
j +=2; // 0000 0000 ์ค์ ๋ท๋ถ๋ถ์ ๋ค์ฑ์ฐ๊ณ ์์ผ๋ก ๋์ด๊ฐ๊ฒ๋๋ฉด 2Byte๋ฅผ ์ฌ์ฉํ๋ ํ๊ธ์ด๋๋ป์
continue;
}
if(!isspace(s[j])){
++j;
}
else break;
}
if(i != j ){
ret.push_back(s.substr(i,j-i));
i = j;
}
}
//Code๋ณ๋ก ๋ค์ ํ์ฑํ๋ค
vector<string> ret2;
string_size k = 0;
string_size e = 0;
string STempNum;
string CodeTemp;
int TempNumCnt = 0;
//์๊ธฐ์ ์ด๊ธฐํ
for(int p = 0; p < 10 ; p++){
ClanMarkNum[p] = -1;
}
i = 0; //์๋ถ๋ถ์๋ CODE๊ฐ ์๋ค
while(i < ret.size()){
while(k != ret[i].size()){
if(ret[i][k] == '='){
CodeTemp.clear();
CodeTemp = ret[i].substr(0,k);
if( i ==0 && CodeTemp == "Code"){
STempNum.clear(); //์ด๊ฑฐ์ํด์ฃผ๊ณ atoiํ๋ค๊ฐ ๋ป๋ ๋์๋ค ์ด์ฐ๋ ๊น๋ค๋ก์ด string์ธ์ง
STempNum = ret[i].substr(k+1,ret[i].size()-(k+1));
if(atoi(STempNum.c_str()) == 2){
ret2.clear();
return ret2;
}
else break;
}
ret2.push_back(ret[i].substr(k+1,ret[i].size()-(k+1)));
if(CodeTemp == "CIMG"){
STempNum.clear(); //์ด๊ฑฐ์ํด์ฃผ๊ณ atoiํ๋ค๊ฐ ๋ป๋ ๋์๋ค ์ด์ฐ๋ ๊น๋ค๋ก์ด string์ธ์ง
STempNum = ret[i].substr(k+1,ret[i].size()-(k+1));
ClanMarkNum[TempNumCnt] = atoi(STempNum.c_str());
ClanMarkIndex[TempNumCnt] = ReadClanInfo( ClanMarkNum[TempNumCnt] );
TempNumCnt++;
}
k = 0;
break;
}
k++;
}
i++;
}
//ํด๋๋งํฌ๋ฅผ ๋ก๋ํ๋ค
for(int t = 0 ;t < TempNumCnt ; t++){
if(ClanMarkIndex[t] >= 0){
if(ClanInfo[ClanMarkIndex[t]].hClanMark){ //TempNumCnt์ด ํ๊ฐ๋ผ๋ ์์ด์ผ ๋ก๋ํ ์ด๋ฏธ์ง๊ฐ์๋๊ฑฐ๋ค
ClanMark[t] = ClanInfo[ClanMarkIndex[t]].hClanMark;
}
}
}
return ret2;
}
// ๋ถํ ๋ ์คํธ๋ง์ ๊ธธ์ด๋ฅผ ๊ธฐ์ค์ผ๋ก ๋ถํ ํ๋ค
vector<string> cSINSOD2::Split_ClanMessage(const string& s , const int Len[])
{
vector<string> ret;
typedef string::size_type string_size;
string_size i = 0;
string_size j = 0;
int LenCnt = 0;
while(i < s.size()){
if(s[i] & 0x80)i += 2; //ํ๊ธ
else i++;
if( (int)i-(int)j >= Len[LenCnt]){
if(Len[LenCnt+1] == 0){
ret.push_back(s.substr(j,i-j));
break;
}
ret.push_back(s.substr(j,i-j));
j = i;
LenCnt++;
}
if(s[i] == '|'){
ret.push_back(s.substr(j,i-j));
break;
}
}
/*
int LenCnt = 0;
vector<string> ret;
typedef string::size_type string_size;
string_size i = 0;
string_size j = 0;
string_size k = 0;
while(i < s.size()){
if(s[i] & 0x80){
i +=2;
if(i == s.size()){
ret.push_back(s.substr(j,i-j));
break;
}
continue;
}
else{
if( (int)i-(int)j >= Len[LenCnt]){
if(isspace(s[i])){
if(Len[LenCnt+1] == 0){
i = s.size(); //์งํฌ๋ฆฌ ๊ธ์จ๋ ๋ค์ฐ์ด์ค๋ค
ret.push_back(s.substr(j,i-j));
break;
}
ret.push_back(s.substr(j,i-j));
++i;
j = i;
LenCnt++;
}
}
++i;
if(i == s.size()){
ret.push_back(s.substr(j,i-j));
break;
}
}
}
*/
return ret;
}
// ์น DB์์ ๋ฐ์ ๋ฐ์ดํ๋ฅผ ๊ตฌ๋ถํ๋ค
vector<string> cSINSOD2::Split_Sod2DaTa(const string& s)
{
string Temp33;
vector<string> ret;
typedef string::size_type string_size;
string_size i = 0;
while(i < s.size()){
while(i < s.size()){
if(s[i] == '|'){
++i;
}
else break;
}
string_size j = i;
while(j < s.size()){
if((j - i) > 200){
i = s.size(); //while๋ฃจํ๋ฅผ ๋๋ธ๋ค
j = i;
break;
}
if(s[j] != '|'){
++j;
}
else break;
}
if(i != j ){
Temp33 = s.substr(i,j-i);
ret.push_back(s.substr(i,j-i));
i = j;
}
}
//Code๋ณ๋ก ๋ค์ ํ์ฑํ๋ค
string Temp;
string Temp2;
string_size k = 0;
string_size e = 0;
int NumTemp = 0;
int TempArray[] = {28,22,26,0};
i = 0;
while(i < ret.size()){
while(k < ret[i].size()){
if(ret[i][k] == '='){
Temp.clear();
Temp = ret[i].substr(0,k);
Temp2.clear();
Temp2 = ret[i].substr(k+1,ret[i].size()-(k+1));
/*
if(k+1 == ret[i].size()){
if(i+1 != ret.size()){
if(ret[i+1][0] != 'C'){ //๋๋๋นต -_- ๋ฐ์๋ค๋ณด๋ ํ ์์๋ค
Temp2.clear();
Temp2 = ret[i+1].c_str();
}
}
}
*/
if(Temp == "Code"){
NumTemp = atoi(Temp2.c_str());
switch(NumTemp){
case 0:
case 5:
case 6:
UserType = 1;
break;
case 1:
UserType = 3;
break;
case 2:
case 3:
UserType = 2;
break;
case 4:
UserType = 4;
break;
}
}
if(Temp == "CName"){
lstrcpy(szClanName,Temp2.c_str());
}
if(Temp == "CNote"){
//Temp2 ="ํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธํ๊ธ";
Temp2.push_back('|');
sinClanMessage = Split_ClanMessage(Temp2 , TempArray);
}
if(Temp == "CZang"){
lstrcpy(szClanMaster,Temp2.c_str());
}
if(Temp == "CIMG"){
ClanImageNum = atoi(Temp2.c_str());
ClanMark_32Index = ReadClanInfo_32X32(ClanImageNum);
ClanMark_32 = ClanInfo[ClanMark_32Index].hClanMark32;
}
if(Temp == "TotalEMoney"){
TotalEMoney = atoi(Temp2.c_str());
}
if(Temp == "CTax"){
Tax = atoi(Temp2.c_str());
}
if(Temp == "TotalMoney"){
TotalMoney = atoi(Temp2.c_str());
}
if(Temp == "CClanMoney"){
ClanMoney = atoi(Temp2.c_str());
}
k = 0;
break;
}
k++;
}
i++;
}
return ret;
}
//์น DB์์ ๋ฉ์ธ์ง๋ฅผ ๋ฐ๋๋ค
int cSINSOD2::RecvWebData(int Index , const string& s)
{
vector<string> Temp_V;
if(bip_port_error)return FALSE;
if(Index){
//Init();
if(Index == 1){
Temp_V = Split_Sod2DaTa(s);
if(Temp_V.size() <= 0)return FALSE;
BoxIndex = 1;
ShowSinMessageBox_New(62,78,381-62,426-78 ,SodButtonRect );
//UserType = 2; //1 ์ผ๋ฐ์ ์ , 2 ํด๋์ ,3 ํด๋๋ง์คํฐ ,4 ๋์ฐพ์๊ฑฐ ์๋ ํด๋๋ง์คํฐ
//if(UserType == 4 || UserType == 3){
// SendClanMoneyToServer(0,0);
//}
}
else if(Index == 3){
//ClanRankFlag = 1;
sinClanRank = Split_ClanRankDaTa(s);
if(sinClanRank.size() <= 0)return FALSE;
BoxIndex = 2;
//ShowSinMessageBox_New(62,78,381-62,426-78 ,SodButtonRect );
}
//์ฌ๊ธฐ์ Clan ๋ง์คํฐ์ธ์ง Clan ์์ธ์ง ์ผ๋ฐ ์ ์ ์ธ์ง๋ฅผ ๊ฐ๋ ค์ ๋ฉ๋ด๋ฅผ ๋ณด์ฌ์ค๋ค
}
return TRUE;
}
//ํด๋์นฉ์ด ๊ธ์ก์ ์ฐพ๋๋ค
int sinRecvClanMoney(int RemainMoney , int GetMoney)
{
//๊ณต์ฑ์ ์ธ๊ธ์ด์ก์ ์ธํ
ํ๋ค.
if(haSiegeMenuFlag){
if(RemainMoney){
cSinSiege.TotalTax = RemainMoney;
cSinSiege.ExpectedTotalTax = RemainMoney; //ํด์ธ์ธ๊ธ
}
if(GetMoney){
CheckCharForm();//์ธ์ฆ
sinPlusMoney2(GetMoney);
sinPlaySound(SIN_SOUND_COIN);
ReformCharForm();//์ฌ์ธ์ฆ
SendSaveMoney(); //๊ธ์ก ์กฐ์์ ๋ชปํ๊ฒํ๊ธฐ์ํด ํธ์ถํ๋ค
cSinSiege.TotalTax = RemainMoney;
cSinSiege.ExpectedTotalTax = RemainMoney; //ํด์ธ์ธ๊ธ
}
return TRUE;
}
if(cSinSod2.UserType == 4 || cSinSod2.UserType ==3){
cSinSod2.ClanMoney = RemainMoney;
if(RemainMoney){
cMessageBox.ShowMessage2(MESSAGE_SOD2_GET_MONEY);
cSinSod2.ClanMasterMessageBoxFlag = 1;
cSinSod2.UserType = 6;
}
else{
if(cSinSod2.UserType == 4){
cSinSod2.UserType = 1; //์ฐพ์ ๋์๋ ํด๋์ฅ์ ์ผ๋ฐํ์์ผ๋ก ๊ฐ๋ฑ -0-
}
else
cMessageBox.ShowMessage(MESSAGE_DONT_HAVE_CLANMONEY);
}
}
if(GetMoney){
CheckCharForm();//์ธ์ฆ
sinPlusMoney2(GetMoney);
sinPlaySound(SIN_SOUND_COIN);
ReformCharForm();//์ฌ์ธ์ฆ
SendSaveMoney(); //๊ธ์ก ์กฐ์์ ๋ชปํ๊ฒํ๊ธฐ์ํด ํธ์ถํ๋ค
cSinSod2.ClanMoney = RemainMoney;
}
return TRUE;
}
/*----------------------------------------------------------------------------*
*
* ( ๊ณต ์ฑ ์ )
*
*-----------------------------------------------------------------------------*/
int sinShowSeigeMessageBox()
{
//SeigeINFOindex(UserAccount, sinChar->szName,szConnServerName,1);
return TRUE;
}
int RecvSeigeWebData(int Index , char *string)
{
//char szTemp[65000];
//lstrcpy(szTemp,string);
return TRUE;
}
/*----------------------------------------------------------------------------*
* ํ
์คํธ <ha>๊ณต์ฑ์ ๋ฉ๋ด๋ฐ์ค
*-----------------------------------------------------------------------------*/
//์์๊ฐ์ฒด
cHASIEGE chaSiege;
/*---์ฌ์ฉ๋ผ๋ ๊ฐ์ข
ํ๋๊ทธ----*/
int haSiegeMenuFlag=0; //๊ณต์ฑ์ ๋ฉ๋ดํ๋
int haSiegeMenuKind=0; //๊ณต์ฑ์ ๋ฉ๋ด์ข
๋ฅ
int ScrollButtonFlag=0; //์คํฌ๋กค ์ฌ์ฉ์ ํ์ํ ํ๋
int GraphLineFlag=0;
int haSiegeBoardFlag=0; //๊ณต์ฑ ํด๋ ์ ์์ฐฝ ํ๋
int haSiegeMerFlag=0; //์ฉ๋ณ ์ค์ ํ๋
/*---์ ๋ณด๋ฐ์ค ๊ด๋ จ ์์น์ ๋ณด---*/
POINT ClanSkillBoxSize={0,0}; //ํด๋์คํฌ ์ ๋ณด ๋ฐ์ค ์ฌ์ด์ฆ
POINT ClanSkillBoxPosi={0,0}; //ํด๋์คํฌ ์ ๋ณด ๋ฐ์ค ํฌ์ง์
/*---์์ฑ์ค์ ๊ด๋ จ ์ธ๋ฑ์ค๋ค---*/
int CastleKindIndex = 0; //์ฑ์ ์ข
๋ฅ ๊ด๋ จ ์ธ๋ฑ์ค
int TowerIconIndex = 0; //ํ์ ์ข
๋ฅ
int haSendTowerIndex = 0;
int MenuButtonIndex = 0; //๋ฉ๋ด ๋ฒํผ ๊ด๋ จ ์ธ๋ฑ์ค
/*--์ ์ฅ๋ผ๊ณ ์ธํ
๋ ๋ ์ฌ์ฉ๋ ์์ํจ์๋ค---*/
int HaTestMoney =0; //์์์ธ๊ธ ๊ธ์ก
int HaTaxRate =0;
/*----ํด๋ ๋ณด๋ ์ค์ -----*/
sHACLANDATA sHaClanData[HACLAN_MAX]; //์์ ํด๋ ๊ฐ์
int haAlpha = 0; //๋ณด๋์ ์ํ๊ฐ
int BoardTime = 0;
int haClanSkillTime=0;
int haTotalDamage = 0; //ํ ํ ๋ฐ๋ฏธ์ง๋ฅผ ์ฐ์ด์ค๋ ์ฌ์ฉํ๋ค.
int haPlayTime[3] = {0}; //๋ณด๋ํ์
/*---์ฉ๋ณ ์ค์ ๊ฐ๊ฒฉ----*/
//์์
int haMercenrayMoney[3] = {50000,100000,300000}; //์ฉ๋ณ ๊ฐ๊ฒฉ
int haMercenrayIndex = 0; //์ฉ๋ณ ์ค์ ์ธ๋ฑ์ค
int haTowerMoney =500000;
//ํฌ๋ฆฌ์คํ ์นด์ดํธ๋ฅผ ๋ฐ๋๋ค.
short haCrystalTowerCount[4]; //ํฌ๋ฆฌ์คํ ์นด์ดํธ
char *haC_CastleWinFilePath = "image\\Sinimage\\help\\CastleWin.sin" ;
char *haC_CastleLoseFilePath = "image\\Sinimage\\help\\CastleLose.sin";
char *haC_CastleWin_FilePath = "image\\Sinimage\\help\\CastleWining.sin" ;
char *haC_CastleLose_FilePath = "image\\Sinimage\\help\\CastleLoseing.sin";
/*---๋ณด๋ ํด๋ ์ด๋ฆ์์น-----*/
char *ScoreBoardName[] = {
"Battle Point", //ํ๋ ์ด์ด ์คํฌ ์ ์
"Con Rate", //์์ ์ ํด๋ ์ ์ ๊ธฐ์ฌ๋
"B.P",
"PlayTime", //ํ์
"Hit Rate", //์๊ธฐ ํด๋์ ์ ์
"BLESS CASTLE", //๋ฌธ๊ตฌ
};
//๋ฒํผ ์์น
int SiegeButtonPosi[][4]={
{70 ,70 ,268,302}, //๋ฉ์ธ
{29+70 ,269+70 ,68 ,23}, //์ฌ์ /๋ฐฉ์ด ์ค์
{144+70,269+70 ,48 ,23}, //ํ์ธ
{197+70,269+70 ,48 ,23}, //์ทจ์
{270 ,236+70 ,48 ,23}, //๋์ฐพ๊ธฐ ํ์ธ
{77+70 ,21+70 ,49 ,11}, //ํ์ ์ค์ ๋ฒํผ
{179+70-3,21+70,49 ,11}, //์ฉ๋ณ ์ค์ ๋ฒํผ
};
//๊ณต์ฑ์ ์์ด์ฝ ์์น
int SiegeIconPosi[][4]={
{26+70,83+70 ,16,16}, //์คํฌ๋กค
{36+70,94+70 ,30,30}, //ํ์์์ฑ
{36+70,216+70,30,30}, //ํด๋์คํฌ ์์น
{8+70 ,45+70 ,51,22}, //์ฑํ์
{10+70 ,63+70 ,12,13}, //ํ์ ํ
๋๋ฆฌ
{26+70,59+70,16,16}, //์ค์ ์ธ์จ ์คํฌ๋กค
};
///๋์์ ํ๋ ์ด์ด
int haMatPlayMenu[8]={0};
int haMovieFlag = 0;
int haMovieKind = 0;
char haMovieName[64];
int haPlayerPosi[4][4] = {
{64+68+8,359,32,32},//์์คํ๋ฒํผ
{270 ,363,48,23},//
};
cHASIEGE::cHASIEGE()
{
int i;
for(i=0;i<6;i++){
cSinSiege.TowerTypeDraw[i][1]=0;
}
for(i=0;i<4;i++){
cSinSiege.MercenaryNum[i] = 0;
}
}
cHASIEGE::~cHASIEGE()
{
}
void cHASIEGE::init()
{
}
void cHASIEGE::ImageLoad()
{
lpSiegeTax = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_tax.bmp"); //์ฌ์ ๋ฉ์ธ
lpSiegeDefense = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_menu.bmp"); //๋ฐฉ์ด๋ฉ์ธ
lpCastleButton = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_button.bmp"); //์ฑ๋ฉ์ธ
lpMercenary = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_box.bmp");//์ฉ๋ณ๋ฉ์ธ
lpDefenseButton[0] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_soldier_text.bmp");//๋ฐฉ์ด/์ฉ๋ณ ์ค์
lpDefenseButton[1] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_tower_text.bmp");
lpTax_Ok[0] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_button_ok01_.bmp"); //๋์ฐพ๊ธฐ ํ์ธ๋ฒํผ
//lpTax_Ok[1] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_button_ok01.bmp");
lpSiegeMercenaryIcon[0] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_soldier_ricaM.bmp");
lpSiegeMercenaryIcon[1] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_soldier_ricaY.bmp");
lpSiegeMercenaryIcon[2] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_soldier_bress.bmp");
lpSiegeMercenaryIcon_[0] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_soldier_ricaM_01.bmp");
lpSiegeMercenaryIcon_[1] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_soldier_ricaY_01.bmp");
lpSiegeMercenaryIcon_[2] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_soldier_bress_01.bmp");
lpSiegeDefeseIcon[0] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_ice.bmp");
lpSiegeDefeseIcon[1] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_ele.bmp");
lpSiegeDefeseIcon[2] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_fire.bmp");
lpSiegeDefeseIcon_[0] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_ice01.bmp");
lpSiegeDefeseIcon_[1] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_ele01.bmp");
lpSiegeDefeseIcon_[2] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_fire01.bmp");
lpSiegeClanskillIcon[0] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_hp.bmp");
lpSiegeClanskillIcon[1] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_attack.bmp");
lpSiegeClanskillIcon[2] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_eva.bmp");
lpSiegeTaxButton = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_button_creat.bmp");
lpSiegeDefenseButton = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_tax_button_defense.bmp");
lpSiegeOkButton = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_button_ok.bmp");
lpSiegeCancelButton = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_button_cancel.bmp");
lpCastleIcon[0] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_castle_outa.bmp");
lpCastleIcon[1] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_castle_outb.bmp");
lpCastleIcon[2] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_castle_ina.bmp");
lpCastleIcon[3] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_castle_inb.bmp");
lpCastleIcon[4] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_castle_inc.bmp");
lpCastleIcon[5] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_castle_ind.bmp");
lpTaxScroll[0] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_arrow01.bmp");
lpTaxScroll[1] = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_arrow02.bmp");
lpTaxGraph = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\war_tax_graph.bmp");
}
/*----------------------------------------------------------------------------*
* Release
*-----------------------------------------------------------------------------*/
void cHASIEGE::Release()
{
halpRelease(lpSiegeTaxButton);
halpRelease(lpSiegeDefenseButton);
halpRelease(lpSiegeOkButton);
halpRelease(lpSiegeCancelButton);
halpRelease(lpTaxScroll[0]);
halpRelease(lpTaxScroll[1]);
halpRelease(lpTaxGraph);
for(int i=0;i<6;i++){
halpRelease(lpCastleIcon[i]);
}
for(int i=0;i<3;i++){
halpRelease(lpSiegeDefeseIcon[i]);
halpRelease(lpSiegeClanskillIcon[i]);
halpRelease(haPlayerButton_G[i]);
halpRelease(haPlayerButton[i]);
halpRelease(haPlayerButtonBox[i]);
halpRelease(haPlayerButtonDown[i]);
}
halpRelease(lpTwoerImage);
}
//ํฐํธ x์ขํ
/*----------------------------------------------------------------------------*
* ๋ฉ์ธ
*-----------------------------------------------------------------------------*/
void cHASIEGE::Main()
{
int i;
//==================================================================//
// ์ฑ์ฃผ๊ฐ ๋ฐ๋๋ฉด ํด๋์คํฌ์ ์์ ์ค๋ค.
//==================================================================//
if(haClanSkillTime < 70*60*10){
if(haClanSkillTime > 70*60*7){
cSkill.CancelContinueSkill(CLANSKILL_ATTACK);
cSkill.CancelContinueSkill(CLANSKILL_EVASION);
cSkill.CancelContinueSkill(CLANSKILL_ABSORB);
haClanSkillTime =70*60*10;
}
else{
haClanSkillTime++;
}
}
//==================================================================//
// ๊ณต์ฑ์ ๋ฉ๋ด ์ค์
//==================================================================//
if(haSiegeMenuFlag){
switch(haSiegeMenuKind){
case HASIEGE_TAXRATES: //์ธ์จ ์กฐ์
if(96 < pCursorPos.x &&96+218 > pCursorPos.x && SiegeIconPosi[0][1] < pCursorPos.y && SiegeIconPosi[0][1] +16 > pCursorPos.y ){
GraphLineFlag = 1;
}
else{
GraphLineFlag = 0;
}
//ํ์ธ๋ฒํผ ๊ด๋ จ ํ๋
for(i=1;i<4;i++){
if(SiegeButtonPosi[i+1][0] < pCursorPos.x && SiegeButtonPosi[i+1][0]+SiegeButtonPosi[i+1][2]> pCursorPos.x
&& SiegeButtonPosi[i+1][1]< pCursorPos.y && SiegeButtonPosi[i+1][1]+SiegeButtonPosi[i+1][3] > pCursorPos.y ){
MenuButtonIndex=i+1;
break;
}
//๋ฐฉ์ด์ค์ ๋ฒํผ
else if(SiegeButtonPosi[1][0] < pCursorPos.x && SiegeButtonPosi[1][0]+SiegeButtonPosi[1][2]> pCursorPos.x
&& SiegeButtonPosi[1][1]< pCursorPos.y && SiegeButtonPosi[1][1]+SiegeButtonPosi[1][3] > pCursorPos.y ){
MenuButtonIndex=7;
break;
}
else{
MenuButtonIndex=0;
}
}
break;
case HASIEGE_DEFENSE: //๋ฐฉ์ด ์ค์
//ํ์ธ๋ฒํผ ๊ด๋ จ ์ธ๋ฑ์ค
for(i=1;i<6;i++){
if(SiegeButtonPosi[i+1][0] < pCursorPos.x && SiegeButtonPosi[i+1][0]+SiegeButtonPosi[i+1][2]> pCursorPos.x
&& SiegeButtonPosi[i+1][1]< pCursorPos.y && SiegeButtonPosi[i+1][1]+SiegeButtonPosi[i+1][3] > pCursorPos.y ){
MenuButtonIndex=i+1;
break;
}
//์ฌ์ ์ค์ ๋ฒํผ
else if(SiegeButtonPosi[1][0] < pCursorPos.x && SiegeButtonPosi[1][0]+SiegeButtonPosi[1][2]> pCursorPos.x
&& SiegeButtonPosi[1][1]< pCursorPos.y && SiegeButtonPosi[1][1]+SiegeButtonPosi[1][3]> pCursorPos.y ){
MenuButtonIndex=8;
break;
}
else{
MenuButtonIndex=0;
}
}
//ํ์๋ฒํผ ๊ด๋ จ ์ธ๋ฑ์ค
for(i=0;i<3;i++){
if(SiegeIconPosi[1][0]+i*84 < pCursorPos.x && SiegeIconPosi[1][0]+SiegeIconPosi[1][2]+i*84 > pCursorPos.x &&
SiegeIconPosi[1][1] < pCursorPos.y && SiegeIconPosi[1][1]+SiegeIconPosi[1][3] > pCursorPos.y ){
TowerIconIndex = i+1;
break;
}
else if(SiegeIconPosi[2][0]+i*84 < pCursorPos.x && SiegeIconPosi[2][0]+SiegeIconPosi[2][2]+i*84 > pCursorPos.x &&
SiegeIconPosi[2][1] < pCursorPos.y && SiegeIconPosi[2][1]+SiegeIconPosi[2][3] > pCursorPos.y ){
TowerIconIndex = i+4;
break;
}
else{
TowerIconIndex=0;
}
}
//์ฑ์ ํ์ฌ ํ์
for(i=0;i<6;i++){
if(SiegeIconPosi[3][0]+i*40 < pCursorPos.x && SiegeIconPosi[3][0]+ SiegeIconPosi[3][2]+i*40 > pCursorPos.x &&
SiegeIconPosi[3][1] < pCursorPos.y && SiegeIconPosi[3][1]+ SiegeIconPosi[3][3]> pCursorPos.y ){
CastleKindIndex=i+1;
break;
}
else{
CastleKindIndex=0;
}
}
break;
}
//์คํฌ๋กค ์์ง์ธ๋ค.
if(ScrollButtonFlag==1){
if(SiegeIconPosi[0][0]<96){
SiegeIconPosi[0][0]=96;
ScrollButtonFlag=0;
}
else if(SiegeIconPosi[0][0]>315){
SiegeIconPosi[0][0]=314;
ScrollButtonFlag=0;
}
else{
if(95<SiegeIconPosi[0][0]&&SiegeIconPosi[0][0]<316)
SiegeIconPosi[0][0] =pCursorPos.x;
}
}
}
//==================================================================//
// ๊ณต์ฑ์ ๋ณด๋ ์ค์
//==================================================================//
//๊ณต์ฑ์ ์ ์ ๋ณด๋๋ฅผ ๋ ์ด๋ค.
if(haSiegeBoardFlag){
BoardTime++;
if(BoardTime>60*30){
haSiegeBoardFlag = 0;
SetCastleInit();
}
}
//==================================================================//
// ๋์์ ์ฌ์ ๋ฉ๋ด
//==================================================================//
if(haMovieFlag){
for(i=0;i<3;i++){
if(haPlayerPosi[0][0]+i*34 < pCursorPos.x && haPlayerPosi[0][0]+haPlayerPosi[0][2]+i*34 > pCursorPos.x &&
haPlayerPosi[0][1] < pCursorPos.y && haPlayerPosi[0][1]+haPlayerPosi[0][3] > pCursorPos.y ){
haMovieKind = i+1;
break;
}
else if(haPlayerPosi[1][0] < pCursorPos.x && haPlayerPosi[1][0]+haPlayerPosi[1][2] > pCursorPos.x &&
haPlayerPosi[1][1] < pCursorPos.y&& haPlayerPosi[1][1]+haPlayerPosi[1][3] > pCursorPos.y ){
haMovieKind = 4;
break;
}
else{
haMovieKind = 0;
}
}
}
}
/*----------------------------------------------------------------------------*
* ๊ทธ๋ฆผ์ ๊ทธ๋ฆฌ๋ค.
*-----------------------------------------------------------------------------*/
int haStartTga=0; //๋ณด๋ ๊ทธ๋ฆผ์ ์ฌ์ฉ๋ผ๋ ์์ ๋ณ์๋ค
int haTempScore[2]={0};
int haStartPosiX=0,haStartPosiY=100;
void cHASIEGE::Draw()
{
int i,j;
//==================================================================//
// ๊ณต์ฑ์ ๋ฉ๋ด ์ค์
//==================================================================//
if(haSiegeMenuFlag){
switch(haSiegeMenuKind){
case HASIEGE_TAXRATES: //์ธ์จ ์กฐ์
DrawSprite(SiegeButtonPosi[0][0],SiegeButtonPosi[0][1],lpSiegeTax ,0, 0, SiegeButtonPosi[0][2], SiegeButtonPosi[0][3], 1); //์ธ์จ ์ค์ ๋ฉ์ธ
DrawSprite(SiegeButtonPosi[4][0],SiegeButtonPosi[4][1],lpTax_Ok[0] ,0, 0, SiegeButtonPosi[4][2], SiegeButtonPosi[4][3], 1); //์ธ๊ธ์ฐพ๊ธฐ๋ฒํผ
DrawSprite(SiegeIconPosi[5][0],SiegeIconPosi[5][1],lpTaxScroll[1] ,0, 0,SiegeIconPosi[5][2], SiegeIconPosi[5][3], 1); //์คํฌ๋กค
DrawSprite(SiegeIconPosi[0][0]-8,SiegeIconPosi[0][1],lpTaxScroll[0] ,0, 0, SiegeIconPosi[0][2],SiegeIconPosi[0][3], 1); //์คํฌ๋กค
DrawSprite(70+26,SiegeIconPosi[0][1]-10,lpTaxGraph ,0, 0, SiegeIconPosi[0][0]-(70+26), 10, 1); //์คํฌ๋กค
break;
case HASIEGE_DEFENSE: //๋ฐฉ์ด ์ค์
DrawSprite(SiegeButtonPosi[0][0],SiegeButtonPosi[0][1],lpSiegeDefense ,0, 0, SiegeButtonPosi[0][2], SiegeButtonPosi[0][3], 1); //๋ฐฉ์ด ์ค์ ๋ฉ์ธ
DrawSprite(SiegeButtonPosi[0][0]+10,SiegeButtonPosi[0][1]+63,lpMercenary ,0, 0,248, 88, 1); //๋ฉ๋ด ๋ฐ์ค
//ํด๋์คํฌ ํ์
if(cSinSiege.ClanSkill){
DrawSprite(SiegeIconPosi[2][0]+(cSinSiege.ClanSkill-1)*84,SiegeIconPosi[2][1],lpSiegeClanskillIcon[cSinSiege.ClanSkill-1] ,0, 0, SiegeIconPosi[2][2], SiegeIconPosi[2][3], 1);//
}
//ํ์๋ฐฉ์ด์ค์ ์ผ ๊ฒฝ์ฐ (๊ธฐ๋ณธ์ ํ์๋ฐฉ์ด์ค์ )
if(!haSiegeMerFlag){
DrawSprite(SiegeButtonPosi[0][0]+10,SiegeButtonPosi[0][1]+43,lpCastleButton ,0, 0, 249, 22, 1); //์ฑ ๋ฉ์ธ
for(i=0;i<3;i++){
DrawSprite(SiegeIconPosi[1][0]+(i*82),SiegeIconPosi[1][1],lpSiegeDefeseIcon_[i] ,0, 0, SiegeIconPosi[1][2], SiegeIconPosi[1][3], 1);
}
//์ฑ์ ์ข
๋ฅ์ ํ์ ํ์
ํ์
for( i=0;i<6;i++){
for( j=0;j<2;j++){
if(cSinSiege.TowerTypeDraw[i][0]){
//๊ทธ๋ฆผ ๋ณด์
if(cSinSiege.TowerTypeDraw[i][0]==1)
DrawSprite(SiegeIconPosi[3][0]+2,SiegeIconPosi[3][1]-2,lpCastleIcon[i] ,0, 0,SiegeIconPosi[3][2], SiegeIconPosi[3][3], 1);
else if(cSinSiege.TowerTypeDraw[i][0]==3)
DrawSprite(SiegeIconPosi[3][0]+80-1,SiegeIconPosi[3][1]-2,lpCastleIcon[i] ,0, 0,SiegeIconPosi[3][2], SiegeIconPosi[3][3], 1);
else
DrawSprite(SiegeIconPosi[3][0]+(cSinSiege.TowerTypeDraw[i][0]-1)*40,SiegeIconPosi[3][1]-2,lpCastleIcon[i] ,0, 0,SiegeIconPosi[3][2], SiegeIconPosi[3][3], 1);
if(cSinSiege.TowerTypeDraw[i][1]){
DrawSprite(SiegeIconPosi[1][0]+(cSinSiege.TowerTypeDraw[i][1]-1)*82,SiegeIconPosi[1][1],lpSiegeDefeseIcon[cSinSiege.TowerTypeDraw[i][1]-1] ,0, 0, SiegeIconPosi[1][2], SiegeIconPosi[1][3], 1);
}
}
}
}
}
//์ฉ๋ณ์ค์ ์ผ๊ฒฝ์ฐ
if(haSiegeMerFlag){
for(i=0;i<3;i++){
DrawSprite(SiegeIconPosi[1][0]+(i*82),SiegeIconPosi[1][1],lpSiegeMercenaryIcon_[i] ,0, 0, 30, 30, 1);
if(cSinSiege.MercenaryNum[i]){
DrawSprite(SiegeIconPosi[1][0]+i*82,SiegeIconPosi[1][1],lpSiegeMercenaryIcon[i] ,0, 0, SiegeIconPosi[1][2], SiegeIconPosi[1][3], 1);
}
}
if(TowerIconIndex > 0){
DrawSprite(SiegeIconPosi[1][0]+(TowerIconIndex-1)*82,SiegeIconPosi[1][1],lpSiegeMercenaryIcon[TowerIconIndex-1] ,0, 0, SiegeIconPosi[1][2], SiegeIconPosi[1][3], 1);
}
}
if(!haSiegeMerFlag)//์ฉ๋ณ์ค์ / ๋ฐฉ์ด์ค์ ๋ฒํผ ํ์ฑํ
DrawSprite(SiegeButtonPosi[5][0],SiegeButtonPosi[5][1],lpDefenseButton[1] ,0, 0, SiegeButtonPosi[5][2], SiegeButtonPosi[5][3], 1); //๋ฐฉ์ด์ค์ ๋ฒํผ
else
DrawSprite(SiegeButtonPosi[6][0],SiegeButtonPosi[6][1],lpDefenseButton[0] ,0, 0, SiegeButtonPosi[6][2], SiegeButtonPosi[6][3], 1); //์ฉ๋ณ์ค์ ๋ฒํผ
//์ ๋ณด๋ฐ์ค๋ฅผ ๋ณด์ฌ์ค๋ค.
if(TowerIconIndex > 0){
if(TowerIconIndex>3){ //ํด๋์คํฌ ์ ๋ณด๋ฐ์ค๋ฅผ ๋ ์ด๋ค.
ClanSkillBoxPosi.x=SiegeIconPosi[2][0]+(TowerIconIndex-4)*84;
ClanSkillBoxPosi.y=SiegeIconPosi[2][1]-96;
ClanSkillBoxSize.x=11;
ClanSkillBoxSize.y=6;
}
else if(TowerIconIndex<4 && haSiegeMerFlag){ //์ฉ๋ณ์ค์ ์ ๋ณด ๋ฐ์ค๋ฅผ ๋ ์ด๋ค.
ClanSkillBoxPosi.x=SiegeIconPosi[2][0]+(TowerIconIndex-1)*84;;
ClanSkillBoxPosi.y=SiegeIconPosi[2][1]-216-20;
ClanSkillBoxSize.x=15;
ClanSkillBoxSize.y=7;
}
else{ //๊ธฐ๋ณธ ์ค์ ์ ๋ณด๋ฐ์ค๋ฅผ ๋ ์ด๋ค.
ClanSkillBoxPosi.x=SiegeIconPosi[2][0]+(TowerIconIndex-1)*84;;
ClanSkillBoxPosi.y=SiegeIconPosi[2][1]-216;
ClanSkillBoxSize.x=15;
ClanSkillBoxSize.y=6;
}
for(i = 0; i < ClanSkillBoxSize.x ; i++){
for(int j = 0; j< ClanSkillBoxSize.y ; j++){
if(i == 0 && j == 0 ) //์ข์ธก์๋จ
dsDrawTexImage( cItem.MatItemInfoBox_TopLeft , ClanSkillBoxPosi.x+(i*16) , ClanSkillBoxPosi.y+(j*16), 16, 16 , 255 );
if(j == 0 && i !=0 && i+1 < ClanSkillBoxSize.x ) //๊ฐ์ด๋ฐ
dsDrawTexImage( cItem.MatItemInfoBox_TopCenter , ClanSkillBoxPosi.x+(i*16) , ClanSkillBoxPosi.y+(j*16), 16, 16 , 255 );
if(j == 0 && i+1 == ClanSkillBoxSize.x) //์ฐ์ธก์๋จ
dsDrawTexImage( cItem.MatItemInfoBox_TopRight , ClanSkillBoxPosi.x+(i*16) , ClanSkillBoxPosi.y+(j*16), 16, 16 , 255 );
if(i == 0 && j != 0 && j+1 != ClanSkillBoxSize.y) //์ข์ธก ์ค๊ฑฐ๋ฆฌ
dsDrawTexImage( cItem.MatItemInfoBox_Left , ClanSkillBoxPosi.x+(i*16) , ClanSkillBoxPosi.y+(j*16), 16, 16 , 255 );
if(i != 0 && j != 0 && i+1 !=ClanSkillBoxSize.x && j+1 !=ClanSkillBoxSize.y) //๊ฐ์ด๋ฐ ํ ๋ง
dsDrawTexImage( cItem.MatItemInfoBox_Center , ClanSkillBoxPosi.x+(i*16) , ClanSkillBoxPosi.y+(j*16), 16, 16 , 255 );
if(i+1 == ClanSkillBoxSize.x && j != 0 && j+1 != ClanSkillBoxSize.y) //์ฐ์ธก ์ค๊ฑฐ๋ฆฌ
dsDrawTexImage( cItem.MatItemInfoBox_Right , ClanSkillBoxPosi.x+(i*16) , ClanSkillBoxPosi.y+(j*16), 16, 16 , 255 );
if(i == 0 && j+1 == ClanSkillBoxSize.y) //๋ฐ๋ฐ๋ฅ ์ผ์ชฝ
dsDrawTexImage( cItem.MatItemInfoBox_BottomLeft , ClanSkillBoxPosi.x+(i*16) , ClanSkillBoxPosi.y+(j*16), 16, 16 , 255 );
if(i != 0 && j+1 == ClanSkillBoxSize.y && i+1 !=ClanSkillBoxSize.x)//๋ฐ๋ฐ๋ฅ ๊ฐ์ด๋ฐ
dsDrawTexImage( cItem.MatItemInfoBox_BottomCenter , ClanSkillBoxPosi.x+(i*16) , ClanSkillBoxPosi.y+(j*16), 16, 16 , 255 );
if(j+1 == ClanSkillBoxSize.y && i+1 ==ClanSkillBoxSize.x)//๋ฐ๋ฐ๋ฅ ์ค๋ฅธ์ชฝ
dsDrawTexImage( cItem.MatItemInfoBox_BottomRight , ClanSkillBoxPosi.x+(i*16) , ClanSkillBoxPosi.y+(j*16), 16, 16 , 255 );
}
}
}
//์ ํ๋ ์ฐฝ์ ํ์์ ํ
๋๋ฆฌ๋ฅผ ๋ณด์ฌ์ค๋ค.
break;
}
switch(MenuButtonIndex){ //๋ฉ๋ด ๋ฒํผ ๊ด๋ จ
case 2:
DrawSprite(SiegeButtonPosi[2][0],SiegeButtonPosi[2][1],lpSiegeOkButton,0, 0, SiegeButtonPosi[2][2], SiegeButtonPosi[2][3], 1);
break;
case 3:
DrawSprite(SiegeButtonPosi[3][0],SiegeButtonPosi[3][1],lpSiegeCancelButton ,0, 0, SiegeButtonPosi[3][2], SiegeButtonPosi[3][3], 1);
break;
case 4:
if(haSiegeMenuKind==HASIEGE_TAXRATES) //๋์ฐพ๊ธฐ ๋ฒํผ์ ํ์ฑํ ์ํจ๋ค.
DrawSprite(SiegeButtonPosi[4][0],SiegeButtonPosi[4][1],lpSiegeOkButton ,0, 0, SiegeButtonPosi[4][2], SiegeButtonPosi[4][3], 1); //์ธ๊ธ์ฐพ๊ธฐ๋ฒํผ
break;
case 5:
DrawSprite(SiegeButtonPosi[5][0],SiegeButtonPosi[5][1],lpDefenseButton[1] ,0, 0, SiegeButtonPosi[5][2], SiegeButtonPosi[5][3], 1); //๋ฐฉ์ด์ค์ ๋ฒํผ
break;
case 6:
DrawSprite(SiegeButtonPosi[6][0],SiegeButtonPosi[6][1],lpDefenseButton[0] ,0, 0, SiegeButtonPosi[6][2], SiegeButtonPosi[6][3], 1); //์ฉ๋ณ์ค์ ๋ฒํผ
break;
case 7:
DrawSprite(SiegeButtonPosi[1][0],SiegeButtonPosi[1][1],lpSiegeDefenseButton ,0, 0,SiegeButtonPosi[1][2],SiegeButtonPosi[1][3], 1);//๋ฐฉ์ด๋ฉ์ธ์ค์ ๋ฒํผ
break;
case 8:
DrawSprite(SiegeButtonPosi[1][0],SiegeButtonPosi[1][1],lpSiegeTaxButton ,0, 0, SiegeButtonPosi[1][2], SiegeButtonPosi[1][3], 1);//์ฌ์ ๋ฉ์ธ์ค์ ๋ฒํผ
break;
}
}
//==================================================================//
// ๊ณต์ฑ์ ๋ณด๋ ์ค์
//==================================================================//
if(haSiegeBoardFlag){
char TempBuff[64];
memset(&TempBuff,0,sizeof(TempBuff));
if(rsBlessCastle.TimeSec[0] < 10){
if(haStartPosiX < WinSizeX/2+256/2){
haStartPosiX+=8+haStartPosiX/2;
if(haAlpha < 255)
haAlpha+=20;
else
haAlpha=255;
}
else{
haStartPosiX = WinSizeX/2+256/2;
if(haAlpha > 0)
haAlpha-=5;
else
haAlpha=0;
}
dsDrawTexImage(haStartTga,haStartPosiX-256,haStartPosiY, 256, 64 , haAlpha );
}
DrawFontImage(ScoreBoardName[5],WinSizeX/2-200, 5,RGBA_MAKE(0,255,0,255),1.0f);
DrawFontImage(ScoreBoardName[4],WinSizeX/2-200,30,RGBA_MAKE(255,255,0,255),0.7f);
DrawFontImage(ScoreBoardName[1],WinSizeX/2-200,49,RGBA_MAKE(255,255,0,255),0.7f);
DrawFontImage(ScoreBoardName[3],WinSizeX/2+20,7,RGBA_MAKE(100,100,255,255),0.8f);
wsprintf(TempBuff,"%d:%d:%d",haPlayTime[2],haPlayTime[1],haPlayTime[0]);
DrawFontImage(TempBuff,WinSizeX/2+115,7,RGBA_MAKE(100,100,255,255),0.8f);
DrawFontImage(ScoreBoardName[0],WinSizeX/2-360,7,RGBA_MAKE(0,255,0,255),0.7f);
wsprintf(TempBuff,"%d",lpCurPlayer->sBlessCastle_Damage[1]);
DrawFontImage(TempBuff,WinSizeX/2-240,7,RGBA_MAKE(200,0,0,255),0.7f);
if(!haStartTga){
haStartTga=CreateTextureMaterial("image\\Bellatra\\T_Start_278_65.tga", 0, 0, 0,0, SMMAT_BLEND_ALPHA);
ReadTextures(); //ํ
์ค์ณ ๋ก๋ฉ
}
for( i=0;i<10;i++){
if(sHaClanData[i].Flag){
if(GetClanCode(lpCurPlayer->smCharInfo.ClassClan) == sHaClanData[i].CLANCODE){
wsprintf(TempBuff,"%d",sHaClanData[i].Score*100/haTotalDamage);
if(haTempScore[0]==sHaClanData[i].Score*100/haTotalDamage)
DrawFontImage(TempBuff,WinSizeX/2-100,30,RGBA_MAKE(255,255,0,255),0.8f);
else
DrawFontImage(TempBuff,WinSizeX/2-100,29,RGBA_MAKE(255,0,0,255),0.8f);
haTempScore[0]=sHaClanData[i].Score*100/haTotalDamage;
wsprintf(TempBuff,"%d",(int)lpCurPlayer->sBlessCastle_Damage[0]*100/sHaClanData[i].Score);
if(haTempScore[1]==(int)lpCurPlayer->sBlessCastle_Damage[0]*100/sHaClanData[i].Score)
DrawFontImage(TempBuff,WinSizeX/2-100,49,RGBA_MAKE(255,255,0,255),0.8f);
else
DrawFontImage(TempBuff,WinSizeX/2-100,48,RGBA_MAKE(255,0,0,255),0.8f);
haTempScore[1] = (int)lpCurPlayer->sBlessCastle_Damage[0]*100/sHaClanData[i].Score;
}
}
}
int TempCount=0;
for(i=0;i<5;i++){
if(sHaClanData[i].Flag){
//๋๋ฒ๊ทธ ๋ชจ๋์ผ๋
if(smConfig.DebugMode){
wsprintf(TempBuff,"%d",sHaClanData[i].Score);
if(GetClanCode(lpCurPlayer->smCharInfo.ClassClan) == sHaClanData[i].CLANCODE){
DrawFontImage(TempBuff,WinSizeX/2+120,30+i*17,RGBA_MAKE(255,255,0,255),0.6f);
}
else{
DrawFontImage(TempBuff,WinSizeX/2+120,30+i*17,RGBA_MAKE(255,128,0,255),0.6f);
}
}
DrawSprite(WinSizeX/2+20,30+i*17,sHaClanData[i].lpClanMark,0, 0, 16, 16, 1);
}
if(haCrystalTowerCount[i] && i<4){
TempCount+= haCrystalTowerCount[i];
if(lpTwoerImage==NULL){
lpTwoerImage = LoadDibSurfaceOffscreen("image\\Sinimage\\Siege\\Tower_image.bmp");
}
}
}
for(i=0;i<TempCount;i++){
DrawSprite(WinSizeX/2-360+i*20,30,lpTwoerImage ,0, 0, 16, 32, 1);
}
}
//-----------------------------------------------------------------------------------/
// ๊ณต์ฑ์ ๋์์ ํ๋ ์ด์ด ๊ทธ๋ฆผ
//-----------------------------------------------------------------------------------/
if(haMovieFlag){
char szBuff[128];
for(i = 0 ; i < 9 ; i++){
wsprintf(szBuff,"Image\\SinImage\\Player\\ha_B%d.tga",i+1);
if(haMatPlayMenu[i]==NULL){
haMatPlayMenu[i] = CreateTextureMaterial( szBuff , 0, 0, 0,0, SMMAT_BLEND_ALPHA );
ReadTextures();
}
}
//int BoxSizeX=10,BoxSizeY=10;
for(i=0;i<7;i++){
dsDrawTexImage( haMatPlayMenu[1] ,26+64+(i*32), 70, 32, 64 , 255 );
if(i<6){
dsDrawTexImage( haMatPlayMenu[3] ,64+(8*32),70+64+(i*32), 32, 32 , 255 );
dsDrawTexImage( haMatPlayMenu[7] ,40,70+64+(i*32), 32, 32 , 255 );
}
dsDrawTexImage( haMatPlayMenu[5] ,26+32+(i*32),70+64+(6*32), 64, 64 , 255 );
}
dsDrawTexImage( haMatPlayMenu[0],40, 70, 64, 64 , 255 );
dsDrawTexImage( haMatPlayMenu[2] ,64+(i*32),70,64,64,255 );
dsDrawTexImage( haMatPlayMenu[4] ,64+(i*32),70+64+((i-1)*32), 64, 64 , 255 );
dsDrawTexImage( haMatPlayMenu[6] ,40 ,70+64+((i-1)*32), 64, 64 , 255 );
dsDrawTexImage( haMatPlayMenu[5] ,26+32+(8*32),70+64+(6*32), 18, 64 , 255 );
for(i =0;i<3;i++){
wsprintf(szBuff,"Image\\SinImage\\Player\\habox_0%d.bmp",i+1);
if(haPlayerButtonBox[i]==NULL){
haPlayerButtonBox[i] = LoadDibSurfaceOffscreen(szBuff);
}
wsprintf(szBuff,"Image\\SinImage\\Player\\ha_S%d_.bmp",i+1);
if(haPlayerButton_G[i]==NULL){
haPlayerButton_G[i] = LoadDibSurfaceOffscreen(szBuff);
}
wsprintf(szBuff,"Image\\SinImage\\Player\\ha_S%d.bmp",i+1);
if(haPlayerButton[i]==NULL){
haPlayerButton[i] = LoadDibSurfaceOffscreen(szBuff);
}
wsprintf(szBuff,"Image\\SinImage\\Player\\ha0%d.bmp",i+1);
if(haPlayerButtonDown[i]==NULL){
haPlayerButtonDown[i] = LoadDibSurfaceOffscreen(szBuff);
}
DrawSprite(haPlayerPosi[0][0]+(i*34),haPlayerPosi[0][1],haPlayerButton_G[i],0, 0,haPlayerPosi[0][2],haPlayerPosi[0][3], 1);
}
DrawSprite(haPlayerPosi[0][0]+((ParkPlayMode/150)*34),haPlayerPosi[0][1],haPlayerButton[ParkPlayMode/150] ,0, 0,32,32, 1);
DrawSprite(120,74 ,haPlayerButtonBox[0] ,0, 0,149,23, 1); //
DrawSprite(64,363 ,haPlayerButtonBox[1] ,0, 0,68 ,23, 1);
DrawSprite(haPlayerPosi[1][0],haPlayerPosi[1][1],haPlayerButtonBox[2] ,0, 0,haPlayerPosi[1][2] ,haPlayerPosi[1][3], 1);
DrawSprite(78,368,haPlayerButtonDown[2] ,0, 0,36,12, 1);
if(haMovieKind==4){
DrawSprite(haPlayerPosi[1][0]+8,haPlayerPosi[1][1]+5,haPlayerButtonDown[0] ,0, 0,32,16, 1);
}
else{
DrawSprite(haPlayerPosi[1][0]+8,haPlayerPosi[1][1]+5,haPlayerButtonDown[1] ,0, 0,32,16, 1);
}
}
}
/*----------------------------------------------------------------------------*
* ์๋ฒ์์ ํธ์ถ๋ผ๋ ํจ์
*-----------------------------------------------------------------------------*/
//<ha>๊ณต์ฑ์ ๋ฉ๋ด๋ฅผ ์ด์ด์ค๋ค.
int cHASIEGE::ShowSiegeMenu(smTRANS_BLESSCASTLE *pData)
{
int i;
//ํด๋์นฉ ๋ถํด๋์นฉ์ด ์๋๊ฒฝ์ฐ ๋ฆฌํด
#ifdef _WINMODE_DEBUG
#else
if(rsBlessCastle.dwMasterClan != GetClanCode(lpCurPlayer->smCharInfo.ClassClan))return TRUE;
#endif
SendClanMoneyToServer(0,0,1);
cSinSiege.ClanSkill = pData->ClanSkill; //ํด๋ ์คํฌ
for(i=0;i<3;i++){
cSinSiege.MercenaryNum[i] = pData->MercenaryNum[i]; //์ฉ๋ณํ์
}
for(i=0;i<6;i++){
cSinSiege.TowerTypeDraw[i][0] = 0;
cSinSiege.TowerTypeDraw[0][0] = 1; //๋ด์ฑ A๋ฅผ ํ์ฑํ ์ํจ๋ค.
cSinSiege.TowerTypeDraw[i][1] = pData->Tower[i]; //์ฑํ์
์ ํ์๋ง ์ ์ฅ
}
ImageLoad(); //์ด๋ฏธ์ง๋ฅผ ๋ก๋
int Temp=0,Temp2=0;
Temp = (pData->TaxRate*22)+96;
Temp2 = (cSinSiege.TaxRate*22)+96-8; //ํ์ฌ ์ ์ฉ๋ผ๋ ์ธ์จ
//ํ์ฌ์ ์ธ์จ์ ์ธํ
ํ๋ค.
SiegeIconPosi[0][0] = Temp-2;
SiegeIconPosi[5][0] = Temp2-2;
HaTaxRate = pData->TaxRate;
//๊ณต์ฑ์ ๋ฉ๋ด๋ฅผ ์ฐ๋ค.
haSiegeMenuFlag = 1;
haSiegeMenuKind = HASIEGE_TAXRATES;//์ฌ์ ์ค์ ์ ์ฐ๋ค.
return TRUE;
}
/*----------------------------------------------------------------------------*
* ์๋ฒ๋ก๋ถํฐ ๊ณต์ฑ ์ ์๋ฅผ ๋ฐ๋๋ค.
*-----------------------------------------------------------------------------*/
int cHASIEGE::ShowSiegeScore(rsUSER_LIST_TOP10 *pData)
{
int i;
//ํด๋ ์ ๋ณด๋ฅผ ๋ฐ์์ ์ ์ฅํ๋ค.
for(i=0;i<HACLAN_MAX ;i++){
if(pData->dwUserCode[i] && pData->Damage[i]){
sHaClanData[i].CLANCODE = pData->dwUserCode[i];
sHaClanData[i].Score = pData->Damage[i];
haTotalDamage = pData->dwTotalDamage;
sHaClanData[i].Flag = 1;
sHaClanData[i].ClanInfoNum = ReadClanInfo(sHaClanData[i].CLANCODE);
if(sHaClanData[i].ClanInfoNum >=0){
lstrcpy(sHaClanData[i].ClanName , ClanInfo[sHaClanData[i].ClanInfoNum].ClanInfoHeader.ClanName);
sHaClanData[i].lpClanMark = ClanInfo[sHaClanData[i].ClanInfoNum].hClanMark;
}
}
}
//ํฌ๋ฆฌ์คํ ์นด์ดํธ ๋ฅผ ๋ฐ๋๋ค.
for(i=0;i<4;i++){
haCrystalTowerCount[i] = pData->bCrystalTowerCount[i];
}
return TRUE;
}
/*----------------------------------------------------------------------------*
* <ha>๊ณต์ฑ์ ์ข
๋ฃ ๋ฉ์ธ์ง๋ฅผ ๋ณด์ฌ์ค๋ค.
*-----------------------------------------------------------------------------*/
int cHASIEGE::ShowExitMessage()
{
//๊ณต์ฑ์ ์งํ์ค ๋ฉ์ธ์ง
haSiegeBoardFlag = 0;
SetCastleInit();
//์น๋ฆฌ์ ํจ๋ฐฐ ๋ฉ์ธ์ง
if(rsBlessCastle.dwMasterClan == GetClanCode(lpCurPlayer->smCharInfo.ClassClan)){
cSinHelp.sinShowHelp(SIN_HELP_KIND_C_TELEPORT,QuestMessageBoxPosi2.x,QuestMessageBoxPosi2.y,QuestMessageBoxSize2.x,QuestMessageBoxSize2.y, RGBA_MAKE(0,15,128,125),haC_CastleWinFilePath);
}
else{
cSinHelp.sinShowHelp(SIN_HELP_KIND_C_TELEPORT,QuestMessageBoxPosi2.x,QuestMessageBoxPosi2.y,QuestMessageBoxSize2.x,QuestMessageBoxSize2.y, RGBA_MAKE(0,15,128,125),haC_CastleLoseFilePath);
}
return TRUE;
}
/*----------------------------------------------------------------------------*
* <ha>๊ณต์ฑ์ ๋ณด๋ ์ด๊ธฐํ ํจ์
*-----------------------------------------------------------------------------*/
int cHASIEGE::SetCastleInit()
{
for(int i=0;i<3;i++){
haPlayTime[i]=0;
}
for(int i=0;i<HACLAN_MAX ;i++){
sHaClanData[i].CLANCODE=0;
sHaClanData[i].Flag=0;
sHaClanData[i].lpClanMark=0;
sHaClanData[i].Score=0;
if(i<4){
haCrystalTowerCount[i]=0;
}
}
BoardTime = 60*30;
return TRUE;
}
/*----------------------------------------------------------------------------*
* ํ๋ ์ด ํ์ ํ์
*-----------------------------------------------------------------------------*/
int cHASIEGE::ShowPlayTime(int StartTime)
{
if(StartTime==0){
SetCastleInit();
return TRUE;
}
//ํ๋ ์ด ํ์์ ์ธํ
ํ๋ค.
haPlayTime[0] = StartTime%60; //์ด
haPlayTime[1] = StartTime/60;
haPlayTime[1]-= StartTime/3600*60;
haPlayTime[2] = StartTime/3600; //์๊ฐ
//1์๊ฐ ๊ฐ๊ฒฉ์ผ๋ก ์ด๊ธฐํ ํด์ค๋ค.
//if(StartTime%60*10 == 0){
// SetCastleInit();
//}
if(rsBlessCastle.TimeSec[1] > 0 ){
haSiegeBoardFlag = 1;//์ด๊ธฐํ ํด์ค๋ค.
BoardTime = 0;
}
else{
haSiegeBoardFlag = 0;
haStartPosiX = 0;
}
return TRUE;
}
/*----------------------------------------------------------------------------*
* <ha>
*-----------------------------------------------------------------------------*/
int cHASIEGE::ShowPickUserKillPoint(int x,int y,int KillCount)
{
char TempBuff[32];
memset(&TempBuff,0,sizeof(TempBuff));
DrawFontImage(ScoreBoardName[2],x,y,RGBA_MAKE(0,255,0,255),0.7f);
wsprintf(TempBuff,"%d",KillCount);
DrawFontImage(TempBuff,x+24,y,RGBA_MAKE(255,0,0,255),0.7f);
return TRUE;
}
/*----------------------------------------------------------------------------*
* ํด๋์คํฌ ๊ด๋ จ
*-----------------------------------------------------------------------------*/
//ํด๋์คํฌ์ด ์์ผ๋ฉด ์ธํ
ํ๋ค.
int cHASIEGE::SetClanSkill(int ClanSkill)
{
DWORD SkillCode;
haClanSkillTime = 0;
//์ด๊ธฐํ
switch(ClanSkill){
case SIN_CLANSKILL_ABSORB:
SkillCode = CLANSKILL_ABSORB;
break;
case SIN_CLANSKILL_DAMAGE:
SkillCode = CLANSKILL_ATTACK;
break;
case SIN_CLANSKILL_EVASION:
SkillCode = CLANSKILL_EVASION;
break;
}
if(rsBlessCastle.dwMasterClan == GetClanCode(lpCurPlayer->smCharInfo.ClassClan)){
if(cSkill.SearchContiueSkillCODE(SkillCode)==SkillCode){
return TRUE;
}
else{
cSkill.CancelContinueSkill(CLANSKILL_ATTACK);
cSkill.CancelContinueSkill(CLANSKILL_EVASION);
cSkill.CancelContinueSkill(CLANSKILL_ABSORB);
}
}
else{
cSkill.CancelContinueSkill(CLANSKILL_ATTACK);
cSkill.CancelContinueSkill(CLANSKILL_EVASION);
cSkill.CancelContinueSkill(CLANSKILL_ABSORB);
return TRUE;
}
//ํด๋์์ด ๋ง์ผ๋ฉด ํด๋์คํฌ์ ์ธํ
ํ๋ค.
sSKILL haClanSkill;
for(int j = 0 ; j < SIN_MAX_SKILL; j++){
if(sSkill[j].CODE == SkillCode){
memcpy(&haClanSkill,&sSkill[j],sizeof(sSKILL));
haClanSkill.UseTime=60;
sinContinueSkillSet(&haClanSkill);
break;
}
}
cInvenTory.SetItemToChar();
return TRUE;
}
/*----------------------------------------------------------------------------*
* haGoon ๊ณต์ฑ์ ์ ์ฉ ์์ดํ
์ ์ฌ์ฉํ๋ค.
*-----------------------------------------------------------------------------*/
int haCastleSkillUseFlag =0;
int cHASIEGE::SetCastleItemSkill(int ItemKind)
{
DWORD CastleSkillCode;
int CastleSkillUseTime=0;
switch(ItemKind){
case SIN_CASTLEITEMSKILL_S_INVU:
CastleSkillCode = SCROLL_INVULNERABILITY;
CastleSkillUseTime = 30;
break;
case SIN_CASTLEITEMSKILL_S_CRITICAL:
CastleSkillCode = SCROLL_CRITICAL;
CastleSkillUseTime = 30;
break;
case SIN_CASTLEITEMSKILL_S_EVASION:
CastleSkillCode = SCROLL_EVASION;
CastleSkillUseTime = 30;
break;
case SIN_CASTLEITEMSKILL_S_P_LIFE:
CastleSkillCode = 0;
break;
case SIN_CASTLEITEMSKILL_S_RES:
CastleSkillCode = 0;
break;
case SIN_CASTLEITEMSKILL_R_FIRE_C:
CastleSkillCode = STONE_R_FIRECRYTAL;
CastleSkillUseTime = 60;
break;
case SIN_CASTLEITEMSKILL_R_ICE_C:
CastleSkillCode = STONE_R_ICECRYTAL;
CastleSkillUseTime = 60;
break;
case SIN_CASTLEITEMSKILL_R_LIGHTING_C:
CastleSkillCode = STONE_R_LINGHTINGCRYTAL;
CastleSkillUseTime = 60;
break;
case SIN_CASTLEITEMSKILL_A_FIGHTER:
CastleSkillCode = STONE_A_FIGHTER;
CastleSkillUseTime = 60;
break;
case SIN_CASTLEITEMSKILL_A_MECHANICIAN:
CastleSkillCode = STONE_A_MECHANICIAN;
CastleSkillUseTime = 60;
break;
case SIN_CASTLEITEMSKILL_A_PIKEMAN:
CastleSkillCode = STONE_A_PIKEMAN;
CastleSkillUseTime = 60;
break;
case SIN_CASTLEITEMSKILL_A_ARCHER:
CastleSkillCode = STONE_A_ARCHER;
CastleSkillUseTime = 60;
break;
case SIN_CASTLEITEMSKILL_A_KNIGHT:
CastleSkillCode = STONE_A_KNIGHT;
CastleSkillUseTime = 60;
break;
case SIN_CASTLEITEMSKILL_A_ATALANTA:
CastleSkillCode = STONE_A_ATALANTA;
CastleSkillUseTime = 60;
break;
case SIN_CASTLEITEMSKILL_A_MAGICIAN:
CastleSkillCode = STONE_A_MAGICIAN;
CastleSkillUseTime = 60;
break;
case SIN_CASTLEITEMSKILL_A_PRIESTESS:
CastleSkillCode = STONE_A_PRIESTESS;
CastleSkillUseTime = 60;
break;
}
//ํด๋น ๋ผ๋ ์์ดํ
์ด ๋ง์ผ๋ฉด ์์ดํ
์คํฌ์ ์ธํ
ํ๋ค.
sSKILL haCastleSkill;
if(cSkill.SearchContiueSkillCODE(CastleSkillCode)==CastleSkillCode && CastleSkillCode != 0){
cMessageBox.ShowMessage(MESSAGE_CLANSKILL_USE);
haCastleSkillUseFlag = 0;
return TRUE;
}
haCastleSkillUseFlag =1;
if(CastleSkillCode==0)return TRUE; //์ ์งํ ์์ด์ฝ์ ๋์ด์ฃผ์ง ์๋ ๊ฒ์ ๋ฆฌํด ์์ผ์ค๋ค.
for(int j = 0 ; j < SIN_MAX_SKILL; j++){
if(sSkill[j].CODE == CastleSkillCode){
memcpy(&haCastleSkill,&sSkill[j],sizeof(sSKILL));
haCastleSkill.UseTime=CastleSkillUseTime;
sinContinueSkillSet(&haCastleSkill);
SwitchSkill(&haCastleSkill);
break;
}
}
return TRUE;
}
/*----------------------------------------------------------------------------*
* ์๋ฒ๋ก ๊ณต์ฑ๋ฉ๋ด ๋ฐ์ดํ๋ฅผ ๋ณด๋ธ๋ค
*-----------------------------------------------------------------------------*/
int cHASIEGE::SendServerSiegeData()
{
int i;
smTRANS_BLESSCASTLE TempBlessCastle;
//TempBlessCastle ์๋ฒ์ ๋ณด๋ธ๋ค
TempBlessCastle.TaxRate = HaTaxRate; //์ธ์จ
TempBlessCastle.ClanSkill = cSinSiege.ClanSkill; //ํด๋์คํฌ
TempBlessCastle.Price = cSinSiege.Price;
for(i=0;i<3;i++){
TempBlessCastle.MercenaryNum[i] = cSinSiege.MercenaryNum[i]; //์ฉ๋ณ
}
for(i=0;i<6;i++){
TempBlessCastle.Tower[i] = cSinSiege.TowerTypeDraw[i][1]; //์ฑํ์
์ ํ์๋ง ์ ์ฅ
}
SendBlessCastleToServer(&TempBlessCastle,0);//์๋ฒ๋ก ๋ณด๋ด๋ค.
SaveGameData();
return TRUE;
}
/*----------------------------------------------------------------------------*
* ๋ฉ๋ด ์ด๊ธฐํ๋ฅผ ํด์ค๋ค.
*-----------------------------------------------------------------------------*/
int cHASIEGE::SetCastleMenuInit()
{
haSiegeMenuFlag=0; //๋ฉ๋ด๋ฅผ ๋ซ์์ค๋ค.
haSiegeMenuKind=0; //๋ฉ๋ด์ข
๋ฅ๋ฅผ ์ด๊ธฐํ ํด์ค๋ค.
haSiegeMerFlag=0; //์ฉ๋ณ ํ๋์ ์ด๊ธฐํ ํด์ค๋ค.
SiegeIconPosi[0][0]=70+20-7; //์คํฌ๋กค์ ๋ค์ ๋ฐฐ์น
SiegeIconPosi[5][0]=70+20-7; //์คํฌ๋กค์ ๋ค์ ๋ฐฐ์น
return TRUE;
}
/*----------------------------------------------------------------------------*
* ํค๋ค์ด
*-----------------------------------------------------------------------------*/
void cHASIEGE::KeyDown()
{
}
/*----------------------------------------------------------------------------*
* LButtonDown/UP
*-----------------------------------------------------------------------------*/
void cHASIEGE::LButtonDown(int x,int y)
{
int i;
//==================================================================//
// haGoon๊ณต์ฑ์ ๋ฉ๋ด ์ค์
//==================================================================//
if(haSiegeMenuFlag){
//ํด๋์นฉ๊ณผ ๋ถํด๋์นฉ๋ง์ด ๋ณ๊ฒฝ ํ ์์๋ค.
if(cldata.myPosition == 101 ){
if(GraphLineFlag){ //์คํฌ๋กค
if(SiegeIconPosi[0][0]-16 < pCursorPos.x && SiegeIconPosi[0][0]+SiegeIconPosi[0][2]+16> pCursorPos.x && SiegeIconPosi[0][1]-16< pCursorPos.y && SiegeIconPosi[0][1]+SiegeIconPosi[0][3]+16> pCursorPos.y ){
ScrollButtonFlag=1;
}
else{
SiegeIconPosi[0][0] = pCursorPos.x;
}
}
if(CastleKindIndex){ //์ฑ์์ข
๋ฅ ์ธ๋ฑ์ค๋ฅผ ๋๊ฒจ์ค๋ค.
for( i=0;i<6;i++){
if((CastleKindIndex-1)==i){
cSinSiege.TowerTypeDraw[CastleKindIndex-1][0] = CastleKindIndex;//์ ํ๋ ์ฑ์ ์ข
๋ฅ๋ง ํ์ฑํ ์ํจ๋ค.
}
else{
cSinSiege.TowerTypeDraw[i][0] = 0;//์ ํ๋ผ์ง์์ ์ฑ์ ์ข
๋ฅ๋ ๋นํ์ฑํ
}
}
}
if(TowerIconIndex){ //ํ์ฌ ์ฑ์ ํ์
์ ์์ฑํ์๋ฅผ ๋๊ฒจ์ค๋ค.
if(TowerIconIndex<4){
if(haSiegeMerFlag){ //์ฉ๋ณ์ค์
haMercenrayIndex=TowerIconIndex;
if(cSinSiege.MercenaryNum[haMercenrayIndex-1] < 20){
cMessageBox.ShowMessage2(MESSAGE_SIEGE_SET_MERCENRAY);//ํ์ธ์ฐฝ์ ๋ ์ด๋ค.
}
}
else{ //ํ์ฌ์ฑ์ ์ข
๋ฅ์ ํ์ ์ธ๋ฑ์ค๋ฅผ ๋๊ฒจ์ค๋ค.
for( i=0;i<6;i++){
if(cSinSiege.TowerTypeDraw[i][0]){
haSendTowerIndex=TowerIconIndex;
if(cSinSiege.TowerTypeDraw[i][1]==0){
switch(TowerIconIndex){
case 1:
cMessageBox.ShowMessage3(MESSAGE_CASTLE_BUYTOWER,"ICE");
break;
case 2:
cMessageBox.ShowMessage3(MESSAGE_CASTLE_BUYTOWER,"LIGHTING");
break;
case 3:
cMessageBox.ShowMessage3(MESSAGE_CASTLE_BUYTOWER,"FIRE");
break;
}
}
else{
cSinSiege.TowerTypeDraw[i][1]=TowerIconIndex;
}
}
}
}
}
else{
//ํ์ฌ ํด๋ ์คํฌ์ ํด๋ ์ธ๋ฑ์ค๋ฅผ ๋๊ฒจ์ค๋ค.
cSinSiege.ClanSkill = TowerIconIndex-3;
}
}
}
switch(MenuButtonIndex){ //๋ฉ๋ด ๋ฒํผ ๊ด๋ จ
case 2:
if(cldata.myPosition == 101 ){
SendServerSiegeData(); //๋ฉ๋ด์ ๋ณด๋ฅผ ์ ์ฅํ๋ค.
SetCastleMenuInit(); //์ด๊ธฐํ
}
break;
case 3:
SetCastleMenuInit(); //์ด๊ธฐํ
break;
case 4: //์ธ๊ธํ์ ๋ฒํผ์ ํด๋ฆญํ๋ฉด ์ด ์ชฝ์ผ๋ก ๋ค์ด์จ๋ค
if(cldata.myPosition == 101 ){
if(haSiegeMenuKind==HASIEGE_TAXRATES){
//์ฐพ์ ๋์ด 0์ด๋ฉด ์ฐพ์์ ์๋ค.
if((int)cSinSiege.TotalTax <= 0){
cMessageBox.ShowMessage(MESSAGE_NOT_CASTLE_TOTALMONEY);
}
else{
cMessageBox.ShowMessage2(MESSAGE_SIEGE_GET_MONEY);//๋์ ์ฐพ๋ค.
}
}
}
break;
case 5:
haSiegeMerFlag =0; //๋ฐฉ์ด์ค์
break;
case 6:
haSiegeMerFlag =1; //์ฉ๋ณ์ค์
break;
case 7:
haSiegeMenuKind=2; //๋ฐฉ์ด์ค์
break;
case 8:
haSiegeMenuKind=1; //์ฌ์ ์ค์
break;
}
}
//==================================================================//
// ๋์์ ์ฌ์ ๋ฉ๋ด๋ฒํผ
//==================================================================//
if(haMovieFlag){
switch(haMovieKind){
case 1: //๋์์ ํ๋ ์ ์
ParkPlayMode = 0;
break;
case 2: //์ค
ParkPlayMode = 150;
break;
case 3: //ํ
ParkPlayMode = 300;
break;
case 4: //exit
haMovieFlag = 0;
Stop_ParkPlayer();
break;
}
}
}
void cHASIEGE::LButtonUp(int x,int y)
{
if(haSiegeMenuFlag){
if(ScrollButtonFlag){ //์คํฌ๋กค์ ์ฃฝ์ฌ์ค๋ค.
ScrollButtonFlag=0;
}
}
}
/*----------------------------------------------------------------------------*
* DrawText
*-----------------------------------------------------------------------------*/
void cHASIEGE::DrawText()
{
HDC hdc;
lpDDSBack->GetDC( &hdc );
SelectObject( hdc, sinFont);
SetBkMode( hdc, TRANSPARENT );
SetTextColor( hdc, RGB(255,255,255) );
char szTempBuff[128];
char haTempBuffer[128];//์์ ๋ฒํผ
//==================================================================//
// haGoon๊ณต์ฑ์ ๋ฉ๋ด ์ค์
//==================================================================//
//๊ณต์ฑ์ ์ค์ ์ ๋ณด์ฌ์ค๋ค.
if(haSiegeMenuFlag){
/*๋ฌธ์์ด์ ์ถ๋ ฅํ๋ค*/
int TempCount =0;
int Skilllen=0;
int cnt=0,cnt1=0,cnt2=0;
int i=0,j=0;
int stringcut=18; //๋ฌธ์์ด์ ์๋ฅผ ํฌ๊ธฐ
int LineCount[10]={0}; //10์ค ๊น์ง์ ์ ๋ณด๋ฅผ ์ ์ฅํ๋ค.
char TempBuffer[64]; //์์ ๋ฒํผ
int Taxlen=0; //์ธ๊ธ์ด์ก์ ๊ธธ์ด๋ฅผ ๊ตฌํ๋ค.
switch(haSiegeMenuKind){
case HASIEGE_TAXRATES: //์ฌ์ ์ค์
//ํ์ฌ ์ธ์จ (์คํฌ๋กค)
HaTaxRate= SiegeIconPosi[0][0]-(73+24-9);
HaTaxRate =HaTaxRate/22;
SelectObject( hdc, sinBoldFont);
SetTextColor( hdc, RGB(100,200,200) );
//์ธ์จ
wsprintf(szTempBuff,SiegeMessage_Taxrates[4],cSinSiege.TaxRate,"%");
dsTextLineOut(hdc,97,112, szTempBuff, lstrlen(szTempBuff));
wsprintf(szTempBuff,SiegeMessage_Taxrates[0],HaTaxRate,"%");
dsTextLineOut(hdc,97,182, szTempBuff, lstrlen(szTempBuff));
memset(szTempBuff,0,sizeof(szTempBuff));
NumLineComa(cSinSiege.TotalTax, szTempBuff); //์ธ๊ธ์ด์ก
lstrcat(szTempBuff,SiegeMessage_Taxrates[2]);
Taxlen=lstrlen(szTempBuff);
dsTextLineOut(hdc,247-((Taxlen-8)*8),260, szTempBuff, lstrlen(szTempBuff));
SelectObject( hdc, sinFont);
SetTextColor( hdc, RGB(255,255,255) );
wsprintf(szTempBuff,SiegeMessage_Taxrates[1]); //์ธ๊ธ ์ด์ก
dsTextLineOut(hdc,97,244, szTempBuff, lstrlen(szTempBuff));
SetTextColor( hdc, RGB(255,255,255) );
wsprintf(szTempBuff,SiegeMessage_Taxrates[3],HaTestMoney);
dsTextLineOut(hdc,97,310, szTempBuff, lstrlen(szTempBuff));
break;
case HASIEGE_DEFENSE: //๋ฐฉ์ด ์ค์
int LinePosX = 0;
int Linelen = 0;
int LineSetX = 0;
/*----ํด๋์คํฌ ์ ๋ณด๋ฅผ ๋ณด์ฌ์ฃผ๋ค.--------*/
SelectObject( hdc, sinBoldFont);
SetBkMode( hdc, TRANSPARENT );
SetTextColor( hdc, RGB(255,200,100) );
//ํ์ฌ์ ์์ด์ฝ์ธ๋ฑ์ค์ ํด๋นํ๋ ์คํฌ ์ ๋ณด๋ฅผ ๋ณด์ฌ์ค๋ค.
if(TowerIconIndex>3){
for( i=0;i<160;i++){
if(sSkill_Info[i].CODE == CLANSKILL_ABSORB && TowerIconIndex-3== 1){
TempCount=i;
break;
}
if(sSkill_Info[i].CODE == CLANSKILL_ATTACK && TowerIconIndex-3== 2){
TempCount=i;
break;
}
if(sSkill_Info[i].CODE == CLANSKILL_EVASION && TowerIconIndex-3== 3){
TempCount=i;
break;
}
}
//์คํฌ์ ์ด๋ฆ์ ๋ณด์ฌ์ค๋ค.
wsprintf(szTempBuff,sSkill_Info[TempCount].SkillName);
LineSetX = 4;
Linelen = lstrlen(szTempBuff);
LinePosX = (ClanSkillBoxSize.x*16-(Linelen*8))/2;
LineSetX+=Linelen/8*5;
dsTextLineOut(hdc,ClanSkillBoxPosi.x+LineSetX+LinePosX ,ClanSkillBoxPosi.y+20, szTempBuff, lstrlen(szTempBuff));
SelectObject( hdc, sinFont);
SetTextColor( hdc, RGB(250,250,250) );
Skilllen = lstrlen(sSkill_Info[TempCount].SkillDoc);
lstrcpy(haTempBuffer,sSkill_Info[TempCount].SkillDoc);
//๋์ด์ฐ๊ธฐ ๋ผ์๋ ๋ฌธ์์ด์ ์๋ฅธ๋ค.
for(cnt=0;cnt<Skilllen;cnt++){
if(cnt1*stringcut+stringcut > cnt)continue;
if(haTempBuffer[cnt] == ' ' ){
if(LineCount[cnt1]-cnt)
LineCount[cnt1++]=cnt+1;
}
}
//๋ง์ง๋ง์ ์ ์ฒด๊ฐ์ ๋ฃ์ด์ค๋ค.
LineCount[cnt1++]=Skilllen;
//์๋ฅธ๋ฌธ์์ด๋งํผ ๋ณด์ฌ์ค๋ค.
for(j=0;j<cnt1+1;j++){
//๋ค์ ์ด๊ธฐํ ํด์ค๋ค.
memset(TempBuffer,0,sizeof(TempBuffer));
for(i=0;cnt2<LineCount[j*1];i++,cnt2++){
TempBuffer[i]=haTempBuffer[cnt2];
}
//ํด๋น๋ผ๋ ํด๋์คํฌ์ ๋ณด์ฌ์ค๋ค.
lstrcpy(szTempBuff,TempBuffer);
Linelen = lstrlen(szTempBuff);
LineSetX=0;
LineSetX+=Linelen/4*5;
LinePosX = (ClanSkillBoxSize.x*16-(Linelen*8))/2;
dsTextLineOut(hdc,ClanSkillBoxPosi.x+LineSetX+LinePosX,ClanSkillBoxPosi.y+40+j*18, szTempBuff, lstrlen(szTempBuff));
}
}
//ํ์์ค์ /์ฉ๋ณ ์ค์ ์ ๋ณด์ฌ์ฃผ๋ค.
memset(TempBuffer,0,sizeof(TempBuffer));
if(TowerIconIndex>0){
cSinSiege.MercenaryNumDraw = cSinSiege.MercenaryNum[TowerIconIndex-1];
for(i=0;i<5;i++){
switch(TowerIconIndex){ //ํ์ฌ ํ์/์ฉ๋ณ ์ข
๋ฅ
case 1:
if(haSiegeMerFlag){
if(i==3){
wsprintf(szTempBuff,SiegeMessage_MercenrayA[i],cSinSiege.MercenaryNumDraw);
}
else
lstrcpy(szTempBuff,SiegeMessage_MercenrayA[i]);
}
else{
if(i>3)break;
lstrcpy(szTempBuff,SiegeMessage_TowerIce[i]);
}
break;
case 2:
if(haSiegeMerFlag){
if(i==3){
wsprintf(szTempBuff,SiegeMessage_MercenrayB[i],cSinSiege.MercenaryNumDraw);
}
else
lstrcpy(szTempBuff,SiegeMessage_MercenrayB[i]);
}
else{
if(i>3)break;
lstrcpy(szTempBuff,SiegeMessage_TowerLighting[i]);
}
break;
case 3:
if(haSiegeMerFlag){
if(i==3){
wsprintf(szTempBuff,SiegeMessage_MercenrayC[i],cSinSiege.MercenaryNumDraw);
}
else
lstrcpy(szTempBuff,SiegeMessage_MercenrayC[i]);
}
else{
if(i>3)break;
lstrcpy(szTempBuff,SiegeMessage_TowerFire[i]);
}
break;
}
//ํ์ฌ์ฑ์ ์ข
๋ฅ๋ฅผ ์ป์ด์จ๋ค.
int TempIndex=0;
int TempIconIndex[3]={0};
for(int k=0;k<6;k++){
if(cSinSiege.TowerTypeDraw[k][0]){
TempIndex = cSinSiege.TowerTypeDraw[k][0];
break;
}
}
if(TowerIconIndex){
if(cSinSiege.MercenaryNum[TowerIconIndex-1]){
TempIconIndex[TowerIconIndex-1]=cSinSiege.MercenaryNum[TowerIconIndex-1];
}
}
SelectObject( hdc, sinBoldFont);
LineSetX = 4;
Linelen = lstrlen(szTempBuff);
LinePosX = (ClanSkillBoxSize.x*16-(Linelen*8))/2;
LineSetX+= Linelen/8*5;
//ํ
์คํธ ํ์
if(i==0){ //์ด๋ฆ
SetTextColor( hdc, RGB(100,100,200));
}
else if(i==3 && cSinSiege.TowerTypeDraw[TempIndex-1][1]==TowerIconIndex && !haSiegeMerFlag){ //ํ์์ค์
SetTextColor( hdc, RGB(200,200,100));
}
else if(i==4 && haSiegeMerFlag && cSinSiege.MercenaryNumDraw == 20){
SetTextColor( hdc, RGB(200,200,100));
}
else{ //๊ธฐ๋ณธ
SelectObject( hdc, sinFont);
SetTextColor( hdc, RGB(250,250,250));
Linelen = lstrlen(szTempBuff);
LineSetX=-4;
LineSetX+=Linelen/4*5;
LinePosX = (ClanSkillBoxSize.x*16-(Linelen*8))/2;
}
char TempBuff[32];
memset(&TempBuff,0,sizeof(TempBuff));
switch(i){
case 0: //์ด๋ฆ
dsTextLineOut(hdc,ClanSkillBoxPosi.x+LineSetX+LinePosX ,ClanSkillBoxPosi.y+14, szTempBuff, lstrlen(szTempBuff));
break;
case 1:
case 2: //๋ด์ฉ
case 3:
if(cSinSiege.TowerTypeDraw[TempIndex-1][1]==TowerIconIndex && !haSiegeMerFlag){
dsTextLineOut(hdc,ClanSkillBoxPosi.x+LineSetX+LinePosX,ClanSkillBoxPosi.y+20+i*18, szTempBuff, lstrlen(szTempBuff));
}
if(cSinSiege.TowerTypeDraw[TempIndex-1][1]==0 && !haSiegeMerFlag && i==3 && TowerIconIndex<4){
lstrcpy(szTempBuff,SiegeMessage_TowerMoney);
NumLineComa(haTowerMoney,TempBuff);
lstrcat(szTempBuff,TempBuff);
lstrcat(szTempBuff,Won);
Linelen = lstrlen(szTempBuff);
LineSetX=-4;
LineSetX+=Linelen/4*5;
LinePosX = (ClanSkillBoxSize.x*16-(Linelen*8))/2;
dsTextLineOut(hdc,ClanSkillBoxPosi.x+LineSetX+LinePosX,ClanSkillBoxPosi.y+20+i*18, szTempBuff, lstrlen(szTempBuff));
}
if(i==3&&haSiegeMerFlag){
dsTextLineOut(hdc,ClanSkillBoxPosi.x+LineSetX+LinePosX,ClanSkillBoxPosi.y+20+i*18, szTempBuff, lstrlen(szTempBuff));
}
else{
dsTextLineOut(hdc,ClanSkillBoxPosi.x+LineSetX+LinePosX,ClanSkillBoxPosi.y+20+i*18, szTempBuff, lstrlen(szTempBuff));
}
break;
case 4:
if(!haSiegeMerFlag || TowerIconIndex >3) break;
//์ฉ๋ณ ๊ฐ๊ฒฉ ํ์
if(haSiegeMerFlag && cSinSiege.MercenaryNumDraw < 20){
lstrcpy(szTempBuff,SiegeMessage_MerMoney);
NumLineComa(haMercenrayMoney[TowerIconIndex-1],TempBuff);
lstrcat(szTempBuff,TempBuff);
lstrcat(szTempBuff,Won);
}
else{
lstrcpy(szTempBuff,SiegeMessage_MerComplete); //์ฉ๋ณ์ค์ ์๋ฃ
}
Linelen = lstrlen(szTempBuff);
LineSetX=-4;
LineSetX+=Linelen/4*5;
LinePosX = (ClanSkillBoxSize.x*16-(Linelen*8))/2;
dsTextLineOut(hdc,ClanSkillBoxPosi.x+LineSetX+LinePosX,ClanSkillBoxPosi.y+20+i*18, szTempBuff, lstrlen(szTempBuff));
break;
}
}
}//if(TowerIconIndex>0){ ์ข
๋ฃ
break;
}//haSiegeMenuKind
}//haSiegeMenuFlag
//==================================================================//
// ๊ณต์ฑ์ ๋ณด๋ ์ค์
//==================================================================//
//๊ณต์ฑ์ ๋ณด๋์ ๋ฐ์ดํ๋ฅผ ๋ณด์ฌ์ค๋ค.
if(haSiegeBoardFlag){
SelectObject( hdc, sinBoldFont);
for(int i=0;i<5 ;i++){
if(sHaClanData[i].Flag ){
if(sHaClanData[i].ClanInfoNum >=0){
if(sinChar->ClassClan == sHaClanData[i].CLANCODE){
SetTextColor( hdc, RGB(200,200,0));
}
else{
SetTextColor( hdc, RGB(200,128,0));
}
lstrcpy(szTempBuff,sHaClanData[i].ClanName);
dsTextLineOut(hdc,WinSizeX/2+40,32+i*17,szTempBuff, lstrlen(szTempBuff));
}
}
}
}
//==================================================================//
// ๊ณต์ฑ์ ๋์์ ํ๋ ์ด๋ฅผ ๋ณด์ฌ์ค๋ค.
//==================================================================//
if(haMovieFlag){
SelectObject( hdc, sinBoldFont);
SetTextColor( hdc, RGB(255,255,255));
dsTextLineOut(hdc,152,80,haMovieName, lstrlen(haMovieName));
}
lpDDSBack->ReleaseDC( hdc );
}
/*----------------------------------------------------------------------------*
* Class cSINSIEGE
*-----------------------------------------------------------------------------*/
int cSINSIEGE::GetTaxRate()
{
return TaxRate;
}
int cSINSIEGE::SetTaxRate(int TempTaxRate)
{
TaxRate = TempTaxRate;
return TRUE;
}
int cSINSIEGE::GetTotalTax()
{
//์๋ฒ์ ํด๋๋จธ๋๊ธ์ก ์ ๋ณด๋ฅผ ์๊ตฌํ๋ค
//TotalTax = getSiegeClanMoneyToServer(0,0); ๋๋ต
return TotalTax;
}
int cSINSIEGE::GetTaxMoney(int Money )
{
//์ฐพ๊ณ ์ถ์ ๋งํผ์ ๋์ ์๊ตฌํ๋ค
return TRUE;
}
/*----------------------------------------------------------------------------*
* ๊ณต์ฑ์ ๋์์ ํ๋ ์ด๋ฅผ ๋ณด์ฌ์ค๋ค.
*-----------------------------------------------------------------------------*/
int cHASIEGE::ShowCastlePlayMovie(char *szPath,char *TitleName,int Option)
{
memset(haMovieName ,0,sizeof(haMovieName));
lstrcpy(haMovieName,TitleName);
haMovieFlag = 1; //ํ๋์ ์ด์ด์ค๋ค.
if(haMovieFlag){
Play_ParkPlayer( szPath ,42,100, 307,260 ,150);
}
return TRUE;
}
| [
"cainankk@outlook.com"
] | cainankk@outlook.com |
34b7d5f9d3a973dc39e0686fc64f1fbf1e033850 | 9ed70c97db0f8c7c5b28dc80da19e3101186d573 | /goggles/goggles.ino | 290bb1fca0030e8c17bc5c47ab7eed96c61181fc | [] | no_license | adgedenkers/arduino | c832bb0478cd43fd348daefc0f873d8df06d9c74 | 7a7ace2e9a293559f258dfbd8d8c99867ec13a14 | refs/heads/master | 2021-06-09T09:37:51.880555 | 2021-05-04T23:56:58 | 2021-05-04T23:56:58 | 157,988,204 | 0 | 0 | null | null | null | null | UTF-8 | C++ | false | false | 1,659 | ino | // Low power NeoPixel goggles example. Makes a nice blinky display // with just a few LEDs on at any time.
#include <Adafruit_NeoPixel.h>
#ifdef __AVR_ATtiny85__ // Trinket, Gemma, etc.
#include <avr/power.h> #endif
#define PIN 0
Adafruit_NeoPixel pixels = Adafruit_NeoPixel(32, PIN);
uint8_t mode = 0; // Current animation effect
offset = 0; // Position of spinny eyes
uint32_t color = 0xFF0000; // Start red
uint32_t prevTime;
void setup() {
#ifdef __AVR_ATtiny85__ // Trinket, Gemma, etc.
if(F_CPU == 16000000) clock_prescale_set(clock_div_1); #endif
pixels.begin();
pixels.setBrightness(85); // 1/3 brightness prevTime = millis();
}
void loop() {
uint8_t i;
uint32_t t;
switch(mode) {
case 0: // Random sparks - just one LED on at a time! i = random(32);
pixels.setPixelColor(i, color);
pixels.show();
delay(10);
pixels.setPixelColor(i, 0);
break;
case 1: // Spinny wheels (8 LEDs on at a time)
for(i=0; i<16; i++) {
uint32_t c = 0;
if(((offset + i) & 7) < 2) {
c = color; // 4 pixels on...
pixels.setPixelColor( i, c); // First eye
pixels.setPixelColor(31-i, c); // Second eye (flipped)
}
}
pixels.show();
offset++;
delay(50);
break;
}
t = millis();
if((t - prevTime) > 8000) {
// Every 8 seconds... // Next mode
// End of modes?
// Start modes over // Next color R->G->B // Reset to red
mode++;
if(mode > 1) {
mode = 0;
color >>= 8;
if(!color) color = 0xFF0000;
}
for(i=0; i<32; i++) {
pixels.setPixelColor(i, 0);
prevTime = t;
}
}
| [
"adge.denkers@gmail.com"
] | adge.denkers@gmail.com |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.