因此,使用此处定义的wavefront对象文件:http: //en.wikipedia.org/wiki/Wavefront_.obj_file
我该如何渲染在opengl中有超过4个顶点的面.我承诺如果它有3个顶点我使用GL_TRIANGLES,如果它有4我使用GL_QUADS,但如果它有5或更多,我应该使用什么?有标准吗?在我的互联网搜索中我还没有能够提出任何东西和样本打开gl代码我发现只支持最多4个顶点.
我目前正在尝试使用symfony表单来处理我的帖子并放入rest api端点.
目前我有:
$request = $this->getRequest();
$cc = new CreditCard();
$form = $this->createForm(new CreditCardType(), $cc);
$form->handleRequest($request);
if ($form->isValid()) {
//...
}
Run Code Online (Sandbox Code Playgroud)
但是,表单永远不会有效.查看问题,似乎表单的isSubmitted字段为false,因此它永远不会通过验证.此外,由于这是一个api调用,我在creditcardtype中将csrf_protection设置为false.
以下是我向用户提交的数据的示例:
{
"credit_card": {
"name" : "Example Name"
...
}
}
Run Code Online (Sandbox Code Playgroud)
如何将此post/put请求注册为已提交并且表单验证者通过?谢谢.
我正在尝试测试为 google pub sub 创建监视器,但收到“无效查询”错误。这是当我查看另一个工作监视器的源时的查询文本,所以我很困惑为什么它不起作用。
错误: Error: error creating monitor: 400 Bad Request: {"errors":["The value provided for parameter 'query' is invalid"]}
地形:
resource "datadog_monitor" "bad_stuff_sub_monitor" {
name = "${var.customer_name} Bad Stuff Monitor"
type = "metric alert"
message = "${var.customer_name} Bad Stuff Topic getting too big. Notify: ${var.datadog_monitor_notify_list}"
escalation_message = "Escalation message @pagerduty"
query = "avg:gcp.pubsub.subscription.num_undelivered_messages{project_id:terraform_gcp_test}"
thresholds = {
ok = 0
warning = 1
warning_recovery = 0
critical = 2
critical_recovery = 1
}
notify_no_data = false
renotify_interval = 1440 …Run Code Online (Sandbox Code Playgroud) 我有一张评论表,看起来有点像这样
ID REVIEWITEM SCORE DATE
1 Object A 5.0 6-5-2012
2 Object A 7.0 6-5-2012
3 Object A 6.0 6-7-2012
4 Object B 4.0 7-1-2012
Run Code Online (Sandbox Code Playgroud)
我希望有一个查询返回给我所有的评论,但如果评论是针对同一项目并且具有相同的日期,则只返回评分较高的评论.例如,上面的结果将是:
ID REVIEWITEM SCORE DATE
2 Object A 7.0 6-5-2012
3 Object A 6.0 6-7-2012
4 Object B 4.0 7-1-2012
Run Code Online (Sandbox Code Playgroud)
我该怎么做?