Author Topic: Waveform & Visuals not Available in .net Standard/ .net core version of bass.net  (Read 1447 times)

DividedSE

  • Posts: 6
While Converting my .net 4.8 Project to .net Core. I tried my Bass Class Library to .net standard 2.0 & later tried .net core 3.1 both time waveforms & visuals class are getting missing assemble reference error & bass.misc greyed out
 Is it not supported?

Ian @ un4seen

  • Administrator
  • Posts: 25609
I'm not a .Net user myself, so I'm not certain, but I believe it is correct that BASS.Net's WaveForm class isn't available with .Net Core because it doesn't support the APIs that the class uses.

radio42

  • Posts: 4833
Fully correct! WaveForm and Visuals rely in the default .Net implementation on GDI+ rendering, which doesn't exist for .Net core/standard.

DividedSE

  • Posts: 6
@radio42 I Can still use those functions (waveforms+visuals) properly in .net5.0 (maybe also in .netcore3.1) by just referencing to the v4.5 framework of bass.net.dll & system.drawing.common by microsoft via nuget.

Microsoft has released System.Drawing.Common to provide access to GDI+ graphics functionality cross-platform. Maybe an update to Bass.Net.dll for .core3.1/.net5.0 in future soon?

& Also no matter which type of bass.net.dll i used in framework/standard/core in .netcore/5 application bass.loadme() & bass.loadme(path) always returns false. But everything works fine other than that
« Last Edit: 4 Feb '21 - 12:21 by DividedSE »

radio42

  • Posts: 4833
Theoretically yes, but then I would need to build a version which always references those libs, which might not be wanted by many other users...
But...I think about this!

Andy09

  • Posts: 32
@Bernd
Oh, yes, please. I'm search since a few weeks for a solution to draw waveforms in .Net Standard and .Net Core.

Andy

radio42

  • Posts: 4833
It is not easy to add - but the drawing isn't that complex - so you might try yourself...?

Andy09

  • Posts: 32
It is not easy to add - but the drawing isn't that complex - so you might try yourself...?
Hi,

yes, is not easy to add in net standard, i know. But i have no idea to start the coding (GetStreamData and Draw Lines).
Have any one a simple idea/sample to do this in UWP oder WPF?

Andy

BaseHead

  • Posts: 194
Andy,
We made our own WF Drawing for BASS years ago as BASS.NET is limited to 2 channels and we needed 10-12 channel drawing and above.
We are going .NET5/6 soon from 4.8

I will gladly share you our C# code if you have the capabilities and think you can get it working in .NET5/Core and make a library out of it.
Then just hand it back to us so we can plug it in easily when we are ready to make the move to Core in the next few months..  ;-)
Scratch our back and we'll scratch yours....hehe

Interested?
send me your email if so so we can discuss it offline.  ;-)

trojannemo

  • Posts: 91
Sorry to resurrect such an old thread, but I'm having similar issue now in going from .NET Framework 4.8.1 to NET 6. I spent a while getting everything ported in my project, and everything is good until I go to run it and it tells me that this new version of Bass.NET doesn't support visuals, which I heavily relied on for the last 10 years.

System.TypeLoadException: 'Could not load type 'Un4seen.Bass.Misc.Visuals' from assembly 'Bass.Net, Version=2.4.17.2

It's been two years since this thread was started. Is there really no solution to this issue yet?

radio42

  • Posts: 4833
There is no standard UI/graphics support available in .Net.
E.g. the System.Drawing.Common namespace is only supported under Windows. So it wouldn't make sense to port to .Net 6 in such case, if you still reply on a pure Windows based code namespace.
And Microsoft.Maui.Graphics is still experimental.

What is your suggestion?
Maybe someone can come up with a nice idea or even library here?

Else, you might need to implement your own visuals and drawing based on your own library of choice for .Net 6 core or higher - a lib, which is supported on all OSs?!

trojannemo

  • Posts: 91
I do not have the knowledge or skills to create my own library, hence why I have relied on your wrapper and Ian's library for the last decade.

It is wild that Microsoft pushes one to update/upgrade to NET 6/7/8 and in doing so, users lose features instead of gaining features. I'm still in the process of porting from 4.8.1 to 6 and i've had to eliminate two major features "just" to get it to run. I'm fairly sure i'm going to have to stick with 4.8.1.

radio42

  • Posts: 4833
With my product I am also still on v4.8.1. And I don’t see any real benefit porting it to .Net core for exactly the same reason.
The same is true for WinForms applications. This is declared ‚dead‘ for decades, but except flaws and religious talks there is no real common alternatives.
As such WinForms is still alive !
Pretty much like a good old vinyl record, which was also declared dead… but is more alive as ever.

Yes, Microsoft has no good UI strategy for desktop apps out yet. Guess they believe most apps are web based nowadays.
But on the Backend side .Net core makes huge sense!
And I assume,