当前位置: 首页>>代码示例>>C++>>正文


C++ Int32函数代码示例

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


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

示例1: Inherited

StageDataBase::StageDataBase(void) :
    Inherited(),
    _sfPartitionRangeBegin    (Int32(-1)),
    _sfPartitionRangeEnd      (Int32(-1)),
    _sfGroupMode              (Int32(0))
{
}
开发者ID:baibaiwei,项目名称:OpenSGDevMaster,代码行数:7,代码来源:OSGStageDataBase.cpp

示例2: returnValue

Vec2f CSMNativeWindow::translateToScreenCoordinatesAbs(Real32 rX,
                                                       Real32 rY)
{
    Vec2f returnValue(0, 0);

    X11Window qChild = 0;

    Int32    qW     = 0;
    Int32    qH     = 0;

    XTranslateCoordinates( _pDisplay, 
                           _pXWindow->getWindow(), 
                           _pRootWindow, 
                          
                            Int32(rX), 
                            Int32(rY), 
                          
                          & qW, 
                          & qH, 
                          
                          & qChild);

    returnValue.setValues(qW, qH);

    return returnValue;
}
开发者ID:jondo2010,项目名称:OpenSG,代码行数:26,代码来源:OSGCSMNativeWindow.cpp

示例3: Int32

hsIntRect *hsRect::Truncate(hsIntRect* r) const
{
	r->fLeft		= Int32(fLeft);
	r->fTop		= Int32(fTop);
	r->fRight		= Int32(fRight);
	r->fBottom	= Int32(fBottom);
	return r;
}
开发者ID:fatman2021,项目名称:myforthprocessor,代码行数:8,代码来源:hsRectangle.cpp

示例4: rand

		void MinusLife::onApply(Player& player, World& world, Int32 duration) const
		{
			Int32 hit = (Int32(D6_MAX_LIFE) / 7) + rand() % (Int32(D6_MAX_LIFE) / 2);
			if (player.hit(Float32(hit)))
			{
				player.playSound(PlayerSounds::Type::WasKilled);
			}
			world.getMessageQueue().add(player, Format("Life -{0}") << hit);
		}
开发者ID:martin-macak,项目名称:duel6r,代码行数:9,代码来源:MinusLife.cpp

示例5: Inherited

PostShaderStageDataBase::PostShaderStageDataBase(void) :
    Inherited(),
    _mfShaderMaterials        (),
    _sfWidth                  (Int32(0)),
    _sfHeight                 (Int32(0)),
    _mfRenderTargets          (),
    _sfCamera                 (NULL)
{
}
开发者ID:marcusl,项目名称:OpenSG,代码行数:9,代码来源:OSGPostShaderStageDataBase.cpp

示例6: Inherited

TextureImageChunkBase::TextureImageChunkBase(void) :
    Inherited(),
    _sfTexture                (NULL),
    _sfLevel                  (Int32(0)),
    _sfLayer                  (Int32(-1)),
    _sfAccess                 (GLenum(GL_READ_ONLY)),
    _sfFormat                 (GLenum(GL_NONE))
{
}
开发者ID:vossg,项目名称:OpenSGDevMaster,代码行数:9,代码来源:OSGTextureImageChunkBase.cpp

示例7: Inherited

FogStageDataBase::FogStageDataBase(void) :
    Inherited(),
    _sfFogMaterial            (NULL),
    _sfWidth                  (Int32(0)),
    _sfHeight                 (Int32(0)),
    _sfRenderTarget           (NULL),
    _sfCamera                 (NULL)
{
}
开发者ID:Himbeertoni,项目名称:OpenSGDevMaster,代码行数:9,代码来源:OSGFogStageDataBase.cpp

示例8: VAL_SERIES

*/	REBINT PD_String(REBPVS *pvs)
/*
***********************************************************************/
{
	REBVAL *data = pvs->value;
	REBVAL *val = pvs->setval;
	REBINT n = 0;
	REBCNT i;
	REBINT c;
	REBSER *ser = VAL_SERIES(data);

	if (IS_INTEGER(pvs->select)) {
		n = Int32(pvs->select) + VAL_INDEX(data) - 1;
	}
	else return PE_BAD_SELECT;

	if (val == 0) {
		if (n < 0 || (REBCNT)n >= SERIES_TAIL(ser)) return PE_NONE;
		if (IS_BINARY(data)) {
			SET_INTEGER(pvs->store, *BIN_SKIP(ser, n));
		} else {
			SET_CHAR(pvs->store, GET_ANY_CHAR(ser, n));
		}
		return PE_USE;
	}

	if (n < 0 || (REBCNT)n >= SERIES_TAIL(ser)) return PE_BAD_RANGE;

	if (IS_CHAR(val)) {
		c = VAL_CHAR(val);
		if (c > MAX_CHAR) return PE_BAD_SET;
	}
	else if (IS_INTEGER(val)) {
		c = Int32(val);
		if (c > MAX_CHAR || c < 0) return PE_BAD_SET;
		if (IS_BINARY(data)) { // special case for binary
			if (c > 0xff) Trap_Range(val);
			BIN_HEAD(ser)[n] = (REBYTE)c;
			return PE_OK;
		}
	}
	else if (ANY_BINSTR(val)) {
		i = VAL_INDEX(val);
		if (i >= VAL_TAIL(val)) return PE_BAD_SET;
		c = GET_ANY_CHAR(VAL_SERIES(val), i);
	}
	else
		return PE_BAD_SELECT;

	TRAP_PROTECT(ser);

	if (BYTE_SIZE(ser) && c > 0xff) Widen_String(ser);
	SET_ANY_CHAR(ser, n, c);

	return PE_OK;
}
开发者ID:RamchandraApte,项目名称:rebol,代码行数:56,代码来源:t-string.c

