Recent Posts

Pages: 1 2 [3] 4 5 ... 10
21
WIP / Re: There are many ways to go to Rome.
« Last post by Patrice Terrier on April 23, 2019, 03:04:30 pm »
No, there was no recorded voice of me in the video.

Quote
(our biggest and most immediate challenge is a full scale unlimited undo-redo stack to avoid possible irreparable damage to our model files likely to occur while debugging the .OBJ file save routines)
That's the easy part, first thing would be to create a .bak of the .obj when saving.
And as long as we test it, working on a copy rather than the original.

For undo-redo, a dynamic global vector array is what i would use, with a structure like this.

struct UNDO_REDO {
    long idx;
    float texCoord[2];
}
to save the
gtm_vertexBuffer[idx].texCoord[0]
gtm_vertexBuffer[idx].texCoord[1]
and two new buttons for undo, redo, and perhaps a third one to restore everything.
22
WIP / Re: There are many ways to go to Rome.
« Last post by Michael Lobko-Lobanovsky on April 23, 2019, 12:18:20 pm »
Thanks for the update, Patrice! Is the video supposed to carry your voice record? Unlike your former videos, this one only produces a few unintelligible sounds on all my players... :-\

I'll inspect your code and submit my review later as I have to attend to some real life duties first.


(our biggest and most immediate challenge is a full scale unlimited undo-redo stack to avoid possible irreparable damage to our model files likely to occur while debugging the .OBJ file save routines)
23
WIP / Re: There are many ways to go to Rome.
« Last post by Patrice Terrier on April 23, 2019, 10:34:03 am »
Here is the Tor.zip able to render VT texCoord that are out of the 0-1 range.
(see the attached harley_quinn.mp4 video)

Search for rxCoord, ryCoord

This version is also able to deal with small textures, look for the comment:
// Resize everything to at least 1024, to ease working with UV's map

Note: tolerance + LMB selection not done yet in this version.

But, our biggest challenge is to update the .obj file with the updated VT texCoord  :(
24
WIP / Re: There are many ways to go to Rome.
« Last post by Michael Lobko-Lobanovsky on April 23, 2019, 12:16:49 am »
May I ask how you managed to do that?
25
WIP / Re: There are many ways to go to Rome.
« Last post by Patrice Terrier on April 22, 2019, 11:12:08 pm »
i got "harley queen" VT to work in both 2d and 3d view.
26
WIP / Re: There are many ways to go to Rome.
« Last post by Michael Lobko-Lobanovsky on April 22, 2019, 09:43:14 pm »
Patrice,

The tolerance should be +/-1 px with respect to the hot spot, i.e. 3x3 pxs all in all as I've been telling you all the time. Hopefully, the red sprite is going to be exactly that size?

Re. texture resizing, OK let's live and see how it works in practice.

Any further comments on what exactly have you got to work? Is it texture tiling for the protruding UV coords?
27
WIP / Re: There are many ways to go to Rome.
« Last post by Patrice Terrier on April 22, 2019, 11:26:49 am »
I think i got it to work, crossing my fingers  :-X

To ease UV mapping every texture smaller than 1024, is now resized to 1024 (while preserving the real size of the disk file). Of course, resizing the 8x8 "neutral_bump.png" to 1024, would cause bluring on edges, but that's the best way to work with such a small texture in Tor.

I plan to add a tolerance to select a specific dot with the MLB, then i shall put a sprite at the selected x,y location to easily change the coordinates, just like what i am doing with a marker in gMap64.
28
WIP / Re: There are many ways to go to Rome.
« Last post by Michael Lobko-Lobanovsky on April 22, 2019, 02:48:32 am »
On giving it a second thought, in order to protect Tor against attempts to display what it currently can't do, the floating point UVs should be evaluated for fitting in the 0.f to 1.f range. Those UVs (and their associated tris!) that fall outside those extrema should be discarded when drawing the UV map.

It's going to narrow the visible and serviceable part of the UV map display but it will also definitely help to avoid meaningless smear in the 2D viewport, straighten out the calc, and preclude possible memory crashes.
29
WIP / Re: There are many ways to go to Rome.
« Last post by Michael Lobko-Lobanovsky on April 22, 2019, 02:28:49 am »
Patrice,

This will require yet more effort on your behalf, my friend. Tor's zoom control must have the ability to not only zoom into the existing texture, but to also tile it, cross-wise, in any of the four directions while zooming, as many times as there are whole integer parts in the extreme floating-point UV coordinates of the mesh. (Think of how many of them would be cleared out if fmod() were applied). Then the offending UV coords would fit into the boundaries of their respective tiles, and the tris that are using those UVs would protrude in the correct directions as far as they should, again ultimately passing through as many tiles on their way as there are whole integer parts in the extreme UV floating point coords of a given mesh.

Then, when the pixel width and height of the texture involved in the calculation is multiplied times the number of whole integer parts in the extreme floating-point UVs, the calculations will return to normal again. But the zoom control should be prepared to depict those extended areas correctly in its 2D viewport too. You cannot simply wrap (map) the extended UVs to the same tile by fmod()'ing out the whole integer parts because then the tris associated with the extended UVs will not protrude in the correct directions.

Look again at the attachment to this message to see how Xandreale used to implement it in its vertex color editor.

Such mesh UVs occur quite often in tiled (GL_REPEATed) textures, but I think you should first get your one-tile (GL_CLAMPed_TO_EDGE) implementation straightened out and then proceed to that general-case extended solution... ???
30
WIP / Re: There are many ways to go to Rome.
« Last post by Patrice Terrier on April 21, 2019, 07:30:46 pm »
My friend

What to do if the texCoord are not within the range 0.0f to 1.0f
See the attachment, when trying to display the Harley Quinn model

example of vt from the HQ.obj
vt -0.05420000106096 1.62569999694824 0
vt -0.08179999887943 1.60469996929169 0
vt -0.07450000196695 1.651899933815 0
vt -0.02749999985099 1.64749991893768 0
vt -0.11209999769926 1.63160002231598 0
vt -0.04580000042915 1.68409991264343 0

vt 1.3798999786377 1.87689995765686 0
vt 1.36230003833771 1.85829997062683 0
vt 1.38380002975464 1.85710000991821 0
vt 1.3643000125885 1.83739995956421 0
vt 1.38769996166229 1.83589994907379 0
vt 1.36619997024536 1.81639993190765 0
vt 1.39160001277924 1.81459999084473 0
# 2258 texture coordinates

Of course the computation of the resulting x,y coordinates are totaly wrong  ???
Pages: 1 2 [3] 4 5 ... 10