![]() |
![]() | ![]() | ![]() | ![]() | ![]() | ![]() | ![]() |
| Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks. |
| |||||||
| |
| | #1 (permalink) |
| | DiffuseMaterial and GeometryModel3D SDK Problem My attampt to associate a material (VisualBrush) with the mesh geomerty failes. Nothing shows up; ImageSource imageSource = new BitmapImage(new Uri(@"C:\done.JPG")); ImageBrush imageBrush = new ImageBrush(imageSource); Material diffuseMaterial = new DiffuseMaterial(imageBrush); GeometryModel3D geometryModel3D = new GeometryModel3D(meshGeometry3D, diffuseMaterial); Model3DGroup model3DGroup = new Model3DGroup(); model3DGroup.Children.Add(geometryModel3D); On the other hand, a solid color brush works fine Material diffuseMaterial = new DiffuseMaterial(new SolidColorBrush(Colors.DarkKhaki)); |
My System Specs![]() |
| | #2 (permalink) |
| | Re: DiffuseMaterial and GeometryModel3D SDK Problem TextureCoordinates! "Roman" <Roman@discussions.microsoft.com> wrote in message news:CF952186-8DFA-4D55-8697-0E5B3EBED297@microsoft.com... > My attampt to associate a material (VisualBrush) with the mesh geomerty > failes. Nothing shows up; > > ImageSource imageSource = new BitmapImage(new Uri(@"C:\done.JPG")); > ImageBrush imageBrush = new ImageBrush(imageSource); > Material diffuseMaterial = new DiffuseMaterial(imageBrush); > GeometryModel3D geometryModel3D = new GeometryModel3D(meshGeometry3D, > diffuseMaterial); > Model3DGroup model3DGroup = new Model3DGroup(); > model3DGroup.Children.Add(geometryModel3D); > > On the other hand, a solid color brush works fine > > Material diffuseMaterial = new DiffuseMaterial(new > SolidColorBrush(Colors.DarkKhaki)); > |
My System Specs![]() |
| | #3 (permalink) |
| | Re: DiffuseMaterial and GeometryModel3D SDK Problem Couldn't find any code examples. Do you have any? "Jason [Mobiform]" wrote: > TextureCoordinates! > > > "Roman" <Roman@discussions.microsoft.com> wrote in message > news:CF952186-8DFA-4D55-8697-0E5B3EBED297@microsoft.com... > > My attampt to associate a material (VisualBrush) with the mesh geomerty > > failes. Nothing shows up; > > > > ImageSource imageSource = new BitmapImage(new Uri(@"C:\done.JPG")); > > ImageBrush imageBrush = new ImageBrush(imageSource); > > Material diffuseMaterial = new DiffuseMaterial(imageBrush); > > GeometryModel3D geometryModel3D = new GeometryModel3D(meshGeometry3D, > > diffuseMaterial); > > Model3DGroup model3DGroup = new Model3DGroup(); > > model3DGroup.Children.Add(geometryModel3D); > > > > On the other hand, a solid color brush works fine > > > > Material diffuseMaterial = new DiffuseMaterial(new > > SolidColorBrush(Colors.DarkKhaki)); > > > > > |
My System Specs![]() |
| | #4 (permalink) |
| | Re: DiffuseMaterial and GeometryModel3D SDK Problem Jason, I fugured it out. It works. Thanks "Jason [Mobiform]" wrote: > TextureCoordinates! > > > "Roman" <Roman@discussions.microsoft.com> wrote in message > news:CF952186-8DFA-4D55-8697-0E5B3EBED297@microsoft.com... > > My attampt to associate a material (VisualBrush) with the mesh geomerty > > failes. Nothing shows up; > > > > ImageSource imageSource = new BitmapImage(new Uri(@"C:\done.JPG")); > > ImageBrush imageBrush = new ImageBrush(imageSource); > > Material diffuseMaterial = new DiffuseMaterial(imageBrush); > > GeometryModel3D geometryModel3D = new GeometryModel3D(meshGeometry3D, > > diffuseMaterial); > > Model3DGroup model3DGroup = new Model3DGroup(); > > model3DGroup.Children.Add(geometryModel3D); > > > > On the other hand, a solid color brush works fine > > > > Material diffuseMaterial = new DiffuseMaterial(new > > SolidColorBrush(Colors.DarkKhaki)); > > > > > |
My System Specs![]() |
| | #5 (permalink) |
| | Re: DiffuseMaterial and GeometryModel3D SDK Problem DanLehen has a good explanation of texture coordinates here: http://blogs.msdn.com/danlehen/archi...06/489627.aspx Jordan "Roman" <Roman@discussions.microsoft.com> wrote in message news:F5E1D0A1-85A6-4D12-9E78-088318531D11@microsoft.com... > Jason, I fugured it out. It works. Thanks > > "Jason [Mobiform]" wrote: > >> TextureCoordinates! >> >> >> "Roman" <Roman@discussions.microsoft.com> wrote in message >> news:CF952186-8DFA-4D55-8697-0E5B3EBED297@microsoft.com... >> > My attampt to associate a material (VisualBrush) with the mesh geomerty >> > failes. Nothing shows up; >> > >> > ImageSource imageSource = new BitmapImage(new Uri(@"C:\done.JPG")); >> > ImageBrush imageBrush = new ImageBrush(imageSource); >> > Material diffuseMaterial = new DiffuseMaterial(imageBrush); >> > GeometryModel3D geometryModel3D = new GeometryModel3D(meshGeometry3D, >> > diffuseMaterial); >> > Model3DGroup model3DGroup = new Model3DGroup(); >> > model3DGroup.Children.Add(geometryModel3D); >> > >> > On the other hand, a solid color brush works fine >> > >> > Material diffuseMaterial = new DiffuseMaterial(new >> > SolidColorBrush(Colors.DarkKhaki)); >> > >> >> >> |
My System Specs![]() |
| Thread Tools | |
| |
Similar Threads | ||||
| Thread | Forum | |||
| the problem with ndis.sys Blue Screen of Death problem solved? | Vista General | |||
| Re: Windows Mail Attachement Problem and Adobe Player Problem with IE8 | Vista mail | |||
| Generic McAfee Problem Message in Vista Problem Reports | Vista performance & maintenance | |||
| Vista Upgrade Problem - Windows Explorer Loop problem | Vista installation & setup | |||