var searchIndex = {}; searchIndex["draw_state"] = {"doc":"Graphics state blocks for gfx-rs","items":[[3,"DrawState","draw_state","An assembly of states that affect regular draw calls",null,null],[12,"primitive","","How to rasterize geometric primitives.",0,null],[12,"multi_sample","","Multi-sampling mode",0,null],[12,"scissor","","Scissor mask to use. If set, no pixel outside of this rectangle (in screen space) will be\nwritten to as a result of rendering.",0,null],[12,"stencil","","Stencil test to use. If None, no stencil testing is done.",0,null],[12,"depth","","Depth test to use. If None, no depth testing is done.",0,null],[12,"blend","","Blend function to use. If None, no blending is done.",0,null],[12,"color_mask","","Color mask to use. Each flag indicates that the given color channel can be written to, and\nthey can be OR'd together.",0,null],[4,"BlendPreset","","Blend function presets for ease of use.",null,null],[13,"Add","","When combining two fragments, add their values together, saturating at 1.0",1,null],[13,"Multiply","","When combining two fragments, multiply their values together.",1,null],[13,"Alpha","","When combining two fragments, add the value of the source times its alpha channel with the\nvalue of the destination multiplied by the inverse of the source alpha channel. Has the\nusual transparency effect: mixes the two colors using a fraction of each one specified by\nthe alpha of the source.",1,null],[13,"Invert","","When combining two fragments, subtract the destination color from a constant color\nusing the source color as weight. Has an invert effect with the constant color\nas base and source color controlling displacement from the base color.\nA white source color and a white value results in plain invert.\nThe output alpha is same as destination alpha.",1,null],[0,"state","","Fixed-function hardware state.",null,null],[3,"Offset","draw_state::state","How to offset vertices in screen space, if at all.",null,null],[12,"0","","",2,null],[12,"1","","",2,null],[3,"Primitive","","Primitive rasterization state. Note that GL allows different raster\nmethod to be used for front and back, while this abstraction does not.",null,null],[12,"front_face","","Which vertex winding is considered to be the front face for culling.",3,null],[12,"method","","How to rasterize this primitive.",3,null],[12,"offset","","Any polygon offset to apply.",3,null],[3,"MultiSample","","Multi-sampling rasterization mode",null,null],[3,"StencilSide","","Complete stencil state for a given side of a face.",null,null],[12,"fun","","Comparison function to use to determine if the stencil test passes.",4,null],[12,"value","","Reference value to compare the value in the stencil buffer with.",4,null],[12,"mask_read","","A mask that is ANDd with both the stencil buffer value and the reference value when they\nare read before doing the stencil test.",4,null],[12,"mask_write","","A mask that is ANDd with the stencil value before writing to the stencil buffer.",4,null],[12,"op_fail","","What operation to do if the stencil test fails.",4,null],[12,"op_depth_fail","","What operation to do if the stenil test passes but the depth test fails.",4,null],[12,"op_pass","","What operation to do if both the depth and stencil test pass.",4,null],[3,"Stencil","","Complete stencil state, specifying how to handle the front and back side of a face.",null,null],[12,"front","","",5,null],[12,"back","","",5,null],[3,"Depth","","Depth test state.",null,null],[12,"fun","","Comparison function to use.",6,null],[12,"write","","Specify whether to write to the depth buffer or not.",6,null],[3,"BlendChannel","","",null,null],[12,"equation","","",7,null],[12,"source","","",7,null],[12,"destination","","",7,null],[3,"Blend","","",null,null],[12,"color","","",8,null],[12,"alpha","","",8,null],[12,"value","","",8,null],[3,"ColorMask","","",null,null],[4,"FrontFace","","The front face winding order of a set of vertices.",null,null],[13,"Clockwise","","Clockwise winding order.",9,null],[13,"CounterClockwise","","Counter-clockwise winding order.",9,null],[4,"CullFace","","Which face, if any, to cull.",null,null],[13,"Nothing","","",10,null],[13,"Front","","",10,null],[13,"Back","","",10,null],[4,"RasterMethod","","How to rasterize a primitive.",null,null],[13,"Point","","Rasterize as a point.",11,null],[13,"Line","","Rasterize as a line with the given width.",11,null],[13,"Fill","","Rasterize as a face with a given cull face mode.",11,null],[4,"Comparison","","A pixel-wise comparison function.",null,null],[13,"Never","","`false`",12,null],[13,"Less","","`x < y`",12,null],[13,"LessEqual","","`x <= y`",12,null],[13,"Equal","","`x == y`",12,null],[13,"GreaterEqual","","`x >= y`",12,null],[13,"Greater","","`x > y`",12,null],[13,"NotEqual","","`x != y`",12,null],[13,"Always","","`true`",12,null],[4,"StencilOp","","Stencil mask operation.",null,null],[13,"Keep","","Keep the current value in the stencil buffer (no change).",13,null],[13,"Zero","","Set the value in the stencil buffer to zero.",13,null],[13,"Replace","","Set the stencil buffer value to `value` from `StencilSide`",13,null],[13,"IncrementClamp","","Increment the stencil buffer value, clamping to its maximum value.",13,null],[13,"IncrementWrap","","Increment the stencil buffer value, wrapping around to 0 on overflow.",13,null],[13,"DecrementClamp","","Decrement the stencil buffer value, clamping to its minimum value.",13,null],[13,"DecrementWrap","","Decrement the stencil buffer value, wrapping around to the maximum value on overflow.",13,null],[13,"Invert","","Bitwise invert the current value in the stencil buffer.",13,null],[4,"Equation","","",null,null],[13,"Add","","Adds source and destination.\nSource and destination are multiplied by blending parameters before addition.",14,null],[13,"Sub","","Subtracts destination from source.\nSource and destination are multiplied by blending parameters before subtraction.",14,null],[13,"RevSub","","Subtracts source from destination.\nSource and destination are multiplied by blending parameters before subtraction.",14,null],[13,"Min","","Component-wise minimum value of source and destination.\nBlending parameters are ignored.",14,null],[13,"Max","","Component-wise maximum value of source and destination.\nBlending parameters are ignored.",14,null],[4,"BlendValue","","",null,null],[13,"SourceColor","","",15,null],[13,"SourceAlpha","","",15,null],[13,"DestColor","","",15,null],[13,"DestAlpha","","",15,null],[13,"ConstColor","","",15,null],[13,"ConstAlpha","","",15,null],[4,"Factor","","",null,null],[13,"Zero","","",16,null],[13,"One","","",16,null],[13,"SourceAlphaSaturated","","",16,null],[13,"ZeroPlus","","",16,null],[13,"OneMinus","","",16,null],[6,"LineWidth","","Width of a line.",null,null],[6,"OffsetFactor","","",null,null],[6,"OffsetUnits","","",null,null],[17,"RED","","",null,null],[17,"GREEN","","",null,null],[17,"BLUE","","",null,null],[17,"ALPHA","","",null,null],[17,"MASK_ALL","","",null,null],[17,"MASK_NONE","","",null,null],[11,"fmt","","",9,null],[11,"clone","","",9,null],[11,"hash","","",9,null],[11,"partial_cmp","","",9,null],[11,"eq","","",9,null],[11,"cmp","","",9,null],[11,"partial_cmp","","",2,null],[11,"lt","","",2,null],[11,"le","","",2,null],[11,"gt","","",2,null],[11,"ge","","",2,null],[11,"fmt","","",2,null],[11,"eq","","",2,null],[11,"ne","","",2,null],[11,"clone","","",2,null],[11,"cmp","","",10,null],[11,"partial_cmp","","",10,null],[11,"hash","","",10,null],[11,"fmt","","",10,null],[11,"eq","","",10,null],[11,"clone","","",10,null],[11,"partial_cmp","","",11,null],[11,"lt","","",11,null],[11,"le","","",11,null],[11,"gt","","",11,null],[11,"ge","","",11,null],[11,"fmt","","",11,null],[11,"eq","","",11,null],[11,"ne","","",11,null],[11,"clone","","",11,null],[11,"partial_cmp","","",3,null],[11,"lt","","",3,null],[11,"le","","",3,null],[11,"gt","","",3,null],[11,"ge","","",3,null],[11,"fmt","","",3,null],[11,"eq","","",3,null],[11,"ne","","",3,null],[11,"clone","","",3,null],[11,"get_cull_face","","Get the cull face, if any, for this primitive state.",3,null],[11,"default","","",3,{"inputs":[],"output":{"name":"primitive"}}],[11,"cmp","","",17,null],[11,"partial_cmp","","",17,null],[11,"hash","","",17,null],[11,"fmt","","",17,null],[11,"eq","","",17,null],[11,"clone","","",17,null],[11,"cmp","","",12,null],[11,"partial_cmp","","",12,null],[11,"hash","","",12,null],[11,"fmt","","",12,null],[11,"eq","","",12,null],[11,"clone","","",12,null],[11,"cmp","","",13,null],[11,"partial_cmp","","",13,null],[11,"hash","","",13,null],[11,"fmt","","",13,null],[11,"eq","","",13,null],[11,"clone","","",13,null],[11,"cmp","","",4,null],[11,"partial_cmp","","",4,null],[11,"lt","","",4,null],[11,"le","","",4,null],[11,"gt","","",4,null],[11,"ge","","",4,null],[11,"hash","","",4,null],[11,"fmt","","",4,null],[11,"eq","","",4,null],[11,"ne","","",4,null],[11,"clone","","",4,null],[11,"default","","",4,{"inputs":[],"output":{"name":"stencilside"}}],[11,"cmp","","",5,null],[11,"partial_cmp","","",5,null],[11,"lt","","",5,null],[11,"le","","",5,null],[11,"gt","","",5,null],[11,"ge","","",5,null],[11,"hash","","",5,null],[11,"fmt","","",5,null],[11,"eq","","",5,null],[11,"ne","","",5,null],[11,"clone","","",5,null],[11,"cmp","","",6,null],[11,"partial_cmp","","",6,null],[11,"lt","","",6,null],[11,"le","","",6,null],[11,"gt","","",6,null],[11,"ge","","",6,null],[11,"hash","","",6,null],[11,"fmt","","",6,null],[11,"eq","","",6,null],[11,"ne","","",6,null],[11,"clone","","",6,null],[11,"default","","",6,{"inputs":[],"output":{"name":"depth"}}],[11,"cmp","","",14,null],[11,"partial_cmp","","",14,null],[11,"hash","","",14,null],[11,"fmt","","",14,null],[11,"eq","","",14,null],[11,"clone","","",14,null],[11,"cmp","","",15,null],[11,"partial_cmp","","",15,null],[11,"hash","","",15,null],[11,"fmt","","",15,null],[11,"eq","","",15,null],[11,"clone","","",15,null],[11,"cmp","","",16,null],[11,"partial_cmp","","",16,null],[11,"lt","","",16,null],[11,"le","","",16,null],[11,"gt","","",16,null],[11,"ge","","",16,null],[11,"hash","","",16,null],[11,"fmt","","",16,null],[11,"eq","","",16,null],[11,"ne","","",16,null],[11,"clone","","",16,null],[11,"fmt","","",7,null],[11,"clone","","",7,null],[11,"hash","","",7,null],[11,"partial_cmp","","",7,null],[11,"lt","","",7,null],[11,"le","","",7,null],[11,"gt","","",7,null],[11,"ge","","",7,null],[11,"eq","","",7,null],[11,"ne","","",7,null],[11,"cmp","","",7,null],[11,"default","","",7,{"inputs":[],"output":{"name":"blendchannel"}}],[11,"eq","","",8,null],[11,"ne","","",8,null],[11,"partial_cmp","","",8,null],[11,"lt","","",8,null],[11,"le","","",8,null],[11,"gt","","",8,null],[11,"ge","","",8,null],[11,"clone","","",8,null],[11,"default","","",8,{"inputs":[],"output":{"name":"blend"}}],[11,"fmt","","",8,null],[11,"hash","","",18,null],[11,"cmp","","",18,null],[11,"partial_cmp","","",18,null],[11,"lt","","",18,null],[11,"le","","",18,null],[11,"gt","","",18,null],[11,"ge","","",18,null],[11,"clone","","",18,null],[11,"eq","","",18,null],[11,"ne","","",18,null],[11,"fmt","","",18,null],[11,"empty","","Returns an empty set of flags.",18,{"inputs":[],"output":{"name":"colormask"}}],[11,"all","","Returns the set containing all flags.",18,{"inputs":[],"output":{"name":"colormask"}}],[11,"bits","","Returns the raw value of the flags currently stored.",18,null],[11,"from_bits","","Convert from underlying bit representation, unless that\nrepresentation contains bits that do not correspond to a flag.",18,{"inputs":[{"name":"u32"}],"output":{"name":"option"}}],[11,"from_bits_truncate","","Convert from underlying bit representation, dropping any bits\nthat do not correspond to flags.",18,{"inputs":[{"name":"u32"}],"output":{"name":"colormask"}}],[11,"is_empty","","Returns `true` if no flags are currently stored.",18,null],[11,"is_all","","Returns `true` if all flags are currently set.",18,null],[11,"intersects","","Returns `true` if there are flags common to both `self` and `other`.",18,null],[11,"contains","","Returns `true` all of the flags in `other` are contained within `self`.",18,null],[11,"insert","","Inserts the specified flags in-place.",18,null],[11,"remove","","Removes the specified flags in-place.",18,null],[11,"toggle","","Toggles the specified flags in-place.",18,null],[11,"bitor","","Returns the union of the two sets of flags.",18,null],[11,"bitxor","","Returns the left flags, but with all the right flags toggled.",18,null],[11,"bitand","","Returns the intersection between the two sets of flags.",18,null],[11,"sub","","Returns the set difference of the two sets of flags.",18,null],[11,"not","","Returns the complement of this set of flags.",18,null],[0,"target","draw_state","Render target specification.",null,null],[3,"Rect","draw_state::target","A screen space rectangle",null,null],[12,"x","","",19,null],[12,"y","","",19,null],[12,"w","","",19,null],[12,"h","","",19,null],[3,"Mask","","Output mask, used for blitting and clearing",null,null],[3,"Mirror","","Mirroring flags, used for blitting",null,null],[3,"ClearData","","How to clear a frame.",null,null],[12,"color","","The color to clear the frame with",20,null],[12,"depth","","The depth value to clear the frame with",20,null],[12,"stencil","","The stencil value to clear the frame with",20,null],[6,"Layer","","A depth value, specifying which plane to select out of a 3D texture.",null,null],[6,"Level","","Mipmap level to select in a texture.",null,null],[6,"Depth","","A single depth value from a depth buffer.",null,null],[6,"Stencil","","A single value from a stencil stencstencil buffer.",null,null],[6,"ColorValue","","A color with floating-point components.",null,null],[17,"COLOR","","",null,null],[17,"COLOR0","","",null,null],[17,"COLOR1","","",null,null],[17,"COLOR2","","",null,null],[17,"COLOR3","","",null,null],[17,"DEPTH","","",null,null],[17,"STENCIL","","",null,null],[17,"MIRROR_X","","",null,null],[17,"MIRROR_Y","","",null,null],[11,"partial_cmp","","",19,null],[11,"lt","","",19,null],[11,"le","","",19,null],[11,"gt","","",19,null],[11,"ge","","",19,null],[11,"fmt","","",19,null],[11,"eq","","",19,null],[11,"ne","","",19,null],[11,"clone","","",19,null],[11,"hash","","",21,null],[11,"cmp","","",21,null],[11,"partial_cmp","","",21,null],[11,"lt","","",21,null],[11,"le","","",21,null],[11,"gt","","",21,null],[11,"ge","","",21,null],[11,"clone","","",21,null],[11,"eq","","",21,null],[11,"ne","","",21,null],[11,"fmt","","",21,null],[11,"empty","","Returns an empty set of flags.",21,{"inputs":[],"output":{"name":"mask"}}],[11,"all","","Returns the set containing all flags.",21,{"inputs":[],"output":{"name":"mask"}}],[11,"bits","","Returns the raw value of the flags currently stored.",21,null],[11,"from_bits","","Convert from underlying bit representation, unless that\nrepresentation contains bits that do not correspond to a flag.",21,{"inputs":[{"name":"u8"}],"output":{"name":"option"}}],[11,"from_bits_truncate","","Convert from underlying bit representation, dropping any bits\nthat do not correspond to flags.",21,{"inputs":[{"name":"u8"}],"output":{"name":"mask"}}],[11,"is_empty","","Returns `true` if no flags are currently stored.",21,null],[11,"is_all","","Returns `true` if all flags are currently set.",21,null],[11,"intersects","","Returns `true` if there are flags common to both `self` and `other`.",21,null],[11,"contains","","Returns `true` all of the flags in `other` are contained within `self`.",21,null],[11,"insert","","Inserts the specified flags in-place.",21,null],[11,"remove","","Removes the specified flags in-place.",21,null],[11,"toggle","","Toggles the specified flags in-place.",21,null],[11,"bitor","","Returns the union of the two sets of flags.",21,null],[11,"bitxor","","Returns the left flags, but with all the right flags toggled.",21,null],[11,"bitand","","Returns the intersection between the two sets of flags.",21,null],[11,"sub","","Returns the set difference of the two sets of flags.",21,null],[11,"not","","Returns the complement of this set of flags.",21,null],[11,"hash","","",22,null],[11,"cmp","","",22,null],[11,"partial_cmp","","",22,null],[11,"lt","","",22,null],[11,"le","","",22,null],[11,"gt","","",22,null],[11,"ge","","",22,null],[11,"clone","","",22,null],[11,"eq","","",22,null],[11,"ne","","",22,null],[11,"fmt","","",22,null],[11,"empty","","Returns an empty set of flags.",22,{"inputs":[],"output":{"name":"mirror"}}],[11,"all","","Returns the set containing all flags.",22,{"inputs":[],"output":{"name":"mirror"}}],[11,"bits","","Returns the raw value of the flags currently stored.",22,null],[11,"from_bits","","Convert from underlying bit representation, unless that\nrepresentation contains bits that do not correspond to a flag.",22,{"inputs":[{"name":"u8"}],"output":{"name":"option"}}],[11,"from_bits_truncate","","Convert from underlying bit representation, dropping any bits\nthat do not correspond to flags.",22,{"inputs":[{"name":"u8"}],"output":{"name":"mirror"}}],[11,"is_empty","","Returns `true` if no flags are currently stored.",22,null],[11,"is_all","","Returns `true` if all flags are currently set.",22,null],[11,"intersects","","Returns `true` if there are flags common to both `self` and `other`.",22,null],[11,"contains","","Returns `true` all of the flags in `other` are contained within `self`.",22,null],[11,"insert","","Inserts the specified flags in-place.",22,null],[11,"remove","","Removes the specified flags in-place.",22,null],[11,"toggle","","Toggles the specified flags in-place.",22,null],[11,"bitor","","Returns the union of the two sets of flags.",22,null],[11,"bitxor","","Returns the left flags, but with all the right flags toggled.",22,null],[11,"bitand","","Returns the intersection between the two sets of flags.",22,null],[11,"sub","","Returns the set difference of the two sets of flags.",22,null],[11,"not","","Returns the complement of this set of flags.",22,null],[11,"partial_cmp","","",20,null],[11,"lt","","",20,null],[11,"le","","",20,null],[11,"gt","","",20,null],[11,"ge","","",20,null],[11,"eq","","",20,null],[11,"ne","","",20,null],[11,"clone","","",20,null],[11,"fmt","","",20,null],[11,"partial_cmp","draw_state","",0,null],[11,"lt","","",0,null],[11,"le","","",0,null],[11,"gt","","",0,null],[11,"ge","","",0,null],[11,"fmt","","",0,null],[11,"eq","","",0,null],[11,"ne","","",0,null],[11,"clone","","",0,null],[11,"cmp","","",1,null],[11,"partial_cmp","","",1,null],[11,"hash","","",1,null],[11,"fmt","","",1,null],[11,"eq","","",1,null],[11,"clone","","",1,null],[11,"new","","Create a default `DrawState`. Uses counter-clockwise winding, culls the backface of each\nprimitive, and does no scissor/stencil/depth/blend/color masking.",0,{"inputs":[],"output":{"name":"drawstate"}}],[11,"get_target_mask","","Return a target mask that contains all the planes required by this state.",0,null],[11,"multi_sample","","Enable multi-sampled rasterization",0,null],[11,"stencil","","Set the stencil test to a simple expression",0,null],[11,"depth","","Set the depth test with the mask",0,null],[11,"scissor","","Set the scissor",0,null],[11,"blend","","Set the blend mode to one of the presets",0,null]],"paths":[[3,"DrawState"],[4,"BlendPreset"],[3,"Offset"],[3,"Primitive"],[3,"StencilSide"],[3,"Stencil"],[3,"Depth"],[3,"BlendChannel"],[3,"Blend"],[4,"FrontFace"],[4,"CullFace"],[4,"RasterMethod"],[4,"Comparison"],[4,"StencilOp"],[4,"Equation"],[4,"BlendValue"],[4,"Factor"],[3,"MultiSample"],[3,"ColorMask"],[3,"Rect"],[3,"ClearData"],[3,"Mask"],[3,"Mirror"]]}; initSearch(searchIndex);