3d

How to programatically merge & render 3d models?

Hi All, I want to write an application that let users customize some 3d objects, making new objects by combining existing ones. For example, if a user wants to change just the roof of a house, he should select a new one (other existing roof object) and the whole model (the whole house) would be updated. I haven´t found any way to do th...

Should I always normalise a point after a homogenous transformation?

I'm just starting out with 3D math/programming and I have a question about point normalization: When doing transformations such as rotations, scaling, camera and perspective projections should I always normalize points so that w is 1 between transformations, or is it better to leave it until I'm ready to display them? Is there any reaso...

Determining if a sphere intersects an object or not

Hello everyone, I have a closed object described by a surface representation of triangles (described by three vertices which forms a right hand rule with a normal pointing to the "outside" of the object). I place a sphere of some radius in 3D space somewhere close to the surface of the object. I want to determine if the sphere intersec...

texture the 3d cube in android

i have ever tried to texture the 3d cube in android using opengl es according to the example in c++, but after several times , the result is disappointed! so i wanna know, who have ever done it before? may you give me some suggestions? thanks in advance! ...

Explain the TexturedSphere example in Processing

The Processing project website has an example of implementing a 3D textured sphere with rotational capabilities. I'm trying to understand the code, but I'm having trouble comprehending many of the code blocks since I don't have a background in graphics. Any higher-level explanation of what each block is trying to accomplish, perhaps re...

Open source 3D positional audio (HRTF)?

I am in need of positional audio for my emulator RetroCopy (http://www.retrocopy.com) . I am currently using DirectSound 3D however it has many issues when I am in the 3D world of my emulator. Instead of trying to hardcode fixes for a single platform I thought it would be better to use software positioning of my buffers that I output to ...

How to implement an ItemsControl3D which can use templates of Visual3D?

I'm looking for something like a ContainerUIElement3D which supports the ItemsSource property and an ItemTemplate property which I can use within a Viewport3D. My aim is to be able to write something like: <ItemsControl3D ItemsSource="{Binding Path=MyItems}"> <ItemsControl3D.ItemTemplate> <DataTemplate3D> ...

How to save WPF 3d MeshGeometry3D to resource

i'm inserting *.obj to main windows. But 3d object contains too many coordinate. My xaml file was very big. How to insert 3d object (.obj) to resource and call from them? ...

3D intersection test

Hi, I have this 3D model loaded.Then on the same screen, I have many points draw on it.. how Can I determine whether the points are on the model or not.Only take the XY plane for consideration. Anyone can teach me how to do a 3D intersection test only on the XY plane, because Im really clueless. ...

Which version of OpenGL/Direct3D should I target for optimum compatability?

When we develop web pages we can broadly work out which browsers to support based on market share. When we develop in .NET we can broadly work out which .NET version to develop for based on which Windows versions have it installed. But when developing OpenGL or Direct3D applications, how do we know which video cards people (I mean "peo...

Euler angles and Quaternion orientation

how to convert Quaternion orientation output of wintracker II device to Euler Angles output only. Because Wintracker II device Output Euler angles and Quaternion orientation. i want to Euler angles output only. ...

Programatically creating a WPF 3D cube

What is the simplest way to programatically create a GeometryModel3D cube in wpf? ...

Translate Local quaternion rotation into global (gyro)

I need a way to get euler angles for rotation in global frame of reference from a local. I am using c#, wpf 3d and a gyroscope. I have a globe on the screen that should move in the same way as the gyro. Since the gyro sends movement relative to itself I need to use quaternions to keep the state of the object and update it but I'm stuck. ...

Stencil Buffer Read/Write mask.

In Direct3D10 the Stencil Read/Write mask is a byte (from 0x00 to 0xFF) In Direct3D9 the Stencil Read/Write mask is a int (from 0x00000000 to 0xFFFFFFFF) The question is : How the stencil read/write mask in Direct3D10 relate to the Direct3D9 one? Direct3D10 | 0x00FFFFFF or Direct3D10 | 0xFFFFFF00 ? And another question : Why the Di...

WPF - Get the angle in degrees of a Vector3D as viewed from above

I'm working with a 3D that has a property of type Vector3D called FrontDirection. This object is rotated as follows: var rotate = new AxisAngleRotation3D(new Vector3D(0, 1, 0), deltaAngleInDegrees); var transform = new RotateTransform3D(rotate); my3DObject.FrontDirection = transform.Transform(my3DObject.FrontDirection); After some a...

Easiest way for a simple 3d app.

A friend of mine asked for a simple program. Input: Coordinates of some points, spheres, planes etc. ( from an excel document (strictly) ) Output: A 3D view of the input which the user can move the camera. The questions is, how can I do that easiest way. I have experience in C++, C#, Flash (AS), Java ...

Is there any algorithm for projecting images onto a non-flat surface?

Is there any algorithm for projecting images onto a non-flat (deformed) surface? It is not deformed too much. It is a really glassy surface covered with high-quality, durable tracing paper. I have a 3-dimensional model of it. How can I texturise it with a projector? I want to write a program in C\C++\C# for Windows, which would be ...

How to determine Z-order when drawing in a one-point perspective?

I'm trying to make a simple javascript that draws rectangles on a canvas, then draws the side faces based on a one-point perspective. The problem is, the amount of rectangles and their positioning is arbitrary, so faces tend to overlap in a way that wouldn't happen in true 3D perspective. How can I determine the correct drawing order so ...

3d geometry: how to align an object to a vector

hello, i have an object in 3d space that i want to align according to a vector. i already got the Y-rotation out by doing an atan2 on the x and z component of the vector. but i would also like to have an X-rotation to make the object look downwards or upwards. imagine a plane that does it's pitch yaw roll, just without the roll. i am...

Draw a antialiased line in a fast way.

I have a little problem. I've recently created an algorithm to allow thick lines to be drawed onscreen (as a quad structure), the problem is that when the line is very long and diagonal the aliasing is very high, making the line look very bad. What are my chance to reduce the aliasing while trying to have high performance? I'm using (as...