Home Database Mysql Tutorial 教你在vs2010下输出cocos2d

教你在vs2010下输出cocos2d

Jun 07, 2016 pm 03:30 PM
vs2010 xcode output

上次在xcode下,使用printf直接在调试窗口可以看到输出的信息,在vs2010中没有看到,于是查看了源代码,找到函数CCLog void CCLog(const char * pszFormat, ...){ char szBuf[MAX_LEN]; va_list ap; va_start(ap, pszFormat); vsnprintf_s(szBuf, MAX_LEN, M

上次在xcode下,使用printf直接在调试窗口可以看到输出的信息,在vs2010中没有看到,于是查看了源代码,找到函数CCLog

void CCLog(const char * pszFormat, ...)
{
    char szBuf[MAX_LEN];

    va_list ap;
    va_start(ap, pszFormat);
    vsnprintf_s(szBuf, MAX_LEN, MAX_LEN, pszFormat, ap);
    va_end(ap);

    WCHAR wszBuf[MAX_LEN] = {0};
    MultiByteToWideChar(CP_UTF8, 0, szBuf, -1, wszBuf, sizeof(wszBuf));
    OutputDebugStringW(wszBuf);
    OutputDebugStringA("\n");
}
Copy after login


看看它的实现吧。

使用CCLog代替printf后就可以在调试窗口看到输出信息。

在vs2010中 调试->输出,可以调出输出窗口。

Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
3 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. Best Graphic Settings
3 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. How to Fix Audio if You Can't Hear Anyone
3 weeks ago By 尊渡假赌尊渡假赌尊渡假赌

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

Recommended configuration for Mac app development using Xcode on Linux Recommended configuration for Mac app development using Xcode on Linux Jul 05, 2023 am 09:45 AM

Overview of recommended configurations for using Xcode on Linux for Mac application development. With the popularity of Mac computers, more and more developers choose to use Xcode for Mac application development. However, Xcode can only run on Mac operating system, which brings some troubles to Linux users. However, some developers hope to use Xcode on Linux for Mac application development. This article will introduce how to configure Xcode on Linux and provide some code examples for reference.

How to output text with line breaks in Go language How to output text with line breaks in Go language Mar 15, 2024 pm 04:15 PM

Go language is a modern, efficient and concise programming language that is widely used in software development in various fields. In the Go language, outputting text with newlines is very simple and can be achieved by using the Println function provided by the fmt package. Below we will introduce in detail how to output text with line breaks in Go language, as well as related code examples. In the Go language, if you want to output text with newlines, you can use the Println function provided by the fmt package. The Println function will output text in

What is the latest key for vs2010 What is the latest key for vs2010 Jul 10, 2023 am 11:09 AM

The latest keys for vs2010 are: 1. YCFHQ-9DWCY-DKV88-T2TMH-G7BHP; 2. YDK44-2WW9W-QV7PM-8P8G8-FTYDF; 3. PQT8W-68YB2-MPY6C-9JV9X-42WJV; 4. 6VPJ7-H3CXH-HBTPT- X4T74-3YVY7 etc.

What software is xcode What software is xcode Dec 08, 2020 pm 04:38 PM

Xcode is an integrated development tool that runs on the operating system Mac OS X. It is an integrated development environment (non-open source) provided by Apple to developers and is used to develop Mac OS X and iOS applications; The fastest way to program. Xcode has a unified user interface design, and coding, testing, and debugging are all completed in a simple window.

iPhone 14 Pro Always-On Display hint may be in Xcode 14 Beta iPhone 14 Pro Always-On Display hint may be in Xcode 14 Beta May 19, 2023 pm 01:56 PM

The upcoming iPhone 14 Pro models will use always-on display technology similar to Apple Watch, and the appearance of the always-on display may be hinted in the latest Xcode14 beta. The Xcode 14 beta has an interesting lock screen interface that removes the details of on-screen widgets when the screen wakes up. The animation shows that ‌iPhone 14 Pro‌ models can remove intricate details from widgets and other lock screen content when the iPhone is locked and the always-on display is active. Also noticed are signs of a black and white version of the widget that was normally in color in the Xcode14 beta, which may have something to do with the always-on display. The latest iOS16 beta also provides wallpapers

What is the vs2010 key? What is the vs2010 key? Jul 10, 2023 am 11:04 AM

The vs2010 keys are: 1. SDJFW-GSDLF-SLDKF-NFWSK-DFKGR; 2. DLKFG-SNGEG-LDFES-FLHNR-SKLJD; 3. PQT8W-68YB2-MPY6C-9JV9X-42WJV; 4. 6VPJ7-H3CXH-HBTPT-X4T74 -3YVY7 etc.

What to do if the output video of VideoStudio x10 is too large - How to solve the problem of too large output video of VideoStudio x10 What to do if the output video of VideoStudio x10 is too large - How to solve the problem of too large output video of VideoStudio x10 Mar 04, 2024 pm 05:04 PM

Many people are using the VideoStudio x10 software at work, but do you know what to do if the output video of the VideoStudio x10 is too large? Below, the editor will bring you the solution to the problem of the output video of the VideoStudio x10 being too large. Method, interested users can take a look below. First of all, you need 10 video codecs and X264 video templates for 64-bit VideoStudio x8 and x10. The method is feasible. When installing the x10 video codec, a prompt dialog box may appear, in which the path of the Chinese file may not match, but it does not affect normal use. Then, continue to click Next to complete the installation of the decoder, and then copy the Chinese version of the software to the corresponding place. There are detailed instructions in the Chinese version file, so I won’t go into details here. After successful installation, open x

Apple is developing a GitHub Copilot competitor: Xcode AI can help developers convert, debug, and generate code Apple is developing a GitHub Copilot competitor: Xcode AI can help developers convert, debug, and generate code Feb 16, 2024 am 09:30 AM

According to news on February 16, according to Bloomberg, Apple is developing an upgraded version of Xcode. The highlight is the integration of multiple AI functions, one of which can generate relevant code for developers. Reports say the artificial intelligence tool will be similar to Microsoft's GitHubCopilot, which can generate code based on natural language requests and convert code from one programming language to another. Note: GitHubCopilot is an artificial intelligence tool jointly developed by GitHub and OpenAI. Users can use VisualStudioCode, MicrosoftVisualStudio, Vim, Cursor or JetBrains integrated development environment through

See all articles