问题标签 [cubes]

For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.

0 投票
2 回答
4428 浏览

java - 在opengl es android中的随机位置绘制多个立方体

使用 OpenGL ES,我正在渲染一个简单的立方体类,将它绘制在屏幕的中心。但是,我希望能够在屏幕上随机位置绘制多个这样的立方体,但不知道如何。这是我的自定义表面视图,它将多维数据集呈现为私有类。我没有包括我的主要 ActivityManager 因为它不是问题。

这里是MYGLCube包含顶点、索引和其他用于构建立方体的东西

0 投票
1 回答
954 浏览

sql-server - SQL Server BI:单个多维数据集,多个事实表

我是创建立方体的新手,所以请耐心等待。

这是我的数据示例,我有多家公司,每家公司都有多家商店。每个销售都与特定公司相关联,在特定日期与特定商店相关联。例如:2011 年 5 月 19 日,A 公司,商店 1 发生了 5 次销售退货与特定日期的特定公司相关联。例如:公司 A 于 2012 年 3 月 11 日发生了 3 次退货 有时我的用户想要查看商店列表、日期、退货次数以及销售额。有时他们想查看公司列表、特定商店和销售数量。

我有一个存储 COMPANY - DATE - STORE- SALES - RETURNS 的表,我最终在特定的 COMPANY - DATE 对下为每个商店重复返回的值。因此,如果我正在编写查询,并且我想找出退货,我只需选择不同的公司,日期,从 mytable 退货

但我不知道如何把它变成一个多维数据集(使用 SS BI 和 Visual Studio)。(到目前为止我只做了几个立方体)

谢谢!(另外,请随时向我指出适当的参考资料)

0 投票
1 回答
85 浏览

cubes - Sifteo 支持哪些声音格式?

我正在尝试在我的立方体上播放一些声音,但没有运气,我的 /assets/sounds 中有一个欢呼.wav,我这样称呼它:

更改名称会在 CreateSound() 方法中引发异常,所以我知道它正在加载它

0 投票
1 回答
898 浏览

ssas - 使用来自多个立方体的测量值创建全局立方体

我有 2 个立方体,每个立方体都有自己的尺寸。一个立方体的一些测量值与第二个立方体相关联。出于某种原因,如果我使用所说的链接测量,查询将不会运行,但它会运行它,我只包括来自我选择的多维数据集的测量。现在,从我读过的内容来看,这看起来不太可能,但我认为我会检查 SO 100% 确定并找出解决方法。

那么,有没有办法从多个立方体中选择测量值?

立方体结构:

我根据 MSDN 的这一部分创建了一个 MDX 查询:http: //msdn.microsoft.com/en-us/library/ms145581.aspx

在桌面上创建全局多维数据集的查询:

0 投票
1 回答
1875 浏览

algorithm - Marching Cubes 算法中的等值

我在这里阅读这篇文章:http: //paulbourke.net/geometry/polygonise/

目前,我有一个使用单纯形噪声生成的类似于我的世界的地形,我将其划分为 16x16 块,这些块具有 32x32x128 块。现在,我想在行进立方体中使用我为 Polygonise 函数生成的噪声。但我的问题是如何计算等值?我不明白。

这里的任何人都知道更多的勺子文章。哈哈

编辑:

嘿,我在http://paulbourke.net/geometry/polygonise/marchingsource.cpp上找到了这个。

sSourcePoint[] 的值为 0.5,因此它只是使对象居中,但 fResult += 0.5/(fDx*fDx + fDy*fDy + fDz*fDz) 有什么作用?天哪,我被这些代码吓到了。

0 投票
2 回答
1748 浏览

android - detecting the side of a cube that is facing the camera in android opengl es

So I started creating an app to learn openGL es on adroid. First I went through a chapter that explained how to construct a cube and get it to rotate using the system timer. I then mapped each side to a different segment of one image. For development purposes each side is textured with a number. I then implemented the drag feature to allow the user to rotate the cube up/down or left/right depending how they swiped.

First here is some background on my problem:

I want to keep track of which side is facing the camera because each face is being rotated on the axis it started on. For example given a cube that has the unfolded layout as follows.

Where 1 is the side facing the screen, 2 is the opposite (or back face), 4 is up, 5 is right, 6 is down, and 3 is left.This means 3/5 are on the x-axis, 4/6 on the y-axis, and 1/2 on the z axis.

Here is my issue:

The cube rotates correctly if I only rotate around 1 axis (i.e. I only go left/righ or up/down until I go 360) but if I only go to 90 180 or 270 then the axis I should be rotating around have switched. This happens because of what is stated above about each side of the cube being stuck to the axis it started on.

If you rotate right once so 5 is facing, then the z axis from the users perspective is the x-axis of the cube. This gets even more convoluted when you start going 90 degrees left/right then 90 degrees up/down, etc.

I tried to keep track of the faces with an array of numbers listed clockwise from the top number, but depending which number you came from the new directions for the surrounding numbers have changed.

For Example:

I mapped out the numbers surrounding each number as it faces the screen if it was rotated to from 1 so

and 2 is a wild card because it can be gotten to from any direction so there is no real initial number layout from 1

So my arrays would be

And MOVE can have the values

Then by keeping track of the previous face, curr face, and last move I tried to figure out a formula to get an offset that would help me select what the next face would be given a direction to move to a new face. Roughly I came out with this interpretation:

1) This tells me that the sides around 4 are in the same order as the array sidesOfFace, in clockwise starting at the top. So when the user swipes again I can know which side we are going to. This is imperative in being able to set up the right rotations of the cube since they change for the viewer as the cube gets turned.

2) This shows that there is an offset, if we look at the array the index of 4 should be 0 but the cube has been rotated such that the UP side is now at index 3, RIGHT is 0, DOWN is 1, and LEFT is 2.

Besides needing to know which side is facing the screen for other functionality in my app, I also have to know because depending on which side is facing the screen I have to rotate the cube along the correct axis. I am keeping track of the xRot and yRot but these rotations have to happen according the the camera/users view, not the cubes axis.

For Example I found that:

This means that depending on which side is facing the screen I have to do the xRotations around the up/down axis and the yRotations around the right/left axis.

A friend said something about possibly checking the 4 vertices that are closest to the camera but since I am using glRotate funcs I wasn't sure where I could get that information from. But I still need to know which numbers are on which side of the front face so I can automate the rotations of the cube.

If you actually sat down and read all this I truely do appreciate it, If you could steer me in the right direction. Maybe a link, or better yet a known solution to this problem would be amazing. I have been struggling with this for a few days now and I was just wondering if this was already a problem that had a solution.

Thanks all,

Alan

0 投票
1 回答
289 浏览

sql-server - 多维数据集角色 - 使用 Active Directory 按区域限制数据

我有一个多维数据集,我想限制用户只能访问他们自己领土内的数据。区域数据可以与他们的用户名和几个不同的表连接,以链接到我的销售区域维度表。我将如何使用 BIDS 创建一个自动更改每个用户允许的成员集的角色。

谢谢!伊森

0 投票
1 回答
550 浏览

linq - 如何使用 EDMX 从 SSAS Cube 中检索数据?

我得到了一个包含所有相关信息的立方体。现在,我想通过 .net EDMX 框架查询多维数据集并获取数据。

谁能帮助我从我应该开始的地方开始?我真的很困惑,不知道如何将 MDX 与 edmx 一起使用。

是否可以在不使用 MDX 的情况下使用 EDMX 和 LINQ 从多维数据集获取数据?

0 投票
3 回答
3188 浏览

c# - 使用对象检索 Datareader

我一直致力于使用 Datareader 从 SQL 数据库中检索数据并将其填充到 Datatable 中。但是,我想知道是否有任何方法可以在不使用 datatable 的情况下处理来自 datareader 的数据? 我的意思是 - 使用对象处理表值应该更可取..

但是,我不想在这里使用 LINQ,因为我将使用 ADOMD 对象从数据库(多维数据集)中提取数据。

0 投票
2 回答
1131 浏览

ssas - 通过使用其显示名称获取属性过滤器?

我正在尝试使用作为层次结构属性的日期过滤器来设计 MDX 查询。现在,我需要将属性过滤器值放在“where”子句中。当我拖放属性说 - “2012”时,它转换为其他格式,例如“[日期]。[财政层次结构]。[年份]。&[2.012E9]”,而在左窗格显示中,它显示为“2012 年”..

如何控制这种转换?我不确定它是在什么基础上转换这个属性的?

我需要根据用户选择在程序中动态构建 MDX 查询。当用户选择“2012”时,如何确定它是“2.012E9”?或者有什么方法可以改变 MDX 中的过滤条件,这样我就可以在不使用 [2.012E9] 字符串的情况下实现这一点?

提前致谢..