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 - Darkstar2

751
What screen resolution are you viewing this on ?
I think this has to do with scaling.

I have done tests using game room 1:1 with screen res, (no scaling) and they display fine,
also at monitor's native resolution, evenly spaced and fine.


752
There you go finally !

I know nothing is wrong with my system and this whole "oh it's you only" thing is rubbish.

Thanks for confirming !  I too tried it on completely different hardware/systems and had the same result.

If people are testing differently then maybe they are not seeing it.

I've never EVER had this problem in any game or any demo, I don't give a crap if they use their own method, fact is nothing is wrong with my hardware.

We already exhausted all the possibilities with offsetting values......

Now the only thing that works is the round 1000 on all vertice, I made a complete report in previous posts.
combined with using font size 14 minimum and aa set to 1.



753
Very confused here, Robert seems to suggest that everyone complains when offsets are present, and that I am the only one having issues with or without offsets, so by that I am to understand that nobody has any issues with fonts.  I find that really difficult to digest because I tried this shit on different systems and all behaved the same way.

My current system this shit was tested on:
Intel i5-3570k
16GB RAM Windows 7 64bit
EVGA GeForce GTX 660 Ti SC 2GB
Drivers 337.88 WHQL (NVIDIA)
----------------------------------------
My other older system I tried the same project on,
as you can see major differences between hardware
AMD Athlon X2 6400
2GB RAM Windows XP SP3
BFG GeForce 8800GTS 320 MB
Very old forceware drivers

2 completely different systems, same bloody display, same exact thing, identically displayed.

2 different chipsets, CPUs, grpahic cards, OS, so this rules out that anything is wrong with my system !!!

754
Also tried all the below, even worse, and the ones with xoff/yoff don't render any text at all.
So as of now I tried everything suggested,
the only thing that works for me is
Code: (cpp) [Select]
draw_vertex_texture(xx + g->x,  yy + g->y, round(g->tx * 1000) / 1000, round(g->ty * 1000) / 1000);
draw_vertex_texture(xx + g->x2, yy + g->y, round(g->tx2 * 1000) / 1000, round(g->ty * 1000) / 1000);
draw_vertex_texture(xx + g->x,  yy + g->y2, round(g->tx * 1000) / 1000,  round(g->ty2 * 1000) / 1000);
draw_vertex_texture(xx + g->x2, yy + g->y2, round(g->tx2 * 1000) / 1000, round(g->ty2 * 1000) / 1000);

This works for default font.

For declared font, any size 14 and above + AA of 1 or above works.

Please refer to the many posts previous to this for explanations and screenshots.

Thanks.


Yes, try that with floor, ceil and float. And also try this mix.

Code: (cpp) [Select]
draw_vertex_texture(xx + g->x,  yy + g->y, floor(g->tx * 100) / 100, floor(g->ty * 100) / 100);
draw_vertex_texture(xx + g->x2, yy + g->y, ceil(g->tx2 * 100) / 100, floor(g->ty * 100) / 100);
draw_vertex_texture(xx + g->x,  yy + g->y2, floor(g->tx * 100) / 100,  ceil(g->ty2 * 100) / 100);
draw_vertex_texture(xx + g->x2, yy + g->y2, ceil(g->tx2 * 100) / 100, ceil(g->ty2 * 100) / 100);

And also try this one.
Code: (cpp) [Select]
float xoff = 0.5 / texture_get_width(fnt->texture),
        yoff = 0.5 / texture_get_height(fnt->texture);
draw_vertex_texture(xx + g->x,  yy + g->y, round((g->tx + xoff) * 100) / 100, round((g->ty + yoff) * 100) / 100);
draw_vertex_texture(xx + g->x2, yy + g->y, round((g->tx2 + xoff) * 100) / 100, round((g->ty + yoff) * 100) / 100);
draw_vertex_texture(xx + g->x,  yy + g->y2, round((g->tx + xoff) * 100) / 100,  round((g->ty2 + yoff) * 100) / 100);
draw_vertex_texture(xx + g->x2, yy + g->y2, round((g->tx2 + xoff) * 100) / 100, round((g->ty2 + yoff)* 100) / 100);

And this one.
Code: (cpp) [Select]
float xoff = 0.5 / texture_get_width(fnt->texture),
        yoff = 0.5 / texture_get_height(fnt->texture);
