This is the discussion forum for Helix Toolkit.
For bugs and new features, use the issue tracker located at GitHub.
Also try the chat room!
0

3d cube with colored cells

TheInevitable360 4 months ago updated by anonymous 3 months ago 3

I am working on a code to build a 3D cube that has mesh/cell in each direction and each cell has its own color. now i sue this method which produces exactly what i want:

private void BuildCustomCube22(int x, int y, int z)
{
    double cubeSize = 1.0; // Size of each cube cell

    Random random = new Random();

    var modelGroup = new Model3DGroup();

    for (int i = 0; i < x; i++)
    {
        for (int j = 0; j < y; j++)
        {
            for (int k = 0; k < z; k++)
            {
                var position = new Point3D(
                    i * cubeSize + cubeSize / 2,
                    j * cubeSize + cubeSize / 2,
                   k * cubeSize + cubeSize / 2);

               // Generate a random color for each cube
               Color color = Color.FromRgb((byte)random.Next(256), (byte)random.Next(256),
               (byte)random.Next(256));

               var cube = new BoxVisual3D
               {
                   Center = position,
                   Width = cubeSize,
                   Height = cubeSize,
                   Length = cubeSize,
                  Material = MaterialHelper.CreateMaterial(color),

                };

               // Add the cube to the model group
               modelGroup.Children.Add(cube.Model);
           }
       }
   }

    // Add the model group to the viewport
    viewport.Children.Add(new ModelVisual3D { Content = modelGroup });
}

and the result is:

Image 195

The issue is when i increase mesh like 100*100*100, i get very poor performance like not being able to easily zoom in/out or move object around. I wonder how can i achieve the result i want event with high number of cells with no lag.

P.S: somebody told me: You are making way too many models. You can try to use Helix toolkit sharpdx version with instancing rendering capability

but i don't know if it can solve my issue and i don't know how to implement it. 

0

How to Share Mouse and Keyboard inputs with custom camera controller

Ahmed moussa 6 months ago updated 6 months ago 0

I made a custom camera controller to create an arcball camera movements, but I can't take mouse or keyboard inputs applied to the viewport
the mousedown event of my controller is bound to a border containing the viewport
the event only receives left mouse clicks 
is it possible to allow the border to receive inputs?

my camera controller will work as expected if I exposed the border ,like makeing a Margin for the viewport so that some area of the border is visible.
also hopfolly without  affecting the hit behavior ,that allows me to select  3d opjects by clicking on them .
also it's possible to to set the viewport as EventsSourceElement but will gave the same result ,although it's better to use a border .

I am using SharpDX .Net6

//xaml <Grid Grid.Column="1"> <Border Name="ViewportBor - Pastebin.com


<script src="https://pastebin.com/embed_js/GBXdzyiL?theme=dark"></script>

0

шкаф угловой эверест

kontent seo 7 months ago 0

Угловой шкаф Everest - это идеальное решение для максимального использования углового пространства в вашем доме. Его компактные размеры и эффективное расположение полок и отделений делают его незаменимым элементом любого интерьера. Этот шкаф позволит вам оптимально организовать хранение одежды, обуви, аксессуаров и других вещей, даже если у вас ограниченное пространство. Кроме того, угловой шкаф Everest отличается стильным и современным дизайном, который добавит уют и функциональность вашей комнате, при этом не занимая лишнего места. Это идеальное решение для тех, кто стремится максимально эффективно использовать каждый угол своего дома.

тумба для обуви Эверест
пеленальный комод эверест
шкаф угловой эверест
меблі Еверест
0

кухня эверест

Marina Pokrovska 10 months ago updated by kanpat88 7 months ago 1

Кухни Эверест: Комфорт и функциональность

Кухня Эверест - это идеальное решение для тех, кто ценит комфорт и функциональность в своей кухне. Они предлагают широкий выбор моделей и дизайнов, позволяющих адаптировать кухню к вашим потребностям и предпочтениям. Кухни Эверест отличаются высоким качеством изготовления и использованием прочных материалов, обеспечивающих долговечность и надежность.

0

Compatibility with Visual Studio 2022 + Windows 11

Robin 2 years ago 0

Hello,

im currently working on a visualization software which is using the Helixtoolkit Viewport for an demanding appearance of 3D Models, with all the features of Helix it offers, like clicking on an object and rotating the viewport.

Since i like it very much and it allows me to work with .stl files. I'm a bit concerned about the future compatibility.
Mainly i'm working with the package Helixtoolkit SharpDX.WPF.Core (or how it is called precisely)

Does anybody have experience concerning the compatibility of the Helix Packages with:

- .NET6 (currently i'm still developing with the .NET5 (Core) Framework) ?
- Can i compile and build .NET projects with Visual Studio 2022 (using the newer Releases of Helix) or are there problems occuring ?

- Could there also occur problems if i switch over to Windows 11 as OS or will it basically just run like on Windows 10 ?

If any of you have some experience concerning my questions i would be glad if you can share it with me.

Thanks.

0

Is it possible to draw a simple text

Michael Insberg 2 years ago 0

Hi,

I want to draw a text with helix anny suggestions how to do that?

Greeting Michael

0

Rotating Label

Alberto 2 years ago 0

Hi, I made an application which render a panel that might have different texture on each side. The model is free of rotation over all axes. My boss asked me if would be possible to identify each panel side with a label (one digit for each side) and let it rotate with the panel... but sincerely I dunno how to achieve this, expecally to keep each label "in front" of the view point.

Any hints?


Image 181

0

.net core reference

Damien Darhk 3 years ago 0

I'm trying to port a .net framework app to .net core (3.1), so I get the packages from nuget helixtoolkit, helixtoolkit.core.wpf and helixtoolkit.core.sharpdx. But the regefence in xaml, that I copied here: http://docs.helix-toolkit.org/en/latest/wpf/getting-started.html#adding-the-toolkit-to-your-xaml is not correct. errors desappear if I reference  xmlns:HelixToolkit="http://helix-toolkit.org/wpf", but app not show anything and crash.What am I missing?
























































































0

writing up docs

jmg07 3 years ago 0

Hi, 

if anyone wanted some help writing up docs for helix toolkit happy to help.

0

Can helix toolkit be used with .NET 5.0? And which nuget SharpDX package should be used?

jmg07 3 years ago 0

Hi, 


I'm guessing helix toolkit can be used with .NET 5.0 because it works in my wpf project - but i did notice in the package tab it says "Package 'HelixToolkit.Wpf.2.17.0 "  was restored using .NetFramework.Version=4.6.1, etc."" 


I wasn't 100% sure which nuget package to use - the "HelixToolkit" or "HelixToolkit.Wpf".


And at the link https://github.com/helix-toolkit/helix-toolkit there are a list of sharpDX packages and wasn't sure whether to use HelixToolkit.SharpDX.wpf or HelixToolkit.SharpDx.core.


Thanks.