Gildor's Forums

Author Topic: Problem with compile Umodel Source Code on VS  (Read 1626 times)
BatFan
Newbie
*
Posts: 31


Smasha


View Profile
Problem with compile Umodel Source Code on VS
« on: April 06, 2020, 00:50 »

Hello again,
Before start explain my technical issue, I get idea for learning C ++ a week ago.
For now I able to write a simple programs such as calculator,
of corse using my notes sometimes,
It is a book made by Alex Allain, and I still learn variables in C ++

Okey so, I have Windows 7 64-bit and Visual Studio 2019 (community version) from last year.

I understood your ReadMe file and I replaced in the build.sh
"$PLATFORM" ] || PLATFORM="vc-win32" on
"$PLATFORM" ] || PLATFORM="vc-win64"

Next I found sln, vcxproj stored in the
UEViewer\Tools\UITest\vs

When program was compiled I seen UI Test window instead Umodel viewer.

You know what's going on?
What I did wrong, how resolve that?

My goal is test your source code by compile.
And Include some cpp files in the solution.

Thanks!
Logged
Gildor
Administrator
Hero Member
*****
Posts: 7969



View Profile WWW
Re: Problem with compile Umodel Source Code on VS
« Reply #1 on: April 06, 2020, 09:57 »

The solution you mentioned is used for UI Test (didn't you see it's name??) - it's NOT UModel.
To open UModel, you should use VS or VSCode, and use "open folder", pointing at UModel's ROOT directory (not Tools....).
Logged
BatFan
Newbie
*
Posts: 31


Smasha


View Profile
Re: Problem with compile Umodel Source Code on VS
« Reply #2 on: April 06, 2020, 16:01 »

Okay I understood, I downloaded as zip from github instead clone repository option for VS.
But I never compile program with ''Launch Json'' in VS and VS Code.
Typically I choose vaild start up item (file) sln or csproj for compile.

So with Json files it can't work for me, because I get error message in the debug console.

You know what I missing?
Logged
Gildor
Administrator
Hero Member
*****
Posts: 7969



View Profile WWW
Re: Problem with compile Umodel Source Code on VS
« Reply #3 on: April 06, 2020, 16:38 »

I do not know what you're doing, your explanation is not well. May be you can record a video?
Logged
BatFan
Newbie
*
Posts: 31


Smasha


View Profile
Re: Problem with compile Umodel Source Code on VS
« Reply #4 on: April 06, 2020, 18:19 »

I just need a guide step by step, how compile your program.
Also I want to say...
how you compiled your own program before release?

I think it should work, but I want ask you what software/freeware you're using?

I can record a video but it doesn't matter in this case.


If you want ask me what I want change with your source code, I have some plans to include files to work with whole existing codes, expecialy I want develop your program for new function for myself.

I don't want to say, what new function I apply in the near future to the Umodel because it would be illegal.

Saying illegal, I mean these things that you can't realise for your program and tools.
So I get idea to build it for myself.

Logged
Gildor
Administrator
Hero Member
*****
Posts: 7969



View Profile WWW
Re: Problem with compile Umodel Source Code on VS
« Reply #5 on: April 06, 2020, 19:06 »

In Visual Studio: open the project (folder), select configuration (if it's not yet selected - e.g. "Win64-Debug"), press "Build" button. Can also run, just need to select configuration again - they're configured in .vs/launch.vs.json.
In Visual Studio Code: open the project, build using Ctrl+Shift+B key, in debug pane select the configuration for launch, press "Run" button.

There's nothing special what should be done to achieve this, except may be requirement to have BuildTools - but I suppose you've read README.md and did that step. Regarding tweaks for Win64 which you mentioned, they're not necessary anymore - my build system has a possibility to select 64 bit platform without changing any files.

Personally I'm building UModel from VS or VSCode (these IDE's has different possibilities and different bugs), sometimes using command line (this was described in README.md).
Logged
BatFan
Newbie
*
Posts: 31


Smasha


View Profile
Re: Problem with compile Umodel Source Code on VS
« Reply #6 on: April 08, 2020, 02:20 »

