MCPcopy Create free account
hub / github.com/dfranx/ShaderDebugger / translateOperator

Method translateOperator

src/HLSLCompiler.cpp:580–601  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

578 }
579
580 void HLSLCompiler::translateOperator(M4::HLSLBinaryOp op)
581 {
582 switch (op)
583 {
584 case M4::HLSLBinaryOp_Add: m_gen.Function.Add(); break;
585 case M4::HLSLBinaryOp_Sub: m_gen.Function.Subtract(); break;
586 case M4::HLSLBinaryOp_Mul: m_gen.Function.Multiply(); break;
587 case M4::HLSLBinaryOp_Mod: m_gen.Function.Modulo(); break;
588 case M4::HLSLBinaryOp_Div: m_gen.Function.Divide(); break;
589 case M4::HLSLBinaryOp_Less: m_gen.Function.Less(); break;
590 case M4::HLSLBinaryOp_Greater: m_gen.Function.Greater(); break;
591 case M4::HLSLBinaryOp_LessEqual: m_gen.Function.LessEqual(); break;
592 case M4::HLSLBinaryOp_GreaterEqual: m_gen.Function.GreaterEqual(); break;
593 case M4::HLSLBinaryOp_Equal: m_gen.Function.Equal(); break;
594 case M4::HLSLBinaryOp_NotEqual: m_gen.Function.NotEqual(); break;
595 case M4::HLSLBinaryOp_And: m_gen.Function.BoolAnd(); break;
596 case M4::HLSLBinaryOp_Or: m_gen.Function.BoolOr(); break;
597 case M4::HLSLBinaryOp_BitAnd: m_gen.Function.BitAnd(); break;
598 case M4::HLSLBinaryOp_BitOr: m_gen.Function.BitOr(); break;
599 case M4::HLSLBinaryOp_BitXor: m_gen.Function.BitXor(); break;
600 }
601 }
602 void HLSLCompiler::translateBinaryExpression(M4::HLSLBinaryExpression* expr)
603 {
604 HLSLCompiler::ExpressionType lType = m_convertType(expr->expression1->expressionType);

Callers

nothing calls this directly

Calls 1

AddMethod · 0.80

Tested by

no test coverage detected