# PTZ Controls



## glikely (May 12, 2021)

glikely submitted a new resource:

PTZ Controls - Pan Tilt Zoom camera controls for OBS



> This plugin adds a PTZ camera control panel to OBS that can control multiple cameras, and can automatically change selected camera based on the currently active preview or program scene.
> 
> The plugin supports the VISCA serial protocol, with plans to add support for VISCA over IP and other camera control protocols. It has been tested on Windows and Linux. MacOS should also work but is untested.
> 
> This is early software that isn't fully functional, and I'm not providing binaries at this time...



Read more about this resource...


----------



## EB123 (May 15, 2021)

awesome to see this feature.. are there any plans to add virtual PTZ option also ? to make it possible to pan/crop 4k footage at 1080 resolution.. also if this could be controlled with standard joysticks somehow it would round out the functionality perfectly..


----------



## glikely (May 17, 2021)

I've thought about a virtual PTZ function. It would be a great feature to have. Right now I'm focused on finishing VISCA support, adding VISCA-over-IP, and making the user interface better.

To implement virtual PTZ, it could be implemented either by directly modifying the transforms on a source, or by adding a virtual source that performs PTZ operations on an existing source. I'd be happy to accept patches that implement either method.


----------



## MarkAducal (May 22, 2021)

when is the release?


----------



## glikely (May 22, 2021)

MarkAducal said:


> when is the release?


Unfortunately I can't make any commitment other than "when it is done". The protocol handling is more or less there, but I need to fix some problems with the UI and sort out a release process for Windows builds.


----------



## EB123 (May 22, 2021)

cool.. hope the development goes well and look forward to seeing these features one day..


----------



## glikely (May 30, 2021)

glikely updated PTZ Controls with a new update entry:

Initial Windows binary now available



> I've just uploaded the first Windows binary to GitHub. This first version supports the VISCA protocol (Serial port) and provides basic pan/tilt/zoom control as well as save & restore presets.
> 
> Please test and let me know what you think.



Read the rest of this update entry...


----------



## glikely (Jun 4, 2021)

glikely updated PTZ Controls with a new update entry:

VISCA-over-IP now implemented



> Big news this week: I've added support for VISCA over IP. The code is a little rough, so I've kept it out of the main branch, but for those of you who want to try it out, clone the "visca-over-ip-test" branch from the GitHub repo:
> https://github.com/glikely/obs-ptz/tree/visca-over-ip-test



Read the rest of this update entry...


----------



## KPC41 (Jun 5, 2021)

Looking forward to your development . Have just purchased a Tenveo PTZ camera  . Works great. Just waiting on Rs 232 control cable .  Loaded your win version on OBS  - can see the direction controls but not seeing any camera information  . Camera works in scenes OK. Do I need the control cable to see your other information in the plugin ?  Not software person .,but will like to assist in testing


----------



## glikely (Jun 5, 2021)

You need to add and configure the cameras. There should be a gear icon at the bottom of the window that opens the PTZ settings window.


----------



## glikely (Jun 5, 2021)

glikely updated PTZ Controls with a new update entry:

New test release adding VISCA over IP support



> I've got VISCA over IP working now. It has been tested using Sony SRG-120DH cameras, but theoretically it should work with any camera that supports VISCA over UDP. Please test and let me know how it works for you.



Read the rest of this update entry...


----------



## KPC41 (Jun 6, 2021)

glikely said:


> You need to add and configure the cameras. There should be a gear icon at the bottom of the window that opens the PTZ settings window.


 Thanks for that.
 Looks OK now!!

 FYI . The PTZ camera I am using is a Tenveo  HD conference Camera- this has  HDMI connection only, but with RS232 plug for connecting control signals to computer. (waiting for Cable - could be about 2 weeks).-With  cable, wiil  I have full functionally.
 Attachment shows details from manual


----------



## dattrax (Jun 6, 2021)

Hi, great plugin.  Wondered which game controllers you'd tested this with?  I've tried a couple of official xbox controllers and a bluetooth controller.  None of them appear in the dropdown for the controllers, so possibly I'm doing something wrong with either the installation or the setup.

Any advise?

Cheers
Jim


----------



## glikely (Jun 6, 2021)

Game controller detection isn't working on Windows at the moment. It worked for me on Linux, but it seems that game controller discovery is touchy on Windows. I haven't figured out a solution yet.

Is the plug-in working for you otherwise?


----------



## dattrax (Jun 6, 2021)

other than the issue with the game controller, there's an issue with the IP address dropdown getting lost (if you add another camera then in is restored, so not a biggy).  Some of the UI sliders didn't seem to do anything, but that might be camera specific.

If the game controller worked, it would be functional for what I need.


----------



## dattrax (Jun 6, 2021)

found this... don't know if its of any help.   [QTBUG-61553] QGamepadManager fails to detect gamepads on Windows if no QWindow was shown yet - Qt Bug Tracker


----------



## glikely (Jun 6, 2021)

The vertical slider controls the pan/tilt speed. The horizontal slider at the bottom is supposed to show the zoom position, but I haven't wired it up yet!


----------



## glikely (Jun 6, 2021)

dattrax said:


> found this... don't know if its of any help.   [QTBUG-61553] QGamepadManager fails to detect gamepads on Windows if no QWindow was shown yet - Qt Bug Tracker


Sadly that fix doesn't seem to work on Windows 10.


----------



## dattrax (Jun 7, 2021)

glikely said:


> Sadly that fix doesn't seem to work on Windows 10.



I had a play with the gamepad qt example tonight.  out the box, I was not able to get a gamepad detection.  After a bit of googling, I was able to get it to work with this workaround

    QGamepadManager* gamepad_manager = QGamepadManager::instance();
    QWindow* window = new QWindow();
    window->show();
    delete window;
    QGuiApplication::processEvents();
    QList<int> gamepads = gamepad_manager->connectedGamepads();
    qInfo() << "connected gamepads : " << gamepads.size();

seems like you have to create/destroy a window for it to appear.  I might have a play compiling your plugin and see if I can get it working with it.


----------



## jrgrant (Jun 7, 2021)

Just gave this a whirl with an ancient Canon VC-C3 connected serially. Heard some whirs and clicks, but sadly nothing that could be called control. I have some developer docs available for this thing if you're interested in pursuing support for it.


----------



## glikely (Jun 7, 2021)

jrgrant said:


> Just gave this a whirl with an ancient Canon VC-C3 connected serially. Heard some whirs and clicks, but sadly nothing that could be called control. I have some developer docs available for this thing if you're interested in pursuing support for it.


The VC-C3 uses an entirely different control protocol from what I can tell. I'd be happy to take patches that add support for it. You'll need to create a new subclass of PTZDevice. Take a look at the PTZVisca and PTZViscaSerial classes for inspiration. The VC-C3 should be simpler to implement than VISCA because the serial port doesn't need to be shared between multiple camera instances.


----------



## glikely (Jun 7, 2021)

dattrax said:


> I had a play with the gamepad qt example tonight.  out the box, I was not able to get a gamepad detection.  After a bit of googling, I was able to get it to work with this workaround
> 
> QGamepadManager* gamepad_manager = QGamepadManager::instance();
> QWindow* window = new QWindow();
> ...


I've not had any success on my end with that code snippit, either in the plugin or in the Qt example. :-( If you get it working with the plugin, send me a patch and I'll merge it in. If it at least works for you then that's better than nothing.


----------



## dattrax (Jun 7, 2021)

I got the gamepad working on windows10.  I'll send a patch over in the next day or so.


----------



## Damocles (Jun 8, 2021)

Great feature. tried to get to work on Windows 10. Can I perhaps get more info on the build.

I have some legacy VISCA PTZ cameras and are currently using LUA to control them with presets (manually calculated Hex)

This can streamline CPU usage I think and setup

Thanks  StevO


----------



## Damocles (Jun 8, 2021)

Damocles said:


> Great feature. tried to get to work on Windows 10. Can I perhaps get more info on the build.
> 
> I have some legacy VISCA PTZ cameras and are currently using LUA to control them with presets (manually calculated Hex)
> 
> ...




Yep... OK Found my issue... Installed correctly now


----------



## dattrax (Jun 8, 2021)

I've created an issue and uploaded a patch for the gamepad issue on windows.  Hope its ok on Linux.  might need to add some conditional compilation to the patch if there's a problem


----------



## WAH0808 (Jun 8, 2021)

I tried the latest beta today at the church where I look after their A/V system.  We have a Sony SRG-300H, I've configure the plugin for the com port however I don't have any control over the camera.  I do have the camera working with a demo copy of  PTZ Controller (www.ptzcontroller.com) so I know the cabling is correct.  Ideas?


----------



## glikely (Jun 9, 2021)

WAH0808 said:


> I tried the latest beta today at the church where I look after their A/V system.  We have a Sony SRG-300H, I've configure the plugin for the com port however I don't have any control over the camera.  I do have the camera working with a demo copy of  PTZ Controller (www.ptzcontroller.com) so I know the cabling is correct.  Ideas?


Do you know what baud rate the cameras are running at? The plug-in is currently hard coded for 9600 baud, but I plan to make that configurable.


----------



## glikely (Jun 9, 2021)

dattrax said:


> I've created an issue and uploaded a patch for the gamepad issue on windows.  Hope its ok on Linux.  might need to add some conditional compilation to the patch if there's a problem


Thanks. I'll check it out tomorrow and reply on the issue in GitHub rather than here.


----------



## WAH0808 (Jun 9, 2021)

glikely said:


> Do you know what baud rate the cameras are running at? The plug-in is currently hard coded for 9600 baud, but I plan to make that configurable.



9600, this was my first thought too.


----------



## glikely (Jun 9, 2021)

WAH0808 said:


> 9600, this was my first thought too.


File an issue on GitHub and attach the OBS log file. The plug-in is very chatty and logs every VISCA message, so that will help with debug.


----------



## glikely (Jun 12, 2021)

glikely updated PTZ Controls with a new update entry:

Improved VISCA handling and gamepad workaround



> New test release. This release fixes a number of problems implementing the VISCA protocol which should result in more reliability overall. It also adds a workaround for detection of XBox gamepads on Windows.
> 
> Unfortunately, XBox gamepads are the only type of gamepad that works on Windows due to QGamepad using the XInput API. Support for other game controllers will require a different backend that uses directinput.
> 
> Please go and test



Read the rest of this update entry...


----------



## toplachi (Jun 16, 2021)

Thank you for this plugin, we can use our Chinese PTZ camera with it via RS485 connection.. I do encounter the VISCA stop code not being effective if holding down the direction & zoom keys in less than 2 secs.

In the future, I hope there could also be an option to invert the horizontal or vertical movement of the camera and probably also support PELCO protocol later in its development

Another idea is if keyboard shortcuts can be assign to the command buttons especially with the presets

More power to the developers!


----------



## glikely (Jun 16, 2021)

toplachi said:


> Thank you for this plugin, we can use our Chinese PTZ camera with it via RS485 connection.. I do encounter the VISCA stop code not being effective if holding down the direction & zoom keys in less than 2 secs.



I'm glad it is working for you. The missing stop command is due to the controller not receiving reply packets from the camera. I've got an idea about how to fix it. There is a GitHub issue tracking this problem:









						VISCA stop code is not sent if camera doesn't respond · Issue #7 · glikely/obs-ptz
					

I use this plugin on linux and thank you for this project. There are some problems, when I press an arrow and release it, it does not always send the 03:03:ff. The problem happens every time, I hav...




					github.com
				






toplachi said:


> In the future, I hope there could also be an option to invert the horizontal or vertical movement of the camera and probably also support PELCO protocol later in its development



Good idea on inverting pan/tilt. Can you file a GitHub issue requesting this feature so I don't forget?









						Build software better, together
					

GitHub is where people build software. More than 94 million people use GitHub to discover, fork, and contribute to over 330 million projects.




					github.com
				




Adding PELCO D/P support should not be difficult. It is just another simple serial protocol and much of the VISCA implementation could be reused. However I don't have any PELCO equipment, so I'll need someone else to add that feature. I'll happily accept patches to add this feature.



toplachi said:


> Another idea is if keyboard shortcuts can be assign to the command buttons especially with the presets



Yes, that is a good idea. Thanks


----------



## glikely (Jun 16, 2021)

toplachi said:


> Thank you for this plugin, we can use our Chinese PTZ camera with it via RS485 connection.. I do encounter the VISCA stop code not being effective if holding down the direction & zoom keys in less than 2 secs.



Give this test build a try: https://github.com/glikely/obs-ptz/actions/runs/944188476


----------



## glikely (Jun 19, 2021)

I've just tagged v0.4.0-pre1. Please test and give a yell if you have any problems. I'll properly release v0.4.0 later today if everything checks out okay.


----------



## glikely (Jun 19, 2021)

glikely updated PTZ Controls with a new update entry:

v0.4.0



> New week, new release. This release fixes a number of bugs and improves performance. Please test.



Read the rest of this update entry...


----------



## KPC41 (Jun 20, 2021)

Now have Tenveo  Hd Camera control cable installed  and can now use plugin to scan (H) and (V)  However Home button only stops (H) and (V), It does not  move camera to Home position  .
 Suggestion : if a camera can only can scan (H) and (V) could the other directional controls be greyed out.
 The Wide and Tele buttons might best be called zoom In and Zoom Out?
 What does the Slider between the wide and Tele buttons  do .?
 Can you control the speed of Zoom In & Zoom out?


----------



## KPC41 (Jun 20, 2021)

KPC41 said:


> Now have Tenveo  Hd Camera control cable installed  and can now use plugin to scan (H) and (V)  However Home button only stops (H) and (V), It does not  move camera to Home position  .
> Suggestion : if a camera can only can scan (H) and (V) could the other directional controls be greyed out.
> The Wide and Tele buttons might best be called zoom In and Zoom Out?
> What does the Slider between the wide and Tele buttons  do .?
> Can you control the speed of Zoom In & Zoom out?


 Most of the control problems  now appear to be fixed V0.40
 Thanks !


----------



## glikely (Jun 20, 2021)

KPC41 said:


> Now have Tenveo  Hd Camera control cable installed  and can now use plugin to scan (H) and (V)  However Home button only stops (H) and (V), It does not  move camera to Home position  .
> Suggestion : if a camera can only can scan (H) and (V) could the other directional controls be greyed out.



Good idea. This will require knowing what kind of camera is connected, which I haven't implemented yet. Please file a feature request as an issue on GitHub so I don't forget about this request.



KPC41 said:


> The Wide and Tele buttons might best be called zoom In and Zoom Out?



I'll be replacing the labels with icons soon which I think will be even better.



KPC41 said:


> What does the Slider between the wide and Tele buttons  do .?



It was supposed to be a direct control of the zoom position, but I haven't implemented that yet so I've removed it for now.



KPC41 said:


> Can you control the speed of Zoom In & Zoom out?



Fixed in v0.4.0


----------



## toplachi (Jun 21, 2021)

glikely said:


> Give this test build a try: https://github.com/glikely/obs-ptz/actions/runs/944188476


Thank you for this update.... Its only now that I was able to test it... and its now working good!


----------



## padrereal2002 (Jun 26, 2021)

I recently bought a PTZ - usb - webcam (OBSBOT Tiny Camera).... in OBS, in the properties, I can change all the PTZ settings... do you think your plugin will work to control the PTZ of this webcam ?? 
I'm a rookie here... in which folder do I have to copy the plugin files or folder for it to show up in OBS ??
Thanks for your help!


----------



## toplachi (Jun 27, 2021)

This plugin currently supports PTZ cameras that uses VISCA or VISCA over IP protocols which I don't think how OBSBOT works


padrereal2002 said:


> I recently bought a PTZ - usb - webcam (OBSBOT Tiny Camera).... in OBS, in the properties, I can change all the PTZ settings... do you think your plugin will work to control the PTZ of this webcam ??


----------



## toplachi (Jun 27, 2021)

I wonder if this plugin can be integrated with this face tracker plugin in the future  https://obsproject.com/forum/resources/face-tracker.1294/


----------



## glikely (Jun 29, 2021)

toplachi said:


> I wonder if this plugin can be integrated with this face tracker plugin in the future  https://obsproject.com/forum/resources/face-tracker.1294/



That would be very interesting. I'd love to have that working.


----------



## EB123 (Jun 30, 2021)

subject tracking incorporated with PTZ would be a great thing.. it would be best if it worked more like it does with drones where it tracks an entire object you draw a box around (not just faces).. that way if you had an event and a person was moving and not always facing the camera it could still follow them.. even just face tracking would still be good though.. this sort of feature would greatly improve multi camera productions where there is only one person (or limited crew) trying to produce everything..

another feature that would be great to see with PTZ is a speed ramping function.. problem with most PTZ cameras is they look jerky when they start and stop movement.. if there was a way to ramp up/down the speed when they begin to move this would produce much nicer results.. even pressure sensitive joysticks never look consistent but if you could set a fixed ramp speed in software that was always the same it would look much smoother, more cinematic etc..


----------



## Chris Goringe (Jun 30, 2021)

Just tried this out with a Zowietek PTZ NDI camera, and it works just fine.

Wondering if there is any chance of some way that it can be made to trigger presets when you switch scene?


----------



## glikely (Jun 30, 2021)

Functionality that is easy. The hard part is the UI. How would you like to have that work? e.g., when does the camera move, when a scene becomes visible in preview or program when using studio mode? Does it need to protect against moving the active camera? Etc.

It would help if you file an issue in GitHub that describes how you would like this feature to work


----------



## wimpy617 (Jul 2, 2021)

Hey team, I'm the biggest noob here.  I've had some success with an IP Network for a live stream, and am now trying to get a PTZ online.  I can pull an image, but cannot control the camera.  I know it is Pelco, which seems to preclude me from a lot of functionality.  Will this plug in help?  Any support would be appreciated!


----------



## glikely (Jul 2, 2021)

wimpy617 said:


> Hey team, I'm the biggest noob here.  I've had some success with an IP Network for a live stream, and am now trying to get a PTZ online.  I can pull an image, but cannot control the camera.  I know it is Pelco, which seems to preclude me from a lot of functionality.  Will this plug in help?  Any support would be appreciated!



What specific camera are you using? Are you needing to control it over serial cable, or over the network. I have not implemented PELCO support. It isn't hard to do, but I don't have any PELCO equipment to test with.

Please file a feature request for PELCO support as an issue on the GitHub page


----------



## wimpy617 (Jul 3, 2021)

glikely said:


> What specific camera are you using? Are you needing to control it over serial cable, or over the network. I have not implemented PELCO support. It isn't hard to do, but I don't have any PELCO equipment to test with.
> 
> Please file a feature request for PELCO support as an issue on the GitHub page



Copy that, I'll look into filing a feature request.  I'm trying to control the camera over a network.  I got the camera from Ali Express.  It's a ANPVIZ 5.0MP 5xIP PTZ Dome POE Camera.


----------



## glikely (Jul 3, 2021)

wimpy617 said:


> Copy that, I'll look into filing a feature request.  I'm trying to control the camera over a network.  I got the camera from Ali Express.  It's a ANPVIZ 5.0MP 5xIP PTZ Dome POE Camera.



From the ANPVIZ website, out looks like the camera uses the ONVIF protocol for PTZ control


----------



## braverock (Jul 3, 2021)

I have no trouble building this plugin as a .so for (Ubuntu) linux.  I just don't see it showing up in OBS.  I've tried putting just the so in

     /usr/share/obs/obs-plugins/

or in

    $HOME/.config/obs-studio/plugins/

and I've also tried with a ptz-controls/  subdirectory under both those directories.

One tutorial for installing OBS plugins on linux suggested copying the pdb file resource out of a Windows zip file in addition to the .so object, but that didn't work in any of these locations either.  I've never needed anything other than lua scripts and the obs-plugins *package* for ubuntu, so I'm still stumbling around in the dark as to where/how to install and enable the plugin.


----------



## glikely (Jul 3, 2021)

braverock said:


> I have no trouble building this plugin as a .so for (Ubuntu) linux.  I just don't see it showing up in OBS.  I've tried putting just the so in
> 
> /usr/share/obs/obs-plugins/
> 
> ...



Check the OBS log file to see if there is any messages from the plug-in. That will tell you if OBS is finding it. If you are still having trouble, file an issue in GitHub and attach the log file


----------



## norihiro (Jul 7, 2021)

toplachi said:


> I wonder if this plugin can be integrated with this face tracker plugin in the future  https://obsproject.com/forum/resources/face-tracker.1294/


I'm also interested in that idea.
The face-tracker is mainly running on graphics thread to get the frame data. I'm not sure what is the best way to send the data. One possibility is having a source-callback on face-tracker, obs-ptz periodically poll by using the callback and send to the camera. I'm appreciate if you have something better idea.


----------



## glikely (Jul 7, 2021)

norihiro said:


> I'm also interested in that idea.
> The face-tracker is mainly running on graphics thread to get the frame data. I'm not sure what is the best way to send the data. One possibility is having a source-callback on face-tracker, obs-ptz periodically poll by using the callback and send to the camera. I'm appreciate if you have something better idea.



I noticed that you've been hacking on the obs-ptz code, and I took a look at how you've been using it in your face tracking plugin. Cool stuff. I hadn't thought of using the obs-ptz backend as a library. Are there ways that you'd like to see the ptz code restructured so it is easier to use by the face tracker?

Right now the PTZ code runs entirely in the frontend thread and is event driven. However, I don't have a clean separation between the UI and the PTZ backend. I need to rework the module initialization to manage the PTZDevice setup independently of the UI dock.

Instead of polling, would it be possible for the facetracking code to send events to the frontend thread? (Yeah, I know, that is still polling, but would be integrated into the Qt event loop.) I don't know enough about Qt yet to know how to do that though.


----------



## norihiro (Jul 7, 2021)

glikely said:


> I noticed that you've been hacking on the obs-ptz code, and I took a look at how you've been using it in your face tracking plugin. Cool stuff. I hadn't thought of using the obs-ptz backend as a library. Are there ways that you'd like to see the ptz code restructured so it is easier to use by the face tracker?


Integer arguments for pan/tilt/zoom is preferable for tracking from my plugin. Since the moving speed is not proportional, I'm making a table to convert. Another change is removing `bind`, which I believe is unnecessary for UDP-client. If two or more cameras use the same UDP-port, I didn't try it but I guess it will conflict to receive data. Other changes are just removing global variables just in case it conflicts. Your code is well organized that it is easy for me to modify.
Current approach is partially working with VISCA-over-IP but it would conflict if both plugins try to access the same UART port.



> Instead of polling, would it be possible for the facetracking code to send events to the frontend thread?


I think so, too. The polling is not the best way. I'm not so familiar with frontend and not sure any event can be defined by plugin developers. Maybe also need to define the destination. Using the signal of Qt might work. Because I'm not so good at Qt, one of the difficulties would be making it thread-safe.


----------



## glikely (Jul 7, 2021)

norihiro said:


> Integer arguments for pan/tilt/zoom is preferable for tracking from my plugin. Since the moving speed is not proportional, I'm making a table to convert.



I'm currently using doubles because it was convenient for choosing relative speed. Each camera could have a different range of valid speed values. By using a double I can define "1.0" to mean fastest speed available and then let the PTZDevice instance rescale it to what the camera can do. It could be switched to int, but would need to define a scale for what those values mean.

If I got a bit more sophisticated, the pan/tilt values could be mapped to deg/s. The cameras I'm using (Sony) document that information, but I doubt all cameras do. Would that be useful in the face tracker? I imagine you'd also need to know the lens FOV angle and current zoom ratio to make proper use of it.



norihiro said:


> Another change is removing `bind`, which I believe is unnecessary for UDP-client. If two or more cameras use the same UDP-port, I didn't try it but I guess it will conflict to receive data.



I need the bind to receive UDP responses from the camera. Sending was no problem, but receiving required the bind. Also, since I've got multiple cameras I need to receive traffic from multiple cameras and send it to the correct device. The current code is very inefficient if there are lots of cameras because received packets are broadcast to *all* cameras using the same socket, but I plan to rewrite that code soon.



norihiro said:


> Other changes are just removing global variables just in case it conflicts. Your code is well organized that it is easy for me to modify.
> Current approach is partially working with VISCA-over-IP but it would conflict if both plugins try to access the same UART port.



Yes, UART will be a problem. I think if we want to support both manual camera control and driving from the facetrack plugin then we need an event/command protocol defined. Having two instances of a PTZDevice for the same camera won't work well in the long term. We'll need to either merge the plugins or have a protocol between them.



norihiro said:


> I think so, too. The polling is not the best way. I'm not so familiar with frontend and not sure any event can be defined by plugin developers. Maybe also need to define the destination. Using the signal of Qt might work. Because I'm not so good at Qt, one of the difficulties would be making it thread-safe.



From what I've read today Qt signals/slots are thread safe by default. If a signal is sent from a different thread than the receiver then Qt will default to queuing the signal in the receiver's event queue. However, that requires an object that inherits from QObject that can emit a signal from inside the facetracking thread. When the signal is emitted, Qt should notice the different thread and use a queued connection. The following was a helpful read:






						Threads Events QObjects - Qt Wiki
					






					wiki.qt.io


----------



## norihiro (Jul 11, 2021)

glikely said:


> Sending was no problem, but receiving required the bind.


I see that. Actually I was struggling to get the response of inquiry commands when I removed bind.



glikely said:


> From what I've read today Qt signals/slots are thread safe by default.


That's good to hear that. Thank you for surveying it. I will consider to use that in my side.
Today, I released with the classes built in my plugin but I hope the communication using a protocol would be much better for users' experience.



glikely said:


> If I got a bit more sophisticated, the pan/tilt values could be mapped to deg/s. The cameras I'm using (Sony) document that information, but I doubt all cameras do. Would that be useful in the face tracker? I imagine you'd also need to know the lens FOV angle and current zoom ratio to make proper use of it.


Yes, deg/s would be useful but it's not mandatory.
The zoom ratio (or raw code) is necessary. The gain for the pan and tilt has to be inverse-proportional to the zoom ratio.
I checked several manuals and find this calculation fit most cases in the range from 0x0000 to 0x4000. The code is not reached due to the problem of bind so far. The hard code 20.0f need to be configurable, for example 12.0f for max-X12 camera.








						obs-face-tracker/face-tracker-ptz.cpp at b6fddaac1e01ceeedb9cbddf3e0b850cdaf73ab3 · norihiro/obs-face-tracker
					

Face tracking plugin for OBS Studio. Contribute to norihiro/obs-face-tracker development by creating an account on GitHub.




					github.com


----------



## glikely (Jul 12, 2021)

glikely updated PTZ Controls with a new update entry:

v0.5.0 Released



> It has been a few weeks, so it is well past time for another release. The big headline in v0.5.0 is that support for the PELCO-P protocol has been merged. If you have a PELCO-P device, please do test and provide feedback.
> 
> Otherwise there have been lots of bug fixes and a few new features. The gamepad support is can now be turned on/off from the settings panel, keyboard modifies can be used on the pan/tilt buttons to adjust the speed, and information about VISCA devices is now outputted to...