Now I can't figure what I did wrong.
In the default VS I added folder containing Umodel source code and I selected Win 64-Debug for my device, then I wanted select the start up item on Current document, but I could not open vs or vs.code folder (for Launch.Json) becuase I doesn't see this folder in the Solution Explorer.

Anyway the executable which I found in that source code, working correctly becuase I downloaded missing dll module to the main directory
SDL2.dll - 775 Kb

But I still can't check process of compilation.

Help
Logged
Gildor
Administrator
Hero Member
*****
Posts: 7969



View Profile WWW
Re: Problem with compile Umodel Source Code on VS
« Reply #7 on: April 08, 2020, 09:34 »

This is why I asked for recording a VIDEO. Your English and QA skills are not enough to explain things in understandable way.
Logged
BatFan
Newbie
*
Posts: 31


Smasha


View Profile
Re: Problem with compile Umodel Source Code on VS
« Reply #8 on: April 08, 2020, 11:58 »

Here
Link to video on Youtube - https://www.youtube.com/watch?v=0eFlUSHG8VA
Logged
Gildor
Administrator
Hero Member
*****
Posts: 7969



View Profile WWW
Re: Problem with compile Umodel Source Code on VS
« Reply #9 on: April 08, 2020, 12:20 »

I see you have "build failed". When build succeeded, SDL2.dll will be automatically copied next to umodel.exe (the dll is somewhere in "libs" folder).
Your mistake: you didn't look at build output, it should say what's wrong exactly. Just an assumption: you probably didn't follow BuildTools setup mentioned in my instructions.
Logged
BatFan
Newbie
*
Posts: 31


Smasha


View Profile
Re: Problem with compile Umodel Source Code on VS
« Reply #10 on: April 08, 2020, 12:29 »

I try to copy your dll to the main directory (x64) and I get another error, with that dll from browser, working.

Okey so I'm going to BuildTools setup and I call if found another problem.

Logged
BatFan
Newbie
*
Posts: 31


Smasha


View Profile
Re: Problem with compile Umodel Source Code on VS
« Reply #11 on: April 08, 2020, 13:24 »

Yes, Thank you!
It work!
https://ibb.co/N6QnPHC - image

Now I'm back to learn C++ and test program with new codes!


* YES FINALLY.png (144.36 KB, 1366x728 - viewed 185 times.)
Logged
BatFan
Newbie
*
Posts: 31


Smasha


View Profile
Re: Problem with compile Umodel Source Code on VS
« Reply #12 on: April 09, 2020, 15:19 »

I see,  shocked
I running the executable file (umodel.exe with one assigned dll)
But I don't know one thing... why you put umodel.exe into github source code.
And I don't know why I still compile ready executable in Visual Studio.
Becuase, when I deleted the all source codes I still able to compile and run your program, becuase it open just umodel.exe in VS.
I thought that written codes in C++ are build and compiled to machine code (exe and dll)

You can explain what's going on?
I really want to see your video on youtube when the same source code is compile.
You can help many people.  grin
Logged
Gildor
Administrator
Hero Member
*****
Posts: 7969



View Profile WWW
Re: Problem with compile Umodel Source Code on VS
« Reply #13 on: April 09, 2020, 17:11 »

But I don't know one thing... why you put umodel.exe into github source code.
To be able to find when some bug appeared. I can grab exe from github for some version and see if bug exists there or not.
Quote
And I don't know why I still compile ready executable in Visual Studio.
What do you mean?
Quote
I really want to see your video on youtube when the same source code is compile.
I'm not a programming teacher. I can't waste my time writing programming tutorial videos. And I doubt there will be people watching that.
Logged
BatFan
Newbie
*
Posts: 31


Smasha


View Profile
Re: Problem with compile Umodel Source Code on VS
« Reply #14 on: April 09, 2020, 19:55 »

As i know you like use VScode, because it has better debugger (as you said)
So you can tell me about compile your source code in VScode?
Because I only understand guides in points.

I don't wan't torture you Mr.Gildor but I wanna just guide like:
1. ''Open that...''
2. ''then select...''
3. ''Go to and click...''

Then I will able back to reading C++, because without that compile I won't finish my next thing.
Please.
Logged
Jump to:  

Powered by SMF | SMF © 2006-2009, Simple Machines LLC
Leviathan design by Bloc | XHTML | CSS