draw_vertex_texture(xx + g->x,  yy + g->y, g->tx + xoff, g->ty + yoff);
draw_vertex_texture(xx + g->x2, yy + g->y, g->tx2 + xoff, g->ty + yoff);
draw_vertex_texture(xx + g->x,  yy + g->y2, g->tx + xoff,  g->ty2 + yoff);
draw_vertex_texture(xx + g->x2, yy + g->y2, g->tx2 + xoff, g->ty2 + yoff);

Also want to say that all this clusterFUCK of a problem that is a pain in my arsehole only affects TEXT !  Sprites, parts, shapes drawn all work fine, at least so far :D


755
Robert, your latest suggestions didn't give me results, only worse:

Code: (cpp) [Select]
float xoff = 0.5 / texture_get_width(fnt->texture),
        yoff = 0.5 / texture_get_height(fnt->texture);
draw_vertex_texture(xx + g->x,  yy + g->y, round((g->tx + xoff) * 100) / 100, round((g->ty + yoff) * 100) / 100);
draw_vertex_texture(xx + g->x2, yy + g->y, round((g->tx2 + xoff) * 100) / 100, round((g->ty + yoff) * 100) / 100);
draw_vertex_texture(xx + g->x,  yy + g->y2, round((g->tx + xoff) * 100) / 100,  round((g->ty2 + yoff) * 100) / 100);
draw_vertex_texture(xx + g->x2, yy + g->y2, round((g->tx2 + xoff) * 100) / 100, round((g->ty2 + yoff)* 100) / 100);

and


Code: (cpp) [Select]
float xoff = 0.5 / texture_get_width(fnt->texture),
        yoff = 0.5 / texture_get_height(fnt->texture);
draw_vertex_texture(xx + g->x,  yy + g->y, g->tx + xoff, g->ty + yoff);
draw_vertex_texture(xx + g->x2, yy + g->y, g->tx2 + xoff, g->ty + yoff);
draw_vertex_texture(xx + g->x,  yy + g->y2, g->tx + xoff,  g->ty2 + yoff);
draw_vertex_texture(xx + g->x2, yy + g->y2, g->tx2 + xoff, g->ty2 + yoff);

Text is not rendered at all, nothing is shown.

Code: (cpp) [Select]
float xoff = 0.5 / texture_get_width(fnt->texture),
        yoff = 0.5 / texture_get_height(fnt->texture);
draw_vertex_texture(xx + g->x,  yy + g->y, round((g->tx + xoff) * 100) / 100, round((g->ty + yoff) * 100) / 100);
draw_vertex_texture(xx + g->x2, yy + g->y, round((g->tx2 - xoff) * 100) / 100, round((g->ty + yoff) * 100) / 100);
draw_vertex_texture(xx + g->x,  yy + g->y2, round((g->tx + xoff) * 100) / 100,  round((g->ty2 - yoff) * 100) / 100);
draw_vertex_texture(xx + g->x2, yy + g->y2, round((g->tx2 - xoff) * 100) / 100, round((g->ty2 - yoff)* 100) / 100);

and

Code: (cpp) [Select]
float xoff = 0.5 / texture_get_width(fnt->texture),
        yoff = 0.5 / texture_get_height(fnt->texture);
draw_vertex_texture(xx + g->x,  yy + g->y, g->tx + xoff, g->ty + yoff);
draw_vertex_texture(xx + g->x2, yy + g->y, g->tx2 - xoff, g->ty + yoff);
draw_vertex_texture(xx + g->x,  yy + g->y2, g->tx + xoff,  g->ty2 - yoff);
draw_vertex_texture(xx + g->x2, yy + g->y2, g->tx2 - xoff, g->ty2 - yoff);

Text completely distorted mess.  Here is an example, ignore blurriness again, the postimage hosting somehow
completely messes up the image quality.  The edges are razor sharp otherwise originally.





756
Issues Help Desk / Re: Font rendering is broken again !
« on: June 02, 2014, 03:30:25 pm »
My GPU has not changed, it is a GeForce GTX660 Ti SC 2GB

This is really strange, i've the GeForce GTX660 (OEM) 1.5GB, which is almost the same model, with the latest Nvidia drivers, and i don't have this problem.
I didn't read the whole thread, but just in case, did you try some OpenGl demos with text ? To see if the problem comes from OpenGl drivers or only with Enigma.

Only with ENIGMA and yes I mentioned this before :D

But that means nothing, the games or demos could be using their own internal fixes.

