gallium: add vertex stream argument to EMIT/ENDPRIM
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Marek Olšák <marek.olsak@amd.com> Reviewed-by: Brian Paul <brianp@vmware.com> Reviewed-by: Roland Scheidegger <sroland@vmware.com>
This commit is contained in:
@@ -134,8 +134,8 @@ static const struct tgsi_opcode_info opcode_info[TGSI_OPCODE_LAST] =
|
|||||||
{ 1, 2, 1, 0, 0, 0, OTHR, "TXF", TGSI_OPCODE_TXF },
|
{ 1, 2, 1, 0, 0, 0, OTHR, "TXF", TGSI_OPCODE_TXF },
|
||||||
{ 1, 2, 1, 0, 0, 0, OTHR, "TXQ", TGSI_OPCODE_TXQ },
|
{ 1, 2, 1, 0, 0, 0, OTHR, "TXQ", TGSI_OPCODE_TXQ },
|
||||||
{ 0, 0, 0, 0, 0, 0, NONE, "CONT", TGSI_OPCODE_CONT },
|
{ 0, 0, 0, 0, 0, 0, NONE, "CONT", TGSI_OPCODE_CONT },
|
||||||
{ 0, 0, 0, 0, 0, 0, NONE, "EMIT", TGSI_OPCODE_EMIT },
|
{ 0, 1, 0, 0, 0, 0, NONE, "EMIT", TGSI_OPCODE_EMIT },
|
||||||
{ 0, 0, 0, 0, 0, 0, NONE, "ENDPRIM", TGSI_OPCODE_ENDPRIM },
|
{ 0, 1, 0, 0, 0, 0, NONE, "ENDPRIM", TGSI_OPCODE_ENDPRIM },
|
||||||
{ 0, 0, 0, 1, 0, 1, NONE, "BGNLOOP", TGSI_OPCODE_BGNLOOP },
|
{ 0, 0, 0, 1, 0, 1, NONE, "BGNLOOP", TGSI_OPCODE_BGNLOOP },
|
||||||
{ 0, 0, 0, 0, 0, 1, NONE, "BGNSUB", TGSI_OPCODE_BGNSUB },
|
{ 0, 0, 0, 0, 0, 1, NONE, "BGNSUB", TGSI_OPCODE_BGNSUB },
|
||||||
{ 0, 0, 0, 1, 1, 0, NONE, "ENDLOOP", TGSI_OPCODE_ENDLOOP },
|
{ 0, 0, 0, 1, 1, 0, NONE, "ENDLOOP", TGSI_OPCODE_ENDLOOP },
|
||||||
|
@@ -1646,14 +1646,14 @@ in any other type of shader.
|
|||||||
|
|
||||||
.. opcode:: EMIT - Emit
|
.. opcode:: EMIT - Emit
|
||||||
|
|
||||||
Generate a new vertex for the current primitive using the values in the
|
Generate a new vertex for the current primitive into the specified vertex
|
||||||
output registers.
|
stream using the values in the output registers.
|
||||||
|
|
||||||
|
|
||||||
.. opcode:: ENDPRIM - End Primitive
|
.. opcode:: ENDPRIM - End Primitive
|
||||||
|
|
||||||
Complete the current primitive (consisting of the emitted vertices),
|
Complete the current primitive in the specified vertex stream (consisting of
|
||||||
and start a new one.
|
the emitted vertices), and start a new one.
|
||||||
|
|
||||||
|
|
||||||
GLSL ISA
|
GLSL ISA
|
||||||
|
@@ -3139,14 +3139,14 @@ void
|
|||||||
glsl_to_tgsi_visitor::visit(ir_emit_vertex *ir)
|
glsl_to_tgsi_visitor::visit(ir_emit_vertex *ir)
|
||||||
{
|
{
|
||||||
assert(this->prog->Target == GL_GEOMETRY_PROGRAM_NV);
|
assert(this->prog->Target == GL_GEOMETRY_PROGRAM_NV);
|
||||||
emit(ir, TGSI_OPCODE_EMIT);
|
emit(ir, TGSI_OPCODE_EMIT, undef_dst, st_src_reg_for_int(0));
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
glsl_to_tgsi_visitor::visit(ir_end_primitive *ir)
|
glsl_to_tgsi_visitor::visit(ir_end_primitive *ir)
|
||||||
{
|
{
|
||||||
assert(this->prog->Target == GL_GEOMETRY_PROGRAM_NV);
|
assert(this->prog->Target == GL_GEOMETRY_PROGRAM_NV);
|
||||||
emit(ir, TGSI_OPCODE_ENDPRIM);
|
emit(ir, TGSI_OPCODE_ENDPRIM, undef_dst, st_src_reg_for_int(0));
|
||||||
}
|
}
|
||||||
|
|
||||||
glsl_to_tgsi_visitor::glsl_to_tgsi_visitor()
|
glsl_to_tgsi_visitor::glsl_to_tgsi_visitor()
|
||||||
|
Reference in New Issue
Block a user