Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - zsbzsb

Pages: 1 ... 92 93 [94]
1396
Graphics / drawing sprite is very slow..
« on: March 01, 2012, 03:22:49 am »
Looks to me like SFML 1.6. Any possibility that you have an ATI graphics card? One thing I would suggest, upgrade to SFML 2.0. It is much better(and faster).

1397
DotNet / Re: SFML.Net GUI?
« on: March 01, 2012, 03:16:28 am »
Quote from: "Richy19"
Just wondering if there are any SFML.net GUI's that work with the current graphcs API?

I haven't seen any, but it shouldn't be too hard to make a binding for the current c++ SFML GUIs out there. Just got to expose the methods in a c++ dll and then wrap it in c#/vb with pinvoke.

1398
DotNet / Small Bug with new Text(Text copy)
« on: February 29, 2012, 03:55:06 pm »
Quote from: "Laurent"
Sorry: "I'll fix it as soon as possible" :)

No problem, just wondered why you hadn't confirmed it.  8)
Thanks again for your great work with SFML  :lol:

1399
DotNet / Small Bug with new Text(Text copy)
« on: February 29, 2012, 02:20:53 am »
Nothing to say Laurent?  :?:

1400
DotNet / Small Bug with new Text(Text copy)
« on: February 27, 2012, 10:31:05 pm »
When creating a new Text object the new object does not have the position of the object that it was copied from. Here is a small and complete example that reproduces the problem.
Code: [Select]
using SFML.Graphics;
using SFML.Window;
namespace WindowsFormsApplication1
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }
        RenderWindow _window;
        Text _text1;
        Text _text1COPY;
        private void Form1_Load(object sender, EventArgs e)
        {
            _window = new RenderWindow(this.Handle);
            _text1 = new Text("Testing Text Copy", SFML.Graphics.Font.DefaultFont, 24);
            _text1.Position = new Vector2f(100,100);
            _text1COPY = new Text(_text1);
        }
        protected override void OnPaint(PaintEventArgs e)
        {
            _window.Clear(Color.Black);
            _window.Draw(_text1);
            _window.Draw(_text1COPY);
            _window.Display();
        }
    }
}


Basically when ran all you should see is one line of text being rendered. Instead you see 2 lines. The one line is at the set coordinates(100, 100) while the second line is at 0,0 because the original coordinates did not copy over.

Edit: Here is a screenshot of what the code renders.
http://imageshack.us/photo/my-images/189/textbug.jpg/

1401
DotNet / Quick Question - Text.GetRect
« on: February 27, 2012, 04:42:17 pm »
Quote from: "Laurent"
You're not seeing it because it's private. I'll fix this as soon as possible :)


Thank you Laurent  :D

1402
DotNet / Quick Question - Text.GetRect
« on: February 27, 2012, 04:36:50 pm »
Quote from: "texus"
You can use Text.GetGlobalBounds() or Text.GetLocalBounds().
These functions return FloatRects which contains the Width and Height.

Ok, So I am using the latest bindings for .Net and these appear to be missing. Is this a bug or am I just not seeing it?

http://imageshack.us/photo/my-images/254/missinggetbounds.jpg

Quote
And please try to use meaningful titles for your posts Wink

Sorry, I will change it.

1403
DotNet / Quick Question - Text.GetRect
« on: February 27, 2012, 02:09:55 am »
Just started updating my code to the newly released .Net bindings and I ran into a small issue. Before in my code I would use Text.GetRect() to center the text. Now I am looking around and I don't see anything to replace it. So my question is, is there anyway to get the Rect of a Text? Maybe possibly using the Text.Origin?

1404
DotNet / Is it possible to get a 2.x version of the .NET bindings?
« on: February 24, 2012, 11:53:12 pm »
Quote from: "Laurent"
The .Net binding is now up-to-date.

It's probably not bug free, so don't hesitate to provide feedback :)

Laurent, you are the best. I too have been waiting weeks for this.  :D  :D  Now I can get this into a couple of my projects that I have been waiting on. Just wanted to say thank you, thank you, thank you.  8)  8)

1405
Graphics / A few Questions regarding Text
« on: January 18, 2012, 02:20:52 am »
Quote from: "Mario"
Just look for an edge detector - should work fine (just detect changes in alpha).

Another solution (that might be slower but won't require shaders) would be rendering the same text multiple times:

Render in black at an offset of (-1, -1), (0, -1), (1, -1), etc. (8 positions), then render the final (and colored) text in the center (offset (0,0)). That way you'll get a nice thin outline, but you have to essentially draw the text 9 times. Depending on what you're doing, this might be acceptable or slow you down too much.

To mix, this would as well work by rendering into a RenderTexture, so you don't have to redraw everything every frame.


Thanks for the reply Mario, drawing a border by offsetting the text looks like what I want.

1406
Graphics / A few Questions regarding Text
« on: January 17, 2012, 12:20:39 am »
So far my project is coming along well. I am currently using .NET SFML 2. I only have a few questions around drawing text. My first question is that sometimes when drawing text at a low font size around 10-20 the text appears blurry. I was reading in some other threads to disable smoothing but I was unable to find that (so maybe an example?). The second question regards drawing text with an outline. I was also reading another (old) thread where the solution was to use a bitmap font or some form of shaders. I really do not want to use bitmap fonts because I load a font that is specified by the user. So that leaves me with only shaders. If using shaders is possible then could someone post an example on using them? (I'm new to the graphics stuff 8) )  Thanks in advance for replies.

1407
Window / Duel Monitors
« on: January 12, 2012, 03:51:29 pm »
Quote
Yes, you should find more details about this in the DotNet forum.


Thanks for the reply Laurent, I am currently looking through the DotNet forum for something but have not found anything(yet). I was hoping if you had any examples or links you could post them. I have tried this but it doesn't work.
Code: [Select]
_window = New RenderWindow(form1.Handle)
Edit Ok sorry about my ignorance, I just found my issue... Thank you for your time.

1408
Window / Duel Monitors
« on: January 12, 2012, 03:23:14 pm »
Ok so I just found SFML and I really love the simplicity of your library. So I am developing an app using .NET and SFML that will be ran on a computer with duel monitors. My questions are...
1. Is there any way to get a list of monitors and then open SFML window on the specified monitor?
2. This isn't as important as #1, but is there a way to draw on a user control in a form instead of just to the render window?

Thank you for answering these questions.

Pages: 1 ... 92 93 [94]
anything