Here use this test:
copy and paste it in an object's draw event
set your monitor resolution to 800x600 (for the purpose of this test) and room size 640x480
Set interpolation to off, scale aspect ratio, window mode and let me know.
Make sure d3d set projection ortho offsets and GL MODEL VIEW offsets in GLMatrix.cpp are nil, meaning no offset at all !

draw_text(10,10,"11111111111111111111111111111111");


757


This seems to me be perfect Runes fonts ! What's the problem ?   ;D  ;)

http://en.wikipedia.org/wiki/Runes

Right FUNNY. :D

Trust me, these are 11111111111's you should be seeing !
The same when compiled using DX9 displays fine.

758
Thanks will go through the new ones you posted today + some left overs from yesterday.

You said "there is something else wrong with you...." No.  There is only one thing so far, it's to do with fonts.  The other minor things with fonts have nothing to do with ENIGMA but scaling.  Normal that if you upscale fonts to native resolution they will exhibit strange looks, (stair step or some letters fatter, etc) that is NOT a problem, but an effect of upscaling when using game res that don't match your screen res....  Good practices are up to the game developer.....

I could care less about that - What I am focusing on strictly now is the vertical line, dots and horizontal lines sometimes appearing on the fonts or around them.The fonts are neither blurry nor anything else.

BTW as I mentioned before, round 100 did not work too well on the first set of tests tried yesterday round 1000 did, should I still use round 100 in your examples above or change it to 1000 ?

Again here is another screenshot, result of 0 offset everywhere and all files back to their defaut.



Now if I declare a font, example arial size 50, no AA, the fonts display crisp but there is a straight vertical line to the left of 1, but not all 1's, only a few out of the lot of 1's. unfortunately cannot take a screenshot of that in FS.......

When using AA 1 + size 14 and above minimum these disappear and provide best results combined with the round 1000 as tested first time.

For my testing I use
Code used in draw event
Code: (GML) [Select]
draw_text(10,10,"11111111111111111111111111111111");

Ignore the blurry look on the text, I resized them 200% in PSP to make them bigger, and used bicubic sample instead of pixel resize......  The text was razor sharp otherwise, coming from ENIGMA.

This was done using monitor resolution 800x600,
game room 640x480

But I've seen this behaviour also on 1920x1080 and other res.

BTW, this is for OPENGL.

I went back and checked DX9, it's unaffected, so
DX9 works. so far.

759
lol, thanks, I've done all the first ones you suggested I will call it a night and work on the rest tomorrow.
BTW, this still is not a 100% fix, and a band aid, as there is something somewhere causing this, again this is just seems to shift things much like when I played with the projection ortho and GL MODEL VIEW offsets before :)

So anyhow,
1) if I understood your comment to me, you are telling me that with offsets 0.00/0.00 for BOTH projection ortho and GL VIEW your text displays fine and no scrolling glitch right ?

2) With round on all vertices with 1000, it solves the problem for window and full screen with default font and size so far across all screen resolutions I tested, from 320x200 ~ 1920x1080 (my native) hoping I did not miss anything.

However, when I tried different fonts and sizes I saw some vertical lines / dots on some letters / numbers, even when big.  Also there are other font glitches one might notice, if using too small fonts and certain screen resolutions, this is NOT an ENIGMA problem and so is up to the developer to use the appropriate size fonts for their game size.  but the lines, dots, etc those influenced by ENIGMA.

So finally after trial and error I found that with the combination of round 1000 across the board and the default font, things work great.  If using declared fonts, it is recommended using no smaller than 14 px, and using aa 1.  I found that with min 14 font size and above + 1 aa worked fine for me across all resolutions, window / full screen and tried different fonts.

So here are the changes I have done :
GSFont.cpp
Code: (cpp) [Select]
draw_vertex_texture(xx + g->x,  yy + g->y, round(g->tx * 1000) / 1000, round(g->ty * 1000) / 1000);
draw_vertex_texture(xx + g->x2, yy + g->y, round(g->tx2 * 1000) / 1000, round(g->ty * 1000) / 1000);
draw_vertex_texture(xx + g->x,  yy + g->y2, round(g->tx * 1000) / 1000,  round(g->ty2 * 1000) / 1000);
draw_vertex_texture(xx + g->x2, yy + g->y2, round(g->tx2 * 1000) / 1000, round(g->ty2 * 1000) / 1000);

Also, these changes apply for the default halign left and valign top.  Whatever is decided to be used, we'll have to change the other vertice for the others.

Will try the rest tomorrow.

See if you are ok with the changes above Robert and that they work for you.  I'm ok with this for now until we find a permanent fix.

