|
-
Sep 12th, 2003, 02:04 PM
#1
help me convert this to C# code
VB Code:
Dim cMatrix As New ColorMatrix(New Single()() _
{New Single() {0.299, 0.299, 0.299, 0, 0}, _
New Single() {0.587, 0.587, 0.587, 0, 0}, _
New Single() {0.114, 0.114, 0.114, 0, 0}, _
New Single() {0, 0, 0, 1, 0}, _
New Single() {0, 0, 0, 0, 1}})
no luck so far
I had posted this in the CodeBank section
rate my posts if they help ya!
Extract thumbnail without reading the whole image file: (C# - VB)
Apply texture to bitmaps: (C# - VB)
Extended console library: (VB)
Save JPEG with a certain quality (image compression): (C# - VB )
VB.NET to C# conversion tips!!
-
Sep 12th, 2003, 02:25 PM
#2
like this you mean? ...
VB Code:
float[][] f = {
new float[] {0.299F, 0.299F, 0.299F, 0, 0},
new float[] {0.587F, 0.587F, 0.587F, 0, 0},
new float[] {0, 0, 0, 1, 0},
new float[] {0, 0, 0, 1, 0}};
ColorMatrix cMatrix=new ColorMatrix(f);
~
if a post is resolved, please mark it as [Resolved]
protected string get_Signature(){return Censored;}
[vbcode][php] please use code tags when posting any code [/php][/vbcode]
-
Sep 12th, 2003, 02:28 PM
#3
Originally posted by dynamic_sysop
like this you mean? ...
VB Code:
float[][] f = {
new float[] {0.299F, 0.299F, 0.299F, 0, 0},
new float[] {0.587F, 0.587F, 0.587F, 0, 0},
new float[] {0, 0, 0, 1, 0},
new float[] {0, 0, 0, 1, 0}};
ColorMatrix cMatrix=new ColorMatrix(f);
Many thanks!
hmm I wonder why MS cant stick to the same keywords when switching languages. Why float in c# then single in VB? aah just be consistent, stupid MS, hehe
rate my posts if they help ya!
Extract thumbnail without reading the whole image file: (C# - VB)
Apply texture to bitmaps: (C# - VB)
Extended console library: (VB)
Save JPEG with a certain quality (image compression): (C# - VB )
VB.NET to C# conversion tips!!
-
Sep 15th, 2003, 03:09 PM
#4
you could still use Single. Single is aprt of the .NET framework. I believe float is built into the C# specification and compiler..
-
Sep 15th, 2003, 04:49 PM
#5
Originally posted by Cander
you could still use Single. Single is aprt of the .NET framework. I believe float is built into the C# specification and compiler..
hmm so basically they convert to the same thing when compiled, right?
rate my posts if they help ya!
Extract thumbnail without reading the whole image file: (C# - VB)
Apply texture to bitmaps: (C# - VB)
Extended console library: (VB)
Save JPEG with a certain quality (image compression): (C# - VB )
VB.NET to C# conversion tips!!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|