LinusTrinus icon indicating copy to clipboard operation
LinusTrinus copied to clipboard

Solved! Phone/head too big/small (lens renders both eyes squeezed on the bottom half of the screen)

Open SaintAnd opened this issue 1 year ago • 24 comments

Why is a small window broadcast, as if one lens is felt, and the second seems to be felt as being located outside the borders. How to fix it? Two problems, a small lens, the second lens seems to be gone.

Screenshot: https://ibb.co/4s1Tf7d

Changed different data in ffmpeg_fg.py and frame_generator.py fork

SaintAnd avatar Aug 10 '22 22:08 SaintAnd

How decide it error.

  1. Install wine
  2. Install Trinus for windows on wine (version for Google Cardboard)
  3. Start Trinus (cd $PATH_TO_TRINUS && wine TGServer.exe
  4. Press "Start" in program and press start "trinus" on android, then activate this
  5. When will be connect program and device you can change "Head mount" in top "Main".
  6. Exit Trinus on wine
  7. Start LinusTrinus and enjoy P.S. If you want change your own size. Edit TGServer.exe.config in $PATH_TO_TRINUS. In Line 29 change "[{"name":"Default_Any"," and other parametrs P.S.S. Sorry form my bad English

SaintAnd avatar Aug 11 '22 21:08 SaintAnd

How decide it error.

  1. Install wine
  2. Install Trinus for windows on wine (version for Google Cardboard)
  3. Start Trinus (cd $PATH_TO_TRINUS && wine TGServer.exe
  4. Press "Start" in program and press start "trinus" on android, then activate this
  5. When will be connect program and device you can change "Head mount" in top "Main".
  6. Exit Trinus on wine
  7. Start LinusTrinus and enjoy P.S. If you want change your own size. Edit TGServer.exe.config in $PATH_TO_TRINUS. In Line 29 change "[{"name":"Default_Any"," and other parametrs P.S.S. Sorry form my bad English

Does this work?

izzijaz avatar Apr 06 '23 10:04 izzijaz

Screenshot_2023-04-06-15-57-17-097_com.loxai.trinus.full.jpg

After doing so i got this very weird video output.

izzijaz avatar Apr 06 '23 10:04 izzijaz

Yes, it's working for me. In app you need turn off any function. Now I install it's app and will write here

SaintAnd avatar Apr 06 '23 11:04 SaintAnd

Screenshot_2023-04-06-15-57-17-097_com.loxai.trinus.full.jpg

After doing so i got this very weird video output.

You need turn off lens in android app. "Lens Off" https://ibb.co/jMKFW2B IMG_20230406_141754

SaintAnd avatar Apr 06 '23 11:04 SaintAnd

Screenshot_2023-04-06-15-57-17-097_com.loxai.trinus.full.jpg

After doing so i got this very weird video output.

This is after enabling lens in the app. How to properly configure this

izzijaz avatar Apr 06 '23 11:04 izzijaz

Disable lens. After disabling the lens function, ffmpeg will work and additionally make a picture from instead of this disabled function.

SaintAnd avatar Apr 06 '23 11:04 SaintAnd

Disable lens. After disabling the lens function, ffmpeg will work and additionally make a picture from instead of this disabled function.

Without the lens option enabled the picture is just a flat image and not suitable for vr. Very difficult to see

izzijaz avatar Apr 06 '23 11:04 izzijaz

@izzijaz I remembered. I made a possible use of lens warp with ffmpeg but didn't add how to do it here. I'll try to add it soon

SaintAnd avatar Apr 06 '23 11:04 SaintAnd

@izzijaz https://github.com/SaintAnd/LinusTrinus Try this repository. Maybe I add here

Yes, I edited this repositories. You can edit frame_generator/ffmpeg_double_fg.py next string: 73 ("filter_complex", f'split[lenl][lenr];[lenl]crop=iw/2:ih:iw/2:0,lenscorrection=k1=0.58101:k2=0[a];[lenr]crop=iw/2:ih:0:0,lenscorrection=k1=0.58101:k2=0[b];[b][a]hstack'),

And edit lenscorrection.

Maybe you need update ffmpeg to new version with support lenscorrection plugin

SaintAnd avatar Apr 06 '23 11:04 SaintAnd

@izzijaz https://github.com/SaintAnd/LinusTrinus Try this repository. Maybe I add here

Yes, I edited this repositories. You can edit frame_generator/ffmpeg_double_fg.py next string: 73 ("filter_complex", f'split[lenl][lenr];[lenl]crop=iw/2:ih:iw/2:0,lenscorrection=k1=0.58101:k2=0[a];[lenr]crop=iw/2:ih:0:0,lenscorrection=k1=0.58101:k2=0[b];[b][a]hstack'),

And edit lenscorrection.

Maybe you need update ffmpeg to new version with support lenscorrection plugin

Is there a setting for Vr Box lens?

izzijaz avatar Apr 06 '23 12:04 izzijaz

@izzijaz Yes you are right. This line is responsible for displaying the image and where you can distort the image for a specific helmet as you like.

SaintAnd avatar Apr 06 '23 12:04 SaintAnd

@izzijaz Yes you are right. This line is responsible for displaying the image and where you can distort the image for a specific helmet as you like.

Is there a reference list i can refer to for the values for different headsets. For example thr k1 value for vr box

izzijaz avatar Apr 06 '23 14:04 izzijaz

Is there a reference list i can refer to for the values for different headsets. For example thr k1 value for vr box

Did you manage to use my repository to customize the image output on a smartphone?

Answering your question, I will say that this is an experimental setting and you can only manually select the screen distortion by changing the values ​​in that seventy-third line.

You can install Trinus Cardboard VR for windows via windows, wine, playonlinux, lutris and so on. Then use the configuration file TGServer.exe.config . There is line 29 with this beginning: {"profiles":[{"name":"Default Simulator" ... [{"name":"Default_Any","scaleX":"146928","scaleY":"230000" ... {"name":"Cardboard_4.7'","scaleX":"151928","scaleY":"250000" ... where you can try to take values from here and convert somehow for changes in ffmpeg_double_fg.py and line 73 from ffmpeg with lenscorrection.

SaintAnd avatar Apr 06 '23 18:04 SaintAnd

Is there a reference list i can refer to for the values for different headsets. For example thr k1 value for vr box

Did you manage to use my repository to customize the image output on a smartphone?

Answering your question, I will say that this is an experimental setting and you can only manually select the screen distortion by changing the values ​​in that seventy-third line.

You can install Trinus Cardboard VR for windows via windows, wine, playonlinux, lutris and so on. Then use the configuration file TGServer.exe.config . There is line 29 with this beginning: {"profiles":[{"name":"Default Simulator" ... [{"name":"Default_Any","scaleX":"146928","scaleY":"230000" ... {"name":"Cardboard_4.7'","scaleX":"151928","scaleY":"250000" ... where you can try to take values from here and convert somehow for changes in ffmpeg_double_fg.py and line 73 from ffmpeg with lenscorrection.

Lens distortion effect is acheived. Now have to configure the distortion parameters to adjust to my VR Box (https://computerplus.com.mv/wp-content/uploads/2022/03/51EULAnjaXL._AC_SL1128_web-600x600.png)

izzijaz avatar Apr 07 '23 21:04 izzijaz

Is there a reference list i can refer to for the values for different headsets. For example thr k1 value for vr box

Did you manage to use my repository to customize the image output on a smartphone? Answering your question, I will say that this is an experimental setting and you can only manually select the screen distortion by changing the values ​​in that seventy-third line. You can install Trinus Cardboard VR for windows via windows, wine, playonlinux, lutris and so on. Then use the configuration file TGServer.exe.config . There is line 29 with this beginning: {"profiles":[{"name":"Default Simulator" ... [{"name":"Default_Any","scaleX":"146928","scaleY":"230000" ... {"name":"Cardboard_4.7'","scaleX":"151928","scaleY":"250000" ... where you can try to take values from here and convert somehow for changes in ffmpeg_double_fg.py and line 73 from ffmpeg with lenscorrection.

Lens distortion effect is acheived. Now have to configure the distortion parameters to adjust to my VR Box (https://computerplus.com.mv/wp-content/uploads/2022/03/51EULAnjaXL._AC_SL1128_web-600x600.png)

I'm glad that you managed to achieve lens distortion. I don't have a helmet like you have in the picture right now, so I hope you can do it the best you can, but take care of your eyes, because these things are not safe in my opinion. ────────────────────── █──██████────██████──█ █─██────██──██────██─█ ─███─██─██████─██─███─ ──██────██──██────██── ───██████────██████───

SaintAnd avatar Apr 07 '23 22:04 SaintAnd

Is there a reference list i can refer to for the values for different headsets. For example thr k1 value for vr box

Did you manage to use my repository to customize the image output on a smartphone? Answering your question, I will say that this is an experimental setting and you can only manually select the screen distortion by changing the values ​​in that seventy-third line. You can install Trinus Cardboard VR for windows via windows, wine, playonlinux, lutris and so on. Then use the configuration file TGServer.exe.config . There is line 29 with this beginning: {"profiles":[{"name":"Default Simulator" ... [{"name":"Default_Any","scaleX":"146928","scaleY":"230000" ... {"name":"Cardboard_4.7'","scaleX":"151928","scaleY":"250000" ... where you can try to take values from here and convert somehow for changes in ffmpeg_double_fg.py and line 73 from ffmpeg with lenscorrection.

Lens distortion effect is acheived. Now have to configure the distortion parameters to adjust to my VR Box (https://computerplus.com.mv/wp-content/uploads/2022/03/51EULAnjaXL._AC_SL1128_web-600x600.png)

I'm glad that you managed to achieve lens distortion. I don't have a helmet like you have in the picture right now, so I hope you can do it the best you can, but take care of your eyes, because these things are not safe in my opinion. ────────────────────── █──██████────██████──█ █─██────██──██────██─█ ─███─██─██████─██─███─ ──██────██──██────██── ───██████────██████───

I have tried this after a while today, When steam vr starts, using ur rep, the steamvr windows shows in my phone and also my desktop also shows. Its not just taking SteamVR Compositor but the whole screen is still being mirrored

izzijaz avatar Apr 13 '23 19:04 izzijaz

Is there a reference list i can refer to for the values for different headsets. For example thr k1 value for vr box

Did you manage to use my repository to customize the image output on a smartphone? Answering your question, I will say that this is an experimental setting and you can only manually select the screen distortion by changing the values ​​in that seventy-third line. You can install Trinus Cardboard VR for windows via windows, wine, playonlinux, lutris and so on. Then use the configuration file TGServer.exe.config . There is line 29 with this beginning: {"profiles":[{"name":"Default Simulator" ... [{"name":"Default_Any","scaleX":"146928","scaleY":"230000" ... {"name":"Cardboard_4.7'","scaleX":"151928","scaleY":"250000" ... where you can try to take values from here and convert somehow for changes in ffmpeg_double_fg.py and line 73 from ffmpeg with lenscorrection.

Lens distortion effect is acheived. Now have to configure the distortion parameters to adjust to my VR Box (https://computerplus.com.mv/wp-content/uploads/2022/03/51EULAnjaXL._AC_SL1128_web-600x600.png)

I'm glad that you managed to achieve lens distortion. I don't have a helmet like you have in the picture right now, so I hope you can do it the best you can, but take care of your eyes, because these things are not safe in my opinion. ────────────────────── █──██████────██████──█ █─██────██──██────██─█ ─███─██─██████─██─███─ ──██────██──██────██── ───██████────██████───

I have tried this after a while today, When steam vr starts, using ur rep, the steamvr windows shows in my phone and also my desktop also shows. Its not just taking SteamVR Compositor but the whole screen is still being mirrored

Yes, I kind of removed the steam capture function. But it can be returned, you just need to find it in the code.

SaintAnd avatar Apr 13 '23 19:04 SaintAnd

This setting is in xwd_fg.py on line 54 of this text: window_id = self.find_window_id("SteamVR Compositor") You need to look at the name of your process in the task manager

SaintAnd avatar Apr 13 '23 19:04 SaintAnd

This setting is in xwd_fg.py on line 54 of this text: window_id = self.find_window_id("SteamVR Compositor") You need to look at the name of your process in the task manager

It is set to steamvr compositor

izzijaz avatar Apr 13 '23 20:04 izzijaz

You need install xwininfo and xwd if it didn't install before After then edit main.py string 25: Replace FRAMEGEN_FFMPEG to FRAMEGEN_XWD

But I don't know now how to edit this windows with lenscorrections

SaintAnd avatar Apr 13 '23 22:04 SaintAnd

You need install xwininfo and xwd if it didn't install before After then edit main.py string 25: Replace FRAMEGEN_FFMPEG to FRAMEGEN_XWD

But I don't know now how to edit this windows with lenscorrections

I will try this, didn't read this part yesterday. Will let you know if i run into any problems.

izzijaz avatar Apr 14 '23 16:04 izzijaz

Extremely nausiating this mode FRAMEGEN_XWD. THE image is doubled also. not one singular image when viewing through Gear. Is the distance between the images adjustable?

izzijaz avatar Apr 14 '23 18:04 izzijaz

My game LFS could not initialise SteamVR. I think i should switch to windows for gaming. Linux is currently a pain in the a** when it comes to VR and these related. Not much ease of use or compatibility yet.

izzijaz avatar Apr 14 '23 18:04 izzijaz