Thanks.

760
Ok working on your suggestions now.

But first,  I did some google searching and found out that people's definition of artifacts varies.  I came upon sites where people were complaining of font artifacts and they were clearly not the same thing as I was describing.  The fix suggested on stackoverflow is for a different matter, whoever reported it called it artifact, when in reality it is truncation of edges.
Anyhow, so I'm assuming by what you are asking me that I have to change each vertice right ?
Such as following :
Code: (cpp) [Select]
draw_vertex_texture(xx + g->x,  yy + g->y, floor(g->tx * 100) / 100, floor(g->ty * 100) / 100);
draw_vertex_texture(xx + g->x2, yy + g->y, floor(g->tx2 * 100) / 100, floor(g->ty * 100) / 100);
draw_vertex_texture(xx + g->x,  yy + g->y2, floor(g->tx * 100) / 100,  floor(g->ty2 * 100) / 100);
draw_vertex_texture(xx + g->x2, yy + g->y2, floor(g->tx2 * 100) / 100, floor(g->ty2 * 100) / 100);

then changing the 100 to 1000 and / 1000, then 10000 and / 10000, then using ceil for all of them then round for all of them.  Just want to make sure I understood correctly.


761
General ENIGMA / Re: New Beginnings
« on: June 01, 2014, 01:00:54 pm »
My only complaint with ENIGMA is the fact that it is sexually confused.

Do elaborate ! :D

Quote
Anyway I am thinking of keeping the object resource for my spinoff and allowing sources and headers to be added with a simplification of the instance system allowing it to be easily coded giving you more control.

I am not sure if any of my ideas will come to fruition or not.

How long do you think this could take you ?  I've mentioned minimum 2+ years and that is being generous.  How long do you expect to do this, alone........  If you can pull this off, then someone should sign you up right away and hire you ! :P

I know of another project that was crowd funded, has an entire team and years later they still are working on it.  So how the bloody hell are you going to pull this off anyway, alone when you mentioned you barely have time to take care of ENIGMA ?

Either way, I am always willing to try something new and will be glad to take your new engine for a spin when it's done, assuming it's done on time before the end times :D

762
General ENIGMA / Re: New Beginnings
« on: June 01, 2014, 12:26:33 pm »
And finally we have Gamer maker. It's very easy to learn, and users can quickly make and test simple games. You have also integrated IDE for managing all aspects of the game. I think that's why, despite all its flaws, it is so successful.

Spot on !  GM had the potential of being so much more, but YYG came along and turned it into rubbish, to some extent, does not mean it is not good enough for a certain market, but there is another market looking for more, advanced stuff, and now they adopt a "let our users make stuff we were supposed to and enjoy the $$$" let's see how many said "extensions" will be worthy or start selling .....

Perhaps it's that  most GM users don't realise all the flaws in GM because they are not advanced or they don't make advanced games.  Or they settle for mediocrity.

@Lone
Quote
Same could be said about the ENIGMA project. Why use ENIGMA over GM:S?

That's an easy one to answer.
#1) It's FREE! It's OpenSource you can tweak it, modify it as you want.
#2) Non interpreted nature!  It is a C++ engine, it compiles your games, no dealing with gay runners.  Smaller files, faster games!
#3) For advanced users allows C++ in your projects, includes unique set of functions as well (EDL).
#4) Developers who listen and go out of their way to HELP, and who fix as much as they can any bugs / issues, even though they are severely understaffed.
#5) For windows developers especially, includes most functions that were deprecated from GMS for silly, unjustified reasons because of laziness !
there are probably more reasons too.


763
I know that, and I don't care, I want to know if the fonts do the same shit to you in windowed mode. If you have any sort of intuition as to whether Direct3D exhibits this, because it only had blurry text for me.

I will have to check again with DX9 will let you know.

Quote
The reason I mention is because when interpolation is on it does the same thing your fonts are doing now, because interpolation is on and all the characters are right next to each other on the texture, they interpolate into each other along their border, which causes similar artifacts to the ones you are describing. We also plan on fixing this by adding padding options to the font packer.

Ahh yes good point indeed, but I can assure you interpolation has always been off. BTW when I had this font issue that is the first thing I checked.

One thing to note, I use the 11111111111111 as example,
not all 1's have artifacts as I explained.  Wouldn't interpolation or vertex changing have an effect on all the 1's ? Why am I seeing those artifacts only on some 1's and not all ? I am using 1 as an example, but I tried with all the letters range and numbers, same, sometimes the lines are on top or bottom of letter or dots.

