您当前的位置:首页 > IT编程 > C++
| C语言 | Java | VB | VC | python | Android | TensorFlow | C++ | oracle | 学术与代码 | cnn卷积神经网络 | gnn | 图像修复 | Keras | 数据集 | Neo4j | 自然语言处理 | 深度学习 | 医学CAD | 医学影像 | 超参数 | pointnet | pytorch | 异常检测 | Transformers | 情感分类 | 知识图谱 |

自学教程:C++ DOUT函数代码示例

51自学网 2021-06-01 20:23:15
  C++
这篇教程C++ DOUT函数代码示例写得很实用,希望能帮到您。

本文整理汇总了C++中DOUT函数的典型用法代码示例。如果您正苦于以下问题:C++ DOUT函数的具体用法?C++ DOUT怎么用?C++ DOUT使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。

在下文中一共展示了DOUT函数的26个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。

示例1: PAGED_CODE

/***************************************************************************** * AddDevice ***************************************************************************** * This function is called by the operating system when the device is added. * All adapter drivers can use this code without change. */NTSTATUS AddDevice(    IN PDRIVER_OBJECT   DriverObject,    IN PDEVICE_OBJECT   PhysicalDeviceObject){    PAGED_CODE ();    DOUT (DBG_PRINT, ("[AddDevice]"));    // disable prefast warning 28152 because     // DO_DEVICE_INITIALIZING is cleared in PcAddAdapterDevice#pragma warning(disable:28152)#ifdef XEN    NTSTATUS ntStatus = XenInitialize(PhysicalDeviceObject);    if (!NT_SUCCESS (ntStatus))        return ntStatus;#endif    //    // Tell portcls (the class driver) to add the device.    //    return PcAddAdapterDevice (DriverObject,                               PhysicalDeviceObject,                               (PCPFNSTARTDEVICE)StartDevice,                               MAX_MINIPORTS,                               0);}
开发者ID:OpenXT,项目名称:xc-windows,代码行数:35,


示例2: _logTree

void Layer::logTree(){  u32 depth = 0;  _numLayers = 0;  _logTree(depth, this);  DOUT("num layers:"<<_numLayers);}
开发者ID:jomanto,项目名称:le2,代码行数:7,


示例3: assert

struct cos_cbuf_item *free_mem_in_local_cache(struct spd_tmem_info *sti){	spdid_t s_spdid;	struct cos_cbuf_item *cci = NULL, *list;	assert(sti);	s_spdid = sti->spdid;	DOUT("/n Check if in local cache!!!");	list = &spd_tmem_info_list[s_spdid].tmem_list;	/* Go through the allocated cbufs, and see if any are not in use... */	for (cci = FIRST_LIST(list, next, prev) ; 	     cci != list; 	     cci = FIRST_LIST(cci, next, prev)) {		union cbuf_meta cm;		cm.c_0.v = cci->entry->c_0.v;		if (!CBUF_IN_USE(cm.c.flags)) goto done;	}	if (cci == list) goto err;done:	/* DOUT("/n hehe found one!!/n/n"); */	return cci;err:	/* DOUT("/n can not found one!!/n"); */	cci = NULL;		return cci;}
开发者ID:asweeney86,项目名称:Composite,代码行数:28,


示例4: mgr_map_client_mem

//  all cbufs that created for this componentvoid mgr_map_client_mem(struct cos_cbuf_item *cci, struct spd_tmem_info *sti){	char *l_addr, *d_addr;	spdid_t d_spdid;//	struct cb_desc *d;	assert(sti && cci);	assert(EMPTY_LIST(cci, next, prev));	d_spdid = sti->spdid;	/* TODO: multiple pages cbuf! */	d_addr = valloc_alloc(cos_spd_id(), sti->spdid, 1);	l_addr = cci->desc.addr;  //initialized in cos_init()	assert(d_addr && l_addr); 	/* ...map it into the requesting component */	if (unlikely(!mman_alias_page(cos_spd_id(), (vaddr_t)l_addr, d_spdid, (vaddr_t)d_addr))) 		goto err;	/* DOUT("<<<MAPPED>>> mgr addr %p client addr %p/n ",l_addr, d_addr); */	cci->desc.owner.addr = (vaddr_t)d_addr;	cci->parent_spdid = d_spdid;	assert(cci->desc.cbid == 0);	// add the cbuf to shared vect here? now we do it in the client.	// and l_addr and d_addr has been assingeddone:	return;err:	DOUT("Cbuf mgr: Cannot alias page to client!/n");	mman_release_page(cos_spd_id(), (vaddr_t)l_addr, 0);	/* valloc_free(cos_spd_id(), cos_spd_id(), l_addr, 1); */	valloc_free(cos_spd_id(), d_spdid, (void *)d_addr, 1);	goto done;}
开发者ID:asweeney86,项目名称:Composite,代码行数:36,


示例5: mgr_remove_client_mem

static voidmgr_remove_client_mem(struct spd_tmem_info *sti, struct cos_cbuf_item *cci){	__cbuf_c_delete(sti, cci->desc.cbid, &cci->desc);	/* DOUT("after buf del before map del/n"); */	cos_map_del(&cb_ids, cci->desc.cbid);	DOUT("fly..........cbid is %d/n", cci->desc.cbid);	cci->desc.cbid = 0;	cci->parent_spdid = 0;	// Clear our memory to prevent leakage	memset(cci->desc.addr, 0, PAGE_SIZE);	/* printc("Removing from local list/n"); */	REM_LIST(cci, next, prev);	/* TODO: move all of this into the tmem generic code just like the ++s */	sti->num_allocated--;	if (sti->num_allocated == 0) empty_comps++;	if (sti->num_allocated >= sti->num_desired) over_quota_total--;	assert(sti->num_allocated == tmem_num_alloc_tmems(sti->spdid));}
开发者ID:asweeney86,项目名称:Composite,代码行数:25,


示例6: kvar_print_vars

void kvar_print_vars(kvar_storage_ptr store){    DOUT("kvar_print_vars: dumping all variables/n");    int index,index2;    kvar_array_ptr arr;    for (index = 0; index < MAX_VARS; index++)    {        if (store->vars[index].content != NULL)        {            switch (store->vars[index].content->type)            {                case kvar_type_number:                    {                        printf("%s: %d/n", store->vars[index].name, store->vars[index].content->number);                    } break;                case kvar_type_array:                    {                        printf("%s: [", store->vars[index].name);                        arr = store->vars[index].content->array;                        for (index2 = 0; index2 < arr->length-1; index2++)                        {                            printf("%d,", arr->array[index2]);                        }                        printf("%d]/n", arr->array[index2]);                    } break;            }         }    }}
开发者ID:aljoscha,项目名称:kalt,代码行数:29,


示例7: shmalloc

stat_tSelfHealingSessionServer::HandleConnect(const L4_ThreadId_t& tid, L4_Msg_t& msg){    ENTER;    L4_Word_t   reg[2];    addr_t      shm = shmalloc(Session::DEFAULT_SHM_PAGES);    DOUT("shm allocate @ %.8lX/n", shm);    if (shm == 0) {        return ERR_OUT_OF_MEMORY;    }    //TODO: Hack: Related to a problem in PersistentPageAllocator.cpp    for (UInt i = 0; i < Session::DEFAULT_SHM_PAGES; i++) {        Pager.Release(shm + i * PAGE_SIZE);    }    for (UInt i = 0; i < Session::DEFAULT_SHM_PAGES; i++) {        Pager.Reserve(shm + i * PAGE_SIZE, tid, L4_ReadWriteOnly);    }    reg[0] = shm;    reg[1] = Session::DEFAULT_SHM_PAGES;    L4_Put(&msg, 0, 2, reg, 0, 0);    Register(tid, reg[0], reg[1]);    EXIT;    return ERR_NONE;}
开发者ID:hro424,项目名称:arcos,代码行数:30,


示例8: GetOurParentWindow

/*! * /return The HWND of the main application window, if it can be identified. *      Otherwise NULL is returned. */HWND GetOurParentWindow(void){    //! Silly nested class so that we can define a local function.    class foo {        foo() {};    public:        static BOOL CALLBACK GOPWEnumWindowsProc(                HWND hwnd,      //!< handle to parent window                LPARAM lParam   //!< application-defined value        )        {            char szClassName[64];            if ( GetClassName(hwnd, szClassName, sizeof(szClassName)) &&                (strcmp(szClassName, "mIRC32") == 0 || strcmp(szClassName, "mIRC") == 0)                )            {                DWORD windowpid;                GetWindowThreadProcessId(hwnd, &windowpid);                if (windowpid == GetCurrentProcessId()) {                    // Found the window that is from our process.                    *reinterpret_cast<HWND*>(lParam) = hwnd;                    return FALSE;       // done enumerating.                }            }            return TRUE;        // continue enumerating.        }    };    // Actually do the enumeration call.    HWND hWnd = NULL;    EnumWindows(foo::GOPWEnumWindowsProc, (LPARAM) &hWnd);    DOUT(("GetOurParentWindow: found hwnd %p/n", hWnd));    return hWnd;}
开发者ID:bovine,项目名称:stuntour,代码行数:38,


示例9: DOUT

void EventSystem::logViewStack(const vector<View*>& vs){  for(auto v : vs)  {    DOUT("-> "<<v->name());  }}
开发者ID:jomanto,项目名称:le2,代码行数:7,


示例10: DOUT

// Cue//BOOL WaveFile::Cue (void){  BOOL fRtn = SUCCESS;    // assume success  DOUT ("WaveFile::Cue/n/r");  // Seek to 'data' chunk from beginning of file  if (mmioSeek (m_hmmio, m_mmckiRiff.dwDataOffset + sizeof(FOURCC), SEEK_SET) != -1)  {    // Descend into 'data' chunk    m_mmckiData.ckid = mmioFOURCC('d', 'a', 't', 'a');    if ((m_mmr = mmioDescend (m_hmmio, &m_mmckiData, &m_mmckiRiff, MMIO_FINDCHUNK)) == MMSYSERR_NOERROR)    {      // Reset byte counter      m_nBytesPlayed = 0;    }    else    {      // UNDONE: set m_mmr      fRtn = FALSE;    }  }  else  {    // mmioSeek error    m_mmr = MMIOERR_CANNOTSEEK;    fRtn = FALSE;  }  return fRtn;}
开发者ID:KerwinMa,项目名称:AerothFlyffSource,代码行数:33,


示例11: DOUT

//// This method binds the parameter to a specified value, updating the worklist// Binding a value updates any combination zeros it completes as a side effect// Binding a value also adds items to work list as a side effect//bool Parameter::Bind(int value, WorkList& worklist){    DOUT(L"Binding " << m_name << L" to value " << value << L"./n");    assert(!m_bound);    assert(value < m_valueCount);    m_result.push_back(value);    m_currentValue = value;    m_bound = true;    for( auto & combination : m_combinations )    {        if( combination->AddBinding() == combination->GetParameterCount() - 1 )        {            // Add any parameter that completes a combination to work list            for( int n = 0; n < combination->GetParameterCount(); ++n )            {                if( !( (*combination)[ n ] ).GetBoundCount() )                {                    worklist.AddItem( &( *combination )[ n ] );                }            }        }    }    worklist.Print();        return true;}
开发者ID:BCxTIM,项目名称:pict,代码行数:34,


示例12: _logTree

void View::logTree(){  u32 depth = 0;  _numViews = 0;  _logTree(depth, this);  DOUT("num view:"<<_numViews);}
开发者ID:lobotony,项目名称:le2,代码行数:7,


示例13: DOUT

    void Application::finalize()    {      DOUT("Application::finalize()");      XFree((void *) hiddenMembers->WM_WAKEUP);      XCloseDisplay(hiddenMembers->display);      delete hiddenMembers;    }
开发者ID:Wednesnight,项目名称:lostengine,代码行数:8,


示例14: DOUT

void Device::initWithDeviceId(const string& inDeviceId){  DOUT("opening device: "<<inDeviceId);  device = alcOpenDevice(inDeviceId.c_str());ALDEBUG_THROW;  if(!device)    THROW_RTE("aclOpenDevice returned NULL for id: "+inDeviceId);  deviceId = inDeviceId;}
开发者ID:Wednesnight,项目名称:lostengine,代码行数:8,


示例15: __declspec

//! Method exported to mIRC that can be invoked to subclass a specified //! window (by hwnd) and make its window frame blue.extern "C" int __declspec(dllexport) __stdcall blue_window(      HWND mWnd, HWND aWnd, char *data, char *parms, BOOL show, BOOL nopause){    DOUT(("mIRC callback for blue_window invoked/n"));    if (data != NULL) {		HWND hwnd = (HWND) LongToHandle(atoi(data));        bool bResult = BlueWindow::SubclassNewWindow(hwnd);        if (bResult) {            DOUT(("blue_window successfully subclassed new window %p/n", (void*) hwnd));        } else {            DOUT(("blue_window failed to subclass new window./n"));        }    }    return 1;       // mIRC should just continue executing.}
开发者ID:bovine,项目名称:stuntour,代码行数:19,


示例16: DOUT

void RemoteProxyHost::start(){   if (this->m_thread.is_running())   {      DOUT(this->dinfo() << "RemoteProxyHost already running on port: " << this->m_local_port);      return;   }   // We do the following because we want it done in the main thread, so exceptions during start are propagated through.   // In particular we want to ensure that we dont have 2 servers with the same port number.   this->dolog(this->dinfo() + std::string("opening connection on port: ") + mylib::to_string(this->m_local_port));   boost::asio::ip::tcp::endpoint ep(boost::asio::ip::tcp::v4(), this->m_local_port);   this->m_acceptor.open(ep.protocol());   this->m_acceptor.set_option(boost::asio::ip::tcp::acceptor::reuse_address(false));   this->m_acceptor.bind(ep);   DOUT(this->dinfo() << "Bind ok for " << ep);   this->m_thread.start( [this]{ this->threadproc(); } );}
开发者ID:pbondo,项目名称:uniproxy,代码行数:17,


示例17: sizeof

void InputEventSystem::run(const char* deviceName){  struct input_event ev[64];  int fd, rd, value, size = sizeof (struct input_event);  char name[256] = "Unknown";  if ((getuid ()) != 0)  {    DOUT("You are not root! This may not work...");  }  //Open Device  if ((fd = open (deviceName, O_RDONLY)) == -1)  {    DOUT(deviceName << "is not a vaild device.");    exit(1);  }  if(hasAbsolutEvents(fd))  {    DOUT("input device provides absolute events");  }  else  {    DOUT("input device does NOT provide absolute events");  }  getTouchBounds(fd);  DOUT("touch bounds: " << minX << " " << maxX << " " << minY << " " << maxY);  //Print Device Name  ioctl (fd, EVIOCGNAME (sizeof (name)), name);  DOUT ("Reading From : " << deviceName << "(" << name << ")");  DOUT("reading , elem size: " << size << " max buffer: " << size << " " << size*64);  while (1){      if ((rd = read (fd, &ev, size*64 )) < size)      {        DOUT("read()");        exit(0);      }      //printf("read bytes: %d elems: %d/n", rd, rd/size);      u32 num = rd/size;      parse(ev, num);/*      value = ev[0].value;      printf("../n");      for(int i=0; i<rd/size; ++i)      {        logEvent(&ev[i]);      }*//*      if (value != ' ' && ev.value == 1 && ev.type == 1){ // Only read the key press event       printf ("Code[%d]/n", (ev.code));      }*/  }  }
开发者ID:jomanto,项目名称:le2,代码行数:56,


示例18: DriverEntry

NTSTATUS DriverEntry (IN PDRIVER_OBJECT pDriverObject, IN PUNICODE_STRING pRegistryPathName){    PAGED_CODE ();        DOUT (DBG_PRINT, ("DriverEntry"));    return KsInitializeDriver (pDriverObject, pRegistryPathName, &DeviceDescriptor);}
开发者ID:kcrazy,项目名称:winekit,代码行数:8,


示例19: FT_Done_FreeType

Library::~Library(){  FT_Error error = FT_Done_FreeType(library);  // don't throw, just log  if(error)  {    DOUT("FT_Done_FreeType error: "<< error);  }}
开发者ID:Wednesnight,项目名称:lostengine,代码行数:9,


示例20: kvar_dispose_storage

void kvar_dispose_storage(kvar_storage_ptr store){    DOUT("kvar_dispose_storage: disposing kvar storage/n");    int index;    for (index = 0; index < MAX_VARS; index++)    {       kvar_delete(store, store->vars[index].name);    }    free(store);}
开发者ID:aljoscha,项目名称:kalt,代码行数:10,


示例21: _logTree

void _logTree(u32 depth, Layer* current){  string spaces;  _numLayers++;  for(u32 i=0; i<depth;++i) { spaces += "-";}  DOUT(spaces << current->name);  for(auto layer : current->sublayers)  {    _logTree(depth+1, layer.get());  }}
开发者ID:lobotony,项目名称:le2,代码行数:11,


示例22: ServerSocket

voidAORB::_initServer(){  if (_serverSocket != Nil)    return;  if (_serverHost == Nil)    _serverHost = AORB::getLocalHost();  _serverSocket = new ServerSocket(_port, 30, acdk::net::InetAddress::getByName(_serverHost));  _port = _serverSocket->getLocalPort();  DOUT("AORB::_initServer: " << _serverSocket->toString()->c_str() << "; port=" << _port);}
开发者ID:huangyt,项目名称:foundations.github.com,代码行数:11,


示例23: DOUT

bool sspDSDeviceGroup::beginImpl(){	bool bRet = true;	for (unsigned int i=0; i<m_pDSBuf.size(); i++)  {		HRESULT nResult = m_pDSBuf[i]->Play (0, 0, DSBPLAY_LOOPING);		if (nResult != DS_OK) {			DOUT(_T("Error, play failed/n/r"));			bRet = false;		}	}	return bRet;}
开发者ID:ssaue,项目名称:soundspace,代码行数:12,


示例24: DOUT

Source::~Source(){	DOUT("");  source->stop();  if (vorbisFile) source->unqueue(vorbisFile->buffer);	shared_ptr<Engine> ng = engine.lock();	if(ng)	{		ng->destroySource(this);	}}
开发者ID:Wednesnight,项目名称:lostengine,代码行数:12,


示例25: get_cos_info_page

/** * maps the compoenents spdid info page on startup * I do it this way since not every component may require stacks or * what spdid's I even have access too. * I am not sure if this is the best way to handle this, but it  * should work for now. */static inline voidget_cos_info_page(spdid_t spdid){	spdid_t s;	int i;	int found = 0;	void *hp;	if(spdid > MAX_NUM_SPDS){		BUG(); 	}	for (i = 0; i < MAX_NUM_SPDS; i++) {		s = cinfo_get_spdid(i);		if(!s) { 			printc("Unable to map compoents cinfo page!/n");			BUG();		}            		if (s == spdid) {			found = 1;			break;		}	}     	if(!found){		DOUT("Could not find cinfo for spdid: %d/n", spdid);		BUG();	}    	hp = cos_get_vas_page();	if(cinfo_map(cos_spd_id(), (vaddr_t)hp, s)){		DOUT("Could not map cinfo page for %d/n", spdid);		BUG();	}	spd_stk_info_list[spdid].ci = hp;	DOUT("mapped -- id: %ld, hp:%x, sp:%x/n",	     spd_stk_info_list[spdid].ci->cos_this_spd_id, 	     (unsigned int)spd_stk_info_list[spdid].ci->cos_heap_ptr,	     (unsigned int)spd_stk_info_list[spdid].ci->cos_stacks.freelists[0].freelist);}
开发者ID:wittrock,项目名称:CompositeOS_Project,代码行数:47,


示例26: kvar_delete

void kvar_delete(kvar_storage_ptr store, char *name){    int index;    kvar_var_ptr var;    for (index = 0; index < MAX_VARS; index++)    {        if (store->vars[index].content != NULL && strcmp(store->vars[index].name, name) == 0)        {            var = store->vars[index].content;            switch (var->type)            {                case kvar_type_number:                    {                        DOUT("kvar_delete: deleting variable /""); DOUT(name); DOUT("/" of type number/n");                        free(var);                    } break;                case kvar_type_array:                    {                        DOUT("kvar_delete: deleting variable /""); DOUT(name); DOUT("/" of type array/n");                        free(var->array->array);                        free(var->array);                        free(var);                    } break;            }                         store->vars[index].content = NULL;            return;        }    }}
开发者ID:aljoscha,项目名称:kalt,代码行数:31,



注:本文中的DOUT函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


C++ DOWNCAST函数代码示例
C++ DOUBLE_TO_JSVAL函数代码示例
万事OK自学网:51自学网_软件自学网_CAD自学网自学excel、自学PS、自学CAD、自学C语言、自学css3实例,是一个通过网络自主学习工作技能的自学平台,网友喜欢的软件自学网站。