示例9: Inherited

ShadowMapEngineBase::ShadowMapEngineBase(void) :
    Inherited(),
    _sfShadowTexChunk         (NULL),
    _sfWidth                  (Int32(512)),
    _sfHeight                 (Int32(512)),
    _sfOffsetBias             (Real32(4.f)),
    _sfOffsetFactor           (Real32(10.f)),
    _sfShadowTravMask         (UInt32(TypeTraits<UInt32>::BitsSet))
{
}
开发者ID:marcusl,项目名称:OpenSG,代码行数:10,代码来源:OSGShadowMapEngineBase.cpp

示例10: Inherited

DisplayFilterGroupBase::DisplayFilterGroupBase(void) :
    Inherited(),
    _sfCalibrationPatternFilter(NULL),
    _sfResolutionFilter       (NULL),
    _sfColorFilter            (NULL),
    _sfDistortionFilter       (NULL),
    _sfDrawerId               (Int32(-1)),
    _sfDrawableId             (Int32(-1))
{
}
开发者ID:Himbeertoni,项目名称:OpenSGDevMaster,代码行数:10,代码来源:OSGDisplayFilterGroupBase.cpp

示例11: Inherited

MultiDisplayWindowBase::MultiDisplayWindowBase(void) :
    Inherited(),
    _sfHServers               (),
    _sfVServers               (),
    _sfManageClientViewports  (bool(true)),
    _sfXOverlap               (Int32(0)),
    _sfYOverlap               (Int32(0)),
    _sfMaxDepth               (Int32(999))
{
}
开发者ID:DaveHarrison,项目名称:OpenSGDevMaster,代码行数:10,代码来源:OSGMultiDisplayWindowBase.cpp

示例12: Int32

Int32 FBOViewport::getPixelBottom(void) const
{
    if(getBottom() > 1)
        return Int32(getBottom());
    
    if(getFrameBufferObject() == NULL)
        return Int32(getBottom());

    return Int32(getFrameBufferObject()->getHeight() * getBottom());
}
开发者ID:DaveHarrison,项目名称:OpenSGDevMaster,代码行数:10,代码来源:OSGFBOViewport.cpp

示例13: verifySignature

//////////////////////////////////////////////////////////////////////////////
// STATIC
void
verifySignature(std::streambuf & istrm, UInt8 validSig)
{
	UInt8 val;
	read(istrm, val);
	if (val != validSig)
	{
		BLOCXX_THROW(BadSignatureException,
			Format("Received invalid signature. Got: %1 Expected: %2", Int32(val),
				Int32(validSig)).c_str());
	}
}
开发者ID:camsoupa,项目名称:redneckracer,代码行数:14,代码来源:BinarySerialization.cpp

示例14: Inherited

StencilChunkBase::StencilChunkBase(void) :
    Inherited(),
    _sfStencilFunc            (GLenum(GL_NONE)),
    _sfStencilValue           (Int32(0)),
    _sfStencilMask            (UInt32(0x1)),
    _sfStencilOpFail          (GLenum(GL_KEEP)),
    _sfStencilOpZFail         (GLenum(GL_KEEP)),
    _sfStencilOpZPass         (GLenum(GL_KEEP)),
    _sfClearBuffer            (Int32(0)),
    _sfBitMask                (UInt32(0xFFFFFFFF))
{
}
开发者ID:Himbeertoni,项目名称:OpenSGDevMaster,代码行数:12,代码来源:OSGStencilChunkBase.cpp

示例15: getQuadtreeDepth

Int32 getQuadtreeDepth(Int32 iSamplesX, Int32 iSamplesY, Int32 iTileSize)
{
#ifdef WIN32
    return Int32(log(Real32(getQuadtreeLeafNodeCount(iSamplesX, 
                                                     iSamplesY, 
                                                     iTileSize)))/log(2.f) +
                 1.f);
#else
    return Int32(log2(Real32(getQuadtreeLeafNodeCount(iSamplesX, 
                                                      iSamplesY, 
                                                      iTileSize))) + 1.f);
#endif
}
开发者ID:chengzg,项目名称:OSGAddOnsGV,代码行数:13,代码来源:OSGBbqNode.cpp


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