Jump to content
  • Register Now

    Sign up and take advantage of the features of our community! Some forums are only accessible to our members!

GR2 Tool [optimize, change textures, convert to fbx or 3ds, etc]


Recommended Posts

Hey guys,

 

Last night I was kinda playing with granny a bit and this tool was born.

I hope it will be useful for most of you!

 

Downloadhttps://distraught.hu/download/m2dev/GR2Tool_by_Distraught.exe

Usage: Just drag and drop a gr2 file on the exe and choose what you would like the program to do.

 

gr2_tool_by_distraught_preview.jpg

 

P.S.: Don't be surprised if the new gr2 file becomes bigger than it was, it is because this tool saves them without compression for better performance.

Edited by Distraught (see edit history)
  • Love 10
  • Party 1

AxgtRfG.png
C++ programmer at Gameloft

 

1331

Link to post

Good idea, Thanks for the tool.

 

I don't know how that sounds to others but to me sounds weird -> 

 

Last night I was kinda playing with granny a bit and this tool was born.

  • Lmao 3
Link to post
56 minutes ago, HITRON said:

Good idea, Thanks for the tool.

 

I don't know how that sounds to others but to me sounds weird -> 

 

Last night I was kinda playing with granny a bit and this tool was born.

 

haha that was intentional :P 

  • Lmao 1

AxgtRfG.png
C++ programmer at Gameloft

 

1331

Link to post
Posted (edited)

Theoretically en bloc it gives some performance gain. For example converting meshes to 16bit indices even tho sounds strange because modern cpus work faster with their native word size but the less cache miss because of the size optimization can turn the balance to the other way around.

Edited by Distraught (see edit history)
  • Love 1

AxgtRfG.png
C++ programmer at Gameloft

 

1331

Link to post
  • 3 weeks later...
  • 2 weeks later...

Thanks a lot for this tool.

I'd like to write a tool that does this process automatically. Could you make a version where you can already specify in command line what you'd like to do with the gr2 file? This way I'd write a program that automatically cleans and optimizes all gr2 files in a folder.

If I use your tool like this it doesn't work:

gr2tool.exe test.gr2 1

It always claims that you first have to give  the gr2 file as an argument and then choose the option afterwards. I'd rather be able to execute the program in one line. If that's not possible it's also okay, I'd share the bulk program here with source code.

Also is there an option to just overwrite the gr2 file instead of adding _new to it? Maybe create a backup file instead and keep the original name?

Edited by Vanilla (see edit history)
  • Love 1

We are the tortured.
We're not your friends.
As long as we're not visible.
We are unfixable.

Link to post
2 hours ago, Vanilla said:

Thanks a lot for this tool.

I'd like to write a tool that does this process automatically. Could you make a version where you can already specify in command line what you'd like to do with the gr2 file? This way I'd write a program that automatically cleans and optimizes all gr2 files in a folder.

If I use your tool like this it doesn't work:

gr2tool.exe test.gr2 1

It always claims that you first have to give  the gr2 file as an argument and then choose the option afterwards. I'd rather be able to execute the program in one line. If that's not possible it's also okay, I'd share the bulk program here with source code.

Also is there an option to just overwrite the gr2 file instead of adding _new to it? Maybe create a backup file instead and keep the original name?

 

I wrote a tool long ago for this, pretty much you can do it in one or two lines in batch.

Simply do a for loop for every file in a given folder and apply the preprocessor action (you can take the one from this git), specify the file name as the output and it will get the thing done :D

  • Love 1
Link to post
27 minutes ago, Gurgarath said:

 

I wrote a tool long ago for this, pretty much you can do it in one or two lines in batch.

Simply do a for loop for every file in a given folder and apply the preprocessor action (you can take the one from this git), specify the file name as the output and it will get the thing done :D

Ah so you're using a different program? Because if I use both arguments I cannot run the tool, it throws an error. I mean I could technically just issue a cmd.exe and further trigger the file processing. But that's kinda overcomplicated so I was asking if the dev can adapt his tool. I'd do it myself but since it's not open source I can't mangle with it :D For me there are only two things that would be cool - an option to keep the original file name and to add the option (what you wanna do with the file) in the first command line. This way it's easy and there'd be many many options, I'd even write a simple python script that does the magic^^'

  • Love 1

We are the tortured.
We're not your friends.
As long as we're not visible.
We are unfixable.

Link to post
On 9/25/2020 at 3:39 PM, Vanilla said:

Thanks a lot for this tool.

I'd like to write a tool that does this process automatically. Could you make a version where you can already specify in command line what you'd like to do with the gr2 file? This way I'd write a program that automatically cleans and optimizes all gr2 files in a folder.

If I use your tool like this it doesn't work:

gr2tool.exe test.gr2 1

It always claims that you first have to give  the gr2 file as an argument and then choose the option afterwards. I'd rather be able to execute the program in one line. If that's not possible it's also okay, I'd share the bulk program here with source code.

Also is there an option to just overwrite the gr2 file instead of adding _new to it? Maybe create a backup file instead and keep the original name?

Thanks for the suggestions, I will release a new version with the options you mentioned somewhen today evening.

  • Love 1

AxgtRfG.png
C++ programmer at Gameloft

 

1331

Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.