gl_Position - GLSL ES 3 - docs.gl

文章推薦指數: 80 %
投票人數:10人

The variable gl_Position is intended for writing the homogeneous vertex position. It can be written at any time during vertexshader execution. Light|Darkdocs.GLOpenGL2.1OpenGL3.0OpenGL3.1OpenGL3.2OpenGL3.3OpenGL4.0OpenGL4.1OpenGL4.2OpenGL4.3OpenGL4.4OpenGL4.5OpenGLES2.0OpenGLES3.0OpenGLES3.1GLSL4.0GLSL4.1GLSL4.2GLSL4.3GLSL4.4GLSL4.5GLSLES3.0GLSLES3.1HideunavailableTexturesglActiveTextureglBindImageTextureglBindImageTexturesglBindTextureglBindTextureUnitglBindTexturesglClearTexImageglClearTexSubImageglCompressedTexImage1DglCompressedTexImage2DglCompressedTexImage3DglCompressedTexSubImage1DglCompressedTexSubImage2DglCompressedTexSubImage3DglCopyImageSubDataglCopyTexImage1DglCopyTexImage2DglCopyTexSubImage1DglCopyTexSubImage2DglCopyTexSubImage3DglCreateTexturesglDeleteTexturesglGenTexturesglGetCompressedTexImageglGetCompressedTextureSubImageglGetTexImageglGetTexLevelParameterglGetTexParameterglGetTextureSubImageglInvalidateTexImageglInvalidateTexSubImageglIsTextureglTexBufferglTexBufferRangeglTexImage1DglTexImage2DglTexImage2DMultisampleglTexImage3DglTexImage3DMultisampleglTexParameterglTexStorage1DglTexStorage2DglTexStorage2DMultisampleglTexStorage3DglTexStorage3DMultisampleglTexSubImage1DglTexSubImage2DglTexSubImage3DglTextureViewRenderingglClearglClearBufferglClearColorglClearDepthglClearDepthfglClearStencilglDrawBufferglFinishglFlushglReadBufferglReadPixelsFrameBuffersglBindFramebufferglBindRenderbufferglBlitFramebufferglCheckFramebufferStatusglCreateFramebuffersglCreateRenderbuffersglDeleteFramebuffersglDeleteRenderbuffersglDrawBuffersglFramebufferParameteriglFramebufferRenderbufferglFramebufferTextureglFramebufferTexture2DglFramebufferTextureLayerglGenFramebuffersglGenRenderbuffersglGenerateMipmapglGetFramebufferAttachmentParameterglGetFramebufferAttachmentParameterivglGetFramebufferParameterglGetFramebufferParameterivglGetRenderbufferParameterglGetRenderbufferParameterivglInvalidateFramebufferglInvalidateSubFramebufferglIsFramebufferglIsRenderbufferglRenderbufferStorageglRenderbufferStorageMultisampleglSampleMaskiShadersglAttachShaderglBindAttribLocationglBindFragDataLocationglBindFragDataLocationIndexedglCompileShaderglCreateProgramglCreateShaderglCreateShaderProgramglDeleteProgramglDeleteShaderglDetachShaderglGetActiveAtomicCounterBufferivglGetActiveAttribglGetActiveSubroutineNameglGetActiveSubroutineUniformglGetActiveSubroutineUniformNameglGetActiveUniformglGetActiveUniformBlockglGetActiveUniformBlockNameglGetActiveUniformBlockivglGetActiveUniformNameglGetActiveUniformsivglGetAttachedShadersglGetAttribLocationglGetFragDataIndexglGetFragDataLocationglGetProgramglGetProgramBinaryglGetProgramInfoLogglGetProgramResourceglGetProgramResourceIndexglGetProgramResourceLocationglGetProgramResourceLocationIndexglGetProgramResourceNameglGetProgramStageglGetProgramivglGetShaderglGetShaderInfoLogglGetShaderPrecisionFormatglGetShaderSourceglGetShaderivglGetSubroutineIndexglGetSubroutineUniformLocationglGetUniformglGetUniformBlockIndexglGetUniformIndicesglGetUniformLocationglGetUniformSubroutineglIsProgramglIsShaderglLinkProgramglMinSampleShadingglProgramBinaryglProgramParameterglProgramParameteriglProgramUniformglReleaseShaderCompilerglShaderBinaryglShaderSourceglShaderStorageBlockBindingglUniformglUniformBlockBindingglUniformSubroutinesglUseProgramglUseProgramStagesglValidateProgramBufferObjectsglBindBufferglBindBufferBaseglBindBufferRangeglBindBuffersBaseglBindBuffersRangeglBindVertexBufferglBindVertexBuffersglBufferDataglBufferStorageglBufferSubDataglClearBufferDataglClearBufferSubDataglCopyBufferSubDataglCreateBuffersglCreateVertexArraysglDeleteBuffersglDisableVertexAttribArrayglDrawArraysglDrawArraysIndirectglDrawArraysInstancedglDrawArraysInstancedBaseInstanceglDrawElementsglDrawElementsBaseVertexglDrawElementsIndirectglDrawElementsInstancedglDrawElementsInstancedBaseInstanceglDrawElementsInstancedBaseVertexglDrawElementsInstancedBaseVertexBaseInstanceglDrawRangeElementsglDrawRangeElementsBaseVertexglEnableVertexAttribArrayglFlushMappedBufferRangeglGenBuffersglGetBufferParameterglGetBufferParameterivglGetBufferPointervglGetBufferSubDataglGetVertexArrayIndexedglGetVertexArrayivglGetVertexAttribglGetVertexAttribPointervglInvalidateBufferDataglInvalidateBufferSubDataglIsBufferglMapBufferglMapBufferRangeglMultiDrawArraysglMultiDrawArraysIndirectglMultiDrawElementsglMultiDrawElementsBaseVertexglMultiDrawElementsIndirectglPatchParameterglPrimitiveRestartIndexglProvokingVertexglUnmapBufferglVertexArrayElementBufferglVertexAttribglVertexAttribBindingglVertexAttribDivisorglVertexAttribFormatglVertexAttribPointerglVertexBindingDivisorStateManagementglBlendColorglBlendEquationglBlendEquationSeparateglBlendFuncglBlendFuncSeparateglClampColorglClipControlglColorMaskglCullFaceglDepthFuncglDepthMaskglDepthRangeglDepthRangeArrayglDepthRangeIndexedglDepthRangefglDisableglEnableglFrontFaceglGetglGetErrorglHintglIsEnabledglLineWidthglLogicOpglPixelStoreglPixelStoreiglPointParameterglPointSizeglPolygonModeglPolygonOffsetglSampleCoverageglScissorglScissorArrayglScissorIndexedglStencilFuncglStencilFuncSeparateglStencilMaskglStencilMaskSeparateglStencilOpglStencilOpSeparateglViewportglViewportArrayglViewportIndexedTransformFeedbackglBeginTransformFeedbackglBindTransformFeedbackglCreateTransformFeedbacksglDeleteTransformFeedbacksglDrawTransformFeedbackglDrawTransformFeedbackInstancedglDrawTransformFeedbackStreamglDrawTransformFeedbackStreamInstancedglEndTransformFeedbackglGenTransformFeedbacksglGetTransformFeedbackglGetTransformFeedbackVaryingglIsTransformFeedbackglPauseTransformFeedbackglResumeTransformFeedbackglTransformFeedbackBufferBaseglTransformFeedbackBufferRangeglTransformFeedbackVaryingsUtilityglDispatchComputeglDispatchComputeIndirectglGetGraphicsResetStatusglGetInternalformatglGetInternalformativglGetMultisampleglGetMultisamplefvglGetStringglMemoryBarrierQueriesglBeginConditionalRenderglBeginQueryglBeginQueryIndexedglCreateQueriesglDeleteQueriesglEndConditionalRenderglEndQueryglEndQueryIndexedglGenQueriesglGetQueryIndexedglGetQueryObjectglGetQueryObjectuivglGetQueryivglIsQueryglQueryCounterSyncingglClientWaitSyncglDeleteSyncglFenceSyncglGetSyncglGetSyncivglIsSyncglTextureBarrierglWaitSyncVertexArrayObjectsglBindVertexArrayglDeleteVertexArraysglGenVertexArraysglIsVertexArraySamplersglBindSamplerglBindSamplersglCreateSamplersglDeleteSamplersglGenSamplersglGetSamplerParameterglIsSamplerglSamplerParameterProgramPipelinesglActiveShaderProgramglBindProgramPipelineglCreateProgramPipelinesglDeleteProgramPipelinesglGenProgramPipelinesglGetProgramPipelineglGetProgramPipelineInfoLogglIsProgramPipelineglValidateProgramPipelineImmediateModeglArrayElementglBeginglColorglEndglEvalCoordglEvalMeshglEvalPointglFogCoordglIndexglMaterialglMultiTexCoordglNormalglSecondaryColorglTexCoordglVertexGL2RasterizationglBitmapglClearIndexglClipPlaneglCopyPixelsglDrawPixelsglFeedbackBufferglFogglGetClipPlaneglGetMapglGetPixelMapglGetPolygonStippleglInitNamesglLineStippleglLoadNameglMap1glMap2glMapGridglPassThroughglPixelZoomglPolygonStippleglPopNameglPushNameglRasterPosglRectglRenderModeglSelectBufferglWindowPosClientArraysglColorPointerglDisableClientStateglEnableClientStateglFogCoordPointerglIndexPointerglInterleavedArraysglNormalPointerglPopClientAttribglPushClientAttribglSecondaryColorPointerglTexCoordPointerglVertexPointerFixedFunctionglAccumglAlphaFuncglClearAccumglColorMaterialglEdgeFlagglEdgeFlagPointerglGetLightglGetMaterialglGetTexEnvglGetTexGenglIndexMaskglLightglLightModelglPopAttribglPushAttribglShadeModelglTexEnvglTexGenMatrixStateglFrustumglLoadIdentityglLoadMatrixglLoadTransposeMatrixglMatrixModeglMultMatrixglMultTransposeMatrixglOrthoglPopMatrixglPushMatrixglRotateglScaleglTranslateGL2TexturesglAreTexturesResidentglClientActiveTextureglPixelMapglPixelTransferglPrioritizeTexturesCallListsglCallListglCallListsglDeleteListsglEndListglGenListsglIsListglListBaseglNewListDebugglDebugMessageCallbackglDebugMessageControlglDebugMessageInsertglGetDebugMessageLogglGetObjectLabelglGetObjectPtrLabelglGetPointervglGetProgramInterfaceglObjectLabelglObjectPtrLabelglPopDebugGroupglPushDebugGroupTrigonometryacosacoshasinasinhatanatanhcoscoshdegreesradianssinsinhtantanhMathematicsabsceilclampdFdxdFdyexpexp2floorfloorfmafractfwidthinversesqrtisinfisnanloglog2maxminmixmodmodfnoisepowroundroundEvensignsmoothstepsqrtsteptruncFloating-PointfloatBitsToIntfrexpintBitsToFloatldexppackDouble2x32packHalf2x16packUnormunpackDouble2x32unpackHalf2x16unpackUnormBuilt-InVariablesgl_ClipDistancegl_CullDistancegl_FragCoordgl_FragDepthgl_FrontFacinggl_GlobalInvocationIDgl_HelperInvocationgl_InstanceIDgl_InvocationIDgl_Layergl_LocalInvocationIDgl_LocalInvocationIndexgl_NumSamplesgl_NumWorkGroupsgl_PatchVerticesIngl_PointCoordgl_PointSizegl_Positiongl_PrimitiveIDgl_PrimitiveIDIngl_SampleIDgl_SampleMaskgl_SampleMaskIngl_SamplePositiongl_TessCoordgl_TessLevelInnergl_TessLevelOutergl_VertexIDgl_ViewportIndexgl_WorkGroupIDgl_WorkGroupSizeVectorcrossdistancedotequalfaceforwardlengthnormalizenotEqualreflectrefractComponentComparisonallanygreaterThangreaterThanEquallessThanlessThanEqualnotGeometryShaderEmitStreamVertexEmitVertexEndPrimitiveEndStreamPrimitiveTextureSamplinginterpolateAtCentroidinterpolateAtOffsetinterpolateAtSampletexelFetchtexelFetchOffsettexturetextureGathertextureGatherOffsettextureGatherOffsetstextureGradtextureGradOffsettextureLodtextureLodOffsettextureOffsettextureProjtextureProjGradtextureProjGradOffsettextureProjLodtextureProjLodOffsettextureProjOffsettextureQueryLevelstextureQueryLodtextureSamplestextureSizeMatrixdeterminantgroupMemoryBarrierinversematrixCompMultouterProducttransposeIntegerbitCountbitfieldExtractbitfieldInsertbitfieldReversefindLSBfindMSBuaddCarryumulExtendedusubBorrowImageimageAtomicAddimageAtomicAndimageAtomicCompSwapimageAtomicExchangeimageAtomicMaximageAtomicMinimageAtomicOrimageAtomicXorimageLoadimageSamplesimageSizeimageStoreAtomicatomicAddatomicAndatomicCompSwapatomicCounteratomicCounterDecrementatomicCounterIncrementatomicExchangeatomicMaxatomicMinatomicOratomicXorMemoryBarrierbarriergroupMemoryBarriermemoryBarriermemoryBarrierAtomicCountermemoryBarrierBuffermemoryBarrierImagememoryBarrierSharedGLSL4GLSLES3gl_PositionNamegl_Position—containsthepositionofthecurrentvertexDeclarationouthighpvec4gl_Position;DescriptionThevariablegl_Positionisintendedforwritingthehomogeneousvertexposition.Itcanbewrittenatanytimeduringvertexshaderexecution.Thisvaluewillbeusedbyprimitiveassembly,clipping,culling,andotherfixedfunctionalityoperations,ifpresent,thatoperateonprimitivesaftervertexprocessinghasoccurred.Itsvalueisundefinedafterthevertexprocessingstageifthevertexshaderexecutabledoesnotwritegl_Position.VersionSupportOpenGLESShadingLanguageVersionVariableName1.003.003.10gl_Position✔✔✔SeeAlsogl_PointSizeCopyrightCopyright©2011-2014KhronosGroup.ThismaterialmaybedistributedsubjecttothetermsandconditionssetforthintheOpenPublicationLicense,v1.0,8June1999.https://opencontent.org/openpub/.Thinkyoucanimprovethispage?EditthispageonGitHub.docs.glwaswrittenbyJorgeRodríguez.Eachentryisunderindividualcopyrightdisplayedatthebottomofthatentry.Allothercontentisinthepublicdomain.docs.gliscompletelyunaffiliatedwithOpenGLandKhronos.Thesepageswerelastcompiledon17March2022at15:33:59GMT.



請為這篇文章評分?