G15VID Expands neong15works.zip by same author PLAY A MOVIE REEL WITH GENUINE FIRST-HAND AUTHENTIC GREEN FLICKERING IN G15 PMN! WITH 16-BIT SOUND! Yes, the flickering has here been consciously programmed in, so that the brain can get a stimulation towards healthy meditative waves in the 8 Hertz region. We're speaking mind-stimulation by keeping to the principle of still images EVEN if it is also suggesting movement; measure the EEG of the brain towards healthy coherent long-wave alpha and deeper to explore how G15 PMN works to stimulate. EACH PACKAGE IS ALSO FIRST-HAND IN HOW THE IMAGES ARE ENCODED: NO FANCY ABSTRACT EQUATIONS, JUST SIMPLE ENCODING. On a personal computer, where you have G15 PMN in folders rather than as separate hardware elements, it makes though sense to keep each g15vid package in a zipped form so that it is unzipped just when it is shown. The g15vid contains the neong15ways.zip files, and some more suitable to play first-hand-like movies. Created over two nights in March 2020 by Aristo Tacoma alias S.R.Weber G15 PMN STANDARD, WHERE A COUPLE OF EXTENSIONS ARE CALLED ON, SUITABLE EG FOR A WAYLAND 64-BIT LINUX LIKE KDE NEON, CHOOSE 'WAYLAND' DURING STARTUP ================================ Even if the content of g15vid.zip seems a bit self-documentary to the G15 PMN expert: Read this howto.txt twice before starting up any bit of this package because you really need the overview; it's a huge thing to start ================================ DO YOU KNOW ABOUT THE CONCEPT OF FIRST-HAND RELATIONSHIP TO DATA? I have written about this fairly often since about 2005. The idea of high-resolution video with high-resolution sound sounds fine in abstraction, but it turns the brain off: this is an approach that stimulates the brain, because it leaves work to be done by the brain to piece it together. This is adequately low-res, adequately free from natural colors, adequately flickering, with 8 frames pr second, that the brain must do work. So this is g15vid. It activates where other approaches to videos dullens. ================================ Suitable to convert up to one and a half hour (and a little more) .mp4 movie into g15 format; contains video player; use eg Linux or use it with the future intraplates electronics for a suitable G15 PMN first-hand hardware computer; have lots of free disk space before you begin to work with this. LOTS. ================================ This documents some of the possibilities inherent in the neong15rmenu approach, which also can be used for robots ['r' for robot] ================================ g15vid -- approaching some first-handedness even in videos -- through green 500x500 8 frames pr second videos with 16-bit mono sound, runnable on a 64-bit Linux like KDE Neon where during Login, you select 'Plasma Wayland session'. Select 'Plasma' session in next log in for those programs that cannot handle Wayland. There are also subtle differences between KDE Neon and Ubuntu (in their 2020 forms) as for Wayland, even though KDE Neon has an Ubuntu core. Confer the g15pmn.com or norskesites.org/fic3/fic3inf3.htm for Wayland under Ubuntu, there are some extra downloads there: this has only been checked with KDE Neon, which is an excellent Linux. USE IT IN A 64-BIT LINUX WHERE IT IS 'WAYLAND' LOGIN METHOD (in some Linuxes, you select this by a menu during login, perhaps by a click on a keyword that says 'Session'). You can also find ways to run it in other platforms, when you use a G15 PMN that has been set up to call external commands. You can check the types of results you get with this before you do your own imports into g15vid: THE SAMPLE CONTAINED HEREIN IS A CA 3 MINUTE FREE YOUTUBE EXTRACTED FROM THE EARLY 1970S, SOME INTERVIEWS FROM A MUCH LARGER MOVIE, AND A PAUSE IN THE BEGINNING WHERE ACKNOWLEDGEMENTS HAVE BEEN GIVEN; HOPEFULLY THE COPYRIGHTS ARE RESPECTED ENOUGH GIVEN THE TINY EXTRACTION, THE MONOCHROME, THE LIMITED IMAGE RESOLUTION, AND THE MANY DECADES SINCE THE ORIGIN COMBINED WITH THE STRONG ACKNOWLEDGEMENT IN THE BEGINNING. IT IS, BY THE WAY, SHOWING SOMETHING WORTHY AS INSPIRATION FOR TANTRIC ENLIGHTENMENT... It has 1628 frames. This sample will effortlessly be overwritten when you import anything yourself; be sure to note that each import overwrites the previous one so create separate folders for each movie. Eg, keep them zipped when not in use, as these quickly get very expansive in disk use compared to the norm on a typical PC. [it only overwrites the former movie completely if the newly imported is longer than the previous; to be sure the previous movie is removed, use the menu E:5 for clearing cards and clear the range used in each disk, 200,000 and up to 2,000,000, from the c disk to the k disk, for storing the GEM photos]. Useful utility in playing videos: vlc. Useful utility in recording video: kazam, combined with pavucontrol where 'monitor of inbuilt audio' is chosen after recording by kazam has begun. Useful to convert to .m4v format in Linux: the program handbrake. Useful to convert the other way: ffmpeg. Useful for audio editing and converting: audacity. gwenview can also be used, like vlc, to view. These programs were all used, together with Firefox browser and Yandex search engine, to produce the g15vid sample as included. It has 1628 frames. We also used Free Pascal earlier on to make some of the bmpconvert utilities as included in the neong15works package, which is included here in full. G15VID: Summary of how to do it--but it is a good idea to read the rest of this text and ponder about it before carrying out this recipe: be sure you have a gigabytes extra or so for each minute (very approximately) of mp4 movie. Put the mp4 movie to the 'import' subfolder (only one at a time!). Eg, cd g15vid cd import mv -i ~/Downloads/mymovie.mp4 . (if it is a .m4v video you can usually very easily convert it with 'ffmpeg' to get it over to .mp4). Note that there are occasions in which sampling speed, also for sound files, are made in a way that doesn't work with all converter programs. The solution in such cases is usually to find a 'streamlining' in-between format like ogg and convert it back again, and proceed.) Start up program audacity or the like and if it is a stereo video, convert to mono. After that, resample to 16000 Hz, and export it as 16-bit PCI mymovie.wav file. Check that the 'sox' is installed by this command play mymovie.wav if not it is a command like apt install sox to get it in place. With less text: play -q mymovie.wav Move the .wav file up to the main G15 PMN folder and overwrite the L disk: mv -i mymovie.wav ../ldisk.g15 It should ask for overwrite y/n. Confirm with y and press lineshift. That sets up the sound. It is quite typical for the play command to create various messages and warnings. These can be ignored if the sound is okay. TO RUN THE FOLLOWING .sh PLEASE LOOK AT THEIR CONTENT FIRST AND SEE WHAT OTHER UTILITY PROGRAMS YOU MAY HAVE TO INSTALL IN YOUR LINUX Do these (do some healthy workout exercises after some of these lines, they will take much more time than to play the movie): ./convertmp4.sh ./convjpg.sh The jpgs are no longer necesary: rm *.jpg Go on with this: ./convsuffix.sh ./addspace.sh ./greenify.sh Have a look at the resulting .bmp images. The first is numbered 00000001.bmp. Make a note of the highest number. Move all the resulting .bmp images to the G15 PMN main folder: mv -i *.bmp .. cd .. Start up the G15 PMN main, in the particular form of it which presumes Wayland for KDE Neon 64-bit that has access to Terminal, and it can go straight to H1. A quick way to start it is: ./neong15rmenu [If you wish to start it through ./neong15rmenu.sh please read the footnote.] Start the Import program and type in the highest number and press lineshift. Quit the G15 PMN and remove the bmp (get the zero in there first, because there are some other .bmp's there): rm 0*.bmp You can now zip the whole package to save space on disk. Unzip to play: start up G15 PMN, at menu H1: ./neong15rmenu [If you wish to start it through ./neong15rmenu.sh please read the footnote.] and start the Play program. NOTE: check that all is well with just a couple hundred frames before importing the whole lot: the import routine assumes that the .bmp's are perfectly named and the content is perfect and you must be sure the .bmp's indeed are there before you start the full import process. ================================ ================================ BACKGROUND G15 PMN is a first-hand still photo and text and graphics and file oriented platform for programming. It can also be tweaked to do a little bit other things. It does not easily lend itself to video and it is not supposed to, because it is supposed to be mind-stimulating as in contrast to the mind-numbing features of high resolution, many frames pr second, hifi music of a typical video in the 21st century. As a result of the focus on first-handedness, we want a visible flickering, and we want not all that high resolution music, and not very fancy hyper-compact storage formats but obvious and first-hand. A single G15 PMN platform with its typical limits can nevertheless hold more than one and a half hour of 500x500 greentone movie with 8 frames pr second, and it is worth an experience. It is an extremely short program, as for the visual part. But even the simplest music file requires tremendous speed of communication between data and oscillators to be played harmoniously to the human ear; and this is best done not by a loop even at machine code level as much as by a specialised piece of electronics that feed oscillators directly from their own little bit of RAM or the like. While BMP is not as elegant nor as first-hand nor as compact as our GEM format, we have, for the reasons mentioned, picked the nearest analogy to the BMP, namely the WAV, as for sound; but in this case not bothered to 'first-handify' it, as it is okay enough. What we got here: you provide an mp4, you start up this program in a 64-bit Linux like Neon KDE, Wayland, with typical programs like convert (mogrify) and sox (which gives the command play) installed, and have a quarter of gigabyte available for every minute of video you wish to convert. The result, after the temporary files have been deleted, will be within 24 GB for more than one and a half movie. On Linux, you can then zip it into a smaller package and only unzip it when you want to play it. It is a very worthwhile experience. TECHNICAL DESCRIPTION We have is a way to run a greenified 500x500 8 frames pr second video with sound in Linux. The wav format is used because it is adequately first-hand, and a parallel, in images, to .bmp, to also allow for fairly simple electronics. For instance, you can put a .wav file to little chip beside a sd card and connect a loadspeaker to it and the little chip will be able to play it without any fancy fourier equations used in mp3. This little card can be controlled by the PC. It can also be made in a larger size than a chip, through what we call intraplates (which is adviced, when it is available). In this folder in g15vid you put a single .mp4 file. You will need considerable space on the disk to do this. If you are fond of Linux terminal commands, all this can be done in a single command; I do it here very step by step with the advantage that it is possible to check and modify each step also for the novice in Linux terminal batch commands. In case of running G15 PMN programs showing the images while also playing sound when it is on top of Linux, the sudo apt install sox will allow this command to start a .wav: play filename.wav And this is started while a loop shows eight GEM photos pr second, after they have been imported to one or more G15 disks. The filename.wav is easily extracted from a filename.mp4 file by means of a program like Audacity: be sure, in it, stereo is converted to mono, that it is resample to 16000 Hz, and that it is saved as 16-bit Microsoft PCI .wav file. The approach we take in g15vid is to use several g15 disks only for the purpose of storing the series of photos, eight pr second as GEM green 500x500 photos, and to use the disk L to contain the wav file. Overwrite the ldisk.g15 like this: mv filename.wav ldisk.g15 All the other disks, from C up to K, except for their first one or two hundred thousand cards, are used to store GEM images, 220 cards pr image, which is less than the corresponding BMP images generated temporarily. TO SET UP THE WAV FILE You rename the filename.wav, after being sure it fits with the essential simplicity of 16 KHz, 16-bit, mono, PCI, to ldisk.g15. Do this by overwriting the ldisk.g15 (that's letter l, eg, lowercase L). Get the .wav in the main G15 PMN folder, and on Linux terminal type: mv filename.wav ldisk.g15 The assumption is that 'play xxxxx' works when 'xxxxx' (no matter extension) is a .wav type of file, residing in the same folder as the .g15 disks. Adjust the computer so the sound works, you can test this command manually before you proceed to the images part. TO GENERATE THE IMAGES Obviously, first time you do this, use a half-minute long movie as test. Run these--on your very giant disk--where you really have the adequate quantity of gigabytes--and eg check the results in between each. Note that some of these commands involve such masses of data that they take time: much much more time than to actually play the movie, alright? Here they are: ./convertmp4.sh ./convjpg.sh Here, the jpgs can be deleted. ./convsuffix.sh ./addspace.sh ./greenify.sh The greenify.sh calls on our bmpgreenx-64bit command, and it is a nice peculiarity that it seems to work fine even though the required input size is not the one outputted by the convert command for .bmp. I mentioned this because the way the convert command handles .bmp has not always been kosher. It can change in the future. You may have to figure out a way to change the .bmp to a more standard format in a batch way other than this if the convert program has undergone some alterations. However I believe it is very doable, as all this initial conversion was worked out during a couple of hours and posed no problem at all. The bmpgreenx-64bit, which I made earlier on, outputs a lot of text each time; but it seems to be perfectly stable; and it allows not only this varied filesize as input but also it allows the same output file name as input file name. TO SET UP THE IMAGES Having done these batch jobs in Linux terminal, you are ready to start up the G15 PMN itself: ./neong15rmenu Supposing that you have indeed logged into this Linux in the Wayland method (see the 015inneon.txt info text for more about this), the neong15rmenu takes you straight to card H:1 and with the Menu mode already enabled, equal to CTR-W. [If you wish to start it through ./neong15rmenu.sh please read the footnote.] Go straight to the H1 menu, as soon as you have made a note of the highest- numbered .bmp, and moved all the .bmp into the main folder for G15 PMN where you already have set up the ldisk.g15 with sound. At menu H:1 you have two G15 PMN programs, one to import the files, and another to play. Import them by typing in the maximum number to import, and leave G15 PMN so as to clear the .BMP files away. Needless to say, because of the intense disk usage, it takes a bit of thought to combine this program with other programs; be sure no overwriting is involved; consult the source of the g15vid as included for where and how it writes to disk during import. During movie play, there is no writing to disk at all. After inputting the images, of course, the .bmp can be deleted and this releases a lot of disk space. Enjoy the first-handedness of the G15 videos. ================================ ================================ Footnote about ./neong15rmenu.sh ================================ Look at the first line in the neong15rmenu.sh, and check that it does 'cd' into the correct folder. The neong15rmenu.sh is not modified in g15vid because it isn't supposed to be used unless you configure it yourself. Background for this .sh solutioN: When a Linux Wayland session is booting freshly up after cold start, not all drivers and utilities to carry the graphics may be up and running at the time an autostarted program is called on. For that reason, that auto- started program may have to have some pauses in it etc. Also, the autostarting process may not set the local directly correctly--or the program is called on in some other way that may not set the local directory correctly--so it is a good general rule to have an extra 'cd' command inside the .sh that starts such a program, in addition to pauses and simplistic ways to call on the graphics and the i/o before the main program gets fully up. The neong15rmenu.sh, like the other neon .. sh start up methods, contain a cd ~/neong15ways which must be modified to the correct directory in each case if you wish to use such a startup method. In addition, you may find it completely unnecessary for the PC to go through the slow startup process of the .sh, and instead you may prefer to go straight into the program. Ie, the preferred method when you start the program from the command line, in all such circumstances in which this works, is: ./neong15rmenu