Read the rest of this update entry...


----------



## Marty Smith (Jul 14, 2021)

Uh oh...  I may be in over my head.  I'm not an experienced GitHub user.  If I'm reading the install instructions correctly, it looks like I need to build OBS as well as build the latest code for the PTZ addin?  Is there an option for a noob like me where I do something like:  "download these three files and put them in your OBS install's 'addin' folder?"


----------



## toplachi (Jul 14, 2021)

Marty Smith said:


> Uh oh...  I may be in over my head.  I'm not an experienced GitHub user.  If I'm reading the install instructions correctly, it looks like I need to build OBS as well as build the latest code for the PTZ addin?  Is there an option for a noob like me where I do something like:  "download these three files and put them in your OBS install's 'addin' folder?"


Just download 
obs-ptz-v0.5.0-win64.zip
and extract it to C:\Program Files\obs-studio\obs-plugins\64bit (if you are using the default obs install location)


----------



## glikely (Jul 14, 2021)

Marty Smith said:


> Uh oh...  I may be in over my head.  I'm not an experienced GitHub user.  If I'm reading the install instructions correctly, it looks like I need to build OBS as well as build the latest code for the PTZ addin?  Is there an option for a noob like me where I do something like:  "download these three files and put them in your OBS install's 'addin' folder?"



It is still early days for this plugin. I do intend to add an installer and do binary releases for all platforms, it is just going to take a while to get to something that is feature complete. As @toplachi says, there is a zip file for win64 that can be unzipped into your plugins folder which should get you started.


----------



## glikely (Jul 14, 2021)

glikely said:


> It is still early days for this plugin. I do intend to add an installer and do binary releases for all platforms, it is just going to take a while to get to something that is feature complete. As @toplachi says, there is a zip file for win64 that can be unzipped into your plugins folder which should get you started.



BTW, for anyone with windows installer experience, I would very much appreciate help getting the plugin packaged as an msi or installer .exe


----------



## Martyats (Jul 14, 2021)

toplachi said:


> Just download
> obs-ptz-v0.5.0-win64.zip
> and extract it to C:\Program Files\obs-studio\obs-plugins\64bit (if you are using the default obs install location)



I did that and relaunched OBS. Where should I see these controls? I've looked in Tools, View, View/Docks, and Settings.
I'm looking forward to trying this!


----------



## glikely (Jul 14, 2021)

Martyats said:


> I did that and relaunched OBS. Where should I see these controls? I've looked in Tools, View, View/Docks, and Settings.
> I'm looking forward to trying this!



An option to add the PTZ control dock should be found under the View menu


----------



## glikely (Jul 15, 2021)

glikely said:


> An option to add the PTZ control dock should be found under the View menu



If you don't see the option there, look in the OBS log file (Help->Log Files->View Current Log) to see if the plugin has loaded. If it has you'll see something like this in there:


```
09:39:29.758: [obs-ndi] NDI library initialized successfully (NDI SDK WIN64 15:59:50 Feb  4 2020 4.1.6.0)
09:39:29.823: Failed to load 'en-US' text for module: 'ptz-controls.dll'
09:39:29.823: PTZ Controls plugin v0.5.0
09:39:29.903: ViscaUART::get_interface():518: Looking for UART object COM5
09:39:29.903: ViscaUART::get_interface():521: Creating new VISCA object COM5
09:39:29.903: VISCA Unable to open UART COM5
09:39:29.903: ViscaUART::get_interface():518: Looking for UART object COM5
09:39:29.903: ViscaUDPSocket::get_interface():638: Looking for Visca UDP Socket object 52381
09:39:29.903: ViscaUDPSocket::get_interface():641: Creating new VISCA object 52381
09:39:29.912: ViscaUDPSocket::send():623: VISCA UDP --> 02:00:00:01:00:00:00:00:01
09:39:29.913: ViscaUDPSocket::send():623: VISCA UDP --> 01:00:00:05:00:00:00:01:81:01:00:01:ff
09:39:29.913: ViscaUDPSocket::send():623: VISCA UDP --> 01:10:00:05:00:00:00:02:81:09:00:02:ff
```


----------



## Martyats (Jul 15, 2021)

glikely said:


