Giter Club home page Giter Club logo

qtpyhammer's People

Contributors

asd417 avatar dependabot[bot] avatar snake-biscuits avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

Forkers

ayaz345

qtpyhammer's Issues

Inputs being handled poorly by camera

yoshimario2000 reported occasionally Left-Right controls break (found to be related to spinning the camera too many times along local X axis

Exactol noted the cursor can escape the window during tracking

QTimer isn’t reliable

When a QTimer is used for timing frames, either in the viewports or the demo player prototype, frames can lag

The error / deviation accumulates too.
We could look at the time taken to execute functions tied to the timer and compensate for the deviation

Or asynchronously run the functions with a 1 frame delay, showing the previous frame (double buffering) some kind of “delayed execution” QTimer subclass (GFrameTimer?) could be useful

Rendering Displacements

The current brush system doesn't have indices for the vertices calculated to represent displacements.
This is because displacements have a consistent pattern.
Meaning instanced draw calls & triangle strips are a potential optimisation available in this case.
However, this would require tracking the power of stored displacements and utilities.render.manager.find_gaps using this info to keep displacements of similar powers together.

Using a tesselation shader and uniform buffer to shape displacements would be a further optimisation, but adds a lot of complexity. (probably a very bad idea then)

it'd be crazy clever to store only the pattern of a power 2 and a power 3, then use some draw call magic to offset the indices to the start of each displacement in the vertex buffer, but that's also very complex and would likely take many months to work out, if it is at all possible.

For now, the index buffer entry for each displacement must be calculated at when organsing buffer writes (render.manager.add_brushes).

Camera jitters

It's not interpolated, it can still be updated every 60/th of a second.
Just need to update utilities.camera to interpolate between it's last state and the latest state (update)
so refactor camera.set to take a value to interpolate by calculated from viewport.timer.remainingTime()

Making selections

We need a way to select objects to apply operations to them.
Since we only have a 3D viewport at time of writing, raycasts seems like the way to go

This will need to work for brushes, displacements, faces & point entities

Work with whoever picks up #6 to ensure the interface to the selection is easy to work with

AttributeError: 'Vmf' object has no attribute 'hidden'

Full log:

Traceback (most recent call last):
  File "D:\repo\QtPyHammer\QtPyHammer\ui\core.py", line 37, in open_files
    def open_files(): ops.open_files(self, self.map_browser)
  File "D:\repo\QtPyHammer\QtPyHammer\ops\__init__.py", line 38, in open_files
    main_window.open(filename)
  File "D:\repo\QtPyHammer\QtPyHammer\ui\core.py", line 313, in open
    tab = workspace.VmfTab(filename, new=False, parent=self)
  File "D:\repo\QtPyHammer\QtPyHammer\ui\workspace.py", line 38, in __init__
    self.map_file = VmfInterface(self, self.filename)
  File "D:\repo\QtPyHammer\QtPyHammer\ops\vmf.py", line 17, in __init__
    self.hidden = self._vmf.hidden
AttributeError: 'Vmf' object has no attribute 'hidden'

Python version

(venv) D:\repo\QtPyHammer>python --version
Python 3.9.2

Installed package

(venv) D:\repo\QtPyHammer>pip list
Package    Version
---------- -------
cx-Freeze  6.1
fgdtools   1.0.1
future     0.18.2
numpy      1.18.5
pip        20.2.3
PyOpenGL   3.1.5
pyparsing  2.4.7
PyQt5      5.15.3
PyQt5-Qt   5.15.2
PyQt5-sip  12.8.1
setuptools 49.2.1
vmf-tool   0.1.0

Rebuild renderer

Setting up OpenGL, adding a object to renderbuffers and changing shaders & vertex formats is very manual

most of the work of adding renderable objects to a viewport happens in render.py
with plenty of other code in ui.core doing setup, which it shouldn't have to

creating a viewport should be a simple as .setWidget(viewport())

viewport should have a "addBrush(...)" method
also we need tweakable GL settings and possibly even a system benchmark

create more specialised classes if nessecary
we do want to recycle viewports for the model browser at least

.vmt parser

need to detect:

  • $basetexture; which .vtf(s) does this .vmt use?
  • $surfaceprop
  • $blendmodulate
  • proxies (angle, scroll, tint, etc.)

this info will be used for rendering & preview thumbnails
previews need to look close to in-game

Move from fbs to cx_Freeze

cx_Freeze is still being updated.
f-man build system is still on python3.6 and it's dependencies are outdated & insecure.
f-man linux builds also didn't compile properly, with OpenGL crashing (something we can't afford to work around).

cx_Freeze is still multi-platform an allows for a simpler folder structure.
QtPyHammer being based on Qt means no changes in files between distributions,
supporting multiple OpenGL shader versions is simple enough.

Some prototyping / experimenting will be needed to see if it will work, but I suspect it will.
Moving should help on the path to reducing the overhead of concerns for working on the project
and get those prototypes back out there so we can get user feedback to give us direction and focus.

Asset Browser

QtPyHammer needs a UI element to select textures and assign them to selected faces
See the project for a rough outline of what needs doing / is done already

work with @snake-biscuits to figure out how to attach the UI & tools to a selection
since they will be working on selecting in 3D for #7

Entity browser needs a refactor

Still in a very prototypey structure, breaking each tab into their own class will be handy for relocating these tabs throughout the UI

this could even lead to a design paradigm similar to blender’s UI panels system
Linking a global scope to UI elements linked to that scope, updating visually to match the active selection

an outliner and a “logic nodes” panel would be quite useful, and thinking about things in this way could really help lock the UI down into something more easily understood

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.