Cold rain - essay 04-11-9

xiaoxiao2021-03-06  75

I haven't written blog for a long time, in fact, I haven't worked for technology for a long time.

Some people say that technology is such a beautiful wine, only when calm, you can taste its sweetness, unfortunate, and recently in my mind.

Today, Beijing is raining, very happy, very rare opportunity to make you calm down, sit here, write something.

---------------------------------------

These days, with CGAMER is half a half study, it is not very smooth, always can't afford my spirit. With CGAMER, I have finished reading the Irrlicht engine. He summarizes: The configuration of the engine is to extract the greatest variability under the premise of invariance and efficiency. I think I have no objection. As for this invariance, what exactly, I want to be the data, data set. I follow the CGAMER quarrel is the problem of disappearance and variability, perhaps, this is not the problem that our furhead can solve.

For example, an image, assuming that we want the file and render layers to detach, then except that render is connected to the label contact (using file * to make the file name, this is in the abstraction of this level, File does not see Render Render also can't see File. Just need to establish an object connection when it is realized.), It is necessary to make an abstraction layer to do data abstraction.

why? We assume these points:

1. Suppose the data is not abstract, only one minimized imageData, what will happen? When the File is an elephant, it is found that there are many data imagedata not preparing to record, then the File is a layer (note that the same layer is not an abstract layer) must implement its own XXImageData, this has one Question, in the render abstraction layer can only know the File abstract layer, then what should I do when the render abstract layer needs to get imagedata? Of course, you can make imageData to solve it, but this is not very convenient: because the standard is determined by the same layer, the abstract layer is very powerful, how can it know that there is not yet - from his angle? Visible - How does an elevant layer customize this standard?

? !

There is also a problem, in the render architecture, do you want to be coupled with the FILE Forma? It seems that it must be coupling. Otherwise, even if you know what DATACHUNK is, you don't know how to arrange such a value in this way, still can't do anything. It is just a standard coupled in this coupling, and you can meet this DATACHUNK organization standard. Then the problem is that the File is changing, it is likely no longer following XXImageData standards, and it is confused to support the YYIMAGEDATA standard.

. All places related to ImageData need to rewrite or re-change.

Imagine why we want to set up an abstraction, is it unique? Is there a close to each other? Mainly in order to make each module out of the coupling, the current design can only be forced to unable to disengage. Since it is unable to disengage, we can try to determine the invariance. The most significant imagedata in the abstract layer, whether it is an abstract layer or an elephant layer, and this standard should be followed. If you don't know what will happen, then you should: set up DWORD DWRESERVED1, DWRESERVED2 ... DWRESERVEDN to customize the standard. Anyway, the core data you have gripped in your hand, and it will be much easier to make it easier to facilitate some of the data that makes it entered. This is similar to DX's idea, core data, and method I firmly controlled in your hand, and all variability should be done on the basis of these invariance.

2, but when this idea encounters a high-rise engine system, it will be more complicated. It is well known that the high-rise engine system can be said to be each game, but in terms of map format, the map format is almost completely different from different games. How to do it? Maybe abstract this high-level core data?

The answer is that it is impossible to abstract the core data that is completely adapted to the various games, but we should try to disconnect the data into each part and the abstraction as possible mode and details. Take the map: We are alone in some details of the map itself (as long as high), while advanced details include regional tables and regional control methods (such as blocking and blocking lattice tables), may also be recorded, or not Record, instant calculating in the map editor, is actually the same. We will make existing things as much as possible, which will inevitably consume a lot of space and efficiency, which is the problem of designers: between efficiency and development efficiency, what weighted. The map may also be posted: including scene manager type (BSP, quadrush, top tree), which requires some scene managers that are currently registered, abstract some scene managers for these registered managers. The data. There will definitely have a better way, but I am stupid and cgamer, huh, huh, huh

.

If you say terrain, the map is a summary of many existing technologies, which will be abstractly abstract, then the object may be more complex. I have given CGAMER, and almost instantly is quite the solution is: In addition to basic data, use a lot of reserved data and script cooperation. I have procedures: If you don't know what the data is used, it doesn't matter, it doesn't matter, the data is handed over to a relatively powerful script. For example, when I am doing an instant strategy, btreserved1 is used as a reference numeral to specify the parties, but when doing RPG, this btreserved1 starts to refer to this article is Player? NPC? Or is it trigger? It can be seen that reserved This abstract data organization is bound to require a strong scripting system as a subsidy, otherwise it is only equipped with a bigger chaos.

But this genius (everyone: You are owying

) The plan, actually by the CGAMER, the instantaneous instant, I don't know what he thinks. (CGAMER: You don't say my bad words ?!

)

Oh, if you have a better idea, you must tell me, follow the reply, or send a letter to Laburas at sohu.com, you can (AT should be @, no @ 为 为 免多 免 搜 工)).

--------------------------------

In recent days, another headache is the input method, pseudo full screen and IME under Windows, Linux don't know, this should be a standard method, but CGAmer does not want to use. Supporting IME input method itself is not a lot, it is said that Microsoft Pinyin has a problem with IME, only intelligent ABC is complete standard, this is not very clear, pseudo full screen reduces efficiency, this earth man knows. Anyway, it is quite annoyed in the last period of time, so when you are going to get off work, please check the information. Get the open source of the open source under Linux, very good. But to tell the truth, the function that is not commented is to see my sweat, but fortunately the system itself is not big.

The future life is still so something: work is packaged and uploading tools, down with CGAMER quarrel with his ghosts, and finally look at the input method. God blessed, perhaps, this day will end soon.

转载请注明原文地址:https://www.9cbs.com/read-93915.html

New Post(0)