It was NEVER mentioned by me that my fonts are blurry in ENIGMA.
I had complained about that about GM and GMS, many have, they seem to use an alternate method of scaling.  I rather see stair stepped fonts (upscale) than ugly blurry fonts.  That has never been an issue for me in ENIGMA.  But I don't recall ever seeing the artifacts in GM:S either.    You are telling me that it is my hardware......:P  I would like for other people who have NVIDIA cards to test files I will upload soon, and more people with different cards.   BTW I will mention that no matter all offsets I have worked with none produced blurry fonts, only artifacts changed position :D
but fonts remained crisp throughout the entire ranges of offsets.

Quote
Which it has to be because the overdraw in your characters is obviously coming from the other characters on the texture.

But how would it explain that the artifacts are not unfirm on all characters?  Example if I were to use 1111111111111111111, not ALL the 1's would have the verticle line next to the 1, in fact most would be displayed ok but 1 in some offsets, in other offsets every 2nd 1 would have artifacts, etc.

Quote
Just to reaffirm, you have been having these vertical bar problems with fonts since you first used ENIGMA?

Good question.  I don't really recall seeing this when I first started using ENIGMA, but then again, I did not use text that much. and did not use full screen as much either.

The first time I ever noticed this glitch was with the image alpha project experiment where I was displaying text on the screen, this is the first time I accidentally stumbled on it. and reported the 1 being displayed weirdly.

Should I try downloading early revisions of ENIGMA and testing ?


764
Yes but that doesn't make any sense. The bars on every side of characters, how can shifting the projection 1px cause them to disappear? Did you make sure texture_set_interpolate(false); was off? Also, did you tell me whether or not Direct3D exhibited this issue?

I know it makes no sense I am just as puzzled about this :P
I already mentioned it is impossible to test with Direct3D because it is broken.  The moment you go full screen or even move the window or lose focus everything disappears.  So it's impossible
to test wit DX9 at this time.

Regarding texture_set function I never used this in my project.
is that the function that can be set inside the IDE ? Yes it's always off.  And yes I have tried setting it on, no change.  This doesn't relate to the artifacts. I've never had to turn this on. You mentioned something about font glyphs and font renderer, maybe the problem is somewhere there?


Ok let us try something else. Follow these exact steps.

Quote
1) Comment out the pixel offsetting in GLmatrix for the ortho projection, do not offset the model view and do not offset the projection.

By that you mean the 2 places I was changing offsets in the CPP,
the d3d set projection ortho and GL MODEL VIEW right ?

Quote
2) Open the following file.
https://github.com/enigma-dev/enigma-dev/blob/master/ENIGMAsystem/SHELL/Graphics_Systems/General/GSfont.cpp#L369
Try the following rounding calls for each of the texture coordinates of each vertice for the character.
floor(x * 100) / 100;
ceil(x * 100) / 100;
round(x * 100) / 100;
So for instance replace the first vertex as follows.
Code: (cpp) [Select]
draw_vertex_texture(xx + g->x, yy + g->y, g->tx, g->ty);
// change it to this
draw_vertex_texture(xx + g->x, yy + g->y, floor(g->tx * 100) / 100, floor(g->ty * 100) / 100);
3) Test the draw_text function for each combination and see how each behaves. Try with 1000, 10000 as well if 100 doesn't yield expected results.

This is a fairly simple test.

Very interesting thanks !  I will try this tomorrow during the day.

So will remove offsets in GLMatrix.cpp in 2 places as mentioned above and work on that file !

Thanks.

765
No it was the same way on my old AMD card.

The real problem here Darkstar, there's very little information on fixing half pixel alignment. I'm still confused as to whether or not you even have blurry text or if these offsets are fixing the bars on font characters.

Everytime I open this topic I want to cry.

I submitted every info I have, please re-read the entire topic
I uploaded a couple of screen shots to show you exactly what I mean.  Blur is not and has never been a problem, I showed you exactly what I mean by text problem, they are artifacts (small lines / dots around text) look at the screenshots I posted in this topic and you will see.

The offsets are indeed shifting out of view the lines next to text.
That's why I kept telling you the problem is not pixel alignment in regards to blur, but just so happens the fixes work because it is offsetting the artifacts out of view, maybe the real problem is in the fonts system / renderer ? Maybe something else can fix it I don't know.
Go check my screenshots I magnified and made it so big you will understand what I mean if you had seen them :D