> If you don't see the option there, look in the OBS log file (Help->Log Files->View Current Log) to see if the plugin has loaded. If it has you'll see something like this in there:
> 
> 
> ```
> ...


I could find no mention of /PTZ controld is the current log.
I copied the 4 files from the Zip file into the 64bit folder. Did I miss something?


----------



## glikely (Jul 15, 2021)

Martyats said:


> I could find no mention of /PTZ controld is the current log.
> I copied the 4 files from the Zip file into the 64bit folder. Did I miss something?



Please attach your full log file. Or even better, file an issue in GitHub and attach your full log file there.









						Issues · glikely/obs-ptz
					

OBS Pan Tilt Zoom camera control plugin. Contribute to glikely/obs-ptz development by creating an account on GitHub.




					github.com


----------



## Martyats (Jul 15, 2021)

16:33:47.505: CPU Name: Intel(R) Core(TM) i5-7200U CPU @ 2.50GHz
16:33:47.505: CPU Speed: 2712MHz
16:33:47.505: Physical Cores: 2, Logical Cores: 4
16:33:47.505: Physical Memory: 8096MB Total, 4039MB Free
16:33:47.505: Windows Version: 10.0 Build 19042 (release: 2009; revision: 1083; 64-bit)
16:33:47.505: Running as administrator: false
16:33:47.505: Aero is Enabled (Aero is always on for windows 8 and above)
16:33:47.506: Windows 10 Gaming Features:
16:33:47.506: Game Bar: Off
16:33:47.506: Game DVR: Off
16:33:47.506: Game DVR Background Recording: Off
16:33:47.509: Sec. Software Status:
16:33:47.514: Webroot SecureAnywhere: enabled (AV)
16:33:47.514: Microsoft Defender Antivirus: disabled (AV)
16:33:47.514: Windows Firewall: enabled (FW)
16:33:47.515: Current Date/Time: 2021-07-15, 16:33:47
16:33:47.515: Browser Hardware Acceleration: true
16:33:47.515: Portable mode: false
16:33:47.915: OBS 27.0.1 (64-bit, windows)
16:33:47.915: ---------------------------------
16:33:47.945: ---------------------------------
16:33:47.945: audio settings reset:
16:33:47.945: samples per sec: 48000
16:33:47.945: speakers: 2
16:33:47.946: ---------------------------------
16:33:47.946: Initializing D3D11...
16:33:47.946: Available Video Adapters:
16:33:47.949: Adapter 0: Intel(R) HD Graphics 620
16:33:47.949: Dedicated VRAM: 134217728
16:33:47.949: Shared VRAM: 4244981760
16:33:47.949: PCI ID: 8086:5916
16:33:47.950: Driver Version: 23.20.16.4973
16:33:47.950: output 0: pos={0, 0}, size={1920, 1080}, attached=true, refresh=60, name=
16:33:47.953: Loading up D3D11 on adapter Intel(R) HD Graphics 620 (0)
16:33:47.973: D3D11 loaded successfully, feature level used: b000
16:33:47.973: DXGI increase maximum frame latency success
16:33:48.497: ---------------------------------
16:33:48.497: video settings reset:
16:33:48.497: base resolution: 1920x1080
16:33:48.497: output resolution: 1920x1080
16:33:48.497: downscale filter: Bicubic
16:33:48.497: fps: 30/1
16:33:48.497: format: NV12
16:33:48.497: YUV mode: 709/Partial
16:33:48.497: NV12 texture support not available
16:33:48.498: Audio monitoring device:
16:33:48.498: name: Speakers (CEntrance MicPort Pro)
16:33:48.498: id: {0.0.0.00000000}.{274ab247-0b7e-4c70-bb82-05efc92b7e8e}
16:33:48.502: ---------------------------------
16:33:48.503: Skipping module '../../obs-plugins/64bit/chrome_elf.dll', not an OBS plugin
16:33:48.505: Skipping module '../../obs-plugins/64bit/concrt140.dll', not an OBS plugin
16:33:48.509: [CoreAudio encoder]: CoreAudio AAC encoder not installed on the system or couldn't be loaded
16:33:48.510: Failed to load 'en-US' text for module: 'decklink-captions.dll'
16:33:48.512: Failed to load 'en-US' text for module: 'decklink-ouput-ui.dll'
16:33:48.978: [AMF] Unable to load 'amfrt64.dll', error code 126.
16:33:48.982: [AMF] AMF Test failed due to one or more errors.
16:33:48.982: Failed to initialize module 'enc-amf.dll'
16:33:48.997: Skipping module '../../obs-plugins/64bit/libcef.dll', not an OBS plugin
16:33:49.008: Skipping module '../../obs-plugins/64bit/libEGL.dll', not an OBS plugin
16:33:49.009: Skipping module '../../obs-plugins/64bit/libGLESv2.dll', not an OBS plugin
16:33:49.015: Skipping module '../../obs-plugins/64bit/msvcp140.dll', not an OBS plugin
16:33:49.018: [obs-browser]: Version 2.14.3
16:33:49.018: [obs-browser]: CEF Version 75.1.16+g16a67c4+chromium-75.0.3770.100
16:33:49.024: [noise suppress: Nvidia RTX denoiser disabled, redistributable not found]
16:33:49.026: [obs-ndi] hello ! (version 4.9.0)
16:33:49.026: [obs-ndi] Trying 'C:\Program Files\NewTek\NDI 4 Runtime\v4'
16:33:49.027: [obs-ndi] Found NDI library at 'C:/Program Files/NewTek/NDI 4 Runtime/v4/Processing.NDI.Lib.x64.dll'
16:33:49.032: [obs-ndi] NDI runtime loaded successfully
16:33:49.044: [obs-ndi] NDI library initialized successfully (NDI SDK WIN64 06:20:19 Apr 1 2020 4.5.1.0)
16:33:49.087: Skipping module '../../obs-plugins/64bit/Qt5Network.dll', not an OBS plugin
16:33:49.089: Module '../../obs-plugins/64bit/Qt5Network.dll' not loaded
16:33:49.093: [Source Dock] loaded version 0.1.1
16:33:49.095: Failed to load 'en-US' text for module: 'StreamDeckPlugin.dll'
16:33:49.106: Skipping module '../../obs-plugins/64bit/ucrtbase.dll', not an OBS plugin
16:33:49.107: Skipping module '../../obs-plugins/64bit/vccorlib140.dll', not an OBS plugin
16:33:49.109: Skipping module '../../obs-plugins/64bit/vcruntime140.dll', not an OBS plugin
16:33:49.114: VLC found, VLC video source enabled
16:33:49.124: A DeckLink iterator could not be created. The DeckLink drivers may not be installed
16:33:49.126: No blackmagic support
16:33:49.139: ---------------------------------
16:33:49.139: Loaded Modules:
16:33:49.139: win-wasapi.dll
16:33:49.139: win-mf.dll
16:33:49.139: win-dshow.dll
16:33:49.139: win-decklink.dll
16:33:49.139: win-capture.dll
16:33:49.139: vlc-video.dll
16:33:49.139: text-freetype2.dll
16:33:49.139: StreamDeckPlugin.dll
16:33:49.139: source-dock.dll
16:33:49.139: rtmp-services.dll
16:33:49.139: obs-x264.dll
16:33:49.139: obs-vst.dll
16:33:49.139: obs-transitions.dll
16:33:49.139: obs-text.dll
16:33:49.139: obs-qsv11.dll
16:33:49.139: obs-outputs.dll
16:33:49.139: obs-ndi.dll
16:33:49.139: obs-filters.dll
16:33:49.139: obs-ffmpeg.dll
16:33:49.139: obs-browser.dll
16:33:49.139: image-source.dll
16:33:49.139: frontend-tools.dll
16:33:49.139: enc-amf.dll
16:33:49.139: decklink-ouput-ui.dll
16:33:49.139: decklink-captions.dll
16:33:49.139: coreaudio-encoder.dll
16:33:49.139: ---------------------------------
16:33:49.140: ==== Startup complete ===============================================
16:33:49.179: Switched to Preview/Program mode
16:33:49.179: ------------------------------------------------
16:33:49.187: All scene data cleared
16:33:49.187: ------------------------------------------------
16:33:49.238: [WASAPISource::WASAPISource] Device '{0.0.0.00000000}.{800788e8-e5ba-4681-9b45-3f8da1978cbf}' not found. Waiting for device
16:33:49.239: [Loaded global audio device]: 'Desktop Audio'
16:33:49.240: [WASAPISource::WASAPISource] Device '{0.0.1.00000000}.{8464afd4-7a46-498f-b0ab-02d7672486cc}' not found. Waiting for device
16:33:49.240: [Loaded global audio device]: 'Mic/Aux'
16:33:49.240: - filter: 'Compressor' (compressor_filter)
16:33:49.240: - filter: 'Expander' (expander_filter)
16:33:49.249: [obs-ndi] started A/V threads for source 'HP-LAPTOP (AMD Radeon HD 6470M 1)'
16:33:49.251: [obs-ndi] A/V thread for 'NDI™ Source' started
16:33:49.295: Switched to scene 'Cam 2 PTZ'
16:33:49.353: ------------------------------------------------
16:33:49.353: Loaded scenes:
16:33:49.353: - scene 'Cam 1 Fixed':
16:33:49.353: - source: 'Fixed Cam' (dshow_input)
16:33:49.353: - scene 'Cam 2 PTZ':
16:33:49.353: - source: 'PTZ Cam' (dshow_input)
16:33:49.353: - scene 'NDI Scene':
16:33:49.353: - source: 'NDI™ Source' (ndi_source)
16:33:49.353: ------------------------------------------------
16:33:49.458: Fixed Cam: data.GetDevice failed
16:33:49.458: Fixed Cam: Video configuration failed
16:33:49.492: ---------------------------------
16:33:49.492: [DShow Device: 'PTZ Cam'] settings updated:
16:33:49.492: video device: MEI CV610-U3-V2
16:33:49.492: video path: \\?\usb#vid_2cb3&pid_0201&mi_00#7&e990382&0&0000#{65e8773d-8f56-11d0-a3b9-00a0c9223196}\global
16:33:49.492: resolution: 1280x720
16:33:49.492: flip: 0
16:33:49.492: fps: 30.00 (interval: 333333)
16:33:49.492: format: YUY2
16:33:49.808: using video device audio: no
16:33:49.808: audio device: Digital Audio Interface (MEI CV610-U3-V2)
16:33:49.808: sample rate: 44100
16:33:49.808: channels: 2
16:33:49.808: audio type: Capture
16:36:48.974: adding 640 milliseconds of audio buffering, total audio buffering is now 640 milliseconds (source: PTZ Cam)
16:36:48.974:


----------



## glikely (Jul 16, 2021)

Well, the log file confirms that OBS doesn't see the plug-in. When you copied the files in, were there other plug-in DLLs already in the 64bit directory? Like decklink-captions.dll? Double check that the ptz-controls files actually landed in the plug-in directory. I've had problems in the past with trying to copy the files in, but Windows blocking it because it is a privileged directory.


----------



## toplachi (Jul 16, 2021)

Martyats said:


> I did that and relaunched OBS. Where should I see these controls? I've looked in Tools, View, View/Docks, and Settings.
> I'm looking forward to trying this!


Hmmm.. Just wondering, were the files copied like on the attached photo and not on another sub-folder?


----------



## Martyats (Jul 16, 2021)

Ah, I had copied them in the x86 folder instead of the 64bit folder.  The plugin now works, thank you,
Now I have to get it to control the camera.


----------



## CaliHC (Jul 16, 2021)

Can i run this great plugin standalone?
most of the time i use vmix and would like to use this piece of software


----------



## glikely (Jul 16, 2021)

CaliHC said:


> Can i run this great plugin standalone?
> most of the time i use vmix and would like to use this piece of software



I've been thinking about making a standalone build. It would be a great feature. Please file a feature request in GitHub requesting one: https://github.com/glikely/obs-ptz/issues/new


----------



## glikely (Jul 16, 2021)

CaliHC said:


> Can i run this great plugin standalone?
> most of the time i use vmix and would like to use this piece of software



Doesn't vMix already include PTZ controls?


----------



## CaliHC (Jul 16, 2021)

yes it does in the 4k and pro licence.
but i only have a hd licence.

and the vmix control only speaks visca over ip, but all my cams are visca over serial.

and it would be good to use only one type of cam control software in both vmix and obs


----------



## glikely (Jul 19, 2021)

glikely updated PTZ Controls with a new update entry:

v0.6.0 released



> Another week, another release. Please test and let me know how it works.
> 
> In this release:
> 
> ...



Read the rest of this update entry...


----------



## er1kr1984 (Jul 21, 2021)

This is looking great, i have connected my AXIS V5925 and it works great, but i am having one issue  the only problem i have is i cant connect my xbox one x gamepad when i select the gamepad tick box a box flashes up and disappears instantly.

Another thing that would be awesome would be ONVIF PTZ controls.


----------



## er1kr1984 (Jul 21, 2021)

er1kr1984 said:


> This is looking great, i have connected my AXIS V5925 and it works great, but i am having one issue  the only problem i have is i cant connect my xbox one x gamepad when i select the gamepad tick box a box flashes up and disappears instantly.
> 
> Another thing that would be awesome would be ONVIF PTZ controls.



some additional information 

When i check the windows game controller settings it can find them, i have downloaded the latest drivers i'm on the latest OBS and current on windows 10 ver 1909, which i am in the process of upgrading to the latest

When i check the log viewer it states gamepad found 0 

ive also tried two different xbox controllers an xbox series x controller and a xbox one x controller


----------



## glikely (Jul 21, 2021)

er1kr1984 said:


> some additional information
> 
> When i check the windows game controller settings it can find them, i have downloaded the latest drivers i'm on the latest OBS and current on windows 10 ver 1909, which i am in the process of upgrading to the latest
> 
> ...



Gamepad support on Windows is very unreliable. It is a problem in the Qt5 gamepad library that is well known but remains unfixed. I don't have a good solution aside from rewriting the gamepad library. This problem probably won't get fixed anyone soon unless someone else can develop and submit a fix


----------



## glikely (Jul 21, 2021)

er1kr1984 said:


> Another thing that would be awesome would be ONVIF PTZ controls.



I've got ONVIF support recorded as a feature request: https://github.com/glikely/obs-ptz/issues/16


----------



## er1kr1984 (Jul 21, 2021)

glikely said:


> Gamepad support on Windows is very unreliable. It is a problem in the Qt5 gamepad library that is well known but remains unfixed. I don't have a good solution aside from rewriting the gamepad library. This problem probably won't get fixed anyone soon unless someone else can develop and submit a fix



oh right, I thought I Read something about it being fixed in 0.5 my mistake.


----------



## er1kr1984 (Jul 21, 2021)

glikely said:


> I've got ONVIF support recorded as a feature request: https://github.com/glikely/obs-ptz/issues/16


If you need any ONVIF testing let me know I have a tonne of them lying around


----------



## glikely (Jul 21, 2021)

er1kr1984 said:


> oh right, I thought I Read something about it being fixed in 0.5 my mistake.



It is /better/ in 0.5, but still mostly busted.


----------



## wilderf353 (Jul 22, 2021)

glikely said:


> BTW, for anyone with windows installer experience, I would very much appreciate help getting the plugin packaged as an msi or installer .exe



I use NSIS (Nullsoft Scriptable Install System) to install python apps on windows machines .  I would be happy to help.









						NSIS: Nullsoft Scriptable Install System
					

Download NSIS: Nullsoft Scriptable Install System for free. Windows installer development tool. NSIS (Nullsoft Scriptable Install System) is a professional open source system to create Windows installers. It is designed to be as small and flexible as possible and is therefore very suitable for...




					sourceforge.net


----------



## glikely (Jul 22, 2021)

wilderf353 said:


> I use NSIS (Nullsoft Scriptable Install System) to install python apps on windows machines .  I would be happy to help.



Help would be much appreciated! The installer needs to copy 4 files from the build into the plugins directory, and it needs to be integrated I to the cmake build system so that the CI loop can generate the installer files automatically. If you're able to get something working, you can send it to me as a GitHub pull request, or email me the patches.


----------



## toplachi (Jul 22, 2021)

I have tested this plugin with the new hotkey feature and it's great! Thank you for this update!

I have another suggestion, is it possible to send bought tilt and pan commands if we press their hotkeys so that it will be possible to move the camera diagonally? I noticed that I can pan or tilt our camera while zooming in or out using the hotkeys


----------



## glikely (Jul 22, 2021)

toplachi said:


> I have tested this plugin with the new hotkey feature and it's great! Thank you for this update!



Great! I'm glad it is working for you.



toplachi said:


> I have another suggestion, is it possible to send bought tilt and pan commands if we press their hotkeys so that it will be possible to move the camera diagonally? I noticed that I can pan or tilt our camera while zooming in or out using the hotkeys



Please file a feature request in GitHub so it isn't forgotten


----------



## wilderf353 (Jul 23, 2021)

glikely said:


> Help would be much appreciated! The installer needs to copy 4 files from the build into the plugins directory, and it needs to be integrated I to the cmake build system so that the CI loop can generate the installer files automatically. If you're able to get something working, you can send it to me as a GitHub pull request, or email me the patches.


Can you confirm that the plugin will only work on x64 systems. Example: if the 64bit folder does not exist, the installer should post a message that says "This plugin only works with the 64 bit OBS..."


----------



## glikely (Jul 23, 2021)

wilderf353 said:


> Can you confirm that the plugin will only work on x64 systems. Example: if the 64bit folder does not exist, the installer should post a message that says "This plugin only works with the 64 bit OBS..."



The plug-in /should/ work on 32 bit. I just haven't added the 32 bit build yet.


----------



## mhortz (Aug 11, 2021)

Obs-ptz plugin doesn't work for me. I have a NeoId USB PTZ camera and I'm using  a VISCA serial


----------



## C-Cedilla (Aug 14, 2021)

Absolutely nothing but appreciation for this piece of work here! Works perfectly fine as far as I can tell with the RGBlink PTZ.

I’m not entirely sure yet what the radio boxes if manual, follow preview and follow program are yet but I’ll mess about with it some more.


----------



## bradpeterson (Aug 16, 2021)

I've got my VISA serial to USB cables on order.  In the meantime, I'm trying to figure out these two things:

1) How do I tell OBS to use a camera present in a scene?  My goal is just to click on a scene and the camera changes what its pointing at.

2) What do I put for the serial UART port?  Do I put in "RS-232"?  Right now my drop down is empty.  Should the drop down be populated with entries I can choose?


----------



## glikely (Aug 17, 2021)

C-Cedilla said:


> Absolutely nothing but appreciation for this piece of work here! Works perfectly fine as far as I can tell with the RGBlink PTZ.
> 
> I’m not entirely sure yet what the radio boxes if manual, follow preview and follow program are yet but I’ll mess about with it some more.



Thanks for the kind words! I'm glad it is working for you. When there are multiple cameras, the radio buttons controls which camera will be controlled when a scene of the same name becomes either the preview or live scene. It's not a very good UI though and needs some rework.


----------



## glikely (Aug 17, 2021)

bradpeterson said:


> I've got my VISA serial to USB cables on order.  In the meantime, I'm trying to figure out these two things:
> 
> 1) How do I tell OBS to use a camera present in a scene?  My goal is just to click on a scene and the camera changes what its pointing at.



Recalling a preset based on selecting a scene hasn't been implemented yet.



bradpeterson said:


> 2) What do I put for the serial UART port?  Do I put in "RS-232"?  Right now my drop down is empty.  Should the drop down be populated with entries I can choose?



When you plug in your USB cable it will be detected and the right port name will be in the UART port drop down.


----------



## bradpeterson (Aug 18, 2021)

Good news.  I got it working on a Lumens A51S through VISCA.  The system I tested on had this 9 pin RS-232 to USB adapter (Keyspan USA HS19).  The UART popped up as COM3, and I used VISCA ID 1.  I found though that had to plug in the USB cable, then start OBS, then configure it.  If I started OBS, then plugged in the cable, nothing worked.  (Note for others, I found I had to double click on the presets to make it switch).  

Also, I would like to assist on this project a bit. I've done my fair share of software development, and I've also worked with the NSIS installer for a couple of projects. 

To make it auto select a preset on a scene, could we just add a PTZ preset "source"? So if I have a scene with a USB webcam input, and a 3.5mm input, could we just add a 3rd source of a PTZ camera preset?


----------



## Joaomacjr (Aug 20, 2021)

mhortz said:


> Obs-ptz plugin doesn't work for me. I have a NeoId USB PTZ camera and I'm using  a VISCA serial


I use the conference ptz. from what i saw is the same as neoid. I needed to change the address of the visca id to 2 to work


----------



## glikely (Aug 22, 2021)

bradpeterson said:


> Good news.  I got it working on a Lumens A51S through VISCA.  The system I tested on had this 9 pin RS-232 to USB adapter (Keyspan USA HS19).  The UART popped up as COM3, and I used VISCA ID 1.  I found though that had to plug in the USB cable, then start OBS, then configure it.  If I started OBS, then plugged in the cable, nothing worked.  (Note for others, I found I had to double click on the presets to make it switch).



Great news! I'm glad it is working for you. It shouldn't be too difficult to fix plugging in the USB cable after OBS is started. Right now the plugin rescans for UARTs whenever the active camera changes, but that never happens if there is only one camera. Adding a Qt slot for a UART being added/removed should fix the problem.

The double click to activate a preset is by design. I found that if it was a single click users would accidentally activate a preset when they were wanting to just select to rename or update the settings.



bradpeterson said:


> Also, I would like to assist on this project a bit. I've done my fair share of software development, and I've also worked with the NSIS installer for a couple of projects.



I'd love to have the help. All development traffic is on GitHub. Send me pull requests!



bradpeterson said:


> To make it auto select a preset on a scene, could we just add a PTZ preset "source"? So if I have a scene with a USB webcam input, and a 3.5mm input, could we just add a 3rd source of a PTZ camera preset?



That's a good idea. Go for it.


----------



## Kishi! (Aug 22, 2021)

Hi 
I used to get this working on my camera using USB serial. After setup on my new rig of fresh pc, it doesnt work anymore :(
Anyone can advise /help , see my attached log.


----------



## glikely (Aug 23, 2021)

Kishi! said:


> Hi
> I used to get this working on my camera using USB serial. After setup on my new rig of fresh pc, it doesnt work anymore :(
> Anyone can advise /help , see my attached log.



It looks like the camera address is set to 0 instead of 1. Can you attach the ptz controls config file?


----------



## glikely (Aug 28, 2021)

Hey everyone. It's been awhile since the last release, so I wanted to give an update. There are a good number of bug fixes and improvements queued up for v0.7.0, including ability to set the UART baud rate, improvements to the properties dialog, proper handling of UTF-8 device and preset names, and manual focus control. Right now I'm dealing with a few remaining bugs, and I hope to get the new release out this weekend.


----------



## glikely (Aug 28, 2021)

glikely updated PTZ Controls with a new update entry:

v0.7.0-rc1



> First release candidate for v0.7.0. Several new features, including:
> 
> - Add focus controls to the dock
> - Adding configurable baud rate
> ...



Read the rest of this update entry...


----------



## GregPeatfield (Aug 29, 2021)

glikely said:


> glikely updated PTZ Controls with a new update entry:
> 
> v0.7.0-rc1
> 
> ...


Hi Grant,

Love the addition of the Focus! With this version I am starting to see "Stuck" controls again while using the PTZ and Focus controls. I think I saw this back at 0.4.0 or earlier I think when you first introduced the VISCA over IP.

I experienced a little unexpected behavior with the Focus controls. I have been trying to figure out the best way to reproduce it but it is elusive in nature. It seems like at first setup, the initial state of the "Focus" controls are not known. Due to this, altering the focus manually doesn't work until you first select AF. I don't know the best way to set the One-Touch Focus, but currently that doesn't do anything I can see yet when I hit that button in Manual focus mode.

The manual focus is a great addition to the Plugin for those with obstacle in their field of view (Poles, etc.) as well as for simple artistic blur of the screen at times.  Love it!

-Greg


----------



## silvamichael (Aug 31, 2021)

it would be very nice if there would be future integration with ONVIF then this tool would be future proof! ;)


----------



## glikely (Aug 31, 2021)

silvamichael said:


> it would be very nice if there would be future integration with ONVIF then this tool would be future proof! ;)


I'd be very happy to merge ONVIF support if anyone gets it implemented. Either that, or somebody needs to send me an ONVIF camera! :-)


----------



## glikely (Aug 31, 2021)

GregPeatfield said:


> Hi Grant,
> 
> Love the addition of the Focus! With this version I am starting to see "Stuck" controls again while using the PTZ and Focus controls. I think I saw this back at 0.4.0 or earlier I think when you first introduced the VISCA over IP.
> 
> ...


Hi Greg,

Thanks for filing a bug report on the problems you're seeing. I've replied on the github thread, but the short version for anyone reading here is that the plugin doesn't appear to be receiving replies from your cameras, so it doesn't know what state autofocus is in. This _might_ be due to OBS being on a different subnet and the camera not configured properly for the gateway.


----------



## Paul G (Aug 31, 2021)

Hello. As I would be using this in a completely NON-Profit use-case - can anyone suggest the least expensive PTZ camera model that will work with this plugin? Thanks!


----------



## glikely (Aug 31, 2021)

Paul G said:


> Hello. As I would be using this in a completely NON-Profit use-case - can anyone suggest the least expensive PTZ camera model that will work with this plugin? Thanks!


I'm using second hand cameras that sourced from eBay. This plugin will support both the older VISCA over Serial, and VISCA over IP, so as long as you find a camera that supports VISCA you should be good to go.

There are also no-name PTZ cameras available on Amazon and Aliexpress, but I cannot say whether or not they are any good.


----------



## Paul G (Aug 31, 2021)

No Model suggestions? Not having any luck with google searching combinations of visca rtsp ptz camera. All I get are controllers.


----------



## Lawrence_SoCal (Aug 31, 2021)

There are a number of NDI PTZ cameras on Amazon at the moment about 1/2 price and appear to be PTZOptics knock-offs. Whether those items are 'legal' or not, I'm not sure. Certainly appears unethical copying ... but maybe not. However, the primary one I looked at has a gmail support address. These are fly-by-night operations, with (very) poor English translations, and bugs, and not certainty of getting future firmware updates (ex updated NDI versions).... so, as much as I'm sorely tempted for a 2nd NDI PTZ at our non-profit, I'm not sure 1/2 now represents good value.... As for finding used, last year this time there were wait times for the cameras. So, I wouldn't expect much savings on used (but I haven't researched that deeply). Then again, a serial PTZ might well be available for lower price, but then you have to consider the overall price (as you then will need  both the serial cable, as well power, and SDI, HDMI, or ?? cabling, and a capture card, etc... why we went NDI). 
If buying used, my approach would be to buy form a Tier 1 vendor, where you can get support (and possibly repairs) if need be
If the streaming PC and a single camera are close to each other and no plan to expend to multi-camera, I'd be inclined to a USB PTZ camera for simplicity


----------



## Paul G (Aug 31, 2021)

I saw this mentioned here on the forum so I checked it out. Seems every interesting. OBS is in the large list of Compatible software. Thoughts?





						OBSBOT Tiny AI-Powered PTZ Webcam (1080p Edition)
					

This is the store page of the OBSBOT Tiny AI-Powered PTZ webcam (1080p edition), where you can place an order directly.




					store.obsbot.com


----------



## glikely (Aug 31, 2021)

Paul G said:


> I saw this mentioned here on the forum so I checked it out. Seems every interesting. OBS is in the large list of Compatible software. Thoughts?
> 
> 
> 
> ...


The OBSBot cameras are cool, but the remote control is entirely proprietary. They cannot be controlled with this plugin.


----------



## Paul G (Sep 1, 2021)

Thanks for the info. After watching a Youtube video of someone using one in OBS - I bought one....78^)


----------



## GregPeatfield (Sep 1, 2021)

Paul G said:


> Hello. As I would be using this in a completely NON-Profit use-case - can anyone suggest the least expensive PTZ camera model that will work with this plugin? Thanks!


Jimcom USA has a few Open Box models listed on eBay with NDI as well for a great and USA supported device, they are a great option.


----------



## markdj (Sep 4, 2021)

I have been trying this out v7.0-rc1, haven't figured out how to use the presets with the scenes and xbox controller just doesn't work. The presets aren't being displayed even though the camera has 4 saved.


----------



## glikely (Sep 5, 2021)

glikely updated PTZ Controls with a new update entry:

v0.7.0



> v0.7.0 is out there with improvements all over the code. Now you can configure the baud rate for VISCA and Pelco protocols. Focus control buttons have been added. The dock layout has been shuffled around to make it easier to select presets, and lots of bug fixes. Please test!
> 
> Things are coming along quite well for this plugin, and I'm starting to think about when to do a v1.0 release. There are still some key features that I want to get added before reaching that point, such as proper...



Read the rest of this update entry...


----------



## Benno Holunder (Sep 6, 2021)

Hello glikely, fantastic that you picked up my proposal for the dock layout so quickly!
I checked it out immediately and found the size of the area with the control buttons (gamepad ?) shrunk a bit compared to 0.7.0-rc1 so that the buttons can be hit less easy now. I would appreciate if you could change the size of the control buttons area back to the previous size. However, that might all depend on the screen resolution and each user would like to have an individual size adjustment. I don't know how to realize that, but I guess you could make it happen, e.g. with a ratio factor in the settings dialogue.
I am looking forward to your next changes ...


----------



## Randle (Sep 7, 2021)

Thanks for your work in integrating PTZ. The pipe dream for me is having multiple PTZ actions triggered from a scene selection. For example: I load a scene and it automatically triggers a PTZ preset as well as presets for multiple other cameras. The reason I'd want multiple presets triggered is that when one camera/scene is used, I usually know that I will be using the next camera at a defined preset. If it has already been moved, then people won't see it moving on the stream which looks much more professional.

Have you talked to this project: OBS Lua - Control Visca-over-IP based cameras | OBS Forums (obsproject.com)


----------



## glikely (Sep 7, 2021)

markdj said:


> I have been trying this out v7.0-rc1, haven't figured out how to use the presets with the scenes and xbox controller just doesn't work. The presets aren't being displayed even though the camera has 4 saved.



Joystick control is not reliable on Windows. It works on some machines, but not all. The while thing needs to be reworked.

Scene presets are planned, but not implemented yet.

Please file an issue on GitHub and give details about the issues your having with presets. Including screenshots would be helpful.


----------



## glikely (Sep 7, 2021)

Benno Holunder said:


> Hello glikely, fantastic that you picked up my proposal for the dock layout so quickly!
> I checked it out immediately and found the size of the area with the control buttons (gamepad ?) shrunk a bit compared to 0.7.0-rc1 so that the buttons can be hit less easy now. I would appreciate if you could change the size of the control buttons area back to the previous size. However, that might all depend on the screen resolution and each user would like to have an individual size adjustment. I don't know how to realize that, but I guess you could make it happen, e.g. with a ratio factor in the settings dialogue.
> I am looking forward to your next changes ...



Qt layout rules are fiddly. I'm still working out the best way to handle them so that the buttons will nicely resize. Please file an issue on GitHub to track the problem.


----------



## jerburgess (Sep 8, 2021)

I tried using the plugin with two old Sony BRC-300 cameras.  Unfortunately, I got nothing.  I'm using camera ID 1, and tried both 9600 and 38400 baud.  I can get them both to work in "PTZ Controller", but of course, it would be much more convenient to have them working in OBS.


----------



## glikely (Sep 8, 2021)

jerburgess said:


> I tried using the plugin with two old Sony BRC-300 cameras.  Unfortunately, I got nothing.  I'm using camera ID 1, and tried both 9600 and 38400 baud.  I can get them both to work in "PTZ Controller", but of course, it would be much more convenient to have them working in OBS.


Can you file an issue on GitHub and attach your OBS log file?


----------



## scaesare (Sep 10, 2021)

Paul G said:


> No Model suggestions? Not having any luck with google searching combinations of visca rtsp ptz camera. All I get are controllers.



During the pandemic, I've bought 3 used Vaddio ConferenceShot 10 cameras for  $50-80 on eBay (although I had to but a $15 power supply separately).

These are uncompressed 1080P USB3 cameras with decent 10X zoom optics. They also do RTSP streaming. I've briefly tested with this plugin and it seems to work.

They are great cams for the price when you can find them.


----------



## jerburgess (Sep 10, 2021)

glikely said:


> Can you file an issue on GitHub and attach your OBS log file?


Done, thanks!


----------



## toplachi (Sep 11, 2021)

I am not yet sure if this is really a bug or just a problem the cameras I have. But I think there's a problem controlling cameras if 1 is connected using visca serial and other is pelco-p.
To try it, when using a visca serial camera, first create a Pelco-P connection, and then add the visca serial camera (vice versa if you have Pelco-P camera). Relaunch OBS and see if you can still control your camera... If you have both kind of cameras, only 1 of them will probably work


----------



## glikely (Sep 11, 2021)

toplachi said:


> I am not yet sure if this is really a bug or just a problem the cameras I have. But I think there's a problem controlling cameras if 1 is connected using visca serial and other is pelco-p.
> To try it, when using a visca serial camera, first create a Pelco-P connection, and then add the visca serial camera (vice versa if you have Pelco-P camera). Relaunch OBS and see if you can still control your camera... If you have both kind of cameras, only 1 of them will probably work


Are you trying to daisy chain them to the same serial port? PELCO and VISCA cannot be on the same connection.


----------



## toplachi (Sep 11, 2021)

glikely said:


> Are you trying to daisy chain them to the same serial port?


Yes,



glikely said:


> PELCO and VISCA cannot be on the same connection.


Is that so? I downloaded a trial version of a paid ptz controller app which can control our cameras that have different protocols, that's why I thought it was just normal. I also want to add that the cameras we have also support multi-protocol _(if that info would help)_.

We also have a physical PTZ keyboard controller connected via RS485, which as far as I know worked _(Is that also normal?)_ before alongside with this plug-in running on the pc. Recently, whenever the ptz keyboard is on, I can no longer control the cameras using this plug-in _(even with the other controller app)_. I changed the camera protocols from visca to pelco and I can again control the cameras either with the physical controller or via this plugin _(which I more prefer)_....  And then I found out that what I thought was a bug.


----------



## Dan Pascu (Sep 12, 2021)

glikely said:


> glikely submitted a new resource:
> 
> PTZ Controls - Pan Tilt Zoom camera controls for OBS
> 
> ...


Dear Glikely, Thank you for your great plugin. I had tested on W10 machine with Avonic CM-70 cameras and is working great.

I have two questions for you is you have time: First - can you add on the saved parameters for each preposition IRIS, Focus and WB!
Second - because I am so knob on compiling the source code to be used on an Intel Mac can you help with the plugin for Mac(not M1).

Thank you so much again for your time and effort.
Best regards, Dan


----------



## glikely (Sep 12, 2021)

Dan Pascu said:


> Dear Glikely, Thank you for your great plugin. I had tested on W10 machine with Avonic CM-70 cameras and is working great.



Glad to hear it is working well for you. What protocol do those cameras use? VISCA, VISCA over IP, or PELCO?



Dan Pascu said:


> I have two questions for you is you have time: First - can you add on the saved parameters for each preposition IRIS, Focus and WB!



The presets are stored entirely on the camera. The plug-in doesn't handle anything other than telling to camera to save or restore a preset. There is a feature request to store preset data in the plug in, but I'm not working on it.



Dan Pascu said:


> Second - because I am so knob on compiling the source code to be used on an Intel Mac can you help with the plugin for Mac(not M1).



I do intend to get it building for Mac, but simply haven't had time to get it going. Theoretically it should build without issue. At some point I'll get around to it unless someone else does it for me. Pull requests welcome!


----------



## Benno Holunder (Sep 12, 2021)

glikely said:


> Qt layout rules are fiddly. I'm still working out the best way to handle them so that the buttons will nicely resize. Please file an issue on GitHub to track the problem.


Hi Grant Likely, thanks for the test version with the adjustable size of the control buttons --- works great on my side:
( I compiled the ptz-controls on openSUSE 15.3 and I am using VISCA over IP ).
I fiddled around a bit with the ptz-controls.ui with QtDesigner and found the attached layout even more handy.
The arrow icons don't stick out too bold and bright.
.



I would also recommend to change the icon size calculation from ( - 2*10 px ) to ( * 3 / 4 ) of qMin (height, width) to scales proportional to the button size


----------



## Benno Holunder (Sep 12, 2021)

I will also file another issue on GitHub to request for a "White Balance" button, because I regularly need to adjust the white balance of all my cameras against a white wall, because it is quite different during the morning hours versus dusk in the late afternoon, when the indoor lights dominate.


----------



## glikely (Sep 13, 2021)

toplachi said:


> Is that so? I downloaded a trial version of a paid ptz controller app which can control our cameras that have different protocols, that's why I thought it was just normal. I also want to add that the cameras we have also support multi-protocol _(if that info would help)_.



PELCO-P and VISCA use entirely different framing schemes for deciding what is a datagram. Using both on the same serial port may work in some circumstances, but there is a high chance that messages will be misinterpreted by other devices. If cameras on the same port support multiple protocols then it is best to configure them all to use the same one.

This plugin doesn't support using multiple protocols on the same port. Only one protocol will be able to open the port, and the other will be blocked



toplachi said:


> We also have a physical PTZ keyboard controller connected via RS485, which as far as I know worked _(Is that also normal?)_ before alongside with this plug-in running on the pc. Recently, whenever the ptz keyboard is on, I can no longer control the cameras using this plug-in _(even with the other controller app)_. I changed the camera protocols from visca to pelco and I can again control the cameras either with the physical controller or via this plugin _(which I more prefer)_....  And then I found out that what I thought was a bug.



Is your RS485 wired as a bus, or daisy chained ring? If it is wired as a ring, then the ptz keyboard may be filtering out the VISCA commands before they go to the cameras. It is a bit hard to debug without access to the hardware. Do you have a way to trace the serial traffic on the line?


----------



## toplachi (Sep 13, 2021)

glikely said:


> Is your RS485 wired as a bus, or daisy chained ring? If it is wired as a ring, then the ptz keyboard may be filtering out the VISCA commands before they go to the cameras. It is a bit hard to debug without access to the hardware. Do you have a way to trace the serial traffic on the line?



I am using a two wire RS485 connection, I just tied the A wires altogether and then the B wires like an asterisk.. I am sorry, I don't know much of this serial connections, mostly I just found over the internet. Its currently working now but I might do some experiments sometime to learn from it.... Thank you for the help!


----------



## glikely (Sep 14, 2021)

toplachi said:


> I am using a two wire RS485 connection, I just tied the A wires altogether and then the B wires like an asterisk.. I am sorry, I don't know much of this serial connections, mostly I just found over the internet. Its currently working now but I might do some experiments sometime to learn from it.... Thank you for the help!



It sounds like it is wired as a bus. It is possible that in VISCA mode the keyboard controller is continuously sending out inquiry commands which are interfering with the plug-in.


----------



## Dan Pascu (Sep 14, 2021)

glikely said:


> Glad to hear it is working well for you. What protocol do those cameras use? VISCA, VISCA over IP, or PELCO?
> 
> 
> 
> ...


Thank you for your effort. I'll wait for the Mac version when will be available!


----------



## Dan Pascu (Sep 14, 2021)

Dan Pascu said:


> Thank you for your effort. I'll wait for the Mac version when will be available!


I'm using Visca over IP for the Avonic CM70 cameras


----------



## glikely (Sep 14, 2021)

glikely said:


> It sounds like it is wired as a bus. It is possible that in VISCA mode the keyboard controller is continuously sending out inquiry commands which are interfering with the plug-in.



What model of PTZ keyboard controller do you have? I'm considering adding PTZ keyboard input support so that a PTZ keyboard can control the plug-in. Basically the plug in would be a proxy for the keyboard, allowing the keyboard to control any camera, regardless of protocol.


----------



## toplachi (Sep 15, 2021)

glikely said:


> What model of PTZ keyboard controller do you have? I'm considering adding PTZ keyboard input support so that a PTZ keyboard can control the plug-in. Basically the plug in would be a proxy for the keyboard, allowing the keyboard to control any camera, regardless of protocol.


We have 2 ptz keyboards, the first one which also supports visca protocol is similar to this https://www.youtube.com/watch?v=t0rnmINzIho but with different key assignments... This is the one that is disabling the controls from the pc. I just tested it again and it doesn't matter which serial protocol I am using.




The 2nd is a much cheaper PTZ keyboard that is used for surveillance cameras. It only has rs485 connection but it can be used simultaneously with software-based ptz controller


----------



## glikely (Sep 16, 2021)

toplachi said:


> We have 2 ptz keyboards, the first one which also supports visca protocol is similar to this https://www.youtube.com/watch?v=t0rnmINzIho but with different key assignments... This is the one that is disabling the controls from the pc. I just tested it again and it doesn't matter which serial protocol I am using.
> View attachment 75178
> 
> The 2nd is a much cheaper PTZ keyboard that is used for surveillance cameras. It only has rs485 connection but it can be used simultaneously with software-based ptz controller
> View attachment 75179


That makes sense. Most likely the first one constantly drives the serial lines when it is turned on, which would block commands sent by the plug-in.

Regardless, neither PELCO nor VISCA is designed to have multiple controllers on the bus. It may work sometimes, but it can cause unpredictable behaviour.


----------



## Ie872 (Sep 18, 2021)

Did anyone know if RGBLink PTZ Camera or Zowietek PTZ Camera supports the ptzctrl CGI / API commands such as PTZOptics Cameras?My usecase is that by changing a scene the preset positions of the camera called (in OBS by using a Media Source with the CGI Call).
Or do the PTZ Control support automatic Preset Call when changing a scene? Thx


----------



## glikely (Sep 18, 2021)

Ie872 said:


> Or do the PTZ Control support automatic Preset Call when changing a scene? Thx



This is a planned feature, but not implemented yet


----------



## minnim6 (Sep 23, 2021)

I am trying to use this on security cameras. Is there any way to use tdp instead of udp?


----------



## glikely (Sep 23, 2021)

minnim6 said:


> I am trying to use this on security cameras. Is there any way to use tdp instead of udp?


It is planned, but not implemented yet. Please file an issue on GitHub and include the specific camera(s) you're using so I can look up the technical detail.


----------



## glikely (Sep 25, 2021)

glikely updated PTZ Controls with a new update entry:

v0.8.0



> Hi everyone, I've just tagged another release. The big news in this one is I've implemented a basic ability to recall presets or move the camera when a scene becomes active in either program or preview. This is a very early prototype of the feature. Please try it out and give me feedback.
> 
> To use the feature, add a "PTZ Action" feature to the scene that you want to trigger camera movement on.
> 
> In other news, the UI layout has been improved and there have been a few bug fixes.



Read the rest of this update entry...


----------



## rosnow (Sep 28, 2021)

Trying to get this to work with a 'PTZ Optics' camera. 
Is there a configuration that is known to work? I've tried visca over IP with the IP address and a few different ports including 5678, which is shown in the camera page. None control the cam for me.


----------



## rosnow (Sep 28, 2021)

Also, I had thought that NDI includes an interface to PTZ. Would it be possible to add that as a connection type?


----------



## dhow (Sep 30, 2021)

glikely said:


> glikely submitted a new resource:
> 
> PTZ Controls - Pan Tilt Zoom camera controls for OBS
> 
> ...


Hello. Very new to all this but am trying to find a cable to connect PTZ to computer (mini din to usb ?) for a visca serial connection to call up presets in scenes. Any reccomendations for such a cable - does it exist?


----------



## GregPeatfield (Oct 1, 2021)

dhow said:


> Hello. Very new to all this but am trying to find a cable to connect PTZ to computer (mini din to usb ?) for a visca serial connection to call up presets in scenes. Any reccomendations for such a cable - does it exist?



What type of camera do you have, the best method would be to use the LAN cable going to the camera if it is an IP camera.


----------



## glikely (Oct 1, 2021)

rosnow said:


> Trying to get this to work with a 'PTZ Optics' camera.
> Is there a configuration that is known to work? I've tried visca over IP with the IP address and a few different ports including 5678, which is shown in the camera page. None control the cam for me.



PTZ Optics use a slightly variant of the VISCA protocol that hasn't been implemented yet. It is on the to-do list.


----------



## glikely (Oct 1, 2021)

dhow said:


> Hello. Very new to all this but am trying to find a cable to connect PTZ to computer (mini din to usb ?) for a visca serial connection to call up presets in scenes. Any reccomendations for such a cable - does it exist?



USB to VISCA is very rare. It is easier to find a usb to rs232 adapter and then an rs232 to VISCA cable.


----------



## Benno Holunder (Oct 1, 2021)

Hi Grant, I compiled the new version 0.8.0 with the PTZ-Action and have only a quick question before testing the version in detail:
Why did you implement the PTZ-Action as an OBS-Source and not as an OBS-Filter. Following the standard OBS logic I would see it as a Filter applied to a Scene. Within the Filter you have then to select the Source item within the Scene which shall be controlled (manipulated) by the Filter. That would then be a PTZ camera in this case. --- Your thoughts?


----------



## wilderf353 (Oct 1, 2021)

dhow said:


> Hello. Very new to all this but am trying to find a cable to connect PTZ to computer (mini din to usb ?) for a visca serial connection to call up presets in scenes. Any reccomendations for such a cable - does it exist?


Our 2 cameras use the Visca protocol.  I picked up a PC serial port to RS-485 adapter on Amazon for $12, and made my own cable to run to the camera. It has been working well with the PTZ Controls Plugin. Maybe you could pick up one too and modify your cable to work with the adapter?

Here is the link on Amazon: https://www.amazon.com/Serial-Communication-Converter-Adapter-Mini-Size/dp/B0196AO1IG


----------



## wilderf353 (Oct 1, 2021)

I really like using the "Follow Preview" radio button at the bottom of the PTZ Controls pane: when you select a camera in the OBS Scenes pane, it will automatically switch to the proper list of presets in the PTZ Controls pane.

*Note*: it looks like PTZ Controls uses the camera's name and not it's ID. This means if you rename a camera in the OBS Scenes pane (and it does not match the name in the PTZ Controls pane),the "Follow Preview" will break. I was able to fix it by (1) shutting down OBS, (2) editing the config file in the  C:\Users\<USER>\AppData\Roaming\obs-studio\plugin_config\ptz-controls folder, (3) restarting OBS


----------



## wilderf353 (Oct 1, 2021)

I am having trouble with the new version 0.8.0  ...  I cannot get the "PTZ Action" feature to work. When I select a scene, then select "+" in the sources pane, I do not see an PTZ-Action. Maybe I am not updating it properly?

When I click on the config button in the PTZ Controls, it reports that I am using V0.7.0. But when I check the properties tab in Windows Explorer on the ptz-controls.pdb file, I see that it was created on 9-25-21. So I think I have the latest file.

Can someone confirm that your PTZ Device Setting window shows v0.8.0?


----------



## glikely (Oct 2, 2021)

Benno Holunder said:


> Hi Grant, I compiled the new version 0.8.0 with the PTZ-Action and have only a quick question before testing the version in detail:
> Why did you implement the PTZ-Action as an OBS-Source and not as an OBS-Filter. Following the standard OBS logic I would see it as a Filter applied to a Scene. Within the Filter you have then to select the Source item within the Scene which shall be controlled (manipulated) by the Filter. That would then be a PTZ camera in this case. --- Your thoughts?



I implemented it as new sources because it is a trigger for actions rather than the ptz camera itself. This matches the was preset recall works when a URL source is used to trigger recall so I thought it would be the most intuitive approach. I am open to other approaches thought. The feature is still very much experimental and I can change it.

On a related topic, I am considering adding a source filter for associating a PTZ device with a video source so that I can get better tracking of when the source is active.


----------



## jbcurler2010 (Oct 3, 2021)

Having trouble getting this set up. Get the dock implemented but when I go to set up the camera the selection box flashes and then disappears. Any thoughts?


----------



## glikely (Oct 3, 2021)

jbcurler2010 said:


> Having trouble getting this set up. Get the dock implemented but when I go to set up the camera the selection box flashes and then disappears. Any thoughts?


Please file an issue on GitHub and attach the OBS log file


----------



## dhow (Oct 5, 2021)

GregPeatfield said:


> What type of camera do you have, the best method would be to use the LAN cable going to the camera if it is an IP camera.


It is a TENVEO usb PTZ so no network interface (just USB)


----------



## dhow (Oct 5, 2021)

wilderf353 said:


> Our 2 cameras use the Visca protocol.  I picked up a PC serial port to RS-485 adapter on Amazon for $12, and made my own cable to run to the camera. It has been working well with the PTZ Controls Plugin. Maybe you could pick up one too and modify your cable to work with the adapter?
> 
> Here is the link on Amazon: https://www.amazon.com/Serial-Communication-Converter-Adapter-Mini-Size/dp/B0196AO1IG


Thank you. I'll have a loook.


----------



## dhow (Oct 5, 2021)

glikely said:


> USB to VISCA is very rare. It is easier to find a usb to rs232 adapter and then an rs232 to VISCA cable.


Thanks, I thought as much.


----------



## rosnow (Oct 10, 2021)

glikely said:


> PTZ Optics use a slightly variant of the VISCA protocol that hasn't been implemented yet. It is on the to-do list.


Got it. Appreciate the reply. Would be willing to test implementation with cameras if needed. 

Also noticed that PTZO released a spec of their visca implementation if that helps:


			https://ptzoptics.com/wp-content/uploads/2020/11/PTZOptics-VISCA-over-IP-Rev-1_2-8-20.pdf


----------



## glikely (Oct 16, 2021)

I've just pushed out prototype code for VISCA-over-TCP support (PTZOptics, Jimcom, etc) into the `visca-tcp` topic branch. Can I get some help testing please? A windows build can be found on github: https://github.com/glikely/obs-ptz/actions/runs/1348631206

Let me know here if it works. If you run into problems create a github issues and attach the OBS log file so I can see the details.


----------



## p8n (Oct 17, 2021)

Just can't get it to work. Have set up the COM ports and baud rate exactly as used in https://www.ptzcontroller.com/
The controls do nothing. it is not clear what the radio buttons for "Manual,Follow Preview, Follow Program" do.

have tried all the options, preset, arrows etc and nothing works. OBS 27.0.1. VISCA Serial TENVEO. Works fine with everything else.


----------



## p8n (Oct 17, 2021)

I just cannot get this to work. I have a TENVEO PTZ with serial control. It works fine with all other PTZ control software that uses serial. I have been using the www.ptzcontroller.com

I have used the same COM ports and baud rates. The controls do nothing.


----------



## glikely (Oct 17, 2021)

p8n said:


> I just cannot get this to work. I have a TENVEO PTZ with serial control. It works fine with all other PTZ control software that uses serial. I have been using the www.ptzcontroller.com
> 
> I have used the same COM ports and baud rates. The controls do nothing.



I'll need to see the OBS log file to help you debug this. Please file an issue in GitHub and attach the log file.


----------



## sebacabezon18 (Oct 18, 2021)

Hi man, realy apreciated your contributions realy works with my Naipix PTX NDI and OBS,  but only manage with the mouse,  when try add Gamepad ps2,ps3  your plugin not recognize the hardware. Let me now if get wrong some steps for configure. 
first install the 0.6 now reeplace the files with the version 0.8 but not have response from Gamepad. Whe enable GamePad  some reason see for just miliseconds one windows of OBS and dissapear but nothings happends. The control not aviable.


----------



## wilderf353 (Oct 19, 2021)

sebacabezon18 said:


> Hi man, realy apreciated your contributions realy works with my Naipix PTX NDI and OBS,  but only manage with the mouse,  when try add Gamepad ps2,ps3  your plugin not recognize the hardware. Let me now if get wrong some steps for configure.
> first install the 0.6 now reeplace the files with the version 0.8 but not have response from Gamepad. Whe enable GamePad  some reason see for just miliseconds one windows of OBS and dissapear but nothings happends. The control not aviable.



I think the "not finding the Gamepad" is a timing issue and a lot of people are having the same issue. I found a post where someone mentioned that it takes a few seconds after you initiate the QT Gamepad library before it returns a handle. His solution was to put the call in a loop. Maybe* glikely *can try this fix too?  Here is the discussion.


----------



## glikely (Oct 19, 2021)

wilderf353 said:


> I think the "not finding the Gamepad" is a timing issue and a lot of people are having the same issue. I found a post where someone mentioned that it takes a few seconds after you initiate the QT Gamepad library before it returns a handle. His solution was to put the call in a loop. Maybe* glikely *can try this fix too?  Here is the discussion.



I have tried that solution, but sadly could get it working reliably. This is a longstanding issue with Qt Windows support, particularly on later versions of Windows 10.

I've left gamepad support in the plug-in because it does work for some people, but really the gamepad support needs to be entirely rewritten to bypass the Qt gamepad library with something more reliable.


----------



## glikely (Oct 19, 2021)

I created a new test build with lots of new features, including:

VISCA over TCP (PTZOptics and other cameras)
white balance controls
Power control
Faster settings dialog
The start of an API for external plugins
Please test. It can be found here: https://github.com/glikely/obs-ptz/actions/runs/1360731273


----------



## GregPeatfield (Oct 19, 2021)

glikely said:


> I've just pushed out prototype code for VISCA-over-TCP support (PTZOptics, Jimcom, etc) into the `visca-tcp` topic branch. Can I get some help testing please? A windows build can be found on github: https://github.com/glikely/obs-ptz/actions/runs/1348631206
> 
> Let me know here if it works. If you run into problems create a github issues and attach the OBS log file so I can see the details.



Sorry, this evidently didn't post.  I am seeing small differences between the two on the initial page, not sure what causes that but the TCP port seems to work better as it now gets the response due that first query.


----------



## jaypa (Oct 20, 2021)

Hi, Newby here to OBS and PTZ controle. I have a IP camera which sometime use it for basic live streaming via OBS. I tried to use the Plugin with both IP address and rtsp stream. But nothing favoured me.  Just wanted to know whether I need to by more hardware in order to use this plugin to control the IP camera via OBS. My IP cam has a little information on the GUI about the PTZ control as seen on the attached screenshot. Thanks.


----------



## glikely (Oct 20, 2021)

jaypa said:


> Hi, Newby here to OBS and PTZ controle. I have a IP camera which sometime use it for basic live streaming via OBS. I tried to use the Plugin with both IP address and rtsp stream. But nothing favoured me.  Just wanted to know whether I need to by more hardware in order to use this plugin to control the IP camera via OBS. My IP cam has a little information on the GUI about the PTZ control as seen on the attached screenshot. Thanks.



Can you post a picture of the network settings page? The first page you shared shows settings for control over a serial cable instead of over the network.

To use serial control you will need a USB to UART converter.

What is the make and model of your camera? Do you have a link to the camera manual?


----------



## jaypa (Oct 21, 2021)

The attached are the network, ONVIF, P2P settings from the GUI of the camera.
The camera make is CamHi. I do not have any link for the manual and also couldnt find any ón online too.
The camera is connected by only via an ethernet cable to the router and no other connections.


----------



## glikely (Oct 21, 2021)

jrgrant said:


> Just gave this a whirl with an ancient Canon VC-C3 connected serially. Heard some whirs and clicks, but sadly nothing that could be called control. I have some developer docs available for this thing if you're interested in pursuing support for it.



Looks like the camera only supports the ONVIF protocol over the network. ONVIF has not yet been implemented in the plug-in.


----------



## glikely (Oct 22, 2021)

glikely updated PTZ Controls with a new update entry:

v0.9.0



> I've just tagged the v0.9.0 release. Thanks to everyone who has helped with testing and providing feedback for this release. Here is the list of new features:
> 
> - Pelco-D protocol
> - VISCA over TCP (Used by PTZ Optics, Jimcom, and others)
> ...



Read the rest of this update entry...


----------



## wilderf353 (Oct 22, 2021)

glikely said:


> glikely updated PTZ Controls with a new update entry:
> 
> v0.9.0
> 
> Read the rest of this update entry...


Nice!  I really like the new UI.  Thanks for doing all of this.


----------



## GregPeatfield (Oct 22, 2021)

jaypa said:


> The attached are the network, ONVIF, P2P settings from the GUI of the camera.
> The camera make is CamHi. I do not have any link for the manual and also couldnt find any ón online too.
> The camera is connected by only via an ethernet cable to the router and no other connections.


Hi Jaypa,

VISCA and Pelco protocols were developed for use with serial communications between devices.  This was the original way to control the PTZ mechanism within these types of cameras. Looking at your screenshots, I don't see a way to enable VISCA over IP for that camera so they might only support the newer ONVIF protocol since they don't support a serial interface.  You likely need something that support ONVIF to control that device.

I know we have requested the ONVIF feature to be added to this plugin, but Grant has stated he needs help as he doesn't have any ONVIF device to debug the addition so he has asked for community help. I don't know of another OBS PlugIn that supports ONVIF, but you might be able to use the Web Interface for your camera for now.

-Greg


----------



## GregPeatfield (Oct 22, 2021)

glikely said:


> glikely updated PTZ Controls with a new update entry:
> 
> v0.9.0
> 
> ...


Grant!

Great news with the addition of TCP/IP.

I have tested the Jimcom cameras and they have since been updated to support both UDP at port 52381 and TCP/IP port at 1259 depending upon the users needs.

Thanks again for the great plugin! I will queue up a video update for your plugin.

-Greg


----------



## glikely (Oct 22, 2021)

GregPeatfield said:


> Thanks again for the great plugin! I will queue up a video update for your plugin.



Thanks Greg. Let me know when it is done and I'll link to it from the main page


----------



## PetitJabanes (Oct 23, 2021)

This is so great! Love the plugin (♥_♥)
Let me just request the ability to move from one preset to another in a configurable amont of time, virtually turning any PTZ camera into a motion control rig (Ô_Ô)


----------



## glikely (Oct 23, 2021)

PetitJabanes said:


> This is so great! Love the plugin (♥_♥)
> Let me just request the ability to move from one preset to another in a configurable amont of time, virtually turning any PTZ camera into a motion control rig (Ô_Ô)


So that your request doesn't get forgotten, please file a feature request on GitHub:









						Issues · glikely/obs-ptz
					

OBS Pan Tilt Zoom camera control plugin. Contribute to glikely/obs-ptz development by creating an account on GitHub.




					github.com


----------



## glikely (Oct 25, 2021)

glikely updated PTZ Controls with a new update entry:

Face tracker plugin now supports PTZ Controls



> I want to take a moment to highlight @norihiro 's excellent Face Tracker plugin. He just released a new version with an experimental feature to link the Face Tracker with PTZ Controls. Go check it out!
> 
> 
> 
> ...



Read the rest of this update entry...


----------



## glikely (Oct 28, 2021)

glikely updated PTZ Controls with a new update entry:

v0.10.0-rc1



> I committed a fair number of improvements to the plugin over the last week and I think it is work another release. Some of the changes are risky and may break stuff, so I'm making this an -rc. Please test and let me know how it is working.
> 
> *New Features:*
> 
> ...



Read the rest of this update entry...


----------



## sotspodcast (Oct 29, 2021)

I recently bought a cheap USB based PTZ. Does this work with USB PTZ cams?


----------



## glikely (Oct 30, 2021)

sotspodcast said:


> I recently bought a cheap USB based PTZ. Does this work with USB PTZ cams?


No, support for USB PTZ cameras has not been added yet


----------



## glikely (Oct 30, 2021)

glikely updated PTZ Controls with a new update entry:

v0.10.0-rc2



> Changes over v0.10.0-rc1:
> 
> Fix problem with movement lock getting enabled when it shouldn't
> Add button to manually disable movement lock
> Change autoselect radio buttons to toolbar buttons that take up less space



Read the rest of this update entry...


----------



## glikely (Oct 30, 2021)

I've added a feature to block camera moves on the live scene when in studio mode. Here's a video of it in action:


----------



## glikely (Oct 31, 2021)

glikely updated PTZ Controls with a new update entry:

v0.10.0



> It took a few -rc releases to finally squash a bug on the live camera lock feature where sometimes a device moving from program to preview will still have its controls locked, and to sort out some UI issues, but it seems to be sorted now. So, v0.10.0 is out there with some helpful new features please go and test.
> 
> If you haven't already seen it, here is a short video showing of the live camera lock feature:
> 
> ...



Read the rest of this update entry...


----------



## sotspodcast (Nov 1, 2021)

glikely said:


> No, support for USB PTZ cameras has not been added yet



Actually I got it to work! Labeled my PTZ as COM3 via serial & boom! I figured it out.


----------



## glikely (Nov 1, 2021)

sotspodcast said:


> Actually I got it to work! Labeled my PTZ as COM3 via serial & boom! I figured it out.


Awesome! Glad it is working for you.


----------



## glikely (Nov 2, 2021)

glikely updated PTZ Controls with a new update entry:

PTZ-Controls Needs an Icon (Please Help!)



> I need some help with this project. The PTZ Controls plugin needs an icon, but my graphic design skills are laughable at best. Are there any artistically minded folks would would like to create an icon for the project? If so, let me know by commenting in the discussion thread here: https://obsproject.com/forum/threads/ptz-controls.143676/
> 
> To be used in the project I would need permission to use the icon either under the terms of the project license which is GPLv2, or under a...



Read the rest of this update entry...


----------



## jbcurler2010 (Nov 2, 2021)

glikely said:


> glikely updated PTZ Controls with a new update entry:
> 
> PTZ-Controls Needs an Icon (Please Help!)
> 
> ...


Took a few minutes to throw this together. Can do something more if you like. Tried to follow the OBS logo theme.


----------



## glikely (Nov 2, 2021)

jbcurler2010 said:


> Took a few minutes to throw this together. Can do something more if you like. Tried to follow the OBS logo theme.View attachment 76712


I like that. I was thinking in terms of a stylized PTZ style camera graphic, but that was feeling a little too concrete. The icon and arrows is better.

I think the lettering can be dropped. The logo will always be used on a page that also includes the project name, so having it in the logo is redundant and less 'iconic'.

How would it look if you used the OBS logo itself as the background instead of a gear?


----------



## toplachi (Nov 2, 2021)

Just trying something while I cannot get my sleep... anybody can modify this to improve the idea


----------



## glikely (Nov 3, 2021)

toplachi said:


> Just trying something while I cannot get my sleep... anybody can modify this to improve the idea


Awesome, thanks! Keep the ideas coming


----------



## 60HzRumble (Nov 3, 2021)

sotspodcast said:


> Actually I got it to work! Labeled my PTZ as COM3 via serial & boom! I figured it out.



I have a Fomako connected via USB which creates a COM port.  It works but wont persist if the PC goes to sleep.  I've found that if I switch to another COM port and back again it seems to wake up most of time.  I think the issue may be with OBS releasing the COM port on sleep and not being able to resume control of it on wake.  A reboot of the machine fixes it most, but not all, of the time.  I wonder if within the power settings there might be something to look at?


----------



## glikely (Nov 4, 2021)

glikely updated PTZ Controls with a new update entry:

New: MacOS support



> Hi everyone. I've just pushed out a minor release adding MacOS support! This is the first time I've released a MacOS build and there may be problems. Please test and let me know how it goes.
> 
> There are no other changes in this release, so if you are already using v0.10.0 you do not need to upgrade.



Read the rest of this update entry...


----------



## EB123 (Nov 6, 2021)

another idea for an icon..


----------



## jbcurler2010 (Nov 6, 2021)

glikely said:


> I like that. I was thinking in terms of a stylized PTZ style camera graphic, but that was feeling a little too concrete. The icon and arrows is better.
> 
> I think the lettering can be dropped. The logo will always be used on a page that also includes the project name, so having it in the logo is redundant and less 'iconic'.
> 
> How would it look if you used the OBS logo itself as the background instead of a gear?


I'll make a few changes and see if you like it.


----------



## jbcurler2010 (Nov 6, 2021)

jbcurler2010 said:


> I'll make a few changes and see if you like it.


----------



## EB123 (Nov 6, 2021)

is there any way of adding speed ramping to PTZ controls ? i find most PTZ cameras tend to look jerky when starting/stopping any movements.. it would be good if you could ramp speed up/down so the movement begins slow and then within a second or two it increases to the maximum.. this would help to use PTZ movement in the production a lot more.. rather than just a series of static shots...


----------



## glikely (Nov 6, 2021)

jbcurler2010 said:


> View attachment 76803


Thanks @jbcurler2010 , I've set this one as the icon


----------



## glikely (Nov 6, 2021)

EB123 said:


> is there any way of adding speed ramping to PTZ controls ? i find most PTZ cameras tend to look jerky when starting/stopping any movements.. it would be good if you could ramp speed up/down so the movement begins slow and then within a second or two it increases to the maximum.. this would help to use PTZ movement in the production a lot more.. rather than just a series of static shots...


It's something I've been thinking of. Can you file a issue on GitHub making this request please?


----------



## MMTech1 (Nov 7, 2021)

I have Panasonic AW-HE40HWP, PTZ the camera. Hooked up to OBS computer with HDMI and camera works fine, moves fine with included remote control. But I found this great resource on here, PTZ control by glikely. I can't seem to hook up to it, and get it to work, with this camera. I also have a less expensive PTZ name brand unknown. It works 5x better then the Panasonic and hooked up to the PTZ control easy, works great. I'm hoping someone can help me hook up the Panasonic, maybe step by step pdf. the pan says it is on 192.168.1.10 port 80? Yet the other one that works is on 10.0.0.47, yet they are both plugged into the same box. I Thank you for your help in advance.


----------



## EB123 (Nov 7, 2021)

glikely said:


> It's something I've been thinking of. Can you file a issue on GitHub making this request please?



yes just added


----------



## mab42 (Nov 8, 2021)

Great add-on, thanks for making it available!

Here is some feedback:
- the Shift-Click for slow movement seems to be broken, at least here it does not do anything at all. Ctrl-click seems to work.
- would be great to be able to select multiple cameras at once and issue the same command to all of them (e.g. zoom in/out, home, left/right...)

Thanks again!


----------



## glikely (Nov 8, 2021)

mab42 said:


> Great add-on, thanks for making it available!
> 
> Here is some feedback:
> - the Shift-Click for slow movement seems to be broken, at least here it does not do anything at all. Ctrl-click seems to work.
> ...


Good feedback, thanks! Can you please file each of these as issues on GitHub so I don't forget about them?








						Issues · glikely/obs-ptz
					

OBS Pan Tilt Zoom camera control plugin. Contribute to glikely/obs-ptz development by creating an account on GitHub.




					github.com


----------



## Lawrence_SoCal (Nov 8, 2021)

MMTech1 said:


> I have Panasonic AW-HE40HWP, PTZ the camera. Hooked up to OBS computer with HDMI and camera works fine, moves fine with included remote control. But I found this great resource on here, PTZ control by glikely. I can't seem to hook up to it, and get it to work, with this camera. I also have a less expensive PTZ name brand unknown. It works 5x better then the Panasonic and hooked up to the PTZ control easy, works great. I'm hoping someone can help me hook up the Panasonic, maybe step by step pdf. the pan says it is on 192.168.1.10 port 80? Yet the other one that works is on 10.0.0.47, yet they are both plugged into the same box. I Thank you for your help in advance.


Those network issues are unrelated to the plug-in, so I recommend taking any more conversation on this onto its own thread
Though most likely, you have mis-configured the Panasonic, hence your inability to control it over the network. You must fix that first


----------



## glikely (Nov 8, 2021)

MMTech1 said:


> I have Panasonic AW-HE40HWP, PTZ the camera. Hooked up to OBS computer with HDMI and camera works fine, moves fine with included remote control. But I found this great resource on here, PTZ control by glikely. I can't seem to hook up to it, and get it to work, with this camera. I also have a less expensive PTZ name brand unknown. It works 5x better then the Panasonic and hooked up to the PTZ control easy, works great. I'm hoping someone can help me hook up the Panasonic, maybe step by step pdf. the pan says it is on 192.168.1.10 port 80? Yet the other one that works is on 10.0.0.47, yet they are both plugged into the same box. I Thank you for your help in advance.


Sounds like your Panasonic camera's network configuration isn't correct. Check with your network admin on the correct IP settings you should use. If the other camera works with a 10.0.0.x address, then the Panasonic probably needs a similar address.


----------



## glikely (Nov 10, 2021)

glikely updated PTZ Controls with a new update entry:

v0.10.2



> v0.10.1 didn't work for MacOS. The serial port library wasn't able to find the Qt libraries on machines without the OBS development environment set up. I think I've got it sorted now. Please try this new release.
> 
> There was also a crash on exit bug that I've fixed.



Read the rest of this update entry...


----------



## glikely (Nov 19, 2021)

glikely updated PTZ Controls with a new update entry:

v0.10.4



> Minor fixes for compatibility with Face Tracker v0.4.2. There is no need to update unless you're using the Face Tracker plugin. Also, please remember that Face Tracker integration is experimental and you may encounter bugs or tracking problems. Always test before using for a live stream.



Read the rest of this update entry...


----------



## rTsComp (Nov 23, 2021)

Hello all,

I have a  SMTAV Ptz Camera controlled via USB. Is there a chance that future releases will support USB control?

Thank you.


----------



## glikely (Nov 24, 2021)

rTsComp said:


> Hello all,
> 
> I have a  SMTAV Ptz Camera controlled via USB. Is there a chance that future releases will support USB control?
> 
> Thank you.


USB camera control is something I want to add. I don't know when I will get to it though.


----------



## rTsComp (Nov 24, 2021)

glikely said:


> USB camera control is something I want to add. I don't know when I will get to it though.


If you need a tester, please let me know.


----------



## rTsComp (Nov 25, 2021)

glikely said:


> USB camera control is something I want to add. I don't know when I will get to it though.


Some Specs on the camera.

*Multiple Protocol Support*
Standard VISCA/Pelco-D/Pelco-P and UVC protocols Support.

Easily controlled by infrared remote controller, USB or serial port









						SMTAV 3x OpticalZoom,PTZ Camera, USB Outputs, Video Conference Camera.
					

SMTAV A3X6U is a new professional Full HD Broadcast and Conference PTZ Camera.It has 3X lossless optical zoom and 109 degree FOV with Sony's 1/3 inch high quality HD CMOS sensor.Supports USB to output 1080P clear image.Support UVC,VISCA/Pelco-D/Pelco-P protocols etc




					www.smtav.com
				




How the camera appears in the Device Manager.


----------



## Carlo ita (Nov 28, 2021)

HI, can you put onvif protocol in this fantastic system ?


----------



## glikely (Nov 29, 2021)

Carlo ita said:


> HI, can you put onvif protocol in this fantastic system ?


ONVIF support has been requested and can be tracked here: https://github.com/glikely/obs-ptz/issues/16


----------



## Jeramiah (Nov 30, 2021)

I have built a streaming system for a church which I tested at home using the same RS-232 and USB cables which have been subsequently been installed in the church. At home the PTZ control panel worked perfectly, in the church none of the functions operate. However, it is possible to control camera motions using the Camera Control functions within Video Capture Device/Properties/Configure Video/Properties. This problem is delaying the project and has become a major problem. Your assistance would be greatly appreciated. By the way. there is an attached streaming deck which I have not thought to test since being on site.


----------



## GregPeatfield (Nov 30, 2021)

Jeramiah said:


> I have built a streaming system for a church which I tested at home using the same RS-232 and USB cables which have been subsequently been installed in the church. At home the PTZ control panel worked perfectly, in the church none of the functions operate. However, it is possible to control camera motions using the Camera Control functions within Video Capture Device/Properties/Configure Video/Properties. This problem is delaying the project and has become a major problem. Your assistance would be greatly appreciated. By the way. there is an attached streaming deck which I have not thought to test since being on site.


Hi Jeramiah,

I am no expert on the RS-232 side, but a few things I would look at:
1) Is the PC different at the church? Could there be less power to drive the cables if they are long?
2) Are the cables shielded? If they are run next to noisy Power, Video, or LAN cables, could it be interference?

Just my immediate thoughts...


----------



## Jeramiah (Nov 30, 2021)

Thank you for your thoughts.
1) I tested the system at home with the same cables as used in the church. The PTZ Control panel worked perfectly. 
2)The control cable is the approriate shielded cable. By the way, there are two cameras in the system. 
I can control the camera via the OBS Camera Control functions so I'm fairly sure that it is not a contol cable problem. Is it possible to uninstall and reinstall the ptz plug-in? Could that help? I wonder, if the streaming deck has someting to do do with the problem, although, it worked well with PTZ Control panel at home.


----------



## steve500 (Nov 30, 2021)

Mac OS Monterey Apple Silicon

The effort of this plugin is amazing as we use NDI cameras throughout our setup. Issue is that I am having the hardest time docking the UI of this tool where I'd like it to go. I have a pretty tiny 8" low resolution touch screen that I have OBS on, when I squish OBS window down small enough to fit that lcd display, the UI of the PTZ controls plugin seems to break OBS interface. 

At times where I want to launch OBS without seeing the PTZ controls at all, when I disable it in the docks menu and relaunch OBS, the PTZ controls window appears separate of OBS floating without any window controls to resize or close it. The UI seems to get very confused.


----------



## Seppie (Dec 1, 2021)

First, thank you for this amazing OBS plugin. Absolutely love it!

Our setup:
OBS with OBS-PTZ plugin on Windows PC
USB to serial cable
Three Tenveo (super cheap) cameras connected via serial (VISCA)

Every time we open OBS, the VISCA number resets on the cameras so they are all set to 1. We then have to log into camera 2 & 3 to reset their VISCA numbers and thus regain control through the OBS-PTZ plugin

Mostly curious if there is a quick fix from the OBS-PTZ side? Maybe there's a reset command, power on, or something sent as a default upon opening OBS?  If not, we'll continue troubleshooting on our end. 

We have a physical joystick that controls all three cameras with settings being saved. We have also been successful with other software-based USB-to-serial camera controllers, but they were garbage compared to your plugin and thus we're attempting to get this working. :)


----------



## ygreq (Dec 10, 2021)

May I ask how you can use a gamepad? I see that you can select it in the PTZ Controls menu


----------



## Nafru (Dec 10, 2021)

Stoked at finding this OBS addon!
So close to what I need for a junk Genbolt PTZ to get set up (needs ONVIF).
What if anything can I contribute for making this happen?
I noticed in a old post that you required a camera. Is that still the case?

Thanks for getting this as far as you all have!


----------



## glikely (Dec 11, 2021)

Nafru said:


> Stoked at finding this OBS addon!
> So close to what I need for a junk Genbolt PTZ to get set up (needs ONVIF).
> What if anything can I contribute for making this happen?
> I noticed in a old post that you required a camera. Is that still the case?
> ...



Yes, that is still the case. Until I have hardware I won't be working on ONVIF. However, is be happy to merge support if someone else gets it done and submits it as a pull request on GitHub


----------



## Nafru (Dec 11, 2021)

glikely said:


> Yes, that is still the case. Until I have hardware I won't be working on ONVIF. However, is be happy to merge support if someone else gets it done and submits it as a pull request on GitHub


Is there a specific camera you want for testing?
If so, what is the cost of it where you are?
If not, can you find a camera that you can test it on and give a price on that?


----------



## Nafru (Dec 11, 2021)

Nafru said:


> Is there a specific camera you want for testing?
> If so, what is the cost of it where you are?
> If not, can you find a camera that you can test it on and give a price on that?


Or set up an Amazon wish list and give us access?


----------



## Nafru (Dec 11, 2021)

So this may be a stupid question, but isnt the ONVIF already on Github to drop in?





						python-onvif for client control of camera cloud
					

Reference resources: https://github.com/quatanium/python-onvif In the onvif test tool for Haikang camera This article introduces how to use onvif test tool to debug Haikang camera and how to configure it. This paper describes how to call the onvif protocol interface to control the cloud table...



					programmer.group


----------



## Nafru (Dec 14, 2021)

I wasnt trying to be a jerk with the question. 
There are at least 4 ONVIF open source pulls on Git Hub that I found in different flavours of code and camera tests. I am not sure what you need for implementation etc.
I am still down with helping in any way I can or sending a donation for making it happen.


----------



## TKaquatics (Dec 15, 2021)

I am interested in this ONVIF project as well. Although not much help on the coding end of things.


----------



## Rx7man (Dec 16, 2021)

glikely said:


> Awesome, thanks! Keep the ideas coming


One thing that bugs me about all the PTZ software is that  it moves very notchy because it's a button, if you could select between a "button" style motion interface and a virtual joystick you could change the rate/direction of movement by how far you drag it,perhaps a doubleclick on it to "home"
I still haven't figured out how to get it to work with my PTZ camera yet (Genbolt 203x ip cam).. I've tried pretty much every combination of device type and port... can you give me a tip based on my camera settings?

Here's a screenshot of any relevant settings










It has serial coms in the settings, but they're not physically exposed on the camera, so kinda pointless, but I thought I'd include it to be complete




i'm going to try and sniff my network packets while using PTZ on other software and see what that reveals


----------



## Nafru (Dec 16, 2021)

Rx7man said:


> One thing that bugs me about all the PTZ software is that  it moves very notchy because it's a button, if you could select between a "button" style motion interface and a virtual joystick you could change the rate/direction of movement by how far you drag it,perhaps a doubleclick on it to "home"
> I still haven't figured out how to get it to work with my PTZ camera yet (Genbolt 203x ip cam).. I've tried pretty much every combination of device type and port... can you give me a tip based on my camera settings?
> 
> Here's a screenshot of any relevant settings
> ...


The Genbolt is using RTSP and ONVIF for controls.

rtsp://IPaddress:554/11
ONVIF port: 8080
HTTP port: 80


----------



## SciTech (Dec 16, 2021)

Love the Docs for our church live stream.  I would like to suggest an enhancement.  It would be nice if you can tell which preset was selected.  We are using the ATEM mini and have a Powerpoint computer and then the PTZ camera.  When the PowerPoint is being displayed we will select one of the docs presets so the PTZ camera has moved and focused.  Then when we switch back to the PTZ camera you don't see the movement.  The problem is, sometimes we don't remember if we selected the preset.  Is there any way to make the preset change color or have a "pressed" appearance.?  Please pass this on to developers.


----------



## wilderf353 (Dec 16, 2021)

ygreq said:


> May I ask how you can use a gamepad? I see that you can select it in the PTZ Controls menu


To control the pan/tilt/zoom on a camera, instead of using the onscreen buttons.  For most of us, this doesn't work, because there are problems with the current 3rd party gamepad library used by PTZ Controls.


----------



## midnightblade31 (Dec 17, 2021)

Which gamepad brands and models can I use for ptz controls and how to set it up?


----------



## bradpeterson (Dec 27, 2021)

I'm having problems with the PTZ Actions.  It's working great on one OBS/computer, but doing weird things on a second OBS/computer. 

On one OBS it isn't triggering on a scene selection, but on another OBS PTZ Action trigger correctly. 

Yet when I configure the PTZ action and then click on "Test Action", it works for both OBS instances.

Any ideas?  It seems like it's a small bug or user error on my end?  For this second computer/OBS, the Test Action works, but a scene selection isn't triggering the PTZ Action.  Is there anything I can do to try and debug this myself (I'm a capable software developer)?


----------



## toplachi (Dec 28, 2021)

I have this little problem with the speed slider. If the speed slider is set to 15 and below, zooming in or out will no longer work and when I set the slider to 4 and below, pan and tilt will also stop working :-(


----------



## sgaechter (Dec 31, 2021)

The plugin is extremely useful and works adequately, but I can't get the Xbox Controller to work on windows. I also encountered, the configs (camera setting and presets) will not be saved when OBS be restarted.. is there someone else having the same issues?


----------



## wilderf353 (Dec 31, 2021)

For many of us on Windows, the gamepad controller doesn't work because there are problems with the current 3rd party gamepad library used by PTZ Controls.  It looks like on most computers, the 3rd party library is returning an invalid handle when initialized.  See this search from additional details.

The camera presets work fine with our 2 FoMaKo cameras. When you say "will not be saved in OBS", what do you mean?
1) Are the preset names in the PTZ Control window gone when you restart OBS?
or
2) The preset names are there, but they don't work anymore?



sgaechter said:


> The plugin is extremely useful and works adequately, but I can't get the Xbox Controller to work on windows. I also encountered, the configs (camera setting and presets) will not be saved when OBS be restarted.. is there someone else having the same issues?


----------



## bradpeterson (Jan 1, 2022)

toplachi said:


> I have this little problem with the speed slider. If the speed slider is set to 15 and below, zooming in or out will no longer work and when I set the slider to 4 and below, pan and tilt will also stop working :-(



I"m seeing similar behavior. It's like the speed of zooming in and out is very slow relative to the speed of panining left/rightup/down. 

So if you set a good speed for zooming, your pan speed is lightning fast.

If you set a good speed for panning, your zoom speed slow or nonexistant. 

I almost wonder if each time a zoom/pan button is pushed, a speed value could be sent prior. So if you click left, it can send a low speed int and then pan left. If you click zoom in, it can send a higher speed int and then zoom.


----------



## glikely (Jan 4, 2022)

Jeramiah said:


> Thank you for your thoughts.
> 1) I tested the system at home with the same cables as used in the church. The PTZ Control panel worked perfectly.
> 2)The control cable is the approriate shielded cable. By the way, there are two cameras in the system.
> I can control the camera via the OBS Camera Control functions so I'm fairly sure that it is not a contol cable problem. Is it possible to uninstall and reinstall the ptz plug-in? Could that help? I wonder, if the streaming deck has someting to do do with the problem, although, it worked well with PTZ Control panel at home.



Is there anything other apps on the church PC that is using the serial port? The UART cannot be shared between multiple applications at once. Please file an issue in github and attach a copy of your OBS log file.


----------



## glikely (Jan 4, 2022)

steve500 said:


> Mac OS Monterey Apple Silicon
> 
> The effort of this plugin is amazing as we use NDI cameras throughout our setup. Issue is that I am having the hardest time docking the UI of this tool where I'd like it to go. I have a pretty tiny 8" low resolution touch screen that I have OBS on, when I squish OBS window down small enough to fit that lcd display, the UI of the PTZ controls plugin seems to break OBS interface.
> 
> At times where I want to launch OBS without seeing the PTZ controls at all, when I disable it in the docks menu and relaunch OBS, the PTZ controls window appears separate of OBS floating without any window controls to resize or close it. The UI seems to get very confused.


This is something that needs to be reworked. Please file an issue in Github to track the problem and I'll see about getting a solution.


----------



## glikely (Jan 4, 2022)

Seppie said:


> First, thank you for this amazing OBS plugin. Absolutely love it!
> 
> Our setup:
> OBS with OBS-PTZ plugin on Windows PC
> ...


How do you have your cameras wired up? Daisy chain, or a serial bus? If they are wired in parallel then every time OBS-PTZ queries the bus to find out how many cameras there are the cameras will all get assigned address 1. The recommended wiring is to have the cameras daisy chained so that TX from the 1st camera goes to RX on the second and so on.

There isn't a quick fix on the OBS-PTZ side. I would need to rework the configuration back end to allow for parallel-wired cameras.

Please file an issue in GitHub and provided details about how your cameras are wired up to the serial port.


----------



## glikely (Jan 4, 2022)

Nafru said:


> I wasnt trying to be a jerk with the question.
> There are at least 4 ONVIF open source pulls on Git Hub that I found in different flavours of code and camera tests. I am not sure what you need for implementation etc.
> I am still down with helping in any way I can or sending a donation for making it happen.


It is a problem of time rather than funding. This is a personal time project for me and ONVIF isn't currently a priority because I'm not using any ONVIF cameras. I wouldn't even know which cameras would be interesting for getting started on ONVIF. If there are specific cameras that you are interested in then please add the details to the GitHub issue requesting ONVIF: https://github.com/glikely/obs-ptz/issues/16


----------



## glikely (Jan 4, 2022)

Rx7man said:


> One thing that bugs me about all the PTZ software is that  it moves very notchy because it's a button, if you could select between a "button" style motion interface and a virtual joystick you could change the rate/direction of movement by how far you drag it,perhaps a doubleclick on it to "home"
> I still haven't figured out how to get it to work with my PTZ camera yet (Genbolt 203x ip cam).. I've tried pretty much every combination of device type and port... can you give me a tip based on my camera settings?
> 
> Here's a screenshot of any relevant settings
> ...


Right, so this is an ONVIF camera which is not yet supported. There is a feature request for ONVIF, but it isn't very high on the priority list at the moment because I don't use any ONVIF hardware. https://github.com/glikely/obs-ptz/issues/16


----------



## glikely (Jan 4, 2022)

SciTech said:


> Love the Docs for our church live stream.  I would like to suggest an enhancement.  It would be nice if you can tell which preset was selected.  We are using the ATEM mini and have a Powerpoint computer and then the PTZ camera.  When the PowerPoint is being displayed we will select one of the docs presets so the PTZ camera has moved and focused.  Then when we switch back to the PTZ camera you don't see the movement.  The problem is, sometimes we don't remember if we selected the preset.  Is there any way to make the preset change color or have a "pressed" appearance.?  Please pass this on to developers.


Good idea. Can you post a feature request in github please? https://github.com/glikely/obs-ptz/issues


----------



## glikely (Jan 4, 2022)

midnightblade31 said:


> Which gamepad brands and models can I use for ptz controls and how to set it up?


Gamepad support is completely broken on Windows because Qt5Gamepad doesn't work with Windows 10. I will be disabling gamepad support on Windows for the next release.


----------



## glikely (Jan 4, 2022)

bradpeterson said:


> I"m seeing similar behavior. It's like the speed of zooming in and out is very slow relative to the speed of panining left/rightup/down.
> 
> So if you set a good speed for zooming, your pan speed is lightning fast.
> 
> ...


Thanks for the feedback. Please file a bug report on github so that it doesn't get forgotten: https://github.com/glikely/obs-ptz/issues

The handling of pan/tilt/zoom/focus speed is kind of hacked together at this point. I need to rewrite it to work consistently with different cameras.


----------



## glikely (Jan 4, 2022)

bradpeterson said:


> I"m seeing similar behavior. It's like the speed of zooming in and out is very slow relative to the speed of panining left/rightup/down.
> 
> So if you set a good speed for zooming, your pan speed is lightning fast.
> 
> ...


Thanks for the feedback. Please file a bug report on github so that it doesn't get forgotten: https://github.com/glikely/obs-ptz/issues

The handling of pan/tilt/zoom/focus speed is kind of hacked together at this point. I need to rewrite it to work consistently with different cameras.


----------



## glikely (Jan 4, 2022)

bradpeterson said:


> I almost wonder if each time a zoom/pan button is pushed, a speed value could be sent prior. So if you click left, it can send a low speed int and then pan left. If you click zoom in, it can send a higher speed int and then zoom.



Is your camera using VISCA or PELCO? In the VISCA protocol the speed is embedded in the command and should already be sent each time the button is pressed.


----------



## toplachi (Jan 13, 2022)

Just wondering if its possible to send preset commands which only control a certain axis.  One use case for this is if I have face tracking enabled which only controls the pan tilt automatically and then I have 2 presets for close up and wide shots that is relative to the current x,y coordinate


----------



## Emmandi (Jan 19, 2022)

PTZ Controller for DS-2DE5425IW-AE(S5) HIKVISION?
Currently using Pleco D via browser


----------



## Quez (Jan 22, 2022)

glikely said:


> glikely submitted a new resource:
> 
> PTZ Controls - Pan Tilt Zoom camera controls for OBS
> 
> ...


Hello. I am new to OBS and came across your PTZ resource while browsing the forum. I use OBS virtual camera to send out to Zoom  and have several USB cameras connected through a powered hub. that I switch between as needed during meetings.
I recently acquired a Tenveo conference camera that connects by USB and has a  i.r. remote control. the camera connects to OBS fine and can give me 1080p and 60fps. My problem with it is that I have to be in front of it for the remote control to work, which is difficult as I am positioned off to one side and can't see the i.r. receiver. I was wondering if your PTZ software would allow me to control this from OBS?
If so. how do I connect the camera? It has USB2 for video out and an RS232 socket and a small green connector with 2 connections labelled A & B. I don't know much about it  but if I can get the PT to work ( It's fixed focus there is no zoom to control) on OBS that would be great.
Alternatively do you know of any way I could use acomputer joystick to move the camera?

 Kind Regards
 Quez


----------



## Quez (Jan 23, 2022)

KPC41 said:


> Thanks for that.
> Looks OK now!!
> 
> FYI . The PTZ camera I am using is a Tenveo  HD conference Camera- this has  HDMI connection only, but with RS232 plug for connecting control signals to computer. (waiting for Cable - could be about 2 weeks).-With  cable, wiil  I have full functionally.
> Attachment shows details from manualView attachment 71908View attachment 71909


Hello, I too have a Tenvio conference cam Model  TEVO-VHD1080Pro. Mine has the RS232 socket for a round plug  and USB out for the video. Also my laptop that I want to use this on doesn't have any RS232 output just USB and my model of camera doesn't have the dip switches shown above. I would like to be able to use this software on my system butI don't know if it would just need a cable from USB to RS232 to work as I don't have the settings dip switches. I am totally new to all this and would be grateful for any advice/ help I can get
Quez


----------



## toplachi (Jan 24, 2022)

Quez said:


> Hello, I too have a Tenvio conference cam Model  TEVO-VHD1080Pro. Mine has the RS232 socket for a round plug  and USB out for the video. Also my laptop that I want to use this on doesn't have any RS232 output just USB and my model of camera doesn't have the dip switches shown above. I would like to be able to use this software on my system butI don't know if it would just need a cable from USB to RS232 to work as I don't have the settings dip switches. I am totally new to all this and would be grateful for any advice/ help I can get
> Quez


If you want to control it using your camera's "small green connector with 2 connections labelled A & B", you will be needing a USB to RS485 adapter... this is more practical option because you will only be needing a cable with 2 wires to connect your camera to the RS485 USB adapter.

If your Tenveo camera already came with RS232 cable with sufficient length, you can buy a USB to RS232 Adapter

There is also a possibility that you can also control (some of) your camera's functions through usb connection using PTZOptics app  Free Camera Control App Download for PC and Mac - PTZOptics


----------



## jbcurler2010 (Jan 26, 2022)

Would love to see Power Off/On or Power Cycle in PTZ Actions.


----------



## wilderf353 (Jan 27, 2022)

Quez said:


> Hello. I am new to OBS and came across your PTZ resource while browsing the forum. I use OBS virtual camera to send out to Zoom  and have several USB cameras connected through a powered hub. that I switch between as needed during meetings.
> I recently acquired a Tenveo conference camera that connects by USB and has a  i.r. remote control. the camera connects to OBS fine and can give me 1080p and 60fps. My problem with it is that I have to be in front of it for the remote control to work, which is difficult as I am positioned off to one side and can't see the i.r. receiver. I was wondering if your PTZ software would allow me to control this from OBS?
> If so. how do I connect the camera? It has USB2 for video out and an RS232 socket and a small green connector with 2 connections labelled A & B. I don't know much about it  but if I can get the PT to work ( It's fixed focus there is no zoom to control) on OBS that would be great.
> Alternatively do you know of any way I could use acomputer joystick to move the camera?
> ...


My church is using an RS-485 adapter plugged into our desktop's serial port to control our two Fomako cameras, but it might be easier for you to purchase a infrared remote repeatet/extender. 




l


----------



## qwedsazxc (Feb 2, 2022)

Hello
I am new to OBS and fortunately find your PTZ controls plugin while browsing all related websites.
To be honest, I don't know which one of  Visca or Pelco or etc is my camera using.
So I'm not sure how can I import the camera in the Plugin configuration section.
I'd be grateful if someone can help me about below questions:

What type is my camera ? [visca or etc]
How should I enter the IP ? [or should i use rtsp type of command in ip section of  plugin configuration]
What Port is my camera using? [what should i use in port section of  plugin configuration]
My camera is
brand: Uniview (UNV)
model: IPC6412LR-X5P 

P.S. I introduce my camera to OBS via Media Source likd this (rtsp://user:pass@192.168.-.-/media/video0)


----------



## johnkeats101 (Feb 2, 2022)

It would be nice if a "Window" menu on Mac showed all the available windows, including items that were minimized. This helps because I often have a very cluttered display with several apps windows. Selecting OBS doesn't always bring the window of interest to the foreground, so I often find myself minimizing other windows in my search. Furthermore, if I minimize the Windowed projector, it disappears from view and I have to recreate it. If I select to show all windows, it does not appear as available. The same applies to the main window, but worse. In order to redisplay, I have to restart OBS. This can happen during streaming :-(.

On Mac, minimizing means to hide the window, but it should be easy to maximize it again. Currently, minimizing (

Configuration: OBS 27.1.3 using MacOS 12.2 (Monterey) on MacBook Pro 16 (Apple Silicon).


----------



## GregPeatfield (Feb 2, 2022)

qwedsazxc said:


> Hello
> I am new to OBS and fortunately find your PTZ controls plugin while browsing all related websites.
> To be honest, I don't know which one of  Visca or Pelco or etc is my camera using.
> So I'm not sure how can I import the camera in the Plugin configuration section.
> ...


Hi Qwedsazxc;

A quick google on the specs of that camera shows:





						IPC6412LR-X5P—Zhejiang Uniview Technologies Co., Ltd.
					

IPC6412LR-X5P




					www.uniview.com
				





Compatible IntegrationONVIF(Profile S, Profile G), API

ONVIF is not yet supported with the PTZ Control. It has been requested, but Grant needs some help from the community to make that protocol happen. No timing is available that I know of on ONVIF implementation.


----------



## qwedsazxc (Feb 3, 2022)

GregPeatfield said:


> Hi Qwedsazxc;
> 
> A quick google on the specs of that camera shows:
> 
> ...


Hi again
Thank you *GregPeatfield* for helpful information.
I’m eagerly looking forward to the next updates (Specially ONVIF implementation)
Best regards


----------



## BCFischer (Feb 4, 2022)

Has anyone tried this plugin with one of the Canon PTZ cameras such as the CR-N300?

Brian


----------



## justsaytim (Feb 5, 2022)

Is there a way to make this work for a USB PTZ camera? I downloaded and installed but can't get any option to work with my USB connected camera.


----------



## joeblow (Feb 7, 2022)

I just registered to thank Grant for this Amazing plugin.


----------



## test156 (Feb 7, 2022)

Hey, is there a chance to have Pelco D over IP ? now is only Visca :) with option to put port number, thanks for answer


----------



## TerryP (Feb 9, 2022)

Many thanks for all your work on this plugin! It's exactly what I need to start my project.
A couple of items on my "wish list" (apologies if I've missed previous references/requests):

1) Incremental manual focus adjustment when the shift key is pressed, matching the really useful facility on pan and tilt

2) Ability to call up and control a camera's OSD menu (although I appreciate this could be redundant once direct control of settings is implemented).


----------



## fbuescher (Feb 11, 2022)

works like a charm with the RGBLink PTZ-WH (visca over TCP).

Would it be possible to remove some of the presets to save some space? my camera only supports preset 0-9. I'd like to remove the unused presets 11-16 ...

anyway, *very* genial tool.


----------



## Jobvini (Feb 12, 2022)

Is there any way to trigger the ptz presets by scripts?


----------



## peterthevicar (Feb 12, 2022)

Working beautifully with a "Tenveo Video Conference Camera 20X (TEVO-NV20U)" controlled by a no-name USB to RS485. All the defaults on camera and OBS work fine (VISCA). THANK YOU!

One issue I found with Pelco D on this camera. When you zoom either way, it doesn't stop zooming when you "release" the button in the dialog. You have to click on another control to stop the movement. Using a Honeywell UltraTouch works OK on the same camera so I guess they must send a "stop" code or something. Sadly the obvious workaround of using VISCA is ruled out because the Honeywell doesn't speak VISCA so we're stuck with Pelco D.

Feature request: could there be two checkboxes to reverse the sense of the left/right and up/down controls? The Tenveo camera inverts them when installed upside-down. You get used to it but...

Thanks again for a really helpful tool. Peter


----------



## peterthevicar (Feb 12, 2022)

Jobvini said:


> Is there any way to trigger the ptz presets by scripts?


Yes, you add a source to the scene in OBS and choose PTZ Action. Then choose the right camera and preset. You can decide whether to move the camera when you preview the scene or when you make it active.


----------



## sntlewis (Feb 24, 2022)

Can I add "other" PTZ Actions?  I would like to Zoom out then call the preset.  Sort of like stacking IP control strings.

Specifically something like http://my.camera.ip.address/cgi-bin/ptzctrl.cgi?ptzcmd&zoomto&7&0000

Presets do all PTZ functions together.  I want to set a "zoom only" present on a SMTAV camera.


----------



## p8n (Mar 4, 2022)

"can automatically change selected camera based on the currently active preview or program scene".

I can't see how to do this.


----------



## sotspodcast (Mar 4, 2022)

Anyone with ANY advice for using this plugin with a Logitech PTZ Pro 2? I don't knokw if it is a Visca, Pelco, or what? There is an image coming from it but I can't control it with this plugin..... yet. Any help is appreciated!!


----------



## Smithy (Mar 8, 2022)

Hi glickey.  Just want to provide some feedback on PTZ Controls v0.10.4 with my Vaddio RoboSHOT 12 HDBT and RoboSHOT 12 USB cameras.  With a single camera source in a scene, the controls work as expected under both “off” and “program” modes.  When multiple active VISCA camera sources are in a scene, any PTZ command given when the mode set to “program” crashes the camera’s PTZ controller and requires a camera reboot. How does your plugin direct the VISCA commands to the active camera in a scene when multiple active cameras are in a scene?  This could just be an issue with my cameras but I think it would be helpful to check for multiple active cameras and if it finds more than one in the scene then force the user to select the specific camera to steer much in the same way as the “off” mode works. Maybe just a state-based lockout of the “program” when multiple active PTZ sources are present to force “off” mode behavior. Does this makes sense?  And thank you for the effort on this project.  Very helpful!


----------



## toplachi (Mar 9, 2022)

p8n said:


> "can automatically change selected camera based on the currently active preview or program scene".
> 
> I can't see how to do this.


PTZ Control can automatically select the active camera to control based on which scene is active in OBS' program or preview mode, your scene must have the same name with the camera in the ptz control


----------



## wilderf353 (Mar 9, 2022)

p8n said:


> "can automatically change selected camera based on the currently active preview or program scene".
> 
> I can't see how to do this.




1) In the _Scenes _window, click on the scene where you want to have PTZ preset automatically activated. I am pretty sure that the scene must include a PTZ camera source that is a listed in the in the_ PTZ Devices _frame of the _PTZ Controls_ window.
2) Click on the "+" sign at the bottom of the _Sources _window to add a new source. A dropdown will open, select the _PTZ Action_ option
3) A dialog window will open. In the _Create New _text control field, type in a unique name, then hit the OK button
4) A new _Properties for ... _dialog window will open. Select the options you want from all of the dropdown fields. You can hit the _Test Action_ button to make sure it works, then hit the OK button.


----------



## FPC AV (Mar 11, 2022)

Don't know if this will end up in the right spot, but my question is I plan on using two ptz cameras and can I position one camera while the feed from the second camera is active?  For example, the camera on the choir is performing and being streamed and the second camera needs to move to the pulpit from a different location. This second camera move needs to be done while the choir is performing so I can then cut to the pulpit. Thanks for your help!


----------



## Smithy (Mar 12, 2022)

FPC AV said:


> Don't know if this will end up in the right spot, but my question is I plan on using two ptz cameras and can I position one camera while the feed from the second camera is active?  For example, the camera on the choir is performing and being streamed and the second camera needs to move to the pulpit from a different location. This second camera move needs to be done while the choir is performing so I can then cut to the pulpit. Thanks for your help!



this is essentially what I’m trying to do with a multi-camera setup but you may have some of the same issues as me if you’re not careful (see my post above). 
You need one OBS scene for each camera source (a single source scene) plus an additional OBS scene containing the feeds from all cameras (a multi-source scene).  Use OBS ”studio mode” with the multi-source scene in the “Edit View” to steer the inactive camera to the next target while the active camera streams to the “Live View”. Once you’re ready to switch to the next camera, you simply need to cut to the scene with the waiting camera.  The more I think about it, the multi-view scene doesn’t add much capability to what you’re doing unless you needed to pick out the best camera for a given shot.  Having all the streams in a mosaic is handy for quick comparisons.  For you, the studio mode is probably all you needs.  Keep one camera on the choir and use the “Edit Mode” to steer the second camera to the pulpit them cut the scene when it’s time


----------



## p8n (Mar 13, 2022)

The plugin is working well to control the cameras and the presets.
HOWEVER, each time OBS closes and then re-opens, the PTZ controls is not docked and have to redo the View->Docks->PTZ controls.
When it does then dock, all the renames of the presets has been lost.


----------



## GregPeatfield (Mar 13, 2022)

p8n said:


> The plugin is working well to control the cameras and the presets.
> HOWEVER, each time OBS closes and then re-opens, the PTZ controls is not docked and have to redo the View->Docks->PTZ controls.
> When it does then dock, all the renames of the presets has been lost.


Ouch, this doesn't happen to me, but sounds like the configuration isn't getting saved. Could this be you need to run as Administrator to make sure OBS has write access to the file (it may have originally been installed as ADMIN and USER might not be able to update the file properly).


----------



## wilderf353 (Mar 13, 2022)

FPC AV said:


> Don't know if this will end up in the right spot, but my question is I plan on using two ptz cameras and can I position one camera while the feed from the second camera is active?  For example, the camera on the choir is performing and being streamed and the second camera needs to move to the pulpit from a different location. This second camera move needs to be done while the choir is performing so I can then cut to the pulpit. Thanks for your help!



If I understand your question, we do this all the time.  We keep OBS in studio mode ( 'preview' on the left and 'program' (live) on the right).  While streaming PTZ camera #1 in the 'program' window, you can choose different scenes in the 'preview' window. If one of those scenes has PTZ camera #2 in it, you can change the pan/tilt/zoom settings and see the affects in real time in the 'preview' window.  When the PTZ settings are where you want them to be, hit the transition button to swap 'program' & 'preview'.


----------



## wilderf353 (Mar 13, 2022)

p8n said:


> The plugin is working well to control the cameras and the presets.
> HOWEVER, each time OBS closes and then re-opens, the PTZ controls is not docked and have to redo the View->Docks->PTZ controls.
> When it does then dock, all the renames of the presets has been lost.



On Windows, I think the settings for PTZ Controls are maintained in a configuration file called 'config.json'.  To find it:

In OBS, in the menu bar at the top,  click on _Help_->_log files -> show log files_.
_Windows Explorer_ should open. If you navigate up 1 level, and then select the _plugin_config _folder, then the _ptz-controls_ folder, you should see the _config.json _file. 
A ) What is the date of the file ... is it close to current date/time?
B ) Is there a backup file? Does it have a near current date/time?
C ) It is a text based file, so you can open it and view it ... just don't make any changes unless you know what you are doing?

Something else...have you checked a current OBS log file? Are there any error messages in it created by PTZ Controls?


----------



## sotspodcast (Mar 13, 2022)

Still hoping for any advice on getting a Logitech PTZ Pro 2 to work on this. OBS sees the camera as Logitech Group cam, has image coming from it but no way to control the PTZ


----------



## ghostman90215 (Mar 13, 2022)

Been using this plug-in for a while with PTZ Presets. I still can't figure out how to trigger a preset for each scene. Behavior I'm trying to do: 
1. when I Transition a Scene from Preview to Progam, I want to trigger an associated Cameras and Preset. How do I to that?


----------



## EstebanTroncoso (Mar 22, 2022)

First of all, thank you very much for this effort making our lives a lot easier!

I recently bought a cheap chinese poor quality PTZ cam that comes with no documentation at all, it does not have a web page, nothing. I can find nothing related to it.

So my question was: is there a way to find out what's whether UDP/TCP port to connect OBS Studio plugin to? I've tried the most common port numbers and I'm not managing to control it.

Any help will be really appreciated.

Thank you very much!

P.D.: I've attached a few pictures I've taken to the camera box so you can have an idea what camera is the one I have, and the ports that can be managed from the web interface of it.


----------



## GregPeatfield (Mar 23, 2022)

EstebanTroncoso said:


> First of all, thank you very much for this effort making our lives a lot easier!
> 
> I recently bought a cheap chinese poor quality PTZ cam that comes with no documentation at all, it does not have a web page, nothing. I can find nothing related to it.
> 
> ...


Hi,

It looks like this camera only support ONVIF protocol. I don't see reference to VISCA or VISCA over IP. This plugin does not yet support ONVIF so I don't think it is going to work for you right now.


----------



## ghostman90215 (Mar 27, 2022)

ghostman90215 said:


> Been using this plug-in for a while with PTZ Presets. I still can't figure out how to trigger a preset for each scene. Behavior I'm trying to do:
> 
> -- When I Transition a Scene from Preview to Program, I want to trigger an associated Cameras and Preset. How do I do that?



Not to be annoying, but I still haven't seen a decent answer for this one. I'm happy to write it up if someone can mentor me.


----------



## toplachi (Mar 28, 2022)

ghostman90215 said:


> Not to be annoying, but I still haven't seen a decent answer for this one. I'm happy to write it up if someone can mentor me.


I just quoted previous answers from the thread



wilderf353 said:


> 1) In the _Scenes _window, click on the scene where you want to have PTZ preset automatically activated. I am pretty sure that the scene must include a PTZ camera source that is a listed in the in the_ PTZ Devices _frame of the _PTZ Controls_ window.
> 2) Click on the "+" sign at the bottom of the _Sources _window to add a new source. A dropdown will open, select the _PTZ Action_ option
> 3) A dialog window will open. In the _Create New _text control field, type in a unique name, then hit the OK button
> 4) A new _Properties for ... _dialog window will open. Select the options you want from all of the dropdown fields. You can hit the _Test Action_ button to make sure it works, then hit the OK button.
> ...





peterthevicar said:


> Yes, you add a source to the scene in OBS and choose PTZ Action. Then choose the right camera and preset. You can decide whether to move the camera when you preview the scene or when you make it active.


----------



## prosys (Mar 30, 2022)

I'm trying to get PTZ controls working with a Birddog PF120 camera which supports VISCA over IP - UDP. I can't get the camera to respond to the PTZ zoom or Preset controls (the camera doesn't have pan and tilt). I believe I have the IP and port settings correct. Attached is the OBS log file which shows the ptz exchanges with the camera. I note that there appears to be a number of timeouts occurring. The entries in the log from 19:45:54 on are a couple of zoom commands followed by selecting Preset 4 and Preset 7. Can you tell me if these are valid VISCA exchanges and if the responses from the camera give any indication of a problem? Thanks for your help.


----------



## gravleycj (Apr 6, 2022)

New to this plugin.  We have Marshall 630NDI and the controls work great, VISCA over IP, UDP Port 52381.  Presets, controls, everything has wonderful response.  My issue is that when I go into the device settings, all the controls are grayed out.  I can't alter exposure compensation, brightness, etc.  Everything is gray and unresponsive.  Could this be related to camera login credentials?

Thank you


----------



## wilderf353 (Apr 8, 2022)

gravleycj said:


> New to this plugin.  We have Marshall 630NDI and the controls work great, VISCA over IP, UDP Port 52381.  Presets, controls, everything has wonderful response.  My issue is that when I go into the device settings, all the controls are grayed out.  I can't alter exposure compensation, brightness, etc.  Everything is gray and unresponsive.  Could this be related to camera login credentials?
> 
> Thank you


I wonder if these apps will let you modify the settings?

-> Camooz : https://obsproject.com/forum/resources/camooz-save-restore-camera-settings.1271/updates

-> Camprops:  https://roland-weigelt.de/camprops/

-> ffmpeg:
- - - Get a list of devices​ffmpeg -list_devices true -f dshow -i dummy​- - - Show windows dialog for device​ffmpeg -f dshow -show_video_device_dialog true -i video="HP Truevision HD"​


----------



## Paul2020 (Apr 10, 2022)

I’m trying to connect up a Hikvision RTSP camera but cannot connect to the controller. Which option and settings do I need?


----------



## gravleycj (Apr 10, 2022)

wilderf353 said:


> I wonder if these apps will let you modify the settings?
> 
> -> Camooz : https://obsproject.com/forum/resources/camooz-save-restore-camera-settings.1271/updates
> 
> ...


Thanks, I can alter the camera settings with their web page interface via IP.  It's just that these controls are in such a handy location it would be very nice to make adjustments on the fly, most especially exposure compensation.  Our Church has terrible lighting and the Sun doesn't help as it move across our front windows.


----------



## joeblow (Apr 17, 2022)

I've been using this plugin since the very beginning and the PTZ is working great.
But I cannot figure out, or if it's possible, to make adjustments  (i.e. Pan Tilt Zoom) to the "preview" camera regardless of which camera that may be, so as not to accidently be adjusting the live "program" Camera.
In other words that the pan tilt zoom is confined only to the camera that is in the "preview" window and not the "program" window so as to avoid making mistakes


----------



## toplachi (Apr 17, 2022)

joeblow said:


> I've been using this plugin since the very beginning and the PTZ is working great.
> But I cannot figure out, or if it's possible, to make adjustments  (i.e. Pan Tilt Zoom) to the "preview" camera regardless of which camera that may be, so as not to accidently be adjusting the live "program" Camera.
> In other words that the pan tilt zoom is confined only to the camera that is in the "preview" window and not the "program" window so as to avoid making mistakes


Have you tried enabling the _Lockout live PTZ moves in studio mode option inside the PTZ device settings?_


----------



## joeblow (Apr 18, 2022)

Great, Thanks toplachi, that solved the problem.


----------



## wrf_pastor (Apr 22, 2022)

I've got this plugin working on a test machine and am looking forward to using it live, once I can figure out how to inject the binary into a snap-maintained install of OBS (anyone with experience hacking snap, please respond!!)

But this post is really a feature request: would it be possible to increase the number of presets above 16? We use PTZOptics cameras that allow 255, and while we don't need THAT many, one of our cams currently has 20+.


----------



## toplachi (Apr 22, 2022)

Hmmm... If I am going to need more presets than its current capabilities, probably my workaround would be adding a copy of my current ptz device, (using the same address but with new set of presets).


----------



## wrf_pastor (Apr 22, 2022)

toplachi said:


> Hmmm... If I am going to need more presets than its current capabilities, probably my workaround would be adding a copy of my current ptz device, (using the same address but with new set of presets).


Hmmm indeed... will give this a try, thanks!


----------



## wilderf353 (Apr 26, 2022)

We have been using PTZ Controls since last summer. On Sunday we had some problems with PTZ Controls: All the presets for a camera would turn light grey (they seemed to be disabled) and then a few minutes later, they would work again.

I tried :
 - restarting OBS multiple times
 - restarting  the computer.
 - reinstalling PTZ Controls.
 - unplugging the external power to the PTZ camera, counting to 10, then plugging them back in.

After trying on or more of the above a few times,  everything would be working fine, then a minute later the presets would be disabled, so I would try something else.  In the end I had to start our church service and just use the remote control.  But during the service, it seemed if I waited for a few minutes, they would be working again for a short while then go grey again.

This enable/disable loop affected both USB cameras. Otherwise, they seemed to be working fine: I could select a scene with the camera and see the live video feed, and use the RF remote control that came with the camera to select a preset.

At one point I tried adding a new camera with the same settings as one of the disabled cameras. It worked for a while, then it would go grey too.

Question: I think this may be either a camera hardware issue, a Windows driver issue or an OBS issue. Looking through the PTZ Controls source code, it looks like the _presetListView _frame is only enabled for a specific camera when the camera is in an active scene. It has nothing to do with communication to the camera over VISCA.  Can anyone confirm this?  The next time I go into our church, I am going to unplug our serial->RS 232 adapter and see if I can duplicate the problem.  FYI: I checked to forums and found a few post about cameras randomly deactivating, maybe this is happing to us too?

(I did a quick look at the log files on Sunday, but nothing jumped out at me. I am going by either tonight or tomorrow night to look at the OBS logs again.)


----------



## toplachi (Apr 27, 2022)

wilderf353 said:


> We have been using PTZ Controls since last summer. On Sunday we had some problems with PTZ Controls: All the presets for a camera would turn light grey (they seemed to be disabled) and then a few minutes later, they would work again.
> 
> I tried :
> - restarting OBS multiple times
> ...



There might be a possibility that your controls are disabled because of the "lock" feature, can you check if its enable on your PTZ control settings?


----------



## Tab12590 (May 2, 2022)

Hello, Looking for some help, if anyone has an idea.  

I am trying to hook up an ip ptz camera.  i can see the video feed, but the ptz will not control.  (PTZ control works fine in the web browser)
my media source input is (See video)





my ptz setting are





I have tried to change the Bind to IP



I have also deleted all the setting and re downloaded the file(all files are in the 64 folder). 

here are the setting of the web gui


----------



## wrf_pastor (May 3, 2022)

Tab12590 said:


> Hello, Looking for some help, if anyone has an idea.
> 
> I am trying to hook up an ip ptz camera.  i can see the video feed, but the ptz will not control.  (PTZ control works fine in the web browser)
> my media source input is (See video)
> ...



Looks like you are using a PTZOptics camera, which we also are. I've gotten PTZ Controls to work with a PT20X-SDI Gen2 model, but yours is probably a different model. Regardless, I /think/ the issue is that you have an RTSP URL in the "IP host" field in the PTZ Controls settings dialog. IIRC, all you want there is the IP address of the camera, i.e., 192.168.1.88. Note that the port number at the end of the URL you are using, 554, is instead specified in the "TCP port" field.

Unfortunately I'm not sitting at a machine where I can verify these settings, so if those changes don't work, I /think/ PTZ Controls allows you to use VISCA over UDP instead. If your camera model supports UDP, the port number is probably  going to be 1259, unless you've changed it in the camera's web interface.

HTH.


----------



## Paul74 (May 5, 2022)

p8n said:


> The plugin is working well to control the cameras and the presets.
> HOWEVER, each time OBS closes and then re-opens, the PTZ controls is not docked and have to redo the View->Docks->PTZ controls.
> When it does then dock, all the renames of the presets has been lost.


I had the same experience on PTZ not showing up. I found out that if PTZ is floating it doesn't remain on next obs start, but if you dock it first and the restart obs, it does remain there.


----------



## Doug-in-MN (May 7, 2022)

The feature of auto selecting the  PTZ Device when using transition stopped work for one on my PTZO camera's. It worked for a while but my fast finger changes probably interrupted a change, so how do I get it to work again?  Or how to reload PTZ Controls v0.10.4 into my PC?


----------



## johnkeats101 (May 14, 2022)

One issue I found with Pelco D on this camera. When you zoom either way, it doesn't stop zooming when you "release" the button in the dialog. You have to click on another control to stop the movement. Using a Honeywell UltraTouch works OK on the same camera so I guess they must send a "stop" code or something. Sadly the obvious workaround of using VISCA is ruled out because the Honeywell doesn't speak VISCA so we're stuck with Pelco D.


----------



## Security_Live (May 14, 2022)

padrereal2002 said:


> I recently bought a PTZ - usb - webcam (OBSBOT Tiny Camera).... in OBS, in the properties, I can change all the PTZ settings... do you think your plugin will work to control the PTZ of this webcam ??
> I'm a rookie here... in which folder do I have to copy the plugin files or folder for it to show up in OBS ??
> Thanks for your help!


I wrote a program to control the OBSBOT Tiny PTZ using DirectShow IAMCameraControl, there are undocumented properties that allow for fast PTZ of OBSBot cameras. The github is here: https://github.com/johnebgood/the-one-camera-controller


----------



## Paul74 (May 18, 2022)

Is there a way to save the speed slider position? On next OBS restart it resets to the center default state. Thanks.


----------



## evergailing (May 20, 2022)

Security_Live said:


> I wrote a program to control the OBSBOT Tiny PTZ using DirectShow IAMCameraControl, there are undocumented properties that allow for fast PTZ of OBSBot cameras. The github is here: https://github.com/johnebgood/the-one-camera-controller


May I ask how to use your program?


----------



## evergailing (May 21, 2022)

Lawrence_SoCal said:


> There are a number of NDI PTZ cameras on Amazon at the moment about 1/2 price and appear to be PTZOptics knock-offs. Whether those items are 'legal' or not, I'm not sure. Certainly appears unethical copying ... but maybe not. However, the primary one I looked at has a gmail support address. These are fly-by-night operations, with (very) poor English translations, and bugs, and not certainty of getting future firmware updates (ex updated NDI versions).... so, as much as I'm sorely tempted for a 2nd NDI PTZ at our non-profit, I'm not sure 1/2 now represents good value.... As for finding used, last year this time there were wait times for the cameras. So, I wouldn't expect much savings on used (but I haven't researched that deeply). Then again, a serial PTZ might well be available for lower price, but then you have to consider the overall price (as you then will need  both the serial cable, as well power, and SDI, HDMI, or ?? cabling, and a capture card, etc... why we went NDI).
> If buying used, my approach would be to buy form a Tier 1 vendor, where you can get support (and possibly repairs) if need be
> If the streaming PC and a single camera are close to each other and no plan to expend to multi-camera, I'd be inclined to a USB PTZ camera for simplicity


Can you give some examples on Tier 1 vendor?


----------



## Lawrence_SoCal (May 22, 2022)

evergailing said:


> Can you give some examples on Tier 1 vendor?


This really isn't the thread for that. so I'll respond directly


----------



## Bart at work (May 25, 2022)

Hi! I'm using this plugin on a Macbook Pro M1 Max, macOS 12.3.1, OBS 27.2.4. Plugin works perfectly fine with the Canon CR-N300 camera's. Great work!
One question though. In the screenshots here and on Github I see an "Enable Gamepad" feature on the Device Settings page. However in my case, I don't see that tickbox. Is that unavailable on Mac? Would be so great to have gamepad control! I've tried a Logitech F310 via USB and a Playstation 4 controller via Bluetooth. Both are recognized by my Mac, but the "Enable Gamepad" tickbox never shows in the plugin. Let me know if I'm doing something wrong.


----------



## evergailing (May 26, 2022)

Security_Live said:


> I wrote a program to control the OBSBOT Tiny PTZ using DirectShow IAMCameraControl, there are undocumented properties that allow for fast PTZ of OBSBot cameras. The github is here: https://github.com/johnebgood/the-one-camera-controller


Managed to use your program. It works well expect for the up and down buttons. Where can we find the undocumented properties?


----------



## TheGreatPond (May 26, 2022)

Smithy said:


> Hi glickey.  Just want to provide some feedback on PTZ Controls v0.10.4 with my Vaddio RoboSHOT 12 HDBT and RoboSHOT 12 USB cameras.  With a single camera source in a scene, the controls work as expected under both “off” and “program” modes.  When multiple active VISCA camera sources are in a scene, any PTZ command given when the mode set to “program” crashes the camera’s PTZ controller and requires a camera reboot. How does your plugin direct the VISCA commands to the active camera in a scene when multiple active cameras are in a scene?  This could just be an issue with my cameras but I think it would be helpful to check for multiple active cameras and if it finds more than one in the scene then force the user to select the specific camera to steer much in the same way as the “off” mode works. Maybe just a state-based lockout of the “program” when multiple active PTZ sources are present to force “off” mode behavior. Does this makes sense?  And thank you for the effort on this project.  Very helpful!


Hey Smithy, did you have to do anything out of the ordinary to get your roboshot cams to work? I've been fighting this for the past couple of days but can't find if it might be that I'm on the wrong port or maybe attempting the wrong type of connection. I would appreciate any help you could give, or mybe even a screenshot of what your config window looks like for a roboshot cam. Thanks!


----------



## Smithy (May 28, 2022)

TheGreatPond said:


> Hey Smithy, did you have to do anything out of the ordinary to get your roboshot cams to work? I've been fighting this for the past couple of days but can't find if it might be that I'm on the wrong port or maybe attempting the wrong type of connection. I would appreciate any help you could give, or mybe even a screenshot of what your config window looks like for a roboshot cam. Thanks!


----------



## Smithy (May 29, 2022)

Configuration is the basic default for the UDP option.  UDP port is the default:  52381


----------



## TheGreatPond (May 31, 2022)

TheGreatPond said:


> Hey Smithy, did you have to do anything out of the ordinary to get your roboshot cams to work? I've been fighting this for the past couple of days but can't find if it might be that I'm on the wrong port or maybe attempting the wrong type of connection. I would appreciate any help you could give, or mybe even a screenshot of what your config window looks like for a roboshot cam. Thanks!


Was just a firmware update that was needed, turns out I was running 3.3.0 and the feature wasn't supported until 3.4.0, Thanks for the great plug in.


----------



## TheGreatPond (May 31, 2022)

Before I start let me say that I'm really looking forward to using this once I get a few kinks out!

The problem I'm having is that now that I've gotten my cameras configured and they are able to be controlled through the plugin, the controls seem to be very inconsistent on whether my camera will accept them. While holding the button within the plugin my camera will start to move, then stop a short  undetermined distance later (also presets are only called halfway sometimes and never reach the final destination) and sometimes it will go a couple minutes simply refusing to listen to instructions that it previously had.

Is this an experience that any others are having or is it likely a problem with Vaddio's VISCA over IP still being in beta?


----------



## TheGreatPond (May 31, 2022)

TheGreatPond said:


> Before I start let me say that I'm really looking forward to using this once I get a few kinks out!
> 
> The problem I'm having is that now that I've gotten my cameras configured and they are able to be controlled through the plugin, the controls seem to be very inconsistent on whether my camera will accept them. While holding the button within the plugin my camera will start to move, then stop a short  undetermined distance later (also presets are only called halfway sometimes and never reach the final destination) and sometimes it will go a couple minutes simply refusing to listen to instructions that it previously had.
> 
> Is this an experience that any others are having or is it likely a problem with Vaddio's VISCA over IP still being in beta?


This just in I believe it is a vaddio issue, trying to use even the built in controller through a webpage is unreliable at best.  We'll see what can be done


----------



## Tab12590 (Jun 3, 2022)

wrf_pastor said:


> Looks like you are using a PTZOptics camera, which we also are. I've gotten PTZ Controls to work with a PT20X-SDI Gen2 model, but yours is probably a different model. Regardless, I /think/ the issue is that you have an RTSP URL in the "IP host" field in the PTZ Controls settings dialog. IIRC, all you want there is the IP address of the camera, i.e., 192.168.1.88. Note that the port number at the end of the URL you are using, 554, is instead specified in the "TCP port" field.
> 
> Unfortunately I'm not sitting at a machine where I can verify these settings, so if those changes don't work, I /think/ PTZ Controls allows you to use VISCA over UDP instead. If your camera model supports UDP, the port number is probably  going to be 1259, unless you've changed it in the camera's web interface.
> 
> HTH.


First off thank you very much for taking the time to help trouble shoot.  

So i found time to play with this again, sorry for the delay.   So i have tried only using the ip ONLY f for the ptz control but no luck,  if i use ip only for the media source the video does not work, only RTSP works.

i also tried to match all the port id's but no luck either. if i found a port in the web setting i tried it in obs.








this is not a braded as a ptz camer but i beliave i bought from there vendor.  the model i have is AT-200TW


----------



## Tab12590 (Jun 4, 2022)

Tab12590 said:


> First off thank you very much for taking the time to help trouble shoot.
> 
> So i found time to play with this again, sorry for the delay.   So i have tried only using the ip ONLY f for the ptz control but no luck,  if i use ip only for the media source the video does not work, only RTSP works.
> 
> ...


  FYI my camera is ONVIF that is why i use RTSP. NOT sure if that has anything to do with this.


----------



## Tab12590 (Jun 4, 2022)

Tab12590 said:


> FYI my camera is ONVIF that is why i use RTSP. NOT sure if that has anything to do with this.


ok so looking over glikely Jan 4 post, ONVIF is not supported.


----------



## Tab12590 (Jun 4, 2022)

Tab12590 said:


> First off thank you very much for taking the time to help trouble shoot.
> 
> So i found time to play with this again, sorry for the delay.   So i have tried only using the ip ONLY f for the ptz control but no luck,  if i use ip only for the media source the video does not work, only RTSP works.
> 
> ...


ok so looking over glikely Jan 4 post, ONVIF is not supported.   thanks for all your help


----------



## iambobthefish (Jun 6, 2022)

This is a great plug-in.
I've found though that when I restart the laptop we're using that the preset names all default back to the default numbering, as opposed to what I've customised them as. The actual positions for the presets are retained, just the names are lost. Interestingly on a second laptop (both running Windows 10) the names are all retained no matter how often I restart etc.
We're only using OBS at the moment for PTZ control, so I'm not very familiar with the rest of the software. Is there something I'm missing to ensure we keep the preset names?


----------



## TonyKSussex (Jun 6, 2022)

We are trying to set up a streaming facility in our fairly large church. The PTZ plugin is working fine with our Tongveo HD conference camera and we have found that we can control it using only the camera's USB port through OBS. Unfortunately the camera is some distance from a suitable control location, so we are using our wi-fi system and a second laptop to control the camera. It would be much simpler if we could, without using a second computer, extend the camera's USB connection wirelessly over the wi-fi system. Is there any device/dongle for doing this? Presumably we would need IP addresses.


----------



## Paul74 (Jun 7, 2022)

iambobthefish said:


> This is a great plug-in.
> I've found though that when I restart the laptop we're using that the preset names all default back to the default numbering, as opposed to what I've customised them as. The actual positions for the presets are retained, just the names are lost. Interestingly on a second laptop (both running Windows 10) the names are all retained no matter how often I restart etc.
> We're only using OBS at the moment for PTZ control, so I'm not very familiar with the rest of the software. Is there something I'm missing to ensure we keep the preset names?


Most probably on that pc you have some issues on writing the config.json file that is where the plug-in stores it's parameters and also the preset names. So from obs go in help menu-log files-show log files. It will open a folder, go one level up and the into plugin_config and then ptz-controls. You will find the config.json file. See in the properties if the user of the pc can write on it, if not, give the permissions. If you open the file with a normal notepad or text editor, you should see the presets with their names.


----------



## labayne (Jun 7, 2022)

glikely said:


> glikely submitted a new resource:
> 
> PTZ Controls - Pan Tilt Zoom camera controls for OBS
> 
> ...


I installed the addon for OBS to control a PTZ camera and I am able to pan, tilt, but I am not able to zoom in or out.  Please help in resolving this issues.


----------



## Northdiver (Jun 8, 2022)

I am wondering if there is a hotkey or hotkey combination to switch which device has focus (not optical focus, attention to accept hotkeys to make PTZ adjustments).  I am working on a project to use a Pro Micro Atmega32U4 board to emulate a keyboard along with a joystick with a pushbutton, optical encoder.  The joystick will control pan and tilt, optical encoder to control zoom, and the push button to change which camera to move.

Thanks for this wonderful plugin!


----------



## Paul74 (Jun 10, 2022)

Northdiver said:


> I am wondering if there is a hotkey or hotkey combination to switch which device has focus (not optical focus, attention to accept hotkeys to make PTZ adjustments).  I am working on a project to use a Pro Micro Atmega32U4 board to emulate a keyboard along with a joystick with a pushbutton, optical encoder.  The joystick will control pan and tilt, optical encoder to control zoom, and the push button to change which camera to move.
> 
> Thanks for this wonderful plugin!


In global settings for OBS, hotkeys, you find some hotkeys relative to PTZ, but I don't find the one to select different cameras. That would be a nice and usefull hotkey to implement indeed.


----------



## mwiggers1974 (Jun 26, 2022)

Having issue using the Controller for my USB PTZ camera.  All the settings want an IP address.  USB doesn't have IP addresses.  Any ideas?


----------



## Paul74 (Jun 27, 2022)

mwiggers1974 said:


> Having issue using the Controller for my USB PTZ camera.  All the settings want an IP address.  USB doesn't have IP addresses.  Any ideas?


There's also serial option. If your cam is USB it probably creates a virtual COM port. You then want to create a cam with the same serial COM port.


----------



## TonyKSussex (Jul 5, 2022)

We are having great success with the PTZ plugin via USB (no IP address needed - just use the plugin). I am able to set and reset the preset camera positions and to name them. I have transferred camera control to the arrow and numerical keys on the PC keyboard using the main setting function in OBS. It may be a feature of this camera but left and right are reversed - easy to fix in OBS. Zoom works with the + and - keys (setttings).  The only problems are: 1. ensuring that the camera is always mounted in the correct position, so that the presets work, and 2. not yet being able to extend the USB by means of a virtual cable over the local wi-fi link. If the camera is powered by a small 12v battery then there is only one cable, the USB cable, to worry about. Is there any way of blanking the screen automatically while panning (in OBS)?


----------



## Maxemum610 (Jul 15, 2022)

Newbie here,  G'day mate.(Hey Bro).
I have the Dahua Camera IPC-HFW71242H-Z that has an RS485 port that through the OS can control a Wiper or a Light.
I want to use this port to control a Pan Tilt Head. 
The Web3 manual  on page22 shows PelcoD, but my OS is Web5? - page 77 in that manual has the serial port config.
Having installed PTZ Control and adding the PTZ device with PelcoD it asks for the 'UART PORT' ...? What am I looking for here? How do I find it. Have I chosen the wrong configuration? Am I using the correct controller?
Thankyou


----------



## JK14 (Jul 23, 2022)

Is it also possible to control the Brio 4K with this plugin?


----------



## VicNox (Jul 24, 2022)

Hi, I currently have 2 PTZ Cameras that are working great with the software. However, I want to use the gamepad function and so I bought a Logitech Extreme 3D Pro thinking that it would be recognised as a gamepad. However, it appeared to be unable to do so. Instead, I tried emulating a XBOX 360 Controller used Xinput and  ViGEmBus to emulate it. However, even with that in place it still does not allow me to enable use of a gamepad. If you could shed some light on how to go about configuring this it would be fantastic. Thank you


----------



## twalp (Jul 25, 2022)

When I add an NDI device (SMRTAV BA30N) in PTZ Controls it is named "PTZ Device" and there's no option to rename it -- at least not that I can see.  How do I specify or change the name?


----------



## dpuckett (Jul 26, 2022)

Any chance for adding support for a DataVideo PTZ camera?  DVIP protocol?


----------



## toplachi (Jul 27, 2022)

twalp said:


> When I add an NDI device (SMRTAV BA30N) in PTZ Controls it is named "PTZ Device" and there's no option to rename it -- at least not that I can see.  How do I specify or change the name?


Try double-clicking the name


----------



## twalp (Jul 28, 2022)

That did it!  Thanks very much.


----------



## nmhammer2 (Aug 2, 2022)

Hello,

I have a camera mounted upside down. I do not see anything in the menu that says to flip the controls. Is there a way to do this in the plugin?


----------



## glikely (Aug 10, 2022)

nmhammer2 said:


> Hello,
> 
> I have a camera mounted upside down. I do not see anything in the menu that says to flip the controls. Is there a way to do this in the plugin?


There isn't at the moment. Please request the feature on GitHub:








						Build software better, together
					

GitHub is where people build software. More than 94 million people use GitHub to discover, fork, and contribute to over 330 million projects.




					github.com


----------



## nmhammer2 (Aug 12, 2022)

glikely said:


> There isn't at the moment. Please request the feature on GitHub:
> 
> 
> 
> ...


Thank you. Will do.


----------



## twalp (Aug 14, 2022)

I have a question that involves your PTZ Controls plugin. Please let me know if I should post it in another category.

Background:

Two FoMaKok NDI PTZ cameras
I have a few Scenes for each camera, and each calls a PTZ Controls preset to frame the desired shot for that scene.
OBS is in Studio view.
Let's say the Program window is showing a WS on camera 1.
In the preview window I call up a CU Preset on camera 2. I then manually reframe C2's shot  (using PTZ Controls plug-in) and cut to this Scene.
As soon as I switch back to the C1 WS to put it on Program, the Preview window changes to show C2, AND (and *here's my question*) C2 does a PTZ move back to original preset shot. My reframed shot is lost and I have to recreate it. 
This reframed shot is not normally needed so I'd rather not add it as a Preset.
I figure what's happening is that Preview auto-selects this Scene and therefore executes everything in it, including the PTZ Controls setting.

Is there a way to tell OBS to leave my custom-framed shot alone so I can return to it?


----------



## lisaroses (Aug 16, 2022)

Same problem I faced, But after some time problem automatically is fixed. Now working fine. 









						Activate Starz.com on Roku, FireStick, Apple TV, Android [Updated]
					

To watch Starz on your device, like Roku, FireTV, Apple TV, etc., you must install the Starz app and activate it at starz.com/activate.




					www.activateguide.com


----------



## toplachi (Aug 17, 2022)

twalp said:


> I have a question that involves your PTZ Controls plugin. Please let me know if I should post it in another category.
> 
> Background:
> 
> ...


Are you using the PTZ Action plug-in? Why not just disable it from C2 and manually call your preset shot when needed? Also you can opt to set a preset where you can save reframed shot just incase you feel that you're going to be needing it


----------



## twalp (Aug 25, 2022)

toplachi said:


> Are you using the PTZ Action plug-in? Why not just disable it from C2 and manually call your preset shot when needed? Also you can opt to set a preset where you can save reframed shot just incase you feel that you're going to be needing it


“PTZ Action plug-in”?  No.  “PTZ _Controls_” plug-in. And I’m trying to make the system operable by anyone. I think that when cutting away from a specially framed shot the operator should be able to return to it, without any rigmarole. But thanks for responding.


----------



## toplachi (Aug 26, 2022)

twalp said:


> I think that when cutting away from a specially framed shot the operator should be able to return to it, without any rigmarole. But thanks for responding.


Yes AFAIK that is what PTZ Control normally does, unless that framed shot was manually change or there is another automation that calls the saved preset. 

I ask about "PTZ Action" because its one of these 2 plugins that I know of that can call a certain preset and move the camera automatically. And from what I understand, your issue is about the camera getting back to that preset whenever this particular scene was in preview ---- which is not happening to mine with just the PTZ Control plugin alone.

Sorry, I am trying to understand but still a bit confused :-D


----------



## Lawrence_SoCal (Aug 26, 2022)

nmhammer2 said:


> I have a camera mounted upside down. I do not see anything in the menu that says to flip the controls. Is there a way to do this in the plugin?


The cameras I've seen have an in-camera option to rotate output (ie an orientation setting) so video output is rotated in-camera. Does your camera not have that option? And even if it doesn't your could use OBS to rotate the image. right?


----------



## Adam H. Berkey (Aug 28, 2022)

28 August 2022
Is the PTZ Control plug-in working with OBS 28 optimized for Mac M-series chips, or should I be using 27?


----------



## jbcurler2010 (Sep 1, 2022)

Is there an update for OBS 28?


----------



## ptz4ez (Sep 1, 2022)

VicNox said:


> Hi, I currently have 2 PTZ Cameras that are working great with the software. However, I want to use the gamepad function and so I bought a Logitech Extreme 3D Pro thinking that it would be recognised as a gamepad. However, it appeared to be unable to do so. Instead, I tried emulating a XBOX 360 Controller used Xinput and  ViGEmBus to emulate it. However, even with that in place it still does not allow me to enable use of a gamepad. If you could shed some light on how to go about configuring this it would be fantastic. Thank you


Hello did you ever find an answer for this?  I'm trying the same thing with joystick/gamepad controllers in order to avoid a dedicated PTZ joystick.


----------



## Paul74 (Sep 5, 2022)

I see that the new OBS 28 is not compatible with ptz controls. really hope that will be.
check here:





						OBS Studio 28 Plugin Compatibility | OBS
					

OBS Knowledge Base. This page tracks plugin compatibility with OBS Studio 28. This list is not exhaustive.




					obsproject.com


----------



## Paul74 (Sep 5, 2022)

Adam H. Berkey said:


> 28 August 2022
> Is the PTZ Control plug-in working with OBS 28 optimized for Mac M-series chips, or should I be using 27?





jbcurler2010 said:


> Is there an update for OBS 28?


not compatible at the moment:





						OBS Studio 28 Plugin Compatibility | OBS
					

OBS Knowledge Base. This page tracks plugin compatibility with OBS Studio 28. This list is not exhaustive.




					obsproject.com


----------



## DennisAllen (Sep 7, 2022)

This plugin has been extremely useful!  Really looking forward to being able to use it in OBS 28!  Will it be updated to work with the new release?  I will be rolling back to OBS 27 for now.

Thanks!


----------



## FL33543 (Sep 7, 2022)

This is such a super plugin, but OBS 28 broke it. Do you plan to update it for the new version?


----------



## Ben Anderson (Sep 8, 2022)

I'm also keen to see this updated for OBS 28. For now I'll stay on v28 and just use a browser dock with companion buttons to control my PTZ device. Not quite as good but it'll get my by for the time being.


----------



## centineo (Sep 8, 2022)

Hi,

I-m trying to control Canon CN500 it works only as VISCA-over-IP through UDP 
I couldn't control through TCP 

Someone knows if that is possible?
Regards

Ruben


----------



## FL33543 (Sep 12, 2022)

Ben Anderson said:


> I'm also keen to see this updated for OBS 28. For now I'll stay on v28 and just use a browser dock with companion buttons to control my PTZ device. Not quite as good but it'll get my by for the time being.
> 
> View attachment 86365


Are browser docs camera-specific, or is there a generic version that can work with anything? They are windowed webpage?


----------



## Ben Anderson (Sep 12, 2022)

FL33543 said:


> Are browser docs camera-specific, or is there a generic version that can work with anything? They are windowed webpage?


You have to install Bitfocus Companion: https://bitfocus.io/companion
Then integrate it with your PTZ camera. After that, you can add in the browser dock from the new web/mobile buttons section of companion.


----------



## ThomasConnolly (Sep 13, 2022)

Version 28 is a neat upgrade; alas, the PTZ control plugin isn't compatible (I wonder what new feature "broke" the plugin. Hope it's updated because it's a great plugin. Thanks.


----------



## Lawrence_SoCal (Sep 13, 2022)

ThomasConnolly said:


> (I wonder what new feature "broke" the plugin.


I don't know for sure, but an educated guess is that the well documented and discussed change to a new User Interface (and dropping 32-bit), which knowingly meant many plugins would require an update to be functional/compatible with OBS v28


----------



## Paul74 (Sep 14, 2022)

Lawrence_SoCal said:


> I don't know for sure, but an educated guess is that the well documented and discussed change to a new User Interface (and dropping 32-bit), which knowingly meant many plugins would require an update to be functional/compatible with OBS v28


yeah, most of all dropping Qt5 in favor of Qt6 for the ui framework, so no longer supporting Windows 7 & 8 and all 32-bit systems.


----------



## glikely (Sep 15, 2022)

For all of you wanting to update to OBS Studio v28, I'm working on an update of the plugin. It is currently building on MacOS and Linux, but I've got a few problems with Windows. I hope to have a test build out there soon. When I do I'll mention it here.


----------



## Paul74 (Sep 15, 2022)

ah yes thank you @glikely ! also the plugin compatibility page on the obs website is now stating "in progress" :-)


----------



## glikely (Sep 15, 2022)

Paul74 said:


> yeah, most of all dropping Qt5 in favor of Qt6 for the ui framework, so no longer supporting Windows 7 & 8 and all 32-bit systems.


It was the switch to Qt6 that caused the breakage. I had to rebase my project onto the newest version of the obs-plugintemplate tp get it building again, and I don't yet have a solution for re-enabling control via a serial port because OBS doesn't include QSerialPort in the list of libraries.


----------



## glikely (Sep 15, 2022)

First test release for v28 is out there now! If you've got some time, please give it a try and let me know how it goes.









						Release obs-ptz v0.12.0-pre2 · glikely/obs-ptz
					

First test release for OBS Studio v28 WARNING: This is not a fully functional release, and it has hardely been tested at all. It has been built on all three OSes, and it has been lightly tested on ...




					github.com
				




Note: I've not tested any of those binaries, and serial port control is disabled.


----------



## glikely (Sep 15, 2022)

glikely updated PTZ Controls with a new update entry:

First build of v28 support now available



> A first test release of the plugin that works with OBS Studio v28 is available now. This is only a test release, and a lot of stuff is still broken, but it should at least run. If you have some time and don't care if it breaks your system then please give it a try and report back here how it goes.
> 
> 
> 
> ...



Read the rest of this update entry...


----------



## youbecha (Sep 16, 2022)

I don't want to sound like I am hijacking the thread, just looking for compatible cameras to this plugin.  

Been looking at this project... We are trying to build a setup for our non-profit to stream meetings and presentations.   We don't want to (can't afford to) buy professional SDI cameras, just use IP cameras.   I understand this only works with VISCA...and I can't find any cameras below about $300 that use this protocol...are there any other camera options out there...you google VISCA and you only see 3 or so Pro camera manufacturers.


----------



## Northdiver (Sep 16, 2022)

Boy, I wish I knew that you were working to fix it before I spent all night to get it to compile with the original code.
Thanks for the great plugin!!


----------



## glikely (Sep 16, 2022)

youbecha said:


> I don't want to sound like I am hijacking the thread, just looking for compatible cameras to this plugin.
> 
> Been looking at this project... We are trying to build a setup for our non-profit to stream meetings and presentations.   We don't want to (can't afford to) buy professional SDI cameras, just use IP cameras.   I understand this only works with VISCA...and I can't find any cameras below about $300 that use this protocol...are there any other camera options out there...you google VISCA and you only see 3 or so Pro camera manufacturers.


The plugin also works with the older PELCO protocols if that helps. It can also be extended to add other protocols if you find one that works for you. ONVIF support is in progress.

For myself I'm using older Sony 1080p cameras that I got off eBay for somewhere around £400 each.


----------



## glikely (Sep 16, 2022)

Northdiver said:


> Boy, I wish I knew that you were working to fix it before I spent all night to get it to compile with the original code.
> Thanks for the great plugin!!


If you're able to build code, then I could use some help! I've got the plugin cleaned up to use the latest obs-plugintemplate, and that has made things /much/ easier to work with. However, I don't have a solution for including the QtSerialPort library on Windows or MacOS yet. If you could get that working it would be a big help


----------



## glowingmoose (Sep 21, 2022)

It seems in the later versions the VISCA over Serial has been removed, is this true? What was the last version that supported it? I user the feature exclusively...


----------



## glikely (Sep 21, 2022)

glowingmoose said:


> It seems in the later versions the VISCA over Serial has been removed, is this true? What was the last version that supported it? I user the feature exclusively...


VISCA over serial is temporarily disabled due to the changes I had to make to the build infrastructure. I've got it working again in the Linux build, but MacOS and Windows still requires some work.


----------



## glikely (Sep 24, 2022)

glikely updated PTZ Controls with a new update entry:

obs-ptz v0.12.0-pre5



> This is another test release. I do not recommend using it in a production environment, but please do test and let me know how it is working. Serial port support has been turned on again, so it will work for your VISCA over UART and PELCO devices.



Read the rest of this update entry...


----------



## Sasksavoy (Sep 25, 2022)

I used v0.12.0-pre5 today via Visca over serial.  It worked great!  

(I even used it in production)


----------



## glikely (Sep 25, 2022)

Sasksavoy said:


> I used v0.12.0-pre5 today via Visca over serial.  It worked great!
> 
> (I even used it in production)


Brave! I've not even done that yet.


----------



## Emmandi (Sep 28, 2022)

Please add ONVIF protocol


----------



## glikely (Sep 29, 2022)

Emmandi said:


> Please add ONVIF protocol


Basic ONVIF support has been implemented, but it is currently disabled because it has some major problems that need to be resolved before it is safe to use. I will need some help on the code before it can be enabled in the release builds.


----------



## Emmandi (Sep 29, 2022)

glikely said:


> Basic ONVIF support has been implemented, but it is currently disabled because it has some major problems that need to be resolved before it is safe to use. I will need some help on the code before it can be enabled in the release builds.


When can we expect a working version ??


----------



## FL33543 (Sep 30, 2022)

Gamepad question...
Is there a trick to getting the gamepad controls to work? I enable gamepad, but nothing seems to happen when I use it. Trying to use a Logitech joystick.


----------



## glikely (Oct 1, 2022)

FL33543 said:


> Gamepad question...
> Is there a trick to getting the gamepad controls to work? I enable gamepad, but nothing seems to happen when I use it. Trying to use a Logitech joystick.


Gamepad support is completely broken on Windows, and has been removed in the latest release


----------



## glikely (Oct 1, 2022)

Emmandi said:


> When can we expect a working version ??


There is no schedule. It will get fixed when someone (probably not me) provides a patch to get it working properly


----------



## obs2210 (Oct 9, 2022)

Is this plugin already compatible with the Apple Silicon version of obs software?


----------



## glikely (Oct 9, 2022)

obs2210 said:


> Is this plugin already compatible with the Apple Silicon version of obs software?


Yes. I'm testing the v0.12.0 pre release builds on an M1 MacBook Pro in both MacOS and Linux. Please try it out and let me know how it works for you


----------



## obs2210 (Oct 10, 2022)

That sounds great. 
I don‘t have an Apple Silicon device at the moment but I‘m planning to buy a MacBook as a new mobile streaming device.


----------



## fabioferraribr (Oct 14, 2022)

I have made a Visca TCP server for ptz webcams running on windows/linux. I'm using this OBS PTZ and controlling my ptzs with this server.








						GitHub - quartzo/webcam-visca-ip: Visca IP protocol for USB PTZ WebCam in Windows/Linux
					

Visca IP protocol for USB PTZ WebCam in Windows/Linux - GitHub - quartzo/webcam-visca-ip: Visca IP protocol for USB PTZ WebCam in Windows/Linux




					github.com


----------



## obs2210 (Oct 29, 2022)

Has anyone experience with controlling old Cisco Tandberg conference cams with this plugin? I got a TTC8-02 cam (without codec. I‘m controlling direct via VISCA). Manual PTZ actions are working great but I can‘t save or call presets. And there is another weird behavior with these cams: the speed setting for pan and tilt is only taken into account if the ‘IR Off‘ command is sent before. I hoped that I can send that command via PuTTY (or any other serial console) after booting the camera (the command lasts till reboot) but that doesn‘t work. Maybe someone else had this problem before.


----------



## centineo (Nov 1, 2022)

Hi to all,
trying to install PTZ plugin in a Mac Studio with Ventura, OBS  28.1 
If I install for any user it don't show in OBS if I install only for me, the OBS crashes at open 
Tried Mac-universal and Mac-ARM - obs-ptz v0.12.0-pre5
some one have any idea of solutions

Ruben


----------



## AmyGM (Nov 4, 2022)

This is my first time posting, so if I'm posting in the wrong place, let me know. The only option I have is "Post Reply" but I'm not replying to anyone. We are using the PTZ Controls plug-in with our Prisual 20X 1080P NDI PTZ camera. The camera is connected to the laptop via a switcher and cable. We are still using OBS Studio 27.2.4. Over the last couple of weeks we've had an issue with a camera view which is not a preset randomly showing up instead of the preset when we switch scenes in Preview. Once it may have actually happened in the middle of a scene (the tech person was not at the computer at the time). This only happens when we are livestreaming. Thoughts on what's going on?


----------



## glikely (Nov 5, 2022)

centineo said:


> Hi to all,
> trying to install PTZ plugin in a Mac Studio with Ventura, OBS  28.1
> If I install for any user it don't show in OBS if I install only for me, the OBS crashes at open
> Tried Mac-universal and Mac-ARM - obs-ptz v0.12.0-pre5
> ...


Please try v0.12.0-rc3 and let me know how it works.









						Release obs-ptz v0.12.0-rc3 · glikely/obs-ptz
					

Checksums obs-ptz-v0.12.0-rc3-linux-x86_64.deb: e6f9a9dd81652c331d93ab38e163bd65571d3a78bb67f00f51becb43d96ef401 obs-ptz-v0.12.0-rc3-macos-arm64.pkg: 240a2d35e227116b24d00e984802c9f4603d6cacf93a546...




					github.com


----------



## glikely (Nov 5, 2022)

AmyGM said:


> This is my first time posting, so if I'm posting in the wrong place, let me know. The only option I have is "Post Reply" but I'm not replying to anyone. We are using the PTZ Controls plug-in with our Prisual 20X 1080P NDI PTZ camera. The camera is connected to the laptop via a switcher and cable. We are still using OBS Studio 27.2.4. Over the last couple of weeks we've had an issue with a camera view which is not a preset randomly showing up instead of the preset when we switch scenes in Preview. Once it may have actually happened in the middle of a scene (the tech person was not at the computer at the time). This only happens when we are livestreaming. Thoughts on what's going on?


No idea what this could be. Can you please open an issue on GitHub and attach the obs log file showing when the wrong camera view is shown?









						Issues · glikely/obs-ptz
					

OBS Pan Tilt Zoom camera control plugin. Contribute to glikely/obs-ptz development by creating an account on GitHub.




					github.com


----------



## Jodi Sankev (Nov 5, 2022)

FL33543 said:


> Gamepad question...
> Is there a trick to getting the gamepad controls to work? I enable gamepad, but nothing seems to happen when I use it. Trying to use a Logitech joystick.





FL33543 said:


> Gamepad question...
> Is there a trick to getting the gamepad controls to work? I enable gamepad, but nothing seems to happen when I use it. Trying to use a Logitech joystick.


Try if you van use 
AntiMicroX​I use this for several tasks in OBS


----------



## glikely (Nov 6, 2022)

glikely updated PTZ Controls with a new update entry:

OBS PTZ Controls v0.12.0



> I've just released v0.12.0 which works with OBS Studio v28. Lots of bug fixes and tweaks in this one, plus binaries for MacOS, Windows and Linux. You can find the full release notes on GitHub here. Please test and report back.



Read the rest of this update entry...


----------



## BCFischer (Nov 8, 2022)

@glikely :

This is a great plugin and you have done a lot of work to get it V28.x ready.

I use it to control 2 Canon CR-N300 ptz cameras via VISCA over IP and it works well. Any thoughts about adding the Canon XC Protocol to the list of selectable protocols?

Thanks, take care, and stay safe,

Brian


----------



## glikely (Nov 9, 2022)

BCFischer said:


> @glikely :
> 
> This is a great plugin and you have done a lot of work to get it V28.x ready.
> 
> ...


Thanks Brian. I’m glad it is working well for you.

I’m not using any Canon hardware myself, but I’m happy to include support for other protocols, if someone does the work to enable it. Patches can be sent to me with a GitHub pull request.

To get things started, please file a feature request here and include any details you can provide about the Canon XC protocol.


----------



## AmyGM (Nov 12, 2022)

Two days ago I updated OBS to the latest version and this morning updated to the most recent PTZ Controls v.0.12.1. When I start up OBS, it says the plug in failed to load. 
Here's the log. 


			https://obsproject.com/logs/0RRn10N5OMAkNJXI
		

I'm going to be in a bind for our worship stream tomorrow if I can't get this figured out. I guess a solution is to return to previous versions of OBS and PTZ controls, but I was updating in order to work out bugs (random unset PTZ views showing up during livestreams). Do I need to set up an entirely new OBS profile and start over on everything?

In the future, if we have the random view problem, I will know how to find the log, but at this point that log is long gone, it seems.


----------



## glikely (Nov 12, 2022)

Thanks for filing a bug report on this one. As I replied there, you've got both the old and new versions of the plugin installed. Delete ptz-controls.dll from the plugin directory and the error message should go away. The log shows that the new version is loading fine.

I hope that gets you sorted for tomorrow morning.


----------



## glikely (Nov 13, 2022)

glikely updated PTZ Controls with a new update entry:

v0.12.2 Bug Fix Release



> This is a minor bug fix release. It fixes toolbar controls that weren't working, and it fixes the Windows installer to remove old versions of the plugin so that an error message isn't shown when OBS starts.



Read the rest of this update entry...


----------



## Steeled_Pick (Nov 14, 2022)

Is it possible to add RTSP?


----------



## glikely (Nov 15, 2022)

Steeled_Pick said:


> Is it possible to add RTSP?


As far as I'm aware, RTSP doesn't do PTZ. I've only seen RTSP cameras being controlled with VISCA over IP, which the plugin does support.


----------



## Cal0209 (Nov 16, 2022)

Is there any plans to support PTZ camera's that use CGI web commands? An example camera is a Sony IPELA SNC-EP550 network camera which I use in my production that uses CGI. Unfortuantely I don't think it supports VISCA over IP, which is a shame.


----------



## glikely (Nov 16, 2022)

Cal0209 said:


> Is there any plans to support PTZ camera's that use CGI web commands? An example camera is a Sony IPELA SNC-EP550 network camera which I use in my production that uses CGI. Unfortuantely I don't think it supports VISCA over IP, which is a shame.


Adding ONVIF support is on the todo list, but I don't have any of that hardware, so I'm depending on others to get it working.


----------



## glikely (Nov 18, 2022)

I've just tagged a test release, v0.13.0-test1, with a bunch of internal fixes, some new hot keys, and a way to block live moves on PTZ action sources. Because some of the changes are invasive, I’d like to get some testing before I release for real.

Please test and let me know how it works for you.









						Release obs-ptz v0.13.0-test1 · glikely/obs-ptz
					

Checksums obs-ptz-v0.13.0-test1-linux-x86_64.deb: cf8057d2df3dfc736a1bf97b7c8b8651742ab77c4f7302bf551bb7c23003fcf4 obs-ptz-v0.13.0-test1-macos-arm64.pkg: baba55e90a1d1e2107854ce5bdc952a49cb691739b3...




					github.com


----------



## dzurn (Nov 20, 2022)

I've tried a dozen times to install the PTZ Controls on Win10 64-bit PC, running as Admin each time with OBS closed (AFAIK). 

The PTZ Control installer (obs-ptz-v0.12.2-windows-x64-Installer) claims success, and there are two "obs-ptz" pieces in the plugins folder, but it hasn't worked according to the log files. 

I updated OBS to 27.2, but that hasn't helped.

13:57:33.462: Skipping module '../../obs-plugins/64bit/libGLESv2.dll', not an OBS plugin​13:57:33.486: [obs-browser]: Version 2.17.13​13:57:33.486: [obs-browser]: CEF Version 95.0.0-MediaHandler.2467+g8092a57+chromium-95.0.4638.69​13:57:33.503: NVENC supported​13:57:33.504: [noise suppress]: NVIDIA RTX denoiser disabled, redistributable not found​13:57:33.526: *LoadLibrary failed for '../../obs-plugins/64bit/obs-ptz.dll': **The specified module could not be found.*​13:57:33.526:  (126)​13:57:33.526: *Module '../../obs-plugins/64bit/obs-ptz.dll' not loaded*​13:57:33.613: [obs-websocket] you can haz websockets (version 4.9.1)​13:57:33.613: [obs-websocket] qt version (compile-time): 5.15.2 ; qt version (run-time): 5.15.2​13:57:33.614: [obs-websocket] module loaded!​13:57:33.628: Skipping module '../../obs-plugins/64bit/Qt6SerialPort.dll', not an OBS plugin​
 I don't have any "obs-ptz" folder in the plugin-config directory either.





Any help is appreciated.

Thanks


----------



## glikely (Nov 20, 2022)

dzurn said:


> I've tried a dozen times to install the PTZ Controls on Win10 64-bit PC, running as Admin each time with OBS closed (AFAIK).
> 
> The PTZ Control installer (obs-ptz-v0.12.2-windows-x64-Installer) claims success, and there are two "obs-ptz" pieces in the plugins folder, but it hasn't worked according to the log files.
> 
> I updated OBS to 27.2, but that hasn't helped.


The released v0.12.2 binaries only work with OBS studio v28 or higher


----------



## JanGVH (Nov 23, 2022)

@glikely

First of all, thanks for this camera control.

I have three comments for the wish list:
I scale the camera control UI to a certain spot on my screen.
I would like it if it came back there when reopening the plugin.

When choosing another preset I have to double-click.
this is difficult with a quick scene change.
can that be a single click?

This question is getting really cheeky, but I'll ask it anyway!
With a preset change, the camera now moves per axis to the next setting.
can it be interpolated?

(just to be clear, this is how I know it with a robot:
with an interpolating movement, the largest axis movement is leading.
that movement is divided into steps. With more steps, the movement becomes smoother.
the other axes move in proportion to allow smooth movement to the new preset point. The movement between the different preset points is calculated in advance and laid out in a table.)

I'll see if I can beta test for you.
Thanks and best regards,
Jan Groeneveld


----------



## glikely (Nov 23, 2022)

JanGVH said:


> @glikely
> 
> First of all, thanks for this camera control.


I'm glad it is working well for you.


JanGVH said:


> I have three comments for the wish list:
> I scale the camera control UI to a certain spot on my screen.
> I would like it if it came back there when reopening the plugin.


That is a good suggestion. Please add a feature request on GitHub to track this. You can file issues at https://github.com/glikely/obs-ptz/issues


JanGVH said:


> When choosing another preset I have to double-click.
> this is difficult with a quick scene change.
> can that be a single click?


I've avoided making it single click to protect against accidental recalls when selecting a preset to update it. On PC/Linux this is less of an issue because the context menu can be called up with a right click, but on Mac that's not very user friendly.

One possible solution is to add an activate button within the list item so that selecting doesn't activate, but clicking the embedded button does. As with the above, please file a feature request on GitHub to track.


JanGVH said:


> This question is getting really cheeky, but I'll ask it anyway!
> With a preset change, the camera now moves per axis to the next setting.
> can it be interpolated?
> 
> ...


This isn't so easy because the controller doesn't manage the preset moves, or even track where the preset points to. The controller just tells the camera which preset to recall. The position information is stored by the camera, and it decides how to move there. Many PTZ cameras do perform a smooth diagonal move (e.g., the Sony SRG-120DH that I use), but others do not.

Interpolating would require rearchitecting presets to be stored by the controller, and then sending interpolated move commands. However even that would not be very smooth because the camera would stop at each interpolation point. It would be quite a jerky transition.


JanGVH said:


> I'll see if I can beta test for you.


Much appreciated. Thanks!


----------



## JanGVH (Nov 26, 2022)

@glikely,
Thanks for the super fast response!
I've added the first two questions to the request list.
I will now return to the third.
my little problem can be solved if there is a possibility to run a chain of presets.
then I can run preset1 - preset1 zoomed out – preset2 zoomed out- preset2
or 
preset1 – waypoint1 – waypoint2 - preset2.

Would this be possible?
Thanks again for all your work!
Jan


----------



## glikely (Nov 29, 2022)

JanGVH said:


> @glikely,
> Thanks for the super fast response!
> I've added the first two questions to the request list.
> I will now return to the third.
> ...



It would be possible, but I think there is a better way. The PTZ action source is kind of a clunky way to make things happen, and it doesn't at all integrate with other non-PTZ actions that a user might want to do. Instead, I want to look into the Advanced Scene Switcher, and see if I can get PTZ actions added to that plugin. If so, then you'd be able to chain up as many actions as you like, PTZ or otherwise, do to what you need.
Does that sound workable?


----------



## kpdillon (Nov 29, 2022)

glikely said:


> glikely submitted a new resource:
> 
> PTZ Controls - Pan Tilt Zoom camera controls for OBS
> 
> ...


This is working, but I have 6 PTZ cameras.  I am confused by the statement "and can automatically change selected camera based on the currently active preview or program scene.".  When I change the scene is the joystick control automatically supposed to change to that camera?  If so, how?  Right now I have to select the PTZ device manually after changing the scene.


----------



## glikely (Nov 29, 2022)

kpdillon said:


> This is working, but I have 6 PTZ cameras.  I am confused by the statement "and can automatically change selected camera based on the currently active preview or program scene.".  When I change the scene is the joystick control automatically supposed to change to that camera?  If so, how?  Right now I have to select the PTZ device manually after changing the scene.


Give the PTZ device exactly the same name as the source it is attached to, and click either the 'PRE' or 'LIVE' button at the bottom of the controls dock. Automatic camera selection should then start working.

This is all a bit hacky and unintuitive though. I am planning to add the associated source to the settings dialog so the that name doesn't need to be identical


----------



## kpdillon (Nov 29, 2022)

glikely said:


> Give the PTZ device exactly the same name as the source it is attached to, and click either the 'PRE' or 'LIVE' button at the bottom of the controls dock. Automatic camera selection should then start working.
> 
> This is all a bit hacky and unintuitive though. I am planning to add the associated source to the settings dialog so the that name doesn't need to be identical


Thank you, that is working... Is it possible to get the preview scene to change then I select the PTZ device from your plugin?


----------



## glikely (Nov 29, 2022)

kpdillon said:


> Thank you, that is working... Is it possible to get the preview scene to change then I select the PTZ device from your plugin?


I’m not following what you mean. Can you describe the behaviour your looking for in more detail?


----------



## kpdillon (Nov 29, 2022)

glikely said:


> I’m not following what you mean. Can you describe the behaviour your looking for in more detail?


In your widget, I would like to be able to select a PTZ camera and have the preview window change when I select that camera.  Just trying to minimize the # of things I need to click when I change between 6 different cameras.


----------



## glikely (Nov 29, 2022)

kpdillon said:


> In your widget, I would like to be able to select a PTZ camera and have the preview window change when I select that camera.  Just trying to minimize the # of things I need to click when I change between 6 different cameras.


Ah, I understand now. I’ll experiment with that, but it is a little complex to do well because a camera may be in multiple scenes, and it won’t be clear which one should be selected to preview.

Just curious, how would that reduce the number of clicks? When automatic camera selection is working I only need to click once on the camera scene, and then the PTZ controls are active for that camera. How does clicking on the PTZ device instead of the scene improve things?


----------



## Randomdude (Nov 30, 2022)

Hi,
I have my CCTV cameras connected to DVR via coax cable. The DVR has an IP address etc and is on LAN (local network). The DVR has a username name and password etc but i can view the feeds easily enough via VLC/OBS/android etc using RTSP URLS with username and password in the TRSP url. I have installed and added the PTZ controls dock to OBS and tried configuring the cameras with VISCO-over-IP connection but I can get it to work. I suspect it is due to the DVRs username and password. Any ideas on how I can tackle this? thanks in advance. Great plugin by the way.


----------



## Randomdude (Nov 30, 2022)

Randomdude said:


> Hi,
> I have my CCTV cameras connected to DVR via coax cable. The DVR has an IP address etc and is on LAN (local network). The DVR has a username name and password etc but i can view the feeds easily enough via VLC/OBS/android etc using RTSP URLS with username and password in the TRSP url. I have installed and added the PTZ controls dock to OBS and tried configuring the cameras with VISCO-over-IP connection but I can get it to work. I suspect it is due to the DVRs username and password. Any ideas on how I can tackle this? thanks in advance. Great plugin by the way.


I think I now see the answer to my question above in post about PTZ over RTSP URL not being supported. I thought I saw someone elsewhere on the web getting something working outside OBS. Ill take another look at options.


----------



## kpdillon (Nov 30, 2022)

glikely said:


> Ah, I understand now. I’ll experiment with that, but it is a little complex to do well because a camera may be in multiple scenes, and it won’t be clear which one should be selected to preview.
> 
> Just curious, how would that reduce the number of clicks? When automatic camera selection is working I only need to click once on the camera scene, and then the PTZ controls are active for that camera. How does clicking on the PTZ device instead of the scene improve things?


I guess it also comes down to distance of clicking a scene and then moving back to the joystick.  Currently I use a separate program (PTZ Optics App) and I select the camera.  When I select the camera it would be great if the preview displayed that corresponding scene and then I could either just control the joystick or select a preset then hit the fade button.  Would be so much better from a usability point of view.  Also, if you can play with adjusting your layout so that it is similar to the ptz optics app - would make it so easy to use!


----------



## glikely (Dec 2, 2022)

kpdillon said:


> I guess it also comes down to distance of clicking a scene and then moving back to the joystick.  Currently I use a separate program (PTZ Optics App) and I select the camera.  When I select the camera it would be great if the preview displayed that corresponding scene and then I could either just control the joystick or select a preset then hit the fade button.  Would be so much better from a usability point of view.



Ah, I see what you're asking. I've generally got the window set up so that the PTZ controls are right beside the scene & source selection, so there isn't such a great distance:







kpdillon said:


> Also, if you can play with adjusting your layout so that it is similar to the ptz optics app - would make it so easy to use!View attachment 89307



I've avoided matching the layout of other controllers, both to avoid simply copying other work, and I'm not convinced it is the best use of space. I wanted the most used buttons right at the top of the dock so that they are the first things seen. I want to experiment with removing the device list entirely as it doesn't add any functionality that isn't already there by clicking on a scene or a source.

The preset list does need a lot of work. Right now they are fixed to camera presets, but I want to store presets locally on the controller end so that predefined sets can be saved/restored, and so that I can get thumbnails of the scene when the preset is stored.


----------



## glikely (Dec 2, 2022)

glikely updated PTZ Controls with a new update entry:

OBS PTZ Controls v0.13.0



> Another release for you to go and try. The big change in this release is speed ramping on the controls. The speed slider has been removed entirely and the speed of movements starts small, and ramps up the longer the button is held down. This behaviour appears to be more user-friendly, but I would like to have feedback on how it is working.
> 
> The other big change is in how a PTZ device is associated with an OBS source. Instead of having to manually name the PTZ device exactly the same as the...



Read the rest of this update entry...


----------



## cyberfrank101 (Dec 2, 2022)

hello, i have tried, but i can't  find the ptz control dock in obs :-(


----------



## EB123 (Dec 3, 2022)

the speed ramping stuff looks good.. unfortunately i cant test anything for a while, but just wanted to mention that it would be great if the user could set a max speed that you ramp up to..  also some curve options would be good to determine take off speeds..  does it ramp down also ? if not that would be good as well... more than anything the ability to set max speed would be most useful..

how does this feature perform so far with cameras ? ive heard vMix developers say that they couldnt add ramp speeds because PTZ motors arent sensitive enough or something ? it would be awesome if PTZ could be made to look less like a security camera and bit more cinematic.. speed ramping is a great start towards that..


----------



## glikely (Dec 3, 2022)

cyberfrank101 said:


> hello, i have tried, but i can't  find the ptz control dock in obs :-(


The option to show the dock should appear in the Docks menu. What version of OBS are you using, and what version of the plug-in?


----------



## glikely (Dec 3, 2022)

EB123 said:


> the speed ramping stuff looks good.. unfortunately i cant test anything for a while, but just wanted to mention that it would be great if the user could set a max speed that you ramp up to..  also some curve options would be good to determine take off speeds..  does it ramp down also ? if not that would be good as well... more than anything the ability to set max speed would be most useful..


A related issue is that every camera seems to accept a different ranges of distance speeds, so I need to add some options to make those options configurable. Hopefully that will also give you the speed limit you want. Right now the ramp is simply linear from 0 to full speed over 2s, and does not ramp down. If found that so far I want the camera to stop immediately when the button is released, instead of carrying on past the point. The cameras I have (Sony SRG-120DH) have enough inertia and slack that they still carry on a bit anyway.

I‘ve got some prototype gamepad support in my tree from DragonRhythm that may be a more intuitive way to get smooth ramps that aren’t fixed to the 8 button directions.

Another possibility would be to implement pre-recorded sequences of moves that can be played back by a preset.


EB123 said:


> how does this feature perform so far with cameras ? ive heard vMix developers say that they couldnt add ramp speeds because PTZ motors arent sensitive enough or something ? it would be awesome if PTZ could be made to look less like a security camera and bit more cinematic.. speed ramping is a great start towards that..


So far it works great! The frontend code updates the speed every 100ms which appears to be frequent enough to be responsive. VISCA camera are limited to 32 speeds, which isn’t a lot of resolution, but it seems to be enough. NDI and ONVIF cameras accept floating point speed values, and so may have higher resolution, but I’ve not implemented either of those backends yet. I don’t know the issue the vMix developers may have run into.


----------



## EB123 (Dec 3, 2022)

glikely said:


> A related issue is that every camera seems to accept a different ranges of distance speeds, so I need to add some options to make those options configurable. Hopefully that will also give you the speed limit you want. Right now the ramp is simply linear from 0 to full speed over 2s, and does not ramp down. If found that so far I want the camera to stop immediately when the button is released, instead of carrying on past the point. The cameras I have (Sony SRG-120DH) have enough inertia and slack that they still carry on a bit anyway.


nice... if its possible to have control of max speed that would be great... also any chance to make the time to ramp up configurable ? if you have 2 secs now but the user wants slower they could make it 3 or 4 secs ? with this feature i always envisaged it would be a fairly slow ramp up as user starts to move camera and then a ramp down would be a fairly fast, maybe 1 sec or less..  just enough to remove the jerky security camera look that some PTZ have.. if there is any chance to eventually have both up/down with user configurable settings that would be really great..

the 100ms and 32 steps resolution seems OK (from what i envisage).. also the idea to record sequences would be awesome as well..  would add a lot of creative possibilities... thanks for adding this feature.


----------



## jswager (Dec 5, 2022)

Hello - using obs-ptz and it's working just fine with our Birddog P400. Thank you for the most useful tool!

Is obs-ptz compatible with obs-websocket, such that a command could be set via obs-websocket and execute PTZ commands?  The "Preset" commands would be most useful.


----------



## dqm (Dec 5, 2022)

Love this plugin, but need some help.  But first, I'm not ready to upgrade to obs 28 yet and I am wondering if versions 12 and 13 are backward compatible.  

The slider speed control gives me fits; wondering if you can help. Let my try to explain my difficulty. 

I usually need a very slow speed.  To that end, I move the slider way down. How far to move it is a guestimate, and if I go too far, I don't get any pan/tilt at all.  So, I nudge it upward until I get the slow movement I need.  But then I don't have any zoom.  If I speed it up enough to get a slow zoom, then the pan/tilt movement is too fast.  The continual slider adjustments needed render your dock too difficult for both pannning and zooming.  Not to mention multiple cameras that respond to the speed adjustments differently. 

I need independent speed controls, preferably remembered across obs restarts.

I understand newer versions have replaced the slider with a ramping mechanism.  I suppose it's worth a try, but seems like tuning the ramping response for different needs would be a can of worms.


----------



## glikely (Dec 5, 2022)

dqm said:


> Love this plugin, but need some help.  But first, I'm not ready to upgrade to obs 28 yet and I am wondering if versions 12 and 13 are backward compatible.


Theoretically, the code will build against OBS v27, but I haven't spent any time trying to do so. I'd be happy to take patches that fix build problems against v27.


dqm said:


> The slider speed control gives me fits; wondering if you can help. Let my try to explain my difficulty.
> 
> I usually need a very slow speed.  To that end, I move the slider way down. How far to move it is a guestimate, and if I go too far, I don't get any pan/tilt at all.  So, I nudge it upward until I get the slow movement I need.  But then I don't have any zoom.  If I speed it up enough to get a slow zoom, then the pan/tilt movement is too fast.


The speed slider code in the versions before v0.13 was very buggy, so I'm not surprised it gave you problems. It didn't work well on my system either.


dqm said:


> The continual slider adjustments needed render your dock too difficult for both pannning and zooming.  Not to mention multiple cameras that respond to the speed adjustments differently.
> 
> I need independent speed controls, preferably remembered across obs restarts.
> 
> I understand newer versions have replaced the slider with a ramping mechanism.  I suppose it's worth a try, but seems like tuning the ramping response for different needs would be a can of worms.


Independent controls are possible, but I've got a few more back-end architecture changes that I need to make before I can start looking at that. However, please give the new version a try. I find the ramped speed mechanism is far more functional that the manual speed control ever was, and it may provide the control you need without doing per camera configuration.


----------



## glikely (Dec 5, 2022)

jswager said:


> Hello - using obs-ptz and it's working just fine with our Birddog P400. Thank you for the most useful tool!
> 
> Is obs-ptz compatible with obs-websocket, such that a command could be set via obs-websocket and execute PTZ commands?  The "Preset" commands would be most useful.


It isn't yet. I do want to add that feature, but I haven't spent any time working on it yet.


----------



## dqm (Dec 8, 2022)

glikely said:


> Theoretically, the code will build against OBS v27, but I haven't spent any time trying to do so. I'd be happy to take patches that fix build problems against v27.
> 
> The speed slider code in the versions before v0.13 was very buggy, so I'm not surprised it gave you problems. It didn't work well on my system either.
> 
> Independent controls are possible, but I've got a few more back-end architecture changes that I need to make before I can start looking at that. However, please give the new version a try. I find the ramped speed mechanism is far more functional that the manual speed control ever was, and it may provide the control you need without doing per camera configuration.


v.13 installs without error but does not load on obs v27.   See attached log.


----------



## DUbstratus (Dec 8, 2022)

Hello, I am new to obs and I can’t say thank you enough for the pts plug in. I recently bought a cheap ptz cam for streaming meetings and having the ptz controls really made a difference. I am having an issue with the controls in that I can get all of the corner controls to move the cam (slow fade in that direction until it maxes out) but left right up and down doesn’t work. I was able to configure presets using the settings sliders. This was adequate for our last meeting but I would like to be able to pan live if needed without using the jumpy sliders. Just curious if anyone else has run into this issue? I am using a jimcom jm810 camera VISCA over serial connection (usb) nay insight would be great.


----------



## glikely (Dec 8, 2022)

dqm said:


> v.13 installs without error but does not load on obs v27.   See attached log.


Yes, that is expected. The released binaries only works with v28 or later.


----------



## toplachi (Dec 9, 2022)

glikely said:


> glikely updated PTZ Controls with a new update entry:
> 
> OBS PTZ Controls v0.13.0
> 
> ...


I am very eager to test this version with speed ramping, unfortunately I don't have the time yet aside from I am still not upgrading to OBS28.
The face tracking plugin seems to have this feature, which looks more like a natural movement than my hands controlling the camera thru the keyboard, but that is as long as I keep the camera not too far from my subject.

Another good feature that might also be a challenge to implement is to able to move the camera diagonally by combining the vertical and horizontal keyboard shortcuts simultaneously


----------



## dqm (Dec 9, 2022)

glikely said:


> Yes, that is expected. The released binaries only works with v28 or later.


How did I miss that???  My time is probably better spent migrating to V28, anyway...just hesitating because some plugins are not supported yet.


glikely said:


> The preset list does need a lot of work. Right now they are fixed to camera presets, but I want to store presets locally on the controller end so that predefined sets can be saved/restored, and so that I can get thumbnails of the scene when the preset is stored.



If by "storing the presets locally" you mean storing the coordinates, I urge caution.  Users must then manage two preset schemes that are immensely challenging to keep in sync.  It also adds difficulty to workflow integration with other PTZ control mechansisms, for example, sources that position the camera when a scene is activated.


----------



## z0mgitsjared (Dec 17, 2022)

Thanks for the plugin, I got a Tenveo NV20A cam and I've connected it via serial to usb to a computer, but the PTZ controls are moving it twice as much as I expect.  One click on the zoom in/out results in it moving 2x, so zooming in from 2x to 4x or 8x to 10x.  Moving in any direction has the same result, it moves about twice as much as it does with the camera's original remote. 

This is with v0.13, I haven't tried a previous version yet to see if this is something new with that version.  Is there any place we can configure how far the camera travels?

No rush, my work around in the meantime is to use the camera remote to position the camera and then save it as a preset.  Not the best but it'll get us through week to week.


----------



## feee (Dec 19, 2022)

I have inadvertently adjusted live PTZ camera many times, so I welcomed the lock out for live PTZ but I do missed not been able to quickly adjust the live PTZ when needed.  May I request a hotkey pressed in order to move the live PTZ slowly.

Thank you


----------



## dqm (Dec 19, 2022)

glikely said:


> Ah, I understand now. I’ll experiment with that, but it is a little complex to do well because a camera may be in multiple scenes, and it won’t be clear which one should be selected to preview.


It would be fairly trivial to add a "preferred scene" setting to the device configuration.  That said, the real complextity  would be distinguishing between a click to simply change cameras and one to also issue the scene change so that OBS "follows" the change.


----------



## dqm (Dec 19, 2022)

I understand that you've previously contemplated starting with an empty preset list that can be maintained similar to the Scene and Source lists. This would allow fewer/more presets and flexible ordering.  While I upvote that idea, I'd like to propose taking it to the next level.

What I had in mind was refactoring the preset list as an "action" list, supporting multiple action types, each action type configurable with the supporting values it needs. Calling a preset would, of course, be one action type, supported by a configurable preset number.  A second action type, which sort of drives this proposal, would be calling a scene, supported by the scene name. Given the complexity with which scenes can be constructed, this would be an enormously powerful feature.  For example, it would enable camera changes with transitions from the ptz control pad. (Confession: calling raw presets without transititons to mask gross camera movements is too risky for my workflow.)

One can imagine other action types with potential for lots of extensibility.  Think about an action type that issues a generic camera command, configurable in the settings.  Or many OBS commands, for that matter (though I urge caution about getting too distant from camera control). Down the road, one could even support a multi-step action type--one that issues a sequence of actions, similar to what Stream Deck and Companion support.

Finally, think about the relationship between an item in a device's action list and the action that it invokes.  In its simplest form (as with presets now), it's 1-1. In other words, each item invokes a single action and that action is associated with a single item. With the mult-action feature mentioned above, that relationship becomes 1-many: one item invokes multiple actions, but each action is still associated with only one item in the list. The most robust design is many-many.  That means separating device settings from action settings in your underlying configuration structure. Then, the same action can be used for multiple devices. For example, an action for "call preset 1", could be assigned to any or all cameras. Or, invoked in other ways--like by assigning it to one of the buttons under direction arrows. FWIW, the relationship between Scenes and Sources follows that design principle.


----------



## Batson Video (Jan 1, 2023)

glikely said:


> glikely submitted a new resource:
> 
> PTZ Controls - Pan Tilt Zoom camera controls for OBS
> 
> ...


i have updated to 28 and we have some controlling back for our ptz camera. the arrows for up down left right will not work and lost the speed control. how can i fix this so all the controls work in obs? i can email picture of what the controls look like if needed


----------



## dqm (Jan 5, 2023)

Batson Video said:


> i have updated to 28 and we have some controlling back for our ptz camera. the arrows for up down left right will not work and lost the speed control. how can i fix this so all the controls work in obs? i can email picture of what the controls look like if needed


I believe the speed control is gone by design: replaced by algorythm that gradually increases the speed the longer you hold the button down.  The arrows may be working, only slowly.  Hold the button down longer to see if the pan/tilt speed ramps up.


----------



## glikely (Sunday at 12:54 PM)

dqm said:


> I believe the speed control is gone by design: replaced by algorythm that gradually increases the speed the longer you hold the button down.  The arrows may be working, only slowly.  Hold the button down longer to see if the pan/tilt speed ramps up.


left/right/up/down no longer working is probably a separate issue. Some VISCA implementations don't behave well when told to only move in one axis. It was a quirk I had fixed before, but I probably broke it again when I overhauled the state machine. I'll see if I can get it working again.

The speed slider removal is indeed by design, but it has caused regressions or unworkable behaviour for some cameras. I'm going to add configuration options to limit the minimum and maximum move speeds.

For anyone having trouble with the latest version I recommend going back to v0.12.2 until I can get the speed ramp to be more usable


----------



## glikely (Sunday at 4:24 PM)

Hi dqm. Thanks for the feedback. Comments below...


dqm said:


> I understand that you've previously contemplated starting with an empty preset list that can be maintained similar to the Scene and Source lists. This would allow fewer/more presets and flexible ordering.  While I upvote that idea, I'd like to propose taking it to the next level.
> 
> What I had in mind was refactoring the preset list as an "action" list, supporting multiple action types, each action type configurable with the supporting values it needs. Calling a preset would, of course, be one action type, supported by a configurable preset number.  A second action type, which sort of drives this proposal, would be calling a scene, supported by the scene name. Given the complexity with which scenes can be constructed, this would be an enormously powerful feature.  For example, it would enable camera changes with transitions from the ptz control pad. (Confession: calling raw presets without transititons to mask gross camera movements is too risky for my workflow.)
> 
> One can imagine other action types with potential for lots of extensibility.  Think about an action type that issues a generic camera command, configurable in the settings.  Or many OBS commands, for that matter (though I urge caution about getting too distant from camera control). Down the road, one could even support a multi-step action type--one that issues a sequence of actions, similar to what Stream Deck and Companion support.


Great ideas, thanks! I'm concerned however that implementing these features in the PTZ plugin could make it quite limited. I've been thinking instead about exporting API hooks that can be used by the Advanced Scene Switcher, and possibly allow the plugin to trigger Advanced Scene Switcher actions since the scene switcher has far more functionality than I'll ever add to the PTZ plugin.


dqm said:


> Finally, think about the relationship between an item in a device's action list and the action that it invokes.  In its simplest form (as with presets now), it's 1-1. In other words, each item invokes a single action and that action is associated with a single item. With the mult-action feature mentioned above, that relationship becomes 1-many: one item invokes multiple actions, but each action is still associated with only one item in the list. The most robust design is many-many.  That means separating device settings from action settings in your underlying configuration structure. Then, the same action can be used for multiple devices. For example, an action for "call preset 1", could be assigned to any or all cameras. Or, invoked in other ways--like by assigning it to one of the buttons under direction arrows. FWIW, the relationship between Scenes and Sources follows that design principle.


So something like a preset triggering a named action, correct? I think this also leans towards defining the action list in a more generic tool, and then merely triggering the action from the PTZ frontend.


----------



## renancs (Monday at 5:36 PM)

Hello, its possible adapt this plugin to work with USB PTZ cameras? Like Logitec Rally? Im trying to create custon scenes in diferents places in a room, but cant figure how... i think your plugin might works, if can be customized to usb cameras.

Thnx!!


----------



## Dav0 (Tuesday at 3:32 AM)

Have been streaming a church service using OBS 27 for over 12 months using two Tenveo Cams over RS232 links. Upgraded today to OBS 29 with PTZ Controls V0.13.0. Everything good except that the cameras keep moving for 2 or 3 seconds after actuation of the up/down and zoom controls ceases. This delay did not occur in the previous configuration, and it makes the system almost unusable. Can you please advise what I can do to solve this problem, please? Should I go back to OBS 27?


----------



## Dav0 (Wednesday at 4:21 AM)

Dav0 said:


> Have been streaming a church service using OBS 27 for over 12 months using two Tenveo Cams over RS232 links. Upgraded today to OBS 29 with PTZ Controls V0.13.0. Everything good except that the cameras keep moving for 2 or 3 seconds after actuation of the up/down and zoom controls ceases. This delay did not occur in the previous configuration, and it makes the system almost unusable. Can you please advise what I can do to solve this problem, please? Should I go back to OBS 27?


I uninstalled V 0.13.0 and installed V 0.12.2 (still with OBS 29). Camera behavior has reverted to the original i.e. without the delay.


----------



## DonA.N4TH (Yesterday at 1:26 AM)

New to the forum. We've been using OBS and Zoom under Win10 at church for about a year. Since the Win11 update OBS has become unstable. I've been trying to set up an Ubuntu 22.04 environment. I have OBS 29 installed. I can't get the OBS-PTZ plugin to install, either from the .deb file or compiling from source. I'd this a known problem? Any workarounds?  Thanks.


----------



## hounddog (Yesterday at 4:10 PM)

glikely said:


> left/right/up/down no longer working is probably a separate issue. Some VISCA implementations don't behave well when told to only move in one axis. It was a quirk I had fixed before, but I probably broke it again when I overhauled the state machine. I'll see if I can get it working again.
> 
> The speed slider removal is indeed by design, but it has caused regressions or unworkable behaviour for some cameras. I'm going to add configuration options to limit the minimum and maximum move speeds.
> 
> For anyone having trouble with the latest version I recommend going back to v0.12.2 until I can get the speed ramp to be more usable


The speed ramping was a great upgrade, but I do also miss the speed slider and am glad to hear your thinking of adding in the ability to set the min/max limits of the move speed.  Thank you for your dedication and time you give for all the updates